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 126DFA0519; Mon, 22 Jun 2020 11:55:50 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 523C11D63B; Mon, 22 Jun 2020 11:55:47 +0200 (CEST) Received: from FRA01-PR2-obe.outbound.protection.outlook.com (mail-eopbgr120090.outbound.protection.outlook.com [40.107.12.90]) by dpdk.org (Postfix) with ESMTP id A90C31D61D for ; Mon, 22 Jun 2020 11:55:45 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kMQZVLSgyBph98ta9+etBiAu6d0JsYJ6NqEcSNVnKMHoNGRnl3fWgNX54qesQDrM0+7SvkJ5gORXDvjPbXH8/9I7dnCeJ75eHN0BURJtlrpEP8WHj/R4hoJO32ZCxph6lFpOEkRQYS2xcidk0Ixcq7VYDsXAWubBlwKJI2eTgznB7zIjXaUch1sOlA5D9VVUeHTiAQS968I+yqit7NgDDPhPtiPj0wueYFTWXBVttFqCTRBoBz5Kai5DDs2i97s91D6PbKU/7c9U5G6Z7cxSfH6Omb6XLhgfsbCJe0eC0FHAJw1a1/XWdArYWypz5Tmfw87iZf25qnPXWOFDjB1FXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=mCcTpfIdyE/isO+qg9wQggBvAmxjxcnHV4OYsNyJLAM=; b=KHapnxUPlZYFI+SRgrcNZbStra3epwGvFf/lfSakehat5gUZgcJz0nMOqivJAs5G3ui4lT1Am8TxyrPIDoYqoog5nY6L1FcuyYk3Ofh9UV5WTJzYFovEpM/GLIjomdve9kRMeFyLVmbQLSRAPP6LIfw8RNdnSWtn49onR1mCgmKt6gRTWJzsWw0z+l+PVF5xxJVrH03823L9nOskuGsme96dJ8eWBJ8uV52qm9qKPTu4ftMKP8nBkwU/ERQf7/VFBMwDzjZRUIkTPbZNx0pRjo+iXQh0e07Ld/qpd6WMKTAfRq+ViTHyuZyPmCeHddmolHsDqk7/PD6PfLfXHIQHSA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=ekinops.com; dmarc=pass action=none header.from=ekinops.com; dkim=pass header.d=ekinops.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ekinops.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=mCcTpfIdyE/isO+qg9wQggBvAmxjxcnHV4OYsNyJLAM=; b=vO+BxR4yE+pw5YH9uiVodlmZwLapPs1xZ0tmRF4hlkL38f5Xy0C82C82ula0YXwHzCho+sNaq5Iz7zj8vNEMzVWdw0iokkj7iSI0RpXbUCGuTbA6DD/oBqJ060autC4UIxFe2RhmPDnZPVx4ZJezT1Eq1Oo1Nmk5ZHQtETvaRKo= Authentication-Results: dpdk.org; dkim=none (message not signed) header.d=none;dpdk.org; dmarc=none action=none header.from=ekinops.com; Received: from MRXP264MB0120.FRAP264.PROD.OUTLOOK.COM (2603:10a6:500:1b::10) by MRXP264MB0391.FRAP264.PROD.OUTLOOK.COM (2603:10a6:500:16::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3109.24; Mon, 22 Jun 2020 09:55:45 +0000 Received: from MRXP264MB0120.FRAP264.PROD.OUTLOOK.COM ([fe80::b9c3:a77c:6837:2548]) by MRXP264MB0120.FRAP264.PROD.OUTLOOK.COM ([fe80::b9c3:a77c:6837:2548%6]) with mapi id 15.20.3109.027; Mon, 22 Jun 2020 09:55:45 +0000 From: Renata Saiakhova To: dev@dpdk.org Cc: Renata Saiakhova Date: Mon, 22 Jun 2020 11:54:42 +0200 Message-Id: <20200622095443.26136-4-Renata.Saiakhova@ekinops.com> X-Mailer: git-send-email 2.17.2 In-Reply-To: <20200622095443.26136-1-Renata.Saiakhova@ekinops.com> References: <20200622095443.26136-1-Renata.Saiakhova@ekinops.com> Content-Type: text/plain X-ClientProxiedBy: AM0PR10CA0015.EURPRD10.PROD.OUTLOOK.COM (2603:10a6:208:17c::25) To MRXP264MB0120.FRAP264.PROD.OUTLOOK.COM (2603:10a6:500:1b::10) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from renataOAB.oneaccess.intra (91.183.184.98) by AM0PR10CA0015.EURPRD10.PROD.OUTLOOK.COM (2603:10a6:208:17c::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3109.22 via Frontend Transport; Mon, 22 Jun 2020 09:55:44 +0000 X-Mailer: git-send-email 2.17.2 X-Originating-IP: [91.183.184.98] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: ee39c3c2-cbdc-4258-bdb6-08d816926e8f X-MS-TrafficTypeDiagnostic: MRXP264MB0391: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1122; X-Forefront-PRVS: 0442E569BC X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: nu+IMy/tMBCRJ0wNhjg14OdkHCNppiiSwgdmow1W29yeGcKWSWb+siugCkwz4Qi3XtCExPhO6X0Hjw4Tl580S78MUWHNSYV4Ycg3io1CjqvrpwZ8GAZ37FrsGFyM02t4V7bBrFPq5aXy9VpknmOluFDMKkrMVWzKEVdsI5WaSk1C860Awd7DoIs6xvKLvZnPqYuJHRr3dfLG6ew2qEn5E4vGnGR1+oBRhp6hyNNEKwws/WJAbgFi0ILSOMk1xZAeMbkl86fYEUAZbF28GrKr+meKEx1U2egxdPYqJNnoKvdsoCNxT2oKAEh2hkdr1E5s X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:MRXP264MB0120.FRAP264.PROD.OUTLOOK.COM; PTR:; CAT:NONE; SFTY:; SFS:(346002)(396003)(136003)(366004)(39840400004)(376002)(316002)(1076003)(478600001)(107886003)(36756003)(52116002)(86362001)(8676002)(2906002)(66556008)(8936002)(83380400001)(66476007)(66946007)(16526019)(956004)(26005)(2616005)(186003)(6512007)(6486002)(6506007)(6916009)(5660300002)(4326008); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData: aN9o0uJBS1uXGHJ0HFOskvWH1xvBJe1OCl7lXDuQYGX+PEByVpTC1n1dvL9PHCP6CMmM8nAGSzH8QJl+Tww3NlSBkevCTauQr02smrULGWp9DvtahHuZzyDpQ5ESi7+Mfvx+m1tUeI3bAi/duDCRioovy6/fmu3sVZni4G1RVtcGNFouZlFyC9D9ZBiiUll9VZyiPWCcumvPAk5Fasi0pqQVvlEGRqldWKmInro8f11LTTWXTz2SQeSDKmG23Fwj/HqDEya67iXYzgZmPo1IWrFlbXJ1xfmAKWHF1VsQXwgpCMp9Z5AOixuRp/KDraiuE2OdXiIZsPZDqvIsedovEB6qxvdele69zIPsg5fm0Cxt2SrsH49mc5Ak3oZkCNf9xsruunEybWmWmZv0m6pq4sp5T48BoVi2yHH+zglcY7atkaiA4DJPFBAW5UNdAZ71JeukIWsLTtHWt5lvR1YNS8TBWeuxvsBT0GIv2QnuBGY= X-OriginatorOrg: ekinops.com X-MS-Exchange-CrossTenant-Network-Message-Id: ee39c3c2-cbdc-4258-bdb6-08d816926e8f X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 Jun 2020 09:55:45.0044 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f57b78a6-c654-4771-a72f-837275f46179 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: wZXF/qn6mCP77KiGHVZfbUkm89iWW9Zq59ihrzhHkec3e9FmifBOn7l9d7wt8/aj5Y29+3VLU1XyFLU9BO5xG0FeK/VXr6iBklQa6PPbDww= X-MS-Exchange-Transport-CrossTenantHeadersStamped: MRXP264MB0391 Subject: [dpdk-dev] [PATCH v4 3/4] drivers/net: Fix in i40e HW rings memory overlap 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" Delete memzones for HW rings in i40e while freeing queues Signed-off-by: Renata Saiakhova --- drivers/net/i40e/i40e_fdir.c | 3 +++ drivers/net/i40e/i40e_rxtx.c | 2 ++ 2 files changed, 5 insertions(+) diff --git a/drivers/net/i40e/i40e_fdir.c b/drivers/net/i40e/i40e_fdir.c index d59399afe..3a82cafac 100644 --- a/drivers/net/i40e/i40e_fdir.c +++ b/drivers/net/i40e/i40e_fdir.c @@ -269,6 +269,7 @@ i40e_fdir_teardown(struct i40e_pf *pf) { struct i40e_hw *hw = I40E_PF_TO_HW(pf); struct i40e_vsi *vsi; + struct rte_eth_dev *dev = pf->adapter->eth_dev; vsi = pf->fdir.fdir_vsi; if (!vsi) @@ -280,8 +281,10 @@ i40e_fdir_teardown(struct i40e_pf *pf) if (err) PMD_DRV_LOG(DEBUG, "Failed to do FDIR RX switch off"); i40e_dev_rx_queue_release(pf->fdir.rxq); + rte_eth_dma_zone_free(dev, "fdir_rx_ring", pf->fdir.rxq->queue_id); pf->fdir.rxq = NULL; i40e_dev_tx_queue_release(pf->fdir.txq); + rte_eth_dma_zone_free(dev, "fdir_tx_ring", pf->fdir.txq->queue_id); pf->fdir.txq = NULL; i40e_vsi_release(vsi); pf->fdir.fdir_vsi = NULL; diff --git a/drivers/net/i40e/i40e_rxtx.c b/drivers/net/i40e/i40e_rxtx.c index 5e7c86ed8..99cec9b99 100644 --- a/drivers/net/i40e/i40e_rxtx.c +++ b/drivers/net/i40e/i40e_rxtx.c @@ -2900,6 +2900,7 @@ i40e_dev_free_queues(struct rte_eth_dev *dev) continue; i40e_dev_rx_queue_release(dev->data->rx_queues[i]); dev->data->rx_queues[i] = NULL; + rte_eth_dma_zone_free(dev, "rx_ring", i); } for (i = 0; i < dev->data->nb_tx_queues; i++) { @@ -2907,6 +2908,7 @@ i40e_dev_free_queues(struct rte_eth_dev *dev) continue; i40e_dev_tx_queue_release(dev->data->tx_queues[i]); dev->data->tx_queues[i] = NULL; + rte_eth_dma_zone_free(dev, "tx_ring", i); } } -- 2.17.2