[dpdk-stable] patch 'app/testpmd: fix txonly flow generation entropy' has been queued to stable release 19.11.1

luca.boccassi at gmail.com luca.boccassi at gmail.com
Mon Feb 17 18:45:18 CET 2020


Hi,

FYI, your patch has been queued to stable release 19.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/19/20. 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.

Thanks.

Luca Boccassi

---
>From 7b6cf048069f44735326a74cdc56d43e86d2ad84 Mon Sep 17 00:00:00 2001
From: Viacheslav Ovsiienko <viacheslavo at mellanox.com>
Date: Sun, 9 Feb 2020 17:02:39 +0000
Subject: [PATCH] app/testpmd: fix txonly flow generation entropy

[ upstream commit 0eb89ba9f49f3f5979a974b9208100eed36c382e ]

The testpmd application in txonly forwarding mode has an option
to generate the packet flows by varying the destination IP address.
The patch increments the IP for each packet sent, this improves
the entropy and RSS distribution on the peer receiving size
is getting more uniform.

Fixes: 01b645dcff7f ("app/testpmd: move txonly prepare in separate function")

Signed-off-by: Viacheslav Ovsiienko <viacheslavo at mellanox.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit at intel.com>
---
 app/test-pmd/txonly.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/app/test-pmd/txonly.c b/app/test-pmd/txonly.c
index d42a157f8f..8ed436def5 100644
--- a/app/test-pmd/txonly.c
+++ b/app/test-pmd/txonly.c
@@ -153,7 +153,6 @@ pkt_burst_prepare(struct rte_mbuf *pkt, struct rte_mempool *mbp,
 		const uint16_t vlan_tci_outer, const uint64_t ol_flags)
 {
 	struct rte_mbuf *pkt_segs[RTE_MAX_SEGS_PER_PKT];
-	uint8_t  ip_var = RTE_PER_LCORE(_ip_var);
 	struct rte_mbuf *pkt_seg;
 	uint32_t nb_segs, pkt_len;
 	uint8_t i;
@@ -192,6 +191,7 @@ pkt_burst_prepare(struct rte_mbuf *pkt, struct rte_mempool *mbp,
 	copy_buf_to_pkt(&pkt_ip_hdr, sizeof(pkt_ip_hdr), pkt,
 			sizeof(struct rte_ether_hdr));
 	if (txonly_multi_flow) {
+		uint8_t  ip_var = RTE_PER_LCORE(_ip_var);
 		struct rte_ipv4_hdr *ip_hdr;
 		uint32_t addr;
 
@@ -207,6 +207,7 @@ pkt_burst_prepare(struct rte_mbuf *pkt, struct rte_mempool *mbp,
 		 */
 		addr = (tx_ip_dst_addr | (ip_var++ << 8)) + rte_lcore_id();
 		ip_hdr->src_addr = rte_cpu_to_be_32(addr);
+		RTE_PER_LCORE(_ip_var) = ip_var;
 	}
 	copy_buf_to_pkt(&pkt_udp_hdr, sizeof(pkt_udp_hdr), pkt,
 			sizeof(struct rte_ether_hdr) +
@@ -314,7 +315,7 @@ pkt_burst_transmit(struct fwd_stream *fs)
 	fs->tx_packets += nb_tx;
 
 	if (txonly_multi_flow)
-		RTE_PER_LCORE(_ip_var) += nb_tx;
+		RTE_PER_LCORE(_ip_var) -= nb_pkt - nb_tx;
 
 #ifdef RTE_TEST_PMD_RECORD_BURST_STATS
 	fs->tx_burst_stats.pkt_burst_spread[nb_tx]++;
-- 
2.20.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2020-02-17 17:00:16.051158752 +0000
+++ 0026-app-testpmd-fix-txonly-flow-generation-entropy.patch	2020-02-17 17:00:15.323950682 +0000
@@ -1,8 +1,10 @@
-From 0eb89ba9f49f3f5979a974b9208100eed36c382e Mon Sep 17 00:00:00 2001
+From 7b6cf048069f44735326a74cdc56d43e86d2ad84 Mon Sep 17 00:00:00 2001
 From: Viacheslav Ovsiienko <viacheslavo at mellanox.com>
 Date: Sun, 9 Feb 2020 17:02:39 +0000
 Subject: [PATCH] app/testpmd: fix txonly flow generation entropy
 
+[ upstream commit 0eb89ba9f49f3f5979a974b9208100eed36c382e ]
+
 The testpmd application in txonly forwarding mode has an option
 to generate the packet flows by varying the destination IP address.
 The patch increments the IP for each packet sent, this improves
@@ -10,7 +12,6 @@
 is getting more uniform.
 
 Fixes: 01b645dcff7f ("app/testpmd: move txonly prepare in separate function")
-Cc: stable at dpdk.org
 
 Signed-off-by: Viacheslav Ovsiienko <viacheslavo at mellanox.com>
 Reviewed-by: Ferruh Yigit <ferruh.yigit at intel.com>
@@ -19,7 +20,7 @@
  1 file changed, 3 insertions(+), 2 deletions(-)
 
 diff --git a/app/test-pmd/txonly.c b/app/test-pmd/txonly.c
-index 4b5bec443b..8a1989fc96 100644
+index d42a157f8f..8ed436def5 100644
 --- a/app/test-pmd/txonly.c
 +++ b/app/test-pmd/txonly.c
 @@ -153,7 +153,6 @@ pkt_burst_prepare(struct rte_mbuf *pkt, struct rte_mempool *mbp,
@@ -30,7 +31,7 @@
  	struct rte_mbuf *pkt_seg;
  	uint32_t nb_segs, pkt_len;
  	uint8_t i;
-@@ -193,6 +192,7 @@ pkt_burst_prepare(struct rte_mbuf *pkt, struct rte_mempool *mbp,
+@@ -192,6 +191,7 @@ pkt_burst_prepare(struct rte_mbuf *pkt, struct rte_mempool *mbp,
  	copy_buf_to_pkt(&pkt_ip_hdr, sizeof(pkt_ip_hdr), pkt,
  			sizeof(struct rte_ether_hdr));
  	if (txonly_multi_flow) {
@@ -38,7 +39,7 @@
  		struct rte_ipv4_hdr *ip_hdr;
  		uint32_t addr;
  
-@@ -208,6 +208,7 @@ pkt_burst_prepare(struct rte_mbuf *pkt, struct rte_mempool *mbp,
+@@ -207,6 +207,7 @@ pkt_burst_prepare(struct rte_mbuf *pkt, struct rte_mempool *mbp,
  		 */
  		addr = (tx_ip_dst_addr | (ip_var++ << 8)) + rte_lcore_id();
  		ip_hdr->src_addr = rte_cpu_to_be_32(addr);
@@ -46,7 +47,7 @@
  	}
  	copy_buf_to_pkt(&pkt_udp_hdr, sizeof(pkt_udp_hdr), pkt,
  			sizeof(struct rte_ether_hdr) +
-@@ -315,7 +316,7 @@ pkt_burst_transmit(struct fwd_stream *fs)
+@@ -314,7 +315,7 @@ pkt_burst_transmit(struct fwd_stream *fs)
  	fs->tx_packets += nb_tx;
  
  	if (txonly_multi_flow)


More information about the stable mailing list