DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] net/vhost: fix double free of MAC addrs
@ 2018-12-19  4:37 Hideyuki Yamashita
  2018-12-19  9:15 ` Tiwei Bie
  2018-12-20 18:20 ` Maxime Coquelin
  0 siblings, 2 replies; 3+ messages in thread
From: Hideyuki Yamashita @ 2018-12-19  4:37 UTC (permalink / raw)
  To: maxime.coquelin, zhihong.wang, tiwei.bie, dev; +Cc: stable, ogawa.yasufumi

The common data freeing has been moved to rte_eth_dev_release_port(),
so freeing mac_addrs like this in eth_dev_close() is unnecessary and
will cause double free.

Fixes: e16adf08e54d ("ethdev: free all common data when releasing port")
Cc: stable@dpdk.org

Signed-off-by: Hideyuki Yamashita <yamashita.hideyuki@po.ntt-tx.co.jp>
Signed-off-by: Yasufumi Ogawa <ogawa.yasufumi@lab.ntt.co.jp>
---
 drivers/net/vhost/rte_eth_vhost.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/net/vhost/rte_eth_vhost.c b/drivers/net/vhost/rte_eth_vhost.c
index 42bdfcbd5..b2cda0483 100644
--- a/drivers/net/vhost/rte_eth_vhost.c
+++ b/drivers/net/vhost/rte_eth_vhost.c
@@ -1000,7 +1000,6 @@ eth_dev_close(struct rte_eth_dev *dev)
 		for (i = 0; i < dev->data->nb_tx_queues; i++)
 			rte_free(dev->data->tx_queues[i]);
 
-	rte_free(dev->data->mac_addrs);
 	free(internal->dev_name);
 	free(internal->iface_name);
 	rte_free(internal);
-- 
2.18.0

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-12-20 18:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-19  4:37 [dpdk-dev] [PATCH] net/vhost: fix double free of MAC addrs Hideyuki Yamashita
2018-12-19  9:15 ` Tiwei Bie
2018-12-20 18:20 ` Maxime Coquelin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).