patch 'net/mlx5: fix error reporting on masked indirect actions' has been queued to stable release 24.11.4
Kevin Traynor
ktraynor at redhat.com
Fri Nov 21 12:20:37 CET 2025
Hi,
FYI, your patch has been queued to stable release 24.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 11/26/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/kevintraynor/dpdk-stable
This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/bd8a9fa033ac7275ae7b3c87227c272e8056d20d
Thanks.
Kevin
---
>From bd8a9fa033ac7275ae7b3c87227c272e8056d20d Mon Sep 17 00:00:00 2001
From: Dariusz Sosnowski <dsosnowski at nvidia.com>
Date: Wed, 5 Nov 2025 17:52:54 +0100
Subject: [PATCH] net/mlx5: fix error reporting on masked indirect actions
[ upstream commit 1d961316d9f541c6679dcd519a40a667f9885f30 ]
Whenever masked indirect actions in actions template were handled
by mlx5 PMD and user passed incorrect action configuration,
the specific errors were not returned through rte_flow_error struct.
Existing logs also used WARNING log level, which made debugging a bit
harder.
This patch fixes error reporting for masked indirect actions,
during flow actions translation done in HWS mode:
- Replace "return -1" with error reporting through rte_flow_error.
- Change log level from WARNING to ERR.
- Add more information to log messages (port index
and action handle).
Fixes: 7ab3962d2d2b ("net/mlx5: add indirect HW steering action")
Fixes: 4d368e1da3a4 ("net/mlx5: support flow counter action for HWS")
Fixes: 463170a7c934 ("net/mlx5: support connection tracking with HWS")
Fixes: 48fbb0e93d06 ("net/mlx5: support flow meter mark indirect action with HWS")
Signed-off-by: Dariusz Sosnowski <dsosnowski at nvidia.com>
Acked-by: Bing Zhao <bingz at nvidia.com>
---
drivers/net/mlx5/mlx5_flow_hw.c | 42 +++++++++++++++++++++++----------
1 file changed, 29 insertions(+), 13 deletions(-)
diff --git a/drivers/net/mlx5/mlx5_flow_hw.c b/drivers/net/mlx5/mlx5_flow_hw.c
index 25cd973a57..667472800f 100644
--- a/drivers/net/mlx5/mlx5_flow_hw.c
+++ b/drivers/net/mlx5/mlx5_flow_hw.c
@@ -1288,5 +1288,6 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
struct mlx5_hw_actions *acts,
uint16_t action_src,
- uint16_t action_dst)
+ uint16_t action_dst,
+ struct rte_flow_error *error)
{
struct mlx5_priv *priv = dev->data->dev_private;
@@ -1305,6 +1306,8 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
(enum rte_flow_action_type)MLX5_RTE_FLOW_ACTION_TYPE_RSS,
action_src, action_dst, idx, shared_rss)) {
- DRV_LOG(WARNING, "Indirect RSS action index %d translate failed", act_idx);
- return -1;
+ DRV_LOG(ERR, "port %u Indirect RSS action (handle %p) translate failed",
+ dev->data->port_id, action->conf);
+ return rte_flow_error_set(error, EINVAL, RTE_FLOW_ERROR_TYPE_ACTION,
+ action, "Indirect RSS action translate failed");
}
break;
@@ -1314,6 +1317,11 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
MLX5_RTE_FLOW_ACTION_TYPE_COUNT,
action_src, action_dst, act_idx)) {
- DRV_LOG(WARNING, "Indirect count action translate failed");
- return -1;
+ DRV_LOG(ERR,
+ "port %u Indirect count action (handle %p) "
+ "translate failed",
+ dev->data->port_id, action->conf);
+ return rte_flow_error_set(error, EINVAL, RTE_FLOW_ERROR_TYPE_ACTION,
+ action,
+ "Indirect count action translate failed");
}
break;
@@ -1321,6 +1329,8 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
if (flow_hw_ct_compile(dev, MLX5_HW_INV_QUEUE,
idx, &acts->rule_acts[action_dst])) {
- DRV_LOG(WARNING, "Indirect CT action translate failed");
- return -1;
+ DRV_LOG(ERR, "port %u Indirect CT action (handle %p) translate failed",
+ dev->data->port_id, action->conf);
+ return rte_flow_error_set(error, EINVAL, RTE_FLOW_ERROR_TYPE_ACTION,
+ action, "Indirect CT action translate failed");
}
break;
@@ -1330,6 +1340,11 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
MLX5_RTE_FLOW_ACTION_TYPE_METER_MARK,
action_src, action_dst, idx)) {
- DRV_LOG(WARNING, "Indirect meter mark action translate failed");
- return -1;
+ DRV_LOG(ERR,
+ "port %u Indirect meter mark action (handle %p) "
+ "translate failed",
+ dev->data->port_id, action->conf);
+ return rte_flow_error_set(error, EINVAL, RTE_FLOW_ERROR_TYPE_ACTION,
+ action,
+ "Indirect meter mark action translate failed");
}
break;
@@ -1338,6 +1353,7 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
break;
default:
- DRV_LOG(WARNING, "Unsupported shared action type:%d", type);
- break;
+ DRV_LOG(ERR, "Unsupported shared action type: %d", type);
+ return rte_flow_error_set(error, ENOTSUP, RTE_FLOW_ERROR_TYPE_ACTION, action,
+ "Unsupported shared action type");
}
return 0;
@@ -2501,6 +2517,6 @@ __flow_hw_translate_actions_template(struct rte_eth_dev *dev,
}
if (actions->conf && masks->conf) {
- if (flow_hw_shared_action_translate
- (dev, actions, acts, src_pos, dr_pos))
+ if (flow_hw_shared_action_translate(dev, actions, acts,
+ src_pos, dr_pos, &sub_error))
goto err;
} else if (__flow_hw_act_data_indirect_append
--
2.51.0
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-11-21 11:05:11.283160308 +0000
+++ 0053-net-mlx5-fix-error-reporting-on-masked-indirect-acti.patch 2025-11-21 11:05:09.520201412 +0000
@@ -1 +1 @@
-From 1d961316d9f541c6679dcd519a40a667f9885f30 Mon Sep 17 00:00:00 2001
+From bd8a9fa033ac7275ae7b3c87227c272e8056d20d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 1d961316d9f541c6679dcd519a40a667f9885f30 ]
+
@@ -24 +25,0 @@
-Cc: stable at dpdk.org
@@ -33 +34 @@
-index 1755f2cffc..4d85fffb8f 100644
+index 25cd973a57..667472800f 100644
@@ -36 +37 @@
-@@ -1322,5 +1322,6 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
+@@ -1288,5 +1288,6 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
@@ -44 +45 @@
-@@ -1339,6 +1340,8 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
+@@ -1305,6 +1306,8 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
@@ -55 +56 @@
-@@ -1348,6 +1351,11 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
+@@ -1314,6 +1317,11 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
@@ -69 +70 @@
-@@ -1355,6 +1363,8 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
+@@ -1321,6 +1329,8 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
@@ -80 +81 @@
-@@ -1364,6 +1374,11 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
+@@ -1330,6 +1340,11 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
@@ -94 +95 @@
-@@ -1372,6 +1387,7 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
+@@ -1338,6 +1353,7 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
@@ -104 +105 @@
-@@ -2537,6 +2553,6 @@ __flow_hw_translate_actions_template(struct rte_eth_dev *dev,
+@@ -2501,6 +2517,6 @@ __flow_hw_translate_actions_template(struct rte_eth_dev *dev,
More information about the stable
mailing list