[dpdk-dev] [Patch v3 1/2] net/virtio: check head desc with correct wrap counter
Maxime Coquelin
maxime.coquelin at redhat.com
Fri Jan 11 10:03:49 CET 2019
On 1/10/19 10:47 PM, Jens Freimann wrote:
> In virtio_pq_send_command() we check for a used descriptor
> and wait in an idle loop until it becomes used. We can't use
> vq->used_wrap_counter here to check for the first descriptor
> we made available because the ring could have wrapped. Let's use
> the used_wrap_counter that matches the state of the head descriptor.
>
> Fixes: ec194c2 ("net/virtio: support packed queue in send command")
>
> Signed-off-by: Jens Freimann <jfreimann at redhat.com>
> ---
> drivers/net/virtio/virtio_ethdev.c | 11 ++++++-----
> drivers/net/virtio/virtqueue.h | 10 ++++++++--
> 2 files changed, 14 insertions(+), 7 deletions(-)
>
Reviewed-by: Maxime Coquelin <maxime.coquelin at redhat.com>
Thanks,
Maxime
More information about the dev
mailing list