Thread (2 messages) 2 messages, 2 authors, 2020-06-30

[dpdk-dev] [PATCH] net/mlx5: fix LACP action type casting

From: Shiri Kuzin <hidden>
Date: 2020-06-29 16:01:30
Subsystem: networking drivers, the rest · Maintainers: Andrew Lunn, "David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Linus Torvalds

The mlx5_flow_lacp_miss flow rule for matching LACP traffic was
added to steer LACP traffic to kernel.

When setting the action type of rte_flow_action to
MLX5_RTE_FLOW_ACTION_TYPE_DEFAULT_MISS we get an error since the
action is an enum of type mlx5_rte_flow_action_type.

To solve this a casting of MLX5_RTE_FLOW_ACTION_TYPE_DEFAULT_MISS
to rte_flow_action was added.

Fixes: 6ff4a90223c4 ("net/mlx5: add default miss action to flow engine")
Signed-off-by: Shiri Kuzin <redacted>
Acked-by: Matan Azrad <redacted>
---
 drivers/net/mlx5/mlx5_flow.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c
index 4700ec1..4a031a5 100644
--- a/drivers/net/mlx5/mlx5_flow.c
+++ b/drivers/net/mlx5/mlx5_flow.c
@@ -5060,7 +5060,8 @@ struct rte_flow *
 	};
 	struct rte_flow_action actions[] = {
 		{
-			.type = MLX5_RTE_FLOW_ACTION_TYPE_DEFAULT_MISS,
+			.type = (enum rte_flow_action_type)
+				MLX5_RTE_FLOW_ACTION_TYPE_DEFAULT_MISS,
 		},
 		{
 			.type = RTE_FLOW_ACTION_TYPE_END,
-- 
1.8.3.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help