qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Fam Zheng <famz@redhat.com>
To: qemu-devel@nongnu.org
Cc: Kevin Wolf <kwolf@redhat.com>,
	qemu-block@nongnu.org, "Michael S. Tsirkin" <mst@redhat.com>,
	Markus Armbruster <armbru@redhat.com>,
	Max Reitz <mreitz@redhat.com>,
	Stefan Hajnoczi <stefanha@redhat.com>,
	Paolo Bonzini <pbonzini@redhat.com>,
	Yanbin Duan <yduan@redhat.com>,
	qemu-stable@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v2 0/4] Drop virtio-{blk,scsi} op blockers
Date: Wed, 25 May 2016 15:20:08 +0800	[thread overview]
Message-ID: <20160525072008.GB32161@ad.usersys.redhat.com> (raw)
In-Reply-To: <1463969978-24970-1-git-send-email-famz@redhat.com>

On Mon, 05/23 10:19, Fam Zheng wrote:
> v2: Switch to bdrv_lookup_bs on target_bs. [Kevin]
>     Rebase onto master.
>     Add Michael's ack-by in virtio patches.
> 
> We are ready to get rid of dataplane's op blockers altogether. Most operations
> are already unblocked in virtio-blk, and those remained for virtio-scsi only
> because we haven't got around to add counterpart unblocking code.
> 
> The first patch fixes an existing bug with blockdev-backup. Then the op
> blockers are removed from both devices.

Without this series, completing a mirror job on virtio-blk-dataplane disk fails
an assertion (thanks to Yanbin Duan <yduan@redhat.com> for providing the
backtrace):

block.c:2338: bdrv_delete: Assertion `bdrv_op_blocker_is_empty(bs)' failed.
 
(gdb) bt
#0  0x00007f10d44915f7 in raise () from /lib64/libc.so.6
#1  0x00007f10d4492ce8 in abort () from /lib64/libc.so.6
#2  0x00007f10d448a566 in __assert_fail_base () from /lib64/libc.so.6
#3  0x00007f10d448a612 in __assert_fail () from /lib64/libc.so.6
#4  0x00007f10dc9f856f in bdrv_delete (bs=0x7f10de16e800) at block.c:2338
#5  bdrv_unref (bs=0x7f10de16e800) at block.c:3376
#6  0x00007f10dc9fb353 in block_job_defer_to_main_loop_bh (opaque=0x7f10de038310) at blockjob.c:476
#7  0x00007f10dc9f3fcd in aio_bh_call (bh=<optimized out>) at async.c:66
#8  aio_bh_poll (ctx=ctx@entry=0x7f10de109980) at async.c:94
#9  0x00007f10dc9fdb70 in aio_dispatch (ctx=0x7f10de109980) at aio-posix.c:308
#10 0x00007f10dc9f3dbe in aio_ctx_dispatch (source=<optimized out>, callback=<optimized out>,
    user_data=<optimized out>) at async.c:233
---Type <return> to continue, or q <return> to quit---
#11 0x00007f10d528f79a in g_main_context_dispatch () from /lib64/libglib-2.0.so.0
#12 0x00007f10dc9fc460 in glib_pollfds_poll () at main-loop.c:213
#13 os_host_main_loop_wait (timeout=<optimized out>) at main-loop.c:258
#14 main_loop_wait (nonblocking=<optimized out>) at main-loop.c:506
#15 0x00007f10dc7c655f in main_loop () at vl.c:1934
#16 main (argc=<optimized out>, argv=<optimized out>, envp=<optimized out>) at vl.c:4667

This is because the bdrv_replace_in_backing_chain skipped the BlockBackend's
"remove notifier" which is responsible for dropping the dataplane op blockers.

Now we are dropping the notifier handlers, the crash is gone.  Therefore this
should probably be included in qemu-stable@nongnu.org because it affacts 2.6
too.

Fam

  parent reply	other threads:[~2016-05-25  7:20 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-23  2:19 [Qemu-devel] [PATCH v2 0/4] Drop virtio-{blk,scsi} op blockers Fam Zheng
2016-05-23  2:19 ` [Qemu-devel] [PATCH v2 1/4] blockdev-backup: Use bdrv_lookup_bs on target Fam Zheng
2016-05-23  2:19 ` [Qemu-devel] [PATCH v2 2/4] blockdev-backup: Don't move target AioContext if it's attached Fam Zheng
2016-05-23  2:19 ` [Qemu-devel] [PATCH v2 3/4] virtio-blk: Remove op blocker for dataplane Fam Zheng
2016-05-23  2:19 ` [Qemu-devel] [PATCH v2 4/4] virtio-scsi: " Fam Zheng
2016-05-25  7:20 ` Fam Zheng [this message]
2016-05-27 22:33 ` [Qemu-devel] [Qemu-block] [PATCH v2 0/4] Drop virtio-{blk, scsi} op blockers 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=20160525072008.GB32161@ad.usersys.redhat.com \
    --to=famz@redhat.com \
    --cc=armbru@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=mst@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-stable@nongnu.org \
    --cc=stefanha@redhat.com \
    --cc=yduan@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).