DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH] net/mlx5: increase max pattern templates
@ 2024-07-01 10:26 Gregory Etelson
  2024-07-02  9:25 ` Raslan Darawsheh
  0 siblings, 1 reply; 2+ messages in thread
From: Gregory Etelson @ 2024-07-01 10:26 UTC (permalink / raw)
  To: dev
  Cc: getelson, mkashani, rasland, Ori Kam, Dariusz Sosnowski,
	Viacheslav Ovsiienko, Suanming Mou, Matan Azrad

From: Ori Kam <orika@nvidia.com>

Until now the number of pattern templates that was
supported per table was limited to 2.
This was the result of the limitation that the table
could only support 1 matcher.
which meant that we could only support merge of
Ipv4 + TCP and IPv4 + UDP.

With the added ability to use extended hash it is now
possible to use more than 2 pattern templates in a
single table.

Extended match works by creating the hash of the rule
based on the intersection of all pattern templates.
As a result this is good for tables with small number
of rules or that the intersection is very large. for
example ACL table.

Using this feature is not recommended to for use
in tables with large number of rules or with small
intersection. Using this feature on such cases may
result in PPS degradation and rule insertion failures.

This patch increase the max number to 32.

Signed-off-by: Ori Kam <orika@nvidia.com>
Acked-by: Dariusz Sosnowski <dsosnowski@nvidia.com>
---
 drivers/net/mlx5/mlx5_flow.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/mlx5/mlx5_flow.h b/drivers/net/mlx5/mlx5_flow.h
index 92e2ecedb3..8cef0bf61b 100644
--- a/drivers/net/mlx5/mlx5_flow.h
+++ b/drivers/net/mlx5/mlx5_flow.h
@@ -1634,7 +1634,7 @@ struct mlx5_flow_group {
 };
 
 
-#define MLX5_HW_TBL_MAX_ITEM_TEMPLATE 2
+#define MLX5_HW_TBL_MAX_ITEM_TEMPLATE 32
 #define MLX5_HW_TBL_MAX_ACTION_TEMPLATE 32
 
 #define MLX5_MULTIPATTERN_ENCAP_NUM 5
-- 
2.43.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] net/mlx5: increase max pattern templates
  2024-07-01 10:26 [PATCH] net/mlx5: increase max pattern templates Gregory Etelson
@ 2024-07-02  9:25 ` Raslan Darawsheh
  0 siblings, 0 replies; 2+ messages in thread
From: Raslan Darawsheh @ 2024-07-02  9:25 UTC (permalink / raw)
  To: Gregory Etelson, dev
  Cc: Maayan Kashani, Ori Kam, Dariusz Sosnowski, Slava Ovsiienko,
	Suanming Mou, Matan Azrad

Hi,

From: Gregory Etelson <getelson@nvidia.com>
Sent: Monday, July 1, 2024 1:26 PM
To: dev@dpdk.org
Cc: Gregory Etelson; Maayan Kashani; Raslan Darawsheh; Ori Kam; Dariusz Sosnowski; Slava Ovsiienko; Suanming Mou; Matan Azrad
Subject: [PATCH] net/mlx5: increase max pattern templates

From: Ori Kam <orika@nvidia.com>

Until now the number of pattern templates that was
supported per table was limited to 2.
This was the result of the limitation that the table
could only support 1 matcher.
which meant that we could only support merge of
Ipv4 + TCP and IPv4 + UDP.

With the added ability to use extended hash it is now
possible to use more than 2 pattern templates in a
single table.

Extended match works by creating the hash of the rule
based on the intersection of all pattern templates.
As a result this is good for tables with small number
of rules or that the intersection is very large. for
example ACL table.

Using this feature is not recommended to for use
in tables with large number of rules or with small
intersection. Using this feature on such cases may
result in PPS degradation and rule insertion failures.

This patch increase the max number to 32.

Signed-off-by: Ori Kam <orika@nvidia.com>
Acked-by: Dariusz Sosnowski <dsosnowski@nvidia.com>


Patch applied to next-net-mlx,

Kindest regards,
Raslan Darawsheh


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-07-02  9:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-07-01 10:26 [PATCH] net/mlx5: increase max pattern templates Gregory Etelson
2024-07-02  9:25 ` Raslan Darawsheh

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).