patch 'app/testpmd: fix GRO packets flush on timeout' has been queued to stable release 23.11.1
Xueming Li
xuemingl at nvidia.com
Tue Mar 5 10:47:57 CET 2024
Hi,
FYI, your patch has been queued to stable release 23.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 03/31/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=05bea47b81f3f38d07cb3aedc6fc2a578c3caae8
Thanks.
Xueming Li <xuemingl at nvidia.com>
---
>From 05bea47b81f3f38d07cb3aedc6fc2a578c3caae8 Mon Sep 17 00:00:00 2001
From: Kumara Parameshwaran <kumaraparamesh92 at gmail.com>
Date: Fri, 16 Feb 2024 09:17:50 +0530
Subject: [PATCH] app/testpmd: fix GRO packets flush on timeout
Cc: Xueming Li <xuemingl at nvidia.com>
[ upstream commit 461c287ab55303bad1e68bd1dfac6e6ec27953c3 ]
In heavy-weight mode GRO which is based on timer, the GRO packets
will not be flushed in spite of timer expiry if there is no packet
in the current poll.
If timer mode GRO is enabled the rte_gro_timeout_flush API should be
invoked.
Fixes: b7091f1dcfbc ("app/testpmd: enable the heavyweight mode TCP/IPv4 GRO")
Signed-off-by: Kumara Parameshwaran <kumaraparamesh92 at gmail.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit at amd.com>
---
app/test-pmd/csumonly.c | 21 +++++++++++++++++----
1 file changed, 17 insertions(+), 4 deletions(-)
diff --git a/app/test-pmd/csumonly.c b/app/test-pmd/csumonly.c
index 21210aff43..d73f08b2c6 100644
--- a/app/test-pmd/csumonly.c
+++ b/app/test-pmd/csumonly.c
@@ -870,16 +870,28 @@ pkt_burst_checksum_forward(struct fwd_stream *fs)
/* receive a burst of packet */
nb_rx = common_fwd_stream_receive(fs, pkts_burst, nb_pkt_per_burst);
- if (unlikely(nb_rx == 0))
+ if (unlikely(nb_rx == 0)) {
+#ifndef RTE_LIB_GRO
return false;
+#else
+ gro_enable = gro_ports[fs->rx_port].enable;
+ /*
+ * Check if packets need to be flushed in the GRO context
+ * due to a timeout.
+ *
+ * Continue only in GRO heavyweight mode and if there are
+ * packets in the GRO context.
+ */
+ if (!gro_enable || (gro_flush_cycles == GRO_DEFAULT_FLUSH_CYCLES) ||
+ (rte_gro_get_pkt_count(current_fwd_lcore()->gro_ctx) == 0))
+ return false;
+#endif
+ }
rx_bad_ip_csum = 0;
rx_bad_l4_csum = 0;
rx_bad_outer_l4_csum = 0;
rx_bad_outer_ip_csum = 0;
-#ifdef RTE_LIB_GRO
- gro_enable = gro_ports[fs->rx_port].enable;
-#endif
txp = &ports[fs->tx_port];
tx_offloads = txp->dev_conf.txmode.offloads;
@@ -1110,6 +1122,7 @@ tunnel_update:
}
#ifdef RTE_LIB_GRO
+ gro_enable = gro_ports[fs->rx_port].enable;
if (unlikely(gro_enable)) {
if (gro_flush_cycles == GRO_DEFAULT_FLUSH_CYCLES) {
nb_rx = rte_gro_reassemble_burst(pkts_burst, nb_rx,
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2024-03-05 17:39:35.071099836 +0800
+++ 0136-app-testpmd-fix-GRO-packets-flush-on-timeout.patch 2024-03-05 17:39:31.093566504 +0800
@@ -1 +1 @@
-From 461c287ab55303bad1e68bd1dfac6e6ec27953c3 Mon Sep 17 00:00:00 2001
+From 05bea47b81f3f38d07cb3aedc6fc2a578c3caae8 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl at nvidia.com>
+
+[ upstream commit 461c287ab55303bad1e68bd1dfac6e6ec27953c3 ]
@@ -14 +16,0 @@
-Cc: stable at dpdk.org
More information about the stable
mailing list