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 <tiwei.bie@intel.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
/* 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)) {