patch 'net/i40e: fix AVX512 fast-free path' has been queued to stable release 21.11.4

Kevin Traynor ktraynor at redhat.com
Wed Mar 22 11:32:01 CET 2023


Hi,

FYI, your patch has been queued to stable release 21.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 03/24/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://github.com/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/ac111b80fe45d3c13c82068e12bba2645b04e6ed

Thanks.

Kevin

---
>From ac111b80fe45d3c13c82068e12bba2645b04e6ed Mon Sep 17 00:00:00 2001
From: Kamalakshitha Aligeri <kamalakshitha.aligeri at arm.com>
Date: Tue, 7 Mar 2023 19:32:21 +0000
Subject: [PATCH] net/i40e: fix AVX512 fast-free path
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit 1ad4bea0d73a7671095c2c675f9bb8b19503ac06 ]

In i40e_tx_free_bufs_avx512 fast-free path, when cache is NULL,
non fast-free path is being executed. Fixed the bug by calling
rte_mempool_generic_put API that handles the cache==NULL case.

Fixes: 5171b4ee6b6b ("net/i40e: optimize Tx by using AVX512")

Signed-off-by: Kamalakshitha Aligeri <kamalakshitha.aligeri at arm.com>
Reviewed-by: Ruifeng Wang <ruifeng.wang at arm.com>
Reviewed-by: Feifei Wang <feifei.wang2 at arm.com>
Acked-by: Morten Brørup <mb at smartsharesystems.com>
---
 .mailmap                                |  1 +
 drivers/net/i40e/i40e_rxtx_vec_avx512.c | 12 ++++--------
 2 files changed, 5 insertions(+), 8 deletions(-)

diff --git a/.mailmap b/.mailmap
index 6a56239c3a..f4568f4984 100644
--- a/.mailmap
+++ b/.mailmap
@@ -680,4 +680,5 @@ Kaiwen Deng <kaiwenx.deng at intel.com>
 Kalesh AP <kalesh-anakkur.purayil at broadcom.com>
 Kamalakannan R <kamalakannan.r at intel.com>
+Kamalakshitha Aligeri <kamalakshitha.aligeri at arm.com>
 Kamil Bednarczyk <kamil.bednarczyk at intel.com>
 Kamil Chalupnik <kamilx.chalupnik at intel.com>
diff --git a/drivers/net/i40e/i40e_rxtx_vec_avx512.c b/drivers/net/i40e/i40e_rxtx_vec_avx512.c
index 2e8a3f0df6..2ad9a920a1 100644
--- a/drivers/net/i40e/i40e_rxtx_vec_avx512.c
+++ b/drivers/net/i40e/i40e_rxtx_vec_avx512.c
@@ -907,14 +907,11 @@ i40e_tx_free_bufs_avx512(struct i40e_tx_queue *txq)
 				rte_lcore_id());
 
-		if (!cache || cache->len == 0)
-			goto normal;
-
-		cache_objs = &cache->objs[cache->len];
-
-		if (n > RTE_MEMPOOL_CACHE_MAX_SIZE) {
-			rte_mempool_ops_enqueue_bulk(mp, (void *)txep, n);
+		if (!cache || n > RTE_MEMPOOL_CACHE_MAX_SIZE) {
+			rte_mempool_generic_put(mp, (void *)txep, n, cache);
 			goto done;
 		}
 
+		cache_objs = &cache->objs[cache->len];
+
 		/* The cache follows the following algorithm
 		 *   1. Add the objects to the cache
@@ -948,5 +945,4 @@ i40e_tx_free_bufs_avx512(struct i40e_tx_queue *txq)
 	}
 
-normal:
 	m = rte_pktmbuf_prefree_seg(txep[0].mbuf);
 	if (likely(m)) {
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2023-03-22 10:30:08.271775142 +0000
+++ 0014-net-i40e-fix-AVX512-fast-free-path.patch	2023-03-22 10:30:07.917866567 +0000
@@ -1 +1 @@
-From 1ad4bea0d73a7671095c2c675f9bb8b19503ac06 Mon Sep 17 00:00:00 2001
+From ac111b80fe45d3c13c82068e12bba2645b04e6ed Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit 1ad4bea0d73a7671095c2c675f9bb8b19503ac06 ]
+
@@ -14 +15,0 @@
-Cc: stable at dpdk.org
@@ -26 +27 @@
-index 9578b86866..c77cdc9ddf 100644
+index 6a56239c3a..f4568f4984 100644
@@ -29 +30 @@
-@@ -682,4 +682,5 @@ Kaiwen Deng <kaiwenx.deng at intel.com>
+@@ -680,4 +680,5 @@ Kaiwen Deng <kaiwenx.deng at intel.com>
@@ -36 +37 @@
-index d3c7bfd121..ad0893324d 100644
+index 2e8a3f0df6..2ad9a920a1 100644
@@ -39 +40 @@
-@@ -784,14 +784,11 @@ i40e_tx_free_bufs_avx512(struct i40e_tx_queue *txq)
+@@ -907,14 +907,11 @@ i40e_tx_free_bufs_avx512(struct i40e_tx_queue *txq)
@@ -58 +59 @@
-@@ -825,5 +822,4 @@ i40e_tx_free_bufs_avx512(struct i40e_tx_queue *txq)
+@@ -948,5 +945,4 @@ i40e_tx_free_bufs_avx512(struct i40e_tx_queue *txq)



More information about the stable mailing list