From: Paolo Bonzini <pbonzini@redhat.com>
To: Stefan Hajnoczi <stefanha@redhat.com>, qemu-devel@nongnu.org
Cc: Kevin Wolf <kwolf@redhat.com>, Fam Zheng <fam@euphon.net>,
"Michael S. Tsirkin" <mst@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v5 0/3] virtio-scsi: restart DMA after iothread
Date: Thu, 20 Jun 2019 20:07:39 +0200 [thread overview]
Message-ID: <06488da0-bac1-25e1-d238-f42284aa2cc0@redhat.com> (raw)
In-Reply-To: <20190620173709.14753-1-stefanha@redhat.com>
On 20/06/19 19:37, Stefan Hajnoczi wrote:
> v5:
> * Plumbing vm change state handlers into DeviceClass/BusClass is a rather
> large bug fix. Instead I've combined the previous priorities approach with
> the observation from Kevin and Paolo that we really want to order by qdev
> tree depth.
>
> The new qdev_add_vm_change_state_handler() API lets DeviceStates register
> callbacks that execute in qdev tree depth order. This solves the
> virtio-scsi bug since the virtio-scsi device's callback must complete before
> its child scsi-disk's callback runs.
>
> Is this a good compromise for everyone?
Yes! Perhaps a bit of a hack, but it works and both the API and the
implementation are very sane. Converting other devices to use
qdev_add_vm_change_state_handler() is left as an exercise for the
reviewer, I guess? :)
Paolo
next prev parent reply other threads:[~2019-06-20 18:23 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-20 17:37 [Qemu-devel] [PATCH v5 0/3] virtio-scsi: restart DMA after iothread Stefan Hajnoczi
2019-06-20 17:37 ` [Qemu-devel] [PATCH v5 1/3] vl: add qemu_add_vm_change_state_handler_prio() Stefan Hajnoczi
2019-06-20 17:37 ` [Qemu-devel] [PATCH v5 2/3] qdev: add qdev_add_vm_change_state_handler() Stefan Hajnoczi
2019-06-20 17:37 ` [Qemu-devel] [PATCH v5 3/3] virtio-scsi: restart DMA after iothread Stefan Hajnoczi
2019-06-20 18:07 ` Paolo Bonzini [this message]
2019-06-27 11:03 ` [Qemu-devel] [PATCH v5 0/3] " Kevin Wolf
-- strict thread matches above, loose matches on Subject: below --
2019-06-20 17:35 Stefan Hajnoczi
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=06488da0-bac1-25e1-d238-f42284aa2cc0@redhat.com \
--to=pbonzini@redhat.com \
--cc=fam@euphon.net \
--cc=kwolf@redhat.com \
--cc=mst@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@redhat.com \
/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).