From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 74C2A43C60 for ; Thu, 7 Mar 2024 02:35:36 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6B48C42EFA; Thu, 7 Mar 2024 02:35:36 +0100 (CET) Received: from mail-wm1-f50.google.com (mail-wm1-f50.google.com [209.85.128.50]) by mails.dpdk.org (Postfix) with ESMTP id 644AB42E64 for ; Thu, 7 Mar 2024 02:35:35 +0100 (CET) Received: by mail-wm1-f50.google.com with SMTP id 5b1f17b1804b1-412e784060cso9076325e9.1 for ; Wed, 06 Mar 2024 17:35:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709775335; x=1710380135; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=CbjSRGeF/wSs36Vxl5gFv6OcKsk5KyvcBmh/lJPgln0=; b=cVltwRnjfrQdqvb+HF8+He1FRsLt0W+n5UplcHPW1jiduV28fvblKXiGD+1o3r7WSC /OqKf3lLNDGbDBqvIr1THU6yfVLU/sNj2V1efE+IaTMyJFyi1/dxiaDXbnUESzhVKHo/ qgUGEY71/UflyBjvLWAlNylRRpBOO+plfCy3Cbdl4rye5virrHY+9dpyxB9eo7T5F9hm zY2aCeZlOGhUHUEdb/LPHhyi4M9STzBcQiAU50B1cEI7M880ABMFdPcRCDpobki86avp 1Ckp66Sbhimpf0WWqgZtn3MyHS1gVEiDavGrdbO5HZooHi1oEUuAPKeJkFdnP9M5uUHK RjQA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709775335; x=1710380135; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=CbjSRGeF/wSs36Vxl5gFv6OcKsk5KyvcBmh/lJPgln0=; b=M8p82ryiwInTa+zzGhGzBcwr2ATo+4QA93VZsOnUKlBI42BPANHPsMfNc7BnmBpRVO v50bzasTpNzzKoOaoE2EfgTRWYdECiiCQMx+x8CGbEgsEPVHzA18tIEnzF9aveM5oLEE oS5G7htmYcCeWIs/fVOLv5c5k5PtFVjVQm5g0CRsehpYPaRJS6/KmoVmQdu2fCVJOgwV DQDGIii+y94IwIu20vsvThX+qE368akn+sjBCp15q/+CzwYfe+xvSlJaIPD0ibKVF4Pu eMn92rVtXfrEd5oHbMerjklbcNCKgGCM3rV2nUzAT4RDcuGKTECVc+ymzkxhA8CyMUBs dWIg== X-Forwarded-Encrypted: i=1; AJvYcCXOruGPUrMVB8jSujXERhOnMWzuJoCzWP7Zgp46cBCDx+Lv2jmQlWOgX0f9HXaweKUQfTtRSoo2Pwwl2X79mt4= X-Gm-Message-State: AOJu0YySZNscwzQ7JgaHmoc/bcpdDgXRdjEIf9hEFe5wpGkyQWzKrgYC qDyei1FBOZ8I0g9iYtwAX3Xan8LuiRDfpwiwMuKTzJ8uibAddoEX X-Google-Smtp-Source: AGHT+IElLddTwQA3R85kafj888qtJEv/xlxjdRmdmvOXT/XxP8bcoY3AiQemCjC6HRW1NsV1zTE8EQ== X-Received: by 2002:a5d:5253:0:b0:33e:2219:9804 with SMTP id k19-20020a5d5253000000b0033e22199804mr35691wrc.25.1709775335071; Wed, 06 Mar 2024 17:35:35 -0800 (PST) Received: from localhost ([137.220.120.171]) by smtp.gmail.com with ESMTPSA id bo16-20020a056000069000b0033e422d0963sm8473555wrb.41.2024.03.06.17.35.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Mar 2024 17:35:34 -0800 (PST) From: luca.boccassi@gmail.com To: Chaoyong He Cc: Long Wu , Peng Zhang , dpdk stable Subject: patch 'net/nfp: fix resource leak for PF initialization' has been queued to stable release 22.11.5 Date: Thu, 7 Mar 2024 01:31:16 +0000 Message-Id: <20240307013159.1735343-59-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240307013159.1735343-1-luca.boccassi@gmail.com> References: <20240307013159.1735343-1-luca.boccassi@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Hi, FYI, your patch has been queued to stable release 22.11.5 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 03/09/24. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/bluca/dpdk-stable This queued commit can be viewed at: https://github.com/bluca/dpdk-stable/commit/bc1e0ee2a380081930d1dd20bfe996d705d22913 Thanks. Luca Boccassi --- >From bc1e0ee2a380081930d1dd20bfe996d705d22913 Mon Sep 17 00:00:00 2001 From: Chaoyong He Date: Mon, 4 Dec 2023 09:57:14 +0800 Subject: [PATCH] net/nfp: fix resource leak for PF initialization [ upstream commit 528812a63c4c2d74ccf2c2f2aa297fcbff3ceea9 ] Fix the resource leak problem in the abnormal logic of PF initialize function. Fixes: 646ea79ce481 ("net/nfp: move PF functions into its own file") Fixes: 8ba461d1eecc ("net/nfp: introduce keepalive mechanism for multiple PF") Signed-off-by: Chaoyong He Reviewed-by: Long Wu Reviewed-by: Peng Zhang --- drivers/net/nfp/nfp_ethdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/nfp/nfp_ethdev.c b/drivers/net/nfp/nfp_ethdev.c index 9f940a12b6..3b70f5c6f1 100644 --- a/drivers/net/nfp/nfp_ethdev.c +++ b/drivers/net/nfp/nfp_ethdev.c @@ -1088,7 +1088,7 @@ nfp_pf_init(struct rte_pci_device *pci_dev) return 0; hwqueues_cleanup: - nfp_cpp_area_free(pf_dev->hwqueues_area); + nfp_cpp_area_release_free(pf_dev->hwqueues_area); pf_cleanup: rte_free(pf_dev); sym_tbl_cleanup: -- 2.39.2 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2024-03-07 01:05:39.887254737 +0000 +++ 0059-net-nfp-fix-resource-leak-for-PF-initialization.patch 2024-03-07 01:05:34.822940526 +0000 @@ -1 +1 @@ -From 528812a63c4c2d74ccf2c2f2aa297fcbff3ceea9 Mon Sep 17 00:00:00 2001 +From bc1e0ee2a380081930d1dd20bfe996d705d22913 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit 528812a63c4c2d74ccf2c2f2aa297fcbff3ceea9 ] + @@ -11 +12,0 @@ -Cc: stable@dpdk.org @@ -17,2 +18,2 @@ - drivers/net/nfp/nfp_ethdev.c | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) + drivers/net/nfp/nfp_ethdev.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) @@ -21 +22 @@ -index c132e97d1a..6fdde105ba 100644 +index 9f940a12b6..3b70f5c6f1 100644 @@ -24 +25 @@ -@@ -1333,12 +1333,13 @@ nfp_pf_init(struct rte_pci_device *pci_dev) +@@ -1088,7 +1088,7 @@ nfp_pf_init(struct rte_pci_device *pci_dev) @@ -28,2 +29,4 @@ -- nfp_cpp_area_free(pf_dev->qc_area); -+ nfp_cpp_area_release_free(pf_dev->qc_area); +- nfp_cpp_area_free(pf_dev->hwqueues_area); ++ nfp_cpp_area_release_free(pf_dev->hwqueues_area); + pf_cleanup: + rte_free(pf_dev); @@ -31,8 +33,0 @@ - free(sym_tbl); - fw_cleanup: - nfp_fw_unload(cpp); - nfp_net_keepalive_stop(&pf_dev->multi_pf); -+ nfp_net_keepalive_uninit(&pf_dev->multi_pf); - eth_table_cleanup: - free(nfp_eth_table); - hwinfo_cleanup: