From: Maxime Coquelin <maxime.coquelin@redhat.com>
To: David Marchand <david.marchand@redhat.com>, dev@dpdk.org
Cc: stable@dpdk.org, Chenbo Xia <chenbox@nvidia.com>
Subject: Re: [PATCH] vhost: fix wrapping on control virtqueue rings
Date: Tue, 8 Apr 2025 09:31:44 +0200 [thread overview]
Message-ID: <c110dc25-05d1-4aee-85f0-5fd4e98c9078@redhat.com> (raw)
In-Reply-To: <20250402065358.3612788-1-david.marchand@redhat.com>
On 4/2/25 8:53 AM, David Marchand wrote:
> The idx field of a virtqueue available ring is increased by the driver
> regardless of the ring size. It is for the device to mask this index
> modulo the ring size (2.7.6 of the virtio 1.3 specification).
> The same applies to the used ring.
>
> Failing to mask triggers:
> - crashes when popping message received on the cvq,
> - system lockups (in the case of VDUSE) when the virtio-net driver waits
> infinitely,
>
> Fixes: 474f4d7840ad ("vhost: add control virtqueue")
> Cc: stable@dpdk.org
>
> Signed-off-by: David Marchand <david.marchand@redhat.com>
> ---
> lib/vhost/virtio_net_ctrl.c | 10 ++--------
> 1 file changed, 2 insertions(+), 8 deletions(-)
>
Thanks for the fix!
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Tested-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Maxime
prev parent reply other threads:[~2025-04-08 7:31 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-02 6:53 David Marchand
2025-04-08 7:31 ` Maxime Coquelin [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=c110dc25-05d1-4aee-85f0-5fd4e98c9078@redhat.com \
--to=maxime.coquelin@redhat.com \
--cc=chenbox@nvidia.com \
--cc=david.marchand@redhat.com \
--cc=dev@dpdk.org \
--cc=stable@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).