net/virtio: fix mbuf port for simple Rx function
authorOlivier Matz <olivier.matz@6wind.com>
Thu, 7 Sep 2017 12:13:42 +0000 (14:13 +0200)
committerYuanhan Liu <yliu@fridaylinux.org>
Tue, 10 Oct 2017 13:51:04 +0000 (15:51 +0200)
commit0c4f909c17af3cff8859439436a8fa0b9a9689c5
tree82d76f65eabef45f08dcd22c8af501da5722498b
parent78fd97c3343ff0811b84bf3461e16b9252ba72fc
net/virtio: fix mbuf port for simple Rx function

The mbuf->port was was not properly set for the first received
mbufs. Fix this by setting it in virtqueue_enqueue_recv_refill_simple(),
which is used to enqueue the first mbuf in the ring.

The function virtio_rxq_rearm_vec(), which is used to rearm the ring
with new mbufs, is correct and does not need to be updated.

Fixes: cab0461234e7 ("virtio: fill Rx avail ring with blank mbufs")
Cc: stable@dpdk.org
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Yuanhan Liu <yliu@fridaylinux.org>
drivers/net/virtio/virtio_rxtx_simple.c