[dpdk-stable] [PATCH 18.05] net/mlx5: fix return value when deleting fdir filter
Yongseok Koh
yskoh at mellanox.com
Thu Aug 16 21:09:57 CEST 2018
rte_errno may have garbage value if there's no error.
Fixes: a6d83b6a9209 ("net/mlx5: standardize on negative errno values")
Fixes: e657445767ed ("net/mlx5: fix error number handling")
Signed-off-by: Yongseok Koh <yskoh at mellanox.com>
---
Hi Christian,
This patch is to amend "net/mlx5: fix error number handling", which has been
already taken in stable/18.05. You can squash this patch to the previous one if
you want, but it is also okay to be two separate patches.
For 17.11, I found this bug after I released 17.11.4-rc1, so I had to keep it
separate though.
Thanks,
Yongseok
drivers/net/mlx5/mlx5_flow.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c
index 45207d70e..b219a1cad 100644
--- a/drivers/net/mlx5/mlx5_flow.c
+++ b/drivers/net/mlx5/mlx5_flow.c
@@ -3570,9 +3570,11 @@ mlx5_fdir_filter_delete(struct rte_eth_dev *dev,
if (parser.queue[i].ibv_attr)
rte_free(parser.queue[i].ibv_attr);
}
- if (ret)
+ if (ret) {
rte_errno = ret; /* Restore rte_errno. */
- return -rte_errno;
+ return -rte_errno;
+ }
+ return 0;
}
/**
--
2.11.0
More information about the stable
mailing list