From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id E7C5CA04C9; Mon, 14 Sep 2020 00:09:43 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 7790F1C0CE; Mon, 14 Sep 2020 00:09:04 +0200 (CEST) Received: from wnew2-smtp.messagingengine.com (wnew2-smtp.messagingengine.com [64.147.123.27]) by dpdk.org (Postfix) with ESMTP id 585921C0AC for ; Mon, 14 Sep 2020 00:09:02 +0200 (CEST) Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailnew.west.internal (Postfix) with ESMTP id 8D80D5E2; Sun, 13 Sep 2020 18:09:00 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Sun, 13 Sep 2020 18:09:01 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; s=fm2; bh=YINKezvtHFDfQ nkRA5+oczbrKUpiy938J0QTZR6JuEQ=; b=wuyHxJA60Vg96enZdDphKHWcccEez VK3seuRYshb9p+dXVcZrXygp3ErNPb67bXldgZ0z0DR1etCihBRSq+h6D2th8NRx hQndkIsUQWIRoO7rdizsa5+DmvO/4jnWp3yEpkQ2rBpoj/FrUmKfijyiu8j5h+Le wX8WaOLoNt0xV0BF9a4kQyWUV+jJGoQpEvU/QKXlv94MJzYGMbPHJqB07vydEGy6 XlykbOQHlcvX04Wl7BvWebVP6UsVh4oqoPSuMLlEKz3cOKAfXQ769uqyVNw33DBd UUHyeIE0awEZ3gDwlx07PKsZCeC6oMV+ZB50kismvYo73JSlLymmoVDRw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:date:from :in-reply-to:message-id:mime-version:references:subject:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=YINKezvtHFDfQnkRA5+oczbrKUpiy938J0QTZR6JuEQ=; b=QspRuZGN f+XefH89LWNPWC9ymYn/fYg5orzvX5j8UX0u+spE6lmdMPsQbu5EmRhVjuR0u121 vtdkzHUDqdLaOp18+7s2ecPjCu9sw4qTnjxLg5NEt25OLCzuisjSSClDOHe2wfH0 meEKSunrRYTgymDPk52o0gqUCo6udvBz6dXQ2Z5/Q/RtKgw/m2GzSnolaPs9Ba92 hCLH+aN0yjrZ6vNQPvO+G5xfd3f0sgTferp9Cm9/1ErPSFwdDVcCkY7Qhk6xBY1i yVjKgdp1UHFFpS8rGH19Csi6dl08w5xR//+g5ObTbq/c2n6zRvZ8ljrjehigKaT6 3L6koHf3IytOLQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduiedrudeihedgtdehucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufffkffojghfggfgsedtkeertdertddtnecuhfhrohhmpefvhhhomhgr shcuofhonhhjrghlohhnuceothhhohhmrghssehmohhnjhgrlhhonhdrnhgvtheqnecugg ftrfgrthhtvghrnhepvdehgfeivdejgedtveehfefhteelfefgieevgfffveefjeegtdfg uedthedtgeevnecukfhppeejjedrudefgedrvddtfedrudekgeenucevlhhushhtvghruf hiiigvpedujeenucfrrghrrghmpehmrghilhhfrhhomhepthhhohhmrghssehmohhnjhgr lhhonhdrnhgvth X-ME-Proxy: Received: from xps.monjalon.net (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id B39BD3064674; Sun, 13 Sep 2020 18:08:58 -0400 (EDT) From: Thomas Monjalon To: dev@dpdk.org Cc: ferruh.yigit@intel.com, arybchenko@solarflare.com, Shepard Siegel , Ed Czeck , John Miller , Ziyang Xuan , Xiaoyun Wang , Guoyang Zhou , Qiming Yang , Qi Zhang , Martin Spinler Date: Mon, 14 Sep 2020 00:07:09 +0200 Message-Id: <20200913220711.3768597-19-thomas@monjalon.net> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200913220711.3768597-1-thomas@monjalon.net> References: <20200913220711.3768597-1-thomas@monjalon.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH 18/20] drivers/net: remove redundant MAC addresses freeing 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" The MAC addresses array is already freed by rte_eth_dev_release_port(). The redundant freeing can be removed from the PMD port closing functions. Signed-off-by: Thomas Monjalon --- drivers/net/ark/ark_ethdev.c | 3 --- drivers/net/hinic/hinic_pmd_ethdev.c | 3 --- drivers/net/ice/ice_ethdev.c | 3 --- drivers/net/nfb/nfb_ethdev.c | 3 --- drivers/net/szedata2/rte_eth_szedata2.c | 3 --- 5 files changed, 15 deletions(-) diff --git a/drivers/net/ark/ark_ethdev.c b/drivers/net/ark/ark_ethdev.c index 8012af75ee..641a694717 100644 --- a/drivers/net/ark/ark_ethdev.c +++ b/drivers/net/ark/ark_ethdev.c @@ -707,9 +707,6 @@ eth_ark_dev_close(struct rte_eth_dev *dev) dev->data->rx_queues[i] = 0; } - rte_free(dev->data->mac_addrs); - dev->data->mac_addrs = 0; - return 0; } diff --git a/drivers/net/hinic/hinic_pmd_ethdev.c b/drivers/net/hinic/hinic_pmd_ethdev.c index 623534fda4..460093bf95 100644 --- a/drivers/net/hinic/hinic_pmd_ethdev.c +++ b/drivers/net/hinic/hinic_pmd_ethdev.c @@ -3225,9 +3225,6 @@ static int hinic_dev_uninit(struct rte_eth_dev *dev) rte_free(nic_dev->mc_list); - rte_free(dev->data->mac_addrs); - dev->data->mac_addrs = NULL; - return HINIC_OK; } diff --git a/drivers/net/ice/ice_ethdev.c b/drivers/net/ice/ice_ethdev.c index f0cb05cbc9..1a7896f0da 100644 --- a/drivers/net/ice/ice_ethdev.c +++ b/drivers/net/ice/ice_ethdev.c @@ -2423,9 +2423,6 @@ ice_dev_close(struct rte_eth_dev *dev) dev->rx_pkt_burst = NULL; dev->tx_pkt_burst = NULL; - rte_free(dev->data->mac_addrs); - dev->data->mac_addrs = NULL; - /* disable uio intr before callback unregister */ rte_intr_disable(intr_handle); diff --git a/drivers/net/nfb/nfb_ethdev.c b/drivers/net/nfb/nfb_ethdev.c index d937ac6922..6fe7500475 100644 --- a/drivers/net/nfb/nfb_ethdev.c +++ b/drivers/net/nfb/nfb_ethdev.c @@ -233,9 +233,6 @@ nfb_eth_dev_close(struct rte_eth_dev *dev) } dev->data->nb_tx_queues = 0; - rte_free(dev->data->mac_addrs); - dev->data->mac_addrs = NULL; - return 0; } diff --git a/drivers/net/szedata2/rte_eth_szedata2.c b/drivers/net/szedata2/rte_eth_szedata2.c index 5f589dfa4c..9ae653e1bd 100644 --- a/drivers/net/szedata2/rte_eth_szedata2.c +++ b/drivers/net/szedata2/rte_eth_szedata2.c @@ -1178,9 +1178,6 @@ eth_dev_close(struct rte_eth_dev *dev) } dev->data->nb_tx_queues = 0; - rte_free(dev->data->mac_addrs); - dev->data->mac_addrs = NULL; - return 0; } -- 2.28.0