Skip to contentSkip to conversation

net/i40e: fix wrong data path selection in secondary process

PATCH Applied [email protected] 2 participants 2 messages Jun 9, 2021 – Jun 21, 2021 Network drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net/i40e: fix wrong data path selection in secondary process

From: Dapeng Yu <[email protected]>

The flag use_avx2 and use_avx512 are defined as local variables, they will not be aware by the secondary process, then wrong data path is selected. Fix the issue by moving them into struct i40e_adapter.

Fixes 6ada10deac66 ("net/i40e: remove devarg use-latest-supported-vec")
Fixes e6a6a138919f ("net/i40e: add AVX512 vector path")
---
 drivers/net/i40e/i40e_ethdev.h |  6 +++
 drivers/net/i40e/i40e_rxtx.c   | 71 +++++++++++++++++++++++-----------
 2 files changed, 54 insertions(+), 23 deletions(-)
drivers/net/i40e/i40e_ethdev.h +6 -0
index cdf1c2fe1f..ba6acd1878 100644
@@ -1313,6 +1313,12 @@ struct i40e_adapter {
 
 	/* For RSS reta table update */
 	uint8_t rss_reta_updated;
+#ifdef RTE_ARCH_X86
+	bool rx_use_avx2;
+	bool rx_use_avx512;
+	bool tx_use_avx2;
+	bool tx_use_avx512;
+#endif
 };
 
 /**
drivers/net/i40e/i40e_rxtx.c +48 -23

145 lines not on this page · raw message

Signature · 1 line
2.27.0
Acked-by on v1 1/1 Applied
#1 lore raw
Quoted 16 lines

-----Original Message-----
From: Yu, DapengX <[email protected]>
Sent: Wednesday, June 9, 2021 3:05 PM
To: Xing, Beilei <[email protected]>
Cc: [email protected]; Zhang, Qi Z <[email protected]>; Yu, DapengX <[email protected]>; [email protected]
Subject: [PATCH] net/i40e: fix wrong data path selection in secondary process

From: Dapeng Yu <[email protected]>

The flag use_avx2 and use_avx512 are defined as local variables, they will not be aware by the secondary process, then wrong data path is selected. Fix the issue by moving them into struct i40e_adapter.

Quoted 5 lines
Fixes 6ada10deac66 ("net/i40e: remove devarg use-latest-supported-vec")
Fixes e6a6a138919f ("net/i40e: add AVX512 vector path")

Applied to dpdk-next-net-intel.

Thanks
Qi