Hi,

> -----Original Message-----
> From: Wisam Monther <[email protected]>
> Sent: Thursday, March 12, 2020 11:25 AM
> To: [email protected]; Raslan Darawsheh <[email protected]>; Matan
> Azrad <[email protected]>
> Cc: Slava Ovsiienko <[email protected]>; [email protected]
> Subject: [PATCH] net/mlx5: fix validate set meta action for zero value
> 
> There is no reason to prevent the user from using zero metadata,
> it indeed means no metadata, but sometimes the user may need to
> report to datapath that there is no metadata anymore, which is
> valid case.
> 
> Fixes: fcc8d2f716fd ("net/mlx5: extend flow metadata support")
> Cc: [email protected]
> Cc: [email protected]
> 
> Signed-off-by: Wisam Jaddo <[email protected]>
> Acked-by: Viacheslav Ovsiienko <[email protected]>
> ---
>  drivers/net/mlx5/mlx5_flow_dv.c | 4 ----
>  1 file changed, 4 deletions(-)
> 
> diff --git a/drivers/net/mlx5/mlx5_flow_dv.c
> b/drivers/net/mlx5/mlx5_flow_dv.c
> index e7278f0..e2d6690 100644
> --- a/drivers/net/mlx5/mlx5_flow_dv.c
> +++ b/drivers/net/mlx5/mlx5_flow_dv.c
> @@ -2109,10 +2109,6 @@ flow_dv_validate_action_set_meta(struct
> rte_eth_dev *dev,
>               return rte_flow_error_set(error, EINVAL,
>                                         RTE_FLOW_ERROR_TYPE_ACTION,
> action,
>                                         "meta data must be within reg C0");
> -     if (!(conf->data & conf->mask))
> -             return rte_flow_error_set(error, EINVAL,
> -                                       RTE_FLOW_ERROR_TYPE_ACTION,
> action,
> -                                       "zero value has no effect");
>       return 0;
>  }
> 
> --
> 2.7.4


Patch applied to next-net-mlx,

Kindest regards,
Raslan Darawsheh

Reply via email to