patch 'net/ixgbe: do not update link status in secondary process' has been queued to stable release 23.11.2
Xueming Li
xuemingl at nvidia.com
Fri Jul 12 12:44:49 CEST 2024
Hi,
FYI, your patch has been queued to stable release 23.11.2
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 07/14/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://git.dpdk.org/dpdk-stable/log/?h=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=6f3188b1fccc5840cbc8152f5ed5922b1f6a78a6
Thanks.
Xueming Li <xuemingl at nvidia.com>
---
>From 6f3188b1fccc5840cbc8152f5ed5922b1f6a78a6 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen at networkplumber.org>
Date: Wed, 20 Mar 2024 10:33:04 -0700
Subject: [PATCH] net/ixgbe: do not update link status in secondary process
Cc: Xueming Li <xuemingl at nvidia.com>
[ upstream commit 5ffd40b85febd2a80b88b4cfbf4e1dd7e5f059c5 ]
The code to update link status is not safe in secondary process.
If called from secondary it will crash, example from dumpcap:
ixgbe_dev_link_update_share()
ixgbe_dev_link_update()
rte_eth_link_get()
Fixes: af75078fece3 ("first public release")
Reported-by: Jun Wang <junwang01 at cestc.cn>
Signed-off-by: Stephen Hemminger <stephen at networkplumber.org>
Acked-by: Bruce Richardson <bruce.richardson at intel.com>
---
drivers/net/ixgbe/ixgbe_ethdev.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c
index a32d3a6d7c..a54920042b 100644
--- a/drivers/net/ixgbe/ixgbe_ethdev.c
+++ b/drivers/net/ixgbe/ixgbe_ethdev.c
@@ -4289,6 +4289,9 @@ ixgbe_dev_link_update_share(struct rte_eth_dev *dev,
int wait = 1;
u32 esdp_reg;
+ if (rte_eal_process_type() != RTE_PROC_PRIMARY)
+ return -1;
+
memset(&link, 0, sizeof(link));
link.link_status = RTE_ETH_LINK_DOWN;
link.link_speed = RTE_ETH_SPEED_NUM_NONE;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2024-07-12 18:40:17.022448777 +0800
+++ 0063-net-ixgbe-do-not-update-link-status-in-secondary-pro.patch 2024-07-12 18:40:14.146594222 +0800
@@ -1 +1 @@
-From 5ffd40b85febd2a80b88b4cfbf4e1dd7e5f059c5 Mon Sep 17 00:00:00 2001
+From 6f3188b1fccc5840cbc8152f5ed5922b1f6a78a6 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl at nvidia.com>
+
+[ upstream commit 5ffd40b85febd2a80b88b4cfbf4e1dd7e5f059c5 ]
@@ -13 +15,0 @@
-Cc: stable at dpdk.org
@@ -23 +25 @@
-index bbdc996f31..a6916da0c5 100644
+index a32d3a6d7c..a54920042b 100644
@@ -26 +28 @@
-@@ -4293,6 +4293,9 @@ ixgbe_dev_link_update_share(struct rte_eth_dev *dev,
+@@ -4289,6 +4289,9 @@ ixgbe_dev_link_update_share(struct rte_eth_dev *dev,
More information about the stable
mailing list