patch 'net/e1000/base: fix semaphore timeout value' has been queued to stable release 24.11.2
Kevin Traynor
ktraynor at redhat.com
Thu Feb 13 10:58:56 CET 2025
Hi,
FYI, your patch has been queued to stable release 24.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 02/17/25. 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/kevintraynor/dpdk-stable
This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/dd2a3409a576403fd8a7dfc89a99800a14e6e60b
Thanks.
Kevin
---
>From dd2a3409a576403fd8a7dfc89a99800a14e6e60b Mon Sep 17 00:00:00 2001
From: Pawel Malinowski <pawel.malinowski at intel.com>
Date: Thu, 6 Feb 2025 16:08:37 +0000
Subject: [PATCH] net/e1000/base: fix semaphore timeout value
[ upstream commit c8bcaf0f2a02995b447c121e860fd550b9c55114 ]
According to datasheet, software ownership of SWSM.SWESMBI bit should
not exceed 100ms. Current implementation caused incorrect timeout
counter values, where each iteration equals 50us delay. Because of that
driver was allowed to wait for semaphore even for 1.5s. This might
trigger DPC timeout.
This implementation hardcodes value to 2000, which multiplied by 50us,
gives 100ms of possible wait time.
Fixes: af75078fece3 ("first public release")
Signed-off-by: Pawel Malinowski <pawel.malinowski at intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov at intel.com>
Acked-by: Bruce Richardson <bruce.richardson at intel.com>
---
drivers/net/e1000/base/e1000_defines.h | 1 +
drivers/net/e1000/base/e1000_mac.c | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/e1000/base/e1000_defines.h b/drivers/net/e1000/base/e1000_defines.h
index 3fbb6c8ea4..97cc2797b2 100644
--- a/drivers/net/e1000/base/e1000_defines.h
+++ b/drivers/net/e1000/base/e1000_defines.h
@@ -505,4 +505,5 @@
#define E1000_SWSM_SMBI 0x00000001 /* Driver Semaphore bit */
#define E1000_SWSM_SWESMBI 0x00000002 /* FW Semaphore bit */
+#define E1000_SWSM_TIMEOUT 2000 /* Driver Semaphore max timeout counter */
#define E1000_SWSM_DRV_LOAD 0x00000008 /* Driver Loaded Bit */
diff --git a/drivers/net/e1000/base/e1000_mac.c b/drivers/net/e1000/base/e1000_mac.c
index d3b3a6bac9..cf0a9f21e1 100644
--- a/drivers/net/e1000/base/e1000_mac.c
+++ b/drivers/net/e1000/base/e1000_mac.c
@@ -1689,5 +1689,5 @@ s32 e1000_get_hw_semaphore_generic(struct e1000_hw *hw)
{
u32 swsm;
- s32 timeout = hw->nvm.word_size + 1;
+ s32 timeout = E1000_SWSM_TIMEOUT;
s32 i = 0;
--
2.48.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-12 17:29:44.090109931 +0000
+++ 0089-net-e1000-base-fix-semaphore-timeout-value.patch 2025-02-12 17:29:34.550947123 +0000
@@ -1 +1 @@
-From c8bcaf0f2a02995b447c121e860fd550b9c55114 Mon Sep 17 00:00:00 2001
+From dd2a3409a576403fd8a7dfc89a99800a14e6e60b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit c8bcaf0f2a02995b447c121e860fd550b9c55114 ]
+
@@ -16 +17,0 @@
-Cc: stable at dpdk.org
@@ -22,2 +23,2 @@
- drivers/net/intel/e1000/base/e1000_defines.h | 1 +
- drivers/net/intel/e1000/base/e1000_mac.c | 2 +-
+ drivers/net/e1000/base/e1000_defines.h | 1 +
+ drivers/net/e1000/base/e1000_mac.c | 2 +-
@@ -26 +27 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_defines.h b/drivers/net/intel/e1000/base/e1000_defines.h
+diff --git a/drivers/net/e1000/base/e1000_defines.h b/drivers/net/e1000/base/e1000_defines.h
@@ -28,2 +29,2 @@
---- a/drivers/net/intel/e1000/base/e1000_defines.h
-+++ b/drivers/net/intel/e1000/base/e1000_defines.h
+--- a/drivers/net/e1000/base/e1000_defines.h
++++ b/drivers/net/e1000/base/e1000_defines.h
@@ -36 +37 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_mac.c b/drivers/net/intel/e1000/base/e1000_mac.c
+diff --git a/drivers/net/e1000/base/e1000_mac.c b/drivers/net/e1000/base/e1000_mac.c
@@ -38,2 +39,2 @@
---- a/drivers/net/intel/e1000/base/e1000_mac.c
-+++ b/drivers/net/intel/e1000/base/e1000_mac.c
+--- a/drivers/net/e1000/base/e1000_mac.c
++++ b/drivers/net/e1000/base/e1000_mac.c
More information about the stable
mailing list