From: Dekel Peled Date: Wed, 22 Jan 2020 14:27:14 +0000 (+0200) Subject: net/mlx5: fix check for VLAN actions X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=a2268a4cfb08e70e3f0f0a082033ad5a24a2a07d;p=dpdk.git net/mlx5: fix check for VLAN actions Flow validation function includes, after all items and actions are validated discretely, a check for VLAN and VXLAN actions. This check is incorrect and redundant. This patch removes the invalid check from validation function. Check is incorrect, action_flags bit map is checked against items mask MLX5_FLOW_LAYER_TUNNEL. Check is also redundant, because VLAN push/pop actions can be used together with packet reformat actions. Fixes: b41e47da2592 ("net/mlx5: support pop flow action on VLAN header") Cc: stable@dpdk.org Signed-off-by: Dekel Peled Acked-by: Ori Kam Acked-by: Viacheslav Ovsiienko --- diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c index 5a1b42698c..afa3d0e1ce 100644 --- a/drivers/net/mlx5/mlx5_flow_dv.c +++ b/drivers/net/mlx5/mlx5_flow_dv.c @@ -5060,13 +5060,6 @@ flow_dv_validate(struct rte_eth_dev *dev, const struct rte_flow_attr *attr, "action not supported"); } } - if ((action_flags & MLX5_FLOW_LAYER_TUNNEL) && - (action_flags & MLX5_FLOW_VLAN_ACTIONS)) - return rte_flow_error_set(error, ENOTSUP, - RTE_FLOW_ERROR_TYPE_ACTION, - actions, - "can't have vxlan and vlan" - " actions in the same rule"); /* Eswitch has few restrictions on using items and actions */ if (attr->transfer) { if (!mlx5_flow_ext_mreg_supported(dev) &&