patch 'net/mlx5: fix unsupported flow rule port action' has been queued to stable release 22.11.11
luca.boccassi at gmail.com
luca.boccassi at gmail.com
Mon Oct 27 17:18:56 CET 2025
Hi,
FYI, your patch has been queued to stable release 22.11.11
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 10/29/25. So please
shout if anyone has objections.
Also note that after the patch there's a diff of the upstream commit vs the
patch applied to the branch. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.
Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable
This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/def814b06fd87d79f247e907f82269737e47eb3e
Thanks.
Luca Boccassi
---
>From def814b06fd87d79f247e907f82269737e47eb3e Mon Sep 17 00:00:00 2001
From: Maayan Kashani <mkashani at nvidia.com>
Date: Thu, 7 Aug 2025 12:12:47 +0300
Subject: [PATCH] net/mlx5: fix unsupported flow rule port action
[ upstream commit c040e9a85a1fbce46528e9bc15d1ce4bbc911346 ]
When dv_flow_en=2, the port ID action is not supported.
Although a rule can be created successfully in non-template mode,
the specified action will be silently ignored and not applied.
To prevent this ambiguous behavior, explicitly return an error
when a port ID action is used with dv_flow_en=2,
and recommend using a represented port action instead.
Fixes: f1fecffa88df ("net/mlx5: support Direct Rules action template API")
Signed-off-by: Maayan Kashani <mkashani at nvidia.com>
Acked-by: Dariusz Sosnowski <dsosnowski at nvidia.com>
Acked-by: Ivan Malov <ivan.malov at arknetworks.am>
---
drivers/net/mlx5/mlx5_flow_hw.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/drivers/net/mlx5/mlx5_flow_hw.c b/drivers/net/mlx5/mlx5_flow_hw.c
index a2cd9b8b5c..7a8455baf6 100644
--- a/drivers/net/mlx5/mlx5_flow_hw.c
+++ b/drivers/net/mlx5/mlx5_flow_hw.c
@@ -1666,6 +1666,10 @@ __flow_hw_actions_translate(struct rte_eth_dev *dev,
case RTE_FLOW_ACTION_TYPE_END:
actions_end = true;
break;
+ case RTE_FLOW_ACTION_TYPE_PORT_ID:
+ DRV_LOG(ERR, "RTE_FLOW_ACTION_TYPE_PORT_ID action is not supported. "
+ "Use RTE_FLOW_ACTION_TYPE_REPRESENTED_PORT instead.");
+ goto err;
default:
break;
}
@@ -4274,6 +4278,10 @@ flow_hw_dr_actions_template_create(struct rte_flow_actions_template *at)
at->actions_off[i] = curr_off;
action_types[curr_off++] = MLX5DR_ACTION_TYP_MISS;
break;
+ case RTE_FLOW_ACTION_TYPE_PORT_ID:
+ DRV_LOG(ERR, "RTE_FLOW_ACTION_TYPE_PORT_ID action is not supported. "
+ "Use RTE_FLOW_ACTION_TYPE_REPRESENTED_PORT instead.\n");
+ return NULL;
default:
type = mlx5_hw_dr_action_types[at->actions[i].type];
at->actions_off[i] = curr_off;
--
2.47.3
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-10-27 15:54:35.502533826 +0000
+++ 0018-net-mlx5-fix-unsupported-flow-rule-port-action.patch 2025-10-27 15:54:34.751948446 +0000
@@ -1 +1 @@
-From c040e9a85a1fbce46528e9bc15d1ce4bbc911346 Mon Sep 17 00:00:00 2001
+From def814b06fd87d79f247e907f82269737e47eb3e Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit c040e9a85a1fbce46528e9bc15d1ce4bbc911346 ]
+
@@ -15 +16,0 @@
-Cc: stable at dpdk.org
@@ -21,2 +22,2 @@
- drivers/net/mlx5/mlx5_flow_hw.c | 10 +++++++++-
- 1 file changed, 9 insertions(+), 1 deletion(-)
+ drivers/net/mlx5/mlx5_flow_hw.c | 8 ++++++++
+ 1 file changed, 8 insertions(+)
@@ -25 +26 @@
-index 016370f68b..0c3f554479 100644
+index a2cd9b8b5c..7a8455baf6 100644
@@ -28 +29 @@
-@@ -2913,6 +2913,10 @@ __flow_hw_translate_actions_template(struct rte_eth_dev *dev,
+@@ -1666,6 +1666,10 @@ __flow_hw_actions_translate(struct rte_eth_dev *dev,
@@ -39,6 +40,4 @@
-@@ -7648,7 +7652,11 @@ flow_hw_parse_flow_actions_to_dr_actions(struct rte_eth_dev *dev,
- case MLX5_RTE_FLOW_ACTION_TYPE_MIRROR:
- at->dr_off[i] = curr_off;
- action_types[curr_off++] = MLX5DR_ACTION_TYP_DEST_ARRAY;
-- break;
-+ break;
+@@ -4274,6 +4278,10 @@ flow_hw_dr_actions_template_create(struct rte_flow_actions_template *at)
+ at->actions_off[i] = curr_off;
+ action_types[curr_off++] = MLX5DR_ACTION_TYP_MISS;
+ break;
@@ -47,2 +46,2 @@
-+ "Use RTE_FLOW_ACTION_TYPE_REPRESENTED_PORT instead.");
-+ return -EINVAL;
++ "Use RTE_FLOW_ACTION_TYPE_REPRESENTED_PORT instead.\n");
++ return NULL;
@@ -51 +50 @@
- at->dr_off[i] = curr_off;
+ at->actions_off[i] = curr_off;
More information about the stable
mailing list