[dpdk-stable] patch 'net/i40e: fix global register recovery' has been queued to stable release 20.11.1

luca.boccassi at gmail.com luca.boccassi at gmail.com
Fri Feb 5 12:15:23 CET 2021


Hi,

FYI, your patch has been queued to stable release 20.11.1

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/07/21. 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/de803d7e033ee2cdb5df86ab47a46ddae1041875

Thanks.

Luca Boccassi

---
>From de803d7e033ee2cdb5df86ab47a46ddae1041875 Mon Sep 17 00:00:00 2001
From: Beilei Xing <beilei.xing at intel.com>
Date: Fri, 20 Nov 2020 16:49:47 +0800
Subject: [PATCH] net/i40e: fix global register recovery

[ upstream commit ac241c74ac75b2670788635b1a8e6809afae0827 ]

PMD configures the global register I40E_GLINT_CTL during
device initialization to work around the Rx write back
issue. But when a device is bound from DPDK to kernel,
the global register is not recovered to the original
state, it will cause kernel driver performance drop issue.
This patch fixes this issue.

Fixes: be6c228d4da3 ("i40e: support Rx interrupt")
Fixes: 4ab831449a1c ("net/i40e: fix interrupt conflict with multi-driver")

Signed-off-by: Beilei Xing <beilei.xing at intel.com>
Acked-by: Jeff Guo <jia.guo at intel.com>
---
 drivers/net/i40e/i40e_ethdev.c | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
index f54769c29d..2cb18ecc03 100644
--- a/drivers/net/i40e/i40e_ethdev.c
+++ b/drivers/net/i40e/i40e_ethdev.c
@@ -763,6 +763,21 @@ static inline void i40e_config_automask(struct i40e_pf *pf)
 	I40E_WRITE_REG(hw, I40E_GLINT_CTL, val);
 }
 
+static inline void i40e_clear_automask(struct i40e_pf *pf)
+{
+	struct i40e_hw *hw = I40E_PF_TO_HW(pf);
+	uint32_t val;
+
+	val = I40E_READ_REG(hw, I40E_GLINT_CTL);
+	val &= ~(I40E_GLINT_CTL_DIS_AUTOMASK_PF0_MASK |
+		 I40E_GLINT_CTL_DIS_AUTOMASK_VF0_MASK);
+
+	if (!pf->support_multi_driver)
+		val &= ~I40E_GLINT_CTL_DIS_AUTOMASK_N_MASK;
+
+	I40E_WRITE_REG(hw, I40E_GLINT_CTL, val);
+}
+
 #define I40E_FLOW_CONTROL_ETHERTYPE  0x8808
 
 /*
@@ -2741,6 +2756,8 @@ i40e_dev_close(struct rte_eth_dev *dev)
 	/* Remove all Traffic Manager configuration */
 	i40e_tm_conf_uninit(dev);
 
+	i40e_clear_automask(pf);
+
 	hw->adapter_closed = 1;
 	return ret;
 }
-- 
2.29.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2021-02-05 11:18:30.950659779 +0000
+++ 0037-net-i40e-fix-global-register-recovery.patch	2021-02-05 11:18:28.690688903 +0000
@@ -1 +1 @@
-From ac241c74ac75b2670788635b1a8e6809afae0827 Mon Sep 17 00:00:00 2001
+From de803d7e033ee2cdb5df86ab47a46ddae1041875 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ac241c74ac75b2670788635b1a8e6809afae0827 ]
+
@@ -15 +16,0 @@
-Cc: stable at dpdk.org


More information about the stable mailing list