Representor matching is always enabled on an E-Switch port, and the PMD
reserves egress group 0 for the default SQ tagging rule. Removing
repr_matching_en left the user group shift enabled only for extended
metadata mode. With any other dv_xmeta_en value, an external egress
group 0 rule is installed on the root table, where a jump to a non-root
group matches but does not continue.
Shift every external egress group when the E-Switch is enabled.
This restores the previous repr_matching_en=1 behavior.
Fixes: c41f621786ff ("net/mlx5: remove representor matching devarg")
Cc: [email protected]
Signed-off-by: Maayan Kashani <[email protected]>
Acked-by: Dariusz Sosnowski <[email protected]>
---
drivers/net/mlx5/mlx5_flow_hw.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/net/mlx5/mlx5_flow_hw.c b/drivers/net/mlx5/mlx5_flow_hw.c
index 8dabf21b768..4b30befa2d1 100644
--- a/drivers/net/mlx5/mlx5_flow_hw.c
+++ b/drivers/net/mlx5/mlx5_flow_hw.c
@@ -5591,7 +5591,6 @@ __translate_group(struct rte_eth_dev *dev,
"group index not supported");
*table_group = group + 1;
} else if (config->dv_esw_en &&
- config->dv_xmeta_en == MLX5_XMETA_MODE_META32_HWS &&
external &&
flow_attr->egress) {
/*
@@ -5600,9 +5599,8 @@ __translate_group(struct rte_eth_dev *dev,
* These flow rules are inserted in group 0 and this group is
reserved by PMD
* for these purposes.
*
- * As a result, if representor matching or extended metadata
mode is enabled,
- * group provided by the user must be incremented to avoid
inserting flow rules
- * in group 0.
+ * Representor matching is always enabled, so the group
provided by the user
+ * must be incremented to avoid inserting flow rules in group 0.
*/
if (group > MLX5_HW_MAX_EGRESS_GROUP)
return rte_flow_error_set(error, EINVAL,
--
2.25.1