From 91397bdc768befd57628e22b99d9eeb7e0ca7085 Mon Sep 17 00:00:00 2001 From: Tiwei Bie Date: Tue, 19 Feb 2019 18:59:47 +0800 Subject: [PATCH] net/virtio: fix Tx desc cleanup for packed ring We should try to cleanup at least the 'need' number of descs. Fixes: 892dc798fa9c ("net/virtio: implement Tx path for packed queues") Cc: stable@dpdk.org Signed-off-by: Tiwei Bie Reviewed-by: Maxime Coquelin --- drivers/net/virtio/virtio_rxtx.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/net/virtio/virtio_rxtx.c b/drivers/net/virtio/virtio_rxtx.c index 4c701c5147..b07ceac6de 100644 --- a/drivers/net/virtio/virtio_rxtx.c +++ b/drivers/net/virtio/virtio_rxtx.c @@ -1943,7 +1943,6 @@ virtio_xmit_pkts_packed(void *tx_queue, struct rte_mbuf **tx_pkts, /* Positive value indicates it need free vring descriptors */ if (unlikely(need > 0)) { - need = RTE_MIN(need, (int)nb_pkts); virtio_xmit_cleanup_packed(vq, need); need = slots - vq->vq_free_cnt; if (unlikely(need > 0)) { -- 2.20.1