All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Blake <eblake@redhat.com>
To: Fam Zheng <famz@redhat.com>, Stefan Hajnoczi <stefanha@gmail.com>
Cc: kwolf@redhat.com, "Jeff Cody" <jcody@redhat.com>,
	"Benoît Canet" <benoit.canet@nodalink.com>,
	stefanha@redhat.com, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] block: Make op blockers recursive
Date: Wed, 10 Sep 2014 09:14:35 -0600	[thread overview]
Message-ID: <54106ADB.7060205@redhat.com> (raw)
In-Reply-To: <20140910085419.GB26233@fam-t430.nay.redhat.com>

[-- Attachment #1: Type: text/plain, Size: 1592 bytes --]

On 09/10/2014 02:54 AM, Fam Zheng wrote:

>> Let's think of a situation that recursive blockers protect but
>> backing_blocker does not:
>>
>> a <- b <- c <- d
>>
>> c is the backing file and is therefore protected by the op blocker.
>>
>> The block-commit command works with node-names, however, so we can
>> manipulate any nodes in the graph, not just the topmost one.  Try this:
>>
>> block-commit d
>> block-commit b
>>
>> I haven't checked yet but I suspect it will launch two block-commit jobs
>> on the same partial chain (that's a bad thing because it can lead to
>> corruption).
> 
> 1) Does block-commit work with node-names already? In other words, is
>    block-commit b possible now? I only see drive-mirror works with it, but not
>    drive-backup, block-mirror or block-commit.

IIRC, Jeff Cody proposed patches for qemu 2.1 that would have done this,
but we dropped them for that release in order to get the recursive
blockers sorted out first.

 >
> 2) Regardless of the answer to 1), I think we could use a similar approach as
>    drive-backup here: split BLOCK_OP_TYPE_COMMIT to
>    BLOCK_OP_TYPE_COMMIT_{SOURCE,TARGET}, and only unblock
>    BLOCK_OP_TYPE_COMMIT_TARGET in bdrv_set_backing_hd.

In that earlier thread, Jeff had some ideas that it is not so much the
operation name that should be the blocker, but the lower-level action(s)
implied by each operation (read metadata, write metadata, read image,
write image)

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 539 bytes --]

  parent reply	other threads:[~2014-09-10 15:14 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-22 16:11 [Qemu-devel] [PATCH] Implement recursive op blockers Benoît Canet
2014-08-22 16:11 ` [Qemu-devel] [PATCH] block: Make op blockers recursive Benoît Canet
2014-08-25  6:04   ` Fam Zheng
2014-08-25  9:06     ` Benoît Canet
2014-08-25  9:37       ` Fam Zheng
2014-08-25 12:12         ` Benoît Canet
2014-08-26  4:42           ` Fam Zheng
2014-08-26  6:45             ` Benoît Canet
2014-09-04 20:42               ` Stefan Hajnoczi
2014-09-10  8:54                 ` Fam Zheng
2014-09-10 14:18                   ` Benoît Canet
2014-09-10 15:14                   ` Eric Blake [this message]
2014-09-10 15:49                     ` Benoît Canet
2014-09-11 11:22                       ` Kevin Wolf
2014-09-11  0:50                     ` Fam Zheng
2014-09-09 11:56   ` Kevin Wolf
2014-09-09 14:28     ` Benoît Canet
2014-09-12  3:48       ` Fam Zheng
2014-09-15 15:17         ` Benoît Canet
2014-09-18  2:57           ` Fam Zheng
2014-09-22 12:33             ` Benoît Canet

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=54106ADB.7060205@redhat.com \
    --to=eblake@redhat.com \
    --cc=benoit.canet@nodalink.com \
    --cc=famz@redhat.com \
    --cc=jcody@redhat.com \
    --cc=kwolf@redhat.com \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.