Return value of function 'eth_kni_dev_stop' passed to 'ret' is
rewritten later, and this is unreasonable.
This patch fixes it.
Fixes:
62024eb82756 ("ethdev: change stop operation callback to return int")
Cc: stable@dpdk.org
Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
return 0;
ret = eth_kni_dev_stop(eth_dev);
+ if (ret)
+ PMD_LOG(WARNING, "Not able to stop kni for %s",
+ eth_dev->data->name);
/* mac_addrs must not be freed alone because part of dev_private */
eth_dev->data->mac_addrs = NULL;