From: Bing Zhao Date: Fri, 13 Nov 2020 07:05:33 +0000 (+0800) Subject: net/mlx5: fix hairpin unbind X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=0746dcabfd52a8722f3590f58b943bf8eba5840c;p=dpdk.git net/mlx5: fix hairpin unbind In the implementation of mlx5_hairpin_unbind, a copy-paste error was inside. If a single peer Rx port needed to be unbound, it would be bound again by mistake. All the hardware resources were released when stopping the device and no mess of the configuration was introduced. But when trying to unbind the ports again, the issue would appear. The typo of the function call is fixed. If there is no hairpin queue bound between two ports, the unbinding process should be considered successful. Fixes: 37cd4501e873 ("net/mlx5: support two ports hairpin mode") Signed-off-by: Bing Zhao Acked-by: Viacheslav Ovsiienko --- diff --git a/drivers/net/mlx5/mlx5_trigger.c b/drivers/net/mlx5/mlx5_trigger.c index 46e4191bfa..bd029154f8 100644 --- a/drivers/net/mlx5/mlx5_trigger.c +++ b/drivers/net/mlx5/mlx5_trigger.c @@ -934,7 +934,7 @@ mlx5_hairpin_unbind(struct rte_eth_dev *dev, uint16_t rx_port) return ret; } else - ret = mlx5_hairpin_bind_single_port(dev, rx_port); + ret = mlx5_hairpin_unbind_single_port(dev, rx_port); return ret; }