If the bond device was created by vdev mode, the kvlist was not free
after the bond device was closed.
This patch fixes it.
Fixes:
144dc4739975 ("net/bonding: fix leak on remove")
Cc: stable@dpdk.org
Signed-off-by: Dapeng Yu <dapengx.yu@intel.com>
Acked-by: Min Hu (Connor) <humin29@huawei.com>
*/
rte_mempool_free(internals->mode6.mempool);
+ if (internals->kvlist != NULL)
+ rte_kvargs_free(internals->kvlist);
+
return 0;
}
ret = bond_ethdev_stop(eth_dev);
bond_ethdev_close(eth_dev);
}
- if (internals->kvlist != NULL)
- rte_kvargs_free(internals->kvlist);
rte_eth_dev_release_port(eth_dev);
return ret;