[dpdk-stable] patch 'net/netvsc: handle Tx completions based on burst size' has been queued to stable release 19.11.3

luca.boccassi at gmail.com luca.boccassi at gmail.com
Tue May 19 15:03:02 CEST 2020


Hi,

FYI, your patch has been queued to stable release 19.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/21/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 9f54fa3e2b37e2ba173f18c0f1e4cca6b4e74596 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen at networkplumber.org>
Date: Tue, 31 Mar 2020 10:14:02 -0700
Subject: [PATCH] net/netvsc: handle Tx completions based on burst size

[ upstream commit 56edef9906558c69a1440173a5a3aac8f8f8710f ]

If tx_free_thresh is quite low, it is possible that we need to
cleanup based on burst size.

Fixes: fc30efe3a22e ("net/netvsc: change Rx descriptor setup and sizing")

Signed-off-by: Stephen Hemminger <stephen at networkplumber.org>
---
 drivers/net/netvsc/hn_rxtx.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/netvsc/hn_rxtx.c b/drivers/net/netvsc/hn_rxtx.c
index e8df846042..cbdfcc628b 100644
--- a/drivers/net/netvsc/hn_rxtx.c
+++ b/drivers/net/netvsc/hn_rxtx.c
@@ -1375,7 +1375,7 @@ hn_xmit_pkts(void *ptxq, struct rte_mbuf **tx_pkts, uint16_t nb_pkts)
 	struct hn_data *hv = txq->hv;
 	struct rte_eth_dev *vf_dev;
 	bool need_sig = false;
-	uint16_t nb_tx;
+	uint16_t nb_tx, avail;
 	int ret;
 
 	if (unlikely(hv->closed))
@@ -1390,7 +1390,8 @@ hn_xmit_pkts(void *ptxq, struct rte_mbuf **tx_pkts, uint16_t nb_pkts)
 		return (*vf_dev->tx_pkt_burst)(sub_q, tx_pkts, nb_pkts);
 	}
 
-	if (rte_mempool_avail_count(txq->txdesc_pool) <= txq->free_thresh)
+	avail = rte_mempool_avail_count(txq->txdesc_pool);
+	if (nb_pkts > avail || avail <= txq->free_thresh)
 		hn_process_events(hv, txq->queue_id, 0);
 
 	for (nb_tx = 0; nb_tx < nb_pkts; nb_tx++) {
-- 
2.20.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2020-05-19 14:04:46.453207797 +0100
+++ 0047-net-netvsc-handle-Tx-completions-based-on-burst-size.patch	2020-05-19 14:04:44.184647792 +0100
@@ -1,13 +1,14 @@
-From 56edef9906558c69a1440173a5a3aac8f8f8710f Mon Sep 17 00:00:00 2001
+From 9f54fa3e2b37e2ba173f18c0f1e4cca6b4e74596 Mon Sep 17 00:00:00 2001
 From: Stephen Hemminger <stephen at networkplumber.org>
 Date: Tue, 31 Mar 2020 10:14:02 -0700
 Subject: [PATCH] net/netvsc: handle Tx completions based on burst size
 
+[ upstream commit 56edef9906558c69a1440173a5a3aac8f8f8710f ]
+
 If tx_free_thresh is quite low, it is possible that we need to
 cleanup based on burst size.
 
 Fixes: fc30efe3a22e ("net/netvsc: change Rx descriptor setup and sizing")
-Cc: stable at dpdk.org
 
 Signed-off-by: Stephen Hemminger <stephen at networkplumber.org>
 ---


More information about the stable mailing list