Re: [dpdk-dev] [PATCH 2/3] ethdev: add flow item/action templates
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
Date: 2021-10-13 02:26:50
On Tue, Oct 12, 2021 at 6:25 PM Alexander Kozyrev [off-list ref] wrote:
quoted
From: Ivan Malov <redacted> On Wednesday, October 6, 2021 13:25 On 06/10/2021 07:48, Alexander Kozyrev wrote:quoted
Treating every single flow rule as a completely independent and separate entity negatively impacts the flow rules insertion rate. Oftentimes in an application, many flow rules share a common structure (the same itemmaskquoted
and/or action list) so they can be grouped and classified together. This knowledge may be used as a source of optimization by a PMD/HW. The item template defines common matching fields (the item mask)withoutquoted
values. The action template holds a list of action types that will be used together in the same rule. The specific values for items and actions will be given only during the rule creation. A table combines item and action templates along with shared flow rule attributes (group ID, priority and traffic direction). This way a PMD/HW can prepare all the resources needed for efficient flow rules creation in the datapath. To avoid any hiccups due to memory reallocation, themaximumquoted
number of flow rules is defined at table creation time. The flow rule creation is done by selecting a table, an item template and an action template (which are bound to the table), and setting unique values for the items and actions.
For the life cycle of the template - Is a template supposed to be destroyed immediately after its use? Can there be multiple templates active at a time? In which case will the application maintain the templates? And how to identify one template from another? Or that will not be needed?
quoted
quoted
Signed-off-by: Alexander Kozyrev <redacted> Suggested-by: Ori Kam <redacted> ---