[PATCH] vhost: fix deadlock with no multiqueue
David Marchand
david.marchand at redhat.com
Sun Mar 26 17:51:03 CEST 2023
On Thu, Mar 23, 2023 at 3:48 PM Maxime Coquelin
<maxime.coquelin at redhat.com> wrote:
> On 3/23/23 15:44, David Marchand wrote:
> > This deadlock happens when a guest, that had virtio ports with multi
> > queues configured, does not announce the multi q feature in
> > SET_FEATURES.
> > In such a situation, all vq locks are already taken before calling
> > free_vq(), which itself takes the lock.
> >
> > As mentioned in the code, in this situation, the virtio device is not
> > running yet and no datapath thread is using the vq. So we can
> > release the lock before calling free_vq().
> >
> > Bugzilla ID: 1196
> > Fixes: 4b02c2673757 ("vhost: annotate async accesses")
> >
> > Signed-off-by: David Marchand <david.marchand at redhat.com>
> Reviewed-by: Maxime Coquelin <maxime.coquelin at redhat.com>
Applied, thanks.
--
David Marchand
More information about the dev
mailing list