qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Li Qiang <liq3ea@gmail.com>
To: Paolo Bonzini <pbonzini@redhat.com>, Gerd Hoffmann <kraxel@redhat.com>
Cc: Qemu Developers <qemu-devel@nongnu.org>
Subject: Does. there exists race condition in virtio-gpu device
Date: Wed, 9 Sep 2020 20:49:25 +0800	[thread overview]
Message-ID: <CAKXe6SJWAt8U-UmCqgtMwt-moL6MAtV5BpBiaM=BN92mQN0Z2g@mail.gmail.com> (raw)

Hello Gerd and Paolo,

I think there is a race condition in virtio-gpu device.
In 'virtio_gpu_reset' and 'virtio_gpu_process_cmdq' they both operate
on 'g->cmdq'.

However the 'virtio_gpu_reset' is in vcpu thread and the
'virtio_gpu_process_cmdq' is
in main thread through BH.

So I think there is a race condition. But I don't find a pattern for
this kind of bug(BH and vcpu thread). I missed anything?

Thanks,
Li Qiang


             reply	other threads:[~2020-09-09 12:51 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-09 12:49 Li Qiang [this message]
2020-09-14  7:42 ` Does. there exists race condition in virtio-gpu device Gerd Hoffmann

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='CAKXe6SJWAt8U-UmCqgtMwt-moL6MAtV5BpBiaM=BN92mQN0Z2g@mail.gmail.com' \
    --to=liq3ea@gmail.com \
    --cc=kraxel@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.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).