From: Yongseok Koh Date: Mon, 8 Oct 2018 18:02:19 +0000 (+0000) Subject: net/mlx5: fix errno values for flow engine X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=c10f5d643b28a3bff1156ae54d5ebcfda15f34d9;p=dpdk.git net/mlx5: fix errno values for flow engine Fixes: af689f1f04c2 ("net/mlx5: support flow Ethernet item along with drop action") Fixes: 919d53ad78d2 ("net/mlx5: fix count query when flow has not counter") Cc: stable@dpdk.org Signed-off-by: Yongseok Koh Acked-by: Ori Kam --- diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c index 078b07619c..ed60c40f90 100644 --- a/drivers/net/mlx5/mlx5_flow.c +++ b/drivers/net/mlx5/mlx5_flow.c @@ -452,10 +452,10 @@ mlx5_flow_item_acceptable(const struct rte_flow_item *item, } ret = memcmp(spec, last, size); if (ret != 0) - return rte_flow_error_set(error, ENOTSUP, + return rte_flow_error_set(error, EINVAL, RTE_FLOW_ERROR_TYPE_ITEM, item, - "range is not supported"); + "range is not valid"); } return 0; } @@ -2336,7 +2336,7 @@ mlx5_flow_query_count(struct rte_flow *flow __rte_unused, } return 0; } - return rte_flow_error_set(error, ENOTSUP, + return rte_flow_error_set(error, EINVAL, RTE_FLOW_ERROR_TYPE_UNSPECIFIED, NULL, "flow does not have counter");