patch 'net/nfp: fix crash on close' has been queued to stable release 22.11.4

Xueming Li xuemingl at nvidia.com
Mon Dec 11 11:10:40 CET 2023


Hi,

FYI, your patch has been queued to stable release 22.11.4

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 12/13/23. 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://git.dpdk.org/dpdk-stable/log/?h=22.11-staging

This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=22.11-staging&id=e671505da168d36e6c001395bf78a574a5a51a68

Thanks.

Xueming Li <xuemingl at nvidia.com>

---
>From e671505da168d36e6c001395bf78a574a5a51a68 Mon Sep 17 00:00:00 2001
From: Chaoyong He <chaoyong.he at corigine.com>
Date: Tue, 17 Oct 2023 10:37:30 +0800
Subject: [PATCH] net/nfp: fix crash on close
Cc: Xueming Li <xuemingl at nvidia.com>

[ upstream commit 3b9dcf252c118705bb17f450318d3495b4608092 ]

The ".dev_close" should not call rte_eth_dev_release_port() API
directly, the rte_eth_dev_close() API will do it.

Fixes: 831c44ab7869 ("net/nfp: add flower PF related routines")

Signed-off-by: Chaoyong He <chaoyong.he at corigine.com>
Reviewed-by: Long Wu <long.wu at corigine.com>
Reviewed-by: Peng Zhang <peng.zhang at corigine.com>
---
 drivers/net/nfp/flower/nfp_flower.c | 2 --
 drivers/net/nfp/nfp_ethdev.c        | 1 -
 2 files changed, 3 deletions(-)

diff --git a/drivers/net/nfp/flower/nfp_flower.c b/drivers/net/nfp/flower/nfp_flower.c
index 9872e010d2..5896d208d0 100644
--- a/drivers/net/nfp/flower/nfp_flower.c
+++ b/drivers/net/nfp/flower/nfp_flower.c
@@ -224,8 +224,6 @@ nfp_flower_pf_close(struct rte_eth_dev *dev)
 
 	nn_cfg_writeb(hw, NFP_NET_CFG_LSC, 0xff);
 
-	rte_eth_dev_release_port(dev);
-
 	/* Now it is safe to free all PF resources */
 	PMD_DRV_LOG(INFO, "Freeing PF resources");
 	nfp_cpp_area_free(pf_dev->ctrl_area);
diff --git a/drivers/net/nfp/nfp_ethdev.c b/drivers/net/nfp/nfp_ethdev.c
index 689e26f1e1..71832bfa23 100644
--- a/drivers/net/nfp/nfp_ethdev.c
+++ b/drivers/net/nfp/nfp_ethdev.c
@@ -304,7 +304,6 @@ nfp_net_close(struct rte_eth_dev *dev)
 	/* Mark this port as unused and free device priv resources*/
 	nn_cfg_writeb(hw, NFP_NET_CFG_LSC, 0xff);
 	app_fw_nic->ports[hw->idx] = NULL;
-	rte_eth_dev_release_port(dev);
 
 	for (i = 0; i < app_fw_nic->total_phyports; i++) {
 		/* Check to see if ports are still in use */
-- 
2.25.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2023-12-11 17:56:23.699270100 +0800
+++ 0015-net-nfp-fix-crash-on-close.patch	2023-12-11 17:56:22.897652300 +0800
@@ -1 +1 @@
-From 3b9dcf252c118705bb17f450318d3495b4608092 Mon Sep 17 00:00:00 2001
+From e671505da168d36e6c001395bf78a574a5a51a68 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl at nvidia.com>
+
+[ upstream commit 3b9dcf252c118705bb17f450318d3495b4608092 ]
@@ -10 +12,0 @@
-Cc: stable at dpdk.org
@@ -21 +23 @@
-index 0c54d7ed27..60d843451e 100644
+index 9872e010d2..5896d208d0 100644
@@ -24 +26 @@
-@@ -221,8 +221,6 @@ nfp_flower_pf_close(struct rte_eth_dev *dev)
+@@ -224,8 +224,6 @@ nfp_flower_pf_close(struct rte_eth_dev *dev)
@@ -34 +36 @@
-index 20940072fe..d32a82210c 100644
+index 689e26f1e1..71832bfa23 100644
@@ -37,2 +39,2 @@
-@@ -286,7 +286,6 @@ nfp_net_close(struct rte_eth_dev *dev)
- 	/* Mark this port as unused and free device priv resources */
+@@ -304,7 +304,6 @@ nfp_net_close(struct rte_eth_dev *dev)
+ 	/* Mark this port as unused and free device priv resources*/


More information about the stable mailing list