net/virtio: update stats when in-order Tx done
authorMarvin Liu <yong.liu@intel.com>
Wed, 18 Sep 2019 17:06:54 +0000 (01:06 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Mon, 7 Oct 2019 13:00:57 +0000 (15:00 +0200)
commit01689b1ed4863f937e5b9db65a79fb72d764629a
tree22a09a601d2b31f85b76e40f98a038e4a3f4f8ae
parentf2f0577eff3d13e761996c7390a244963b433bdc
net/virtio: update stats when in-order Tx done

When doing xmit in-order enqueue, packets are buffered and then flushed
into avail ring. Buffered packets can be dropped due to insufficient
space. Moving stats update action just after successful avail ring
updates can guarantee correctness.

Fixes: e5f456a98d3c ("net/virtio: support in-order Rx and Tx")
Cc: stable@dpdk.org
Signed-off-by: Marvin Liu <yong.liu@intel.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
drivers/net/virtio/virtio_rxtx.c