From: Kevin Wolf <kwolf@redhat.com>
To: Stefan Hajnoczi <stefanha@gmail.com>
Cc: Eric Blake <eblake@redhat.com>,
Paolo Bonzini <pbonzini@redhat.com>,
qemu block <qemu-block@nongnu.org>, Fam Zheng <famz@redhat.com>,
qemu-devel <qemu-devel@nongnu.org>,
Stefan Hajnoczi <stefanha@redhat.com>
Subject: Re: [Qemu-devel] [Qemu-block] [PATCH 2/3] block: use BDRV_POLL_WHILE() in bdrv_rw_vmstate()
Date: Thu, 18 May 2017 10:22:13 +0200 [thread overview]
Message-ID: <20170518082213.GC4646@noname.redhat.com> (raw)
In-Reply-To: <CAJSP0QXgsJfBr5jdU9dyNZRmfqZSOy1Wr1pQzy-adG9e5=oYUA@mail.gmail.com>
Am 18.05.2017 um 10:06 hat Stefan Hajnoczi geschrieben:
> On Thu, May 18, 2017 at 8:57 AM, Kevin Wolf <kwolf@redhat.com> wrote:
> > Am 17.05.2017 um 22:16 hat Eric Blake geschrieben:
> >> On 05/17/2017 12:09 PM, Stefan Hajnoczi wrote:
> >> > Calling aio_poll() directly may have been fine previously, but this is
> >> > the future, man!
> >>
> >> lol
> >>
> >> > The difference between an aio_poll() loop and
> >> > BDRV_POLL_WHILE() is that BDRV_POLL_WHILE() releases the AioContext
> >> > around aio_poll().
> >> >
> >> > This allows the IOThread to run fd handlers or BHs to complete the
> >> > request. Failure to release the AioContext causes deadlocks.
> >> >
> >> > Using BDRV_POLL_WHILE() partially fixes a 'savevm' hang with -object
> >> > iothread.
> >>
> >> I'm surprised at how many separate hangs we actually had!
> >
> > How hard would it be to write some test cases for this? Dataplane has
> > a serious lack of automated testing.
>
> And this hang doesn't even require in-flight guest I/O, so it would be
> easy to reproduce in qemu-iotests if we add an IOThread mode.
I don't think I would make it a separate mode (because people would run
only one or the other - when did you last run qcow2 v2 tests?), but just
add some test cases that make use of it during the normal -qcow2 or -raw
run.
Kevin
next prev parent reply other threads:[~2017-05-18 8:22 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-17 17:09 [Qemu-devel] [PATCH 0/3] block: fix 'savevm' hang with -object iothread Stefan Hajnoczi
2017-05-17 17:09 ` [Qemu-devel] [PATCH 1/3] block: count bdrv_co_rw_vmstate() requests Stefan Hajnoczi
2017-05-17 20:09 ` Eric Blake
2017-05-17 17:09 ` [Qemu-devel] [PATCH 2/3] block: use BDRV_POLL_WHILE() in bdrv_rw_vmstate() Stefan Hajnoczi
2017-05-17 20:16 ` Eric Blake
2017-05-17 20:47 ` Paolo Bonzini
2017-05-18 7:57 ` Kevin Wolf
2017-05-18 8:06 ` [Qemu-devel] [Qemu-block] " Stefan Hajnoczi
2017-05-18 8:22 ` Kevin Wolf [this message]
2017-05-18 8:05 ` Stefan Hajnoczi
2017-05-17 17:09 ` [Qemu-devel] [PATCH 3/3] migration: avoid recursive AioContext locking in save_vmstate() Stefan Hajnoczi
2017-05-17 20:24 ` Eric Blake
2017-05-18 8:18 ` Kevin Wolf
2017-05-19 9:07 ` [Qemu-devel] [Qemu-block] " Stefan Hajnoczi
2017-05-17 20:49 ` [Qemu-devel] [PATCH 0/3] block: fix 'savevm' hang with -object iothread Paolo Bonzini
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=20170518082213.GC4646@noname.redhat.com \
--to=kwolf@redhat.com \
--cc=eblake@redhat.com \
--cc=famz@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@gmail.com \
--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).