From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail04.ics.ntt-tx.co.jp (mail05.ics.ntt-tx.co.jp [210.232.35.69]) by dpdk.org (Postfix) with ESMTP id 45AEE1B5FB; Wed, 19 Dec 2018 05:41:41 +0100 (CET) Received: from gwchk03.silk.ntt-tx.co.jp (gwchk03.silk.ntt-tx.co.jp [10.107.0.111]) by mail04.ics.ntt-tx.co.jp (unknown) with ESMTP id wBJ4fdf1024534; Wed, 19 Dec 2018 13:41:39 +0900 Received: (from root@localhost) by gwchk03.silk.ntt-tx.co.jp (unknown) id wBJ4fdis010920; Wed, 19 Dec 2018 13:41:39 +0900 Received: from gwchk.silk.ntt-tx.co.jp [10.107.0.110] by gwchk03.silk.ntt-tx.co.jp with ESMTP id PAA10919; Wed, 19 Dec 2018 13:41:39 +0900 Received: from imss06.silk.ntt-tx.co.jp (localhost [127.0.0.1]) by ccmail04.silk.ntt-tx.co.jp (unknown) with ESMTP id wBJ4fcV5029395; Wed, 19 Dec 2018 13:41:38 +0900 Received: from imss06.silk.ntt-tx.co.jp (localhost [127.0.0.1]) by imss06.silk.ntt-tx.co.jp (unknown) with ESMTP id wBJ4fcK0030102; Wed, 19 Dec 2018 13:41:38 +0900 Received: from ccmail04 (smtp03.silk.ntt-tx.co.jp [10.107.0.135]) by imss06.silk.ntt-tx.co.jp (unknown) with SMTP id wBJ4fct3030099; Wed, 19 Dec 2018 13:41:38 +0900 Date: Wed, 19 Dec 2018 13:37:18 +0900 From: Hideyuki Yamashita MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Mailer: Becky! ver. 2.74 [ja] X-CCMail7: CC-Mail-V7.0.2-Client-Relayed Message-Id: <201812190440.wBJ4cabt027283@ccmail04.silk.ntt-tx.co.jp> X-TM-AS-MML: No X-CC-Mail-RelayStamp: CC-Mail-V5.14-Server To: maxime.coquelin@redhat.com, zhihong.wang@intel.com, tiwei.bie@intel.com, dev@dpdk.org Cc: stable@dpdk.org, ogawa.yasufumi@lab.ntt.co.jp Subject: [dpdk-dev] [PATCH] net/vhost: fix double free of MAC addrs X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Dec 2018 04:41:41 -0000 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 Signed-off-by: Yasufumi Ogawa --- 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