On 12/07/2017 06:30 AM, Tiwei Bie wrote:
The vector Rx will be broken if backend has consumed all the descs in the avail ring before the device is started. Because in current implementation, vector Rx will return immediately without refilling the avail ring if the used ring is empty. So we have to refill the avail ring after flushing the elements in the used ring for vector Rx. Besides, vector Rx has a different ring layout assumption and mbuf management. So we need to handle it differently. Fixes: d8227497ec5c ("net/virtio: flush Rx queues on start") Cc: sta...@dpdk.org Reported-by: Antonio Fischetti <antonio.fische...@intel.com> Signed-off-by: Tiwei Bie <tiwei....@intel.com> --- drivers/net/virtio/virtio_ethdev.c | 2 +- drivers/net/virtio/virtqueue.c | 31 ++++++++++++++++++++++++------- drivers/net/virtio/virtqueue.h | 2 +- 3 files changed, 26 insertions(+), 9 deletions(-)
Reviewed-by: Maxime Coquelin <maxime.coque...@redhat.com> Thanks, Maxime