qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Jeff Cody <jcody@redhat.com>
To: Eric Blake <eblake@redhat.com>
Cc: kwolf@redhat.com, pbonzini@redhat.com, stefanha@gmail.com,
	qemu-devel@nongnu.org, supriyak@linux.vnet.ibm.com
Subject: Re: [Qemu-devel] [PATCH 1/8] block: add support functions for live commit, to find and delete images.
Date: Fri, 14 Sep 2012 11:39:47 -0400	[thread overview]
Message-ID: <50534FC3.90109@redhat.com> (raw)
In-Reply-To: <50534BE7.2070803@redhat.com>

On 09/14/2012 11:23 AM, Eric Blake wrote:
> On 09/14/2012 07:41 AM, Jeff Cody wrote:
>> Add bdrv_find_overlay(), and bdrv_drop_intermediate().
>>
>> bdrv_find_overlay():  given 'bs' and the active (topmost) BDS of an image chain,
>>                     find the image that is the immediate top of 'bs'
>>
>> bdrv_drop_intermediate():
>>                     Given 3 BDS (active, top, base), delete images above
> 
> s/delete/drop/
> 

Thanks

>>                     base up to and including top, and set base to be the
>>                     parent of top's child node.
> 
> set base to be the backing file of top's overlay node.
> 

Thanks

>>
>>                     E.g., this converts:
>>
>>                     bottom <- base <- intermediate <- top <- active
>>
>>                     to
>>
>>                     bottom <- base <- active
>>
>> +++ b/block.c
>> @@ -1713,6 +1713,156 @@ int bdrv_change_backing_file(BlockDriverState *bs,
>>      return ret;
>>  }
>>  
>> +/*
>> + * Finds the image layer immediately to the 'top' of bs.
> 
> Or even:
> 
> Finds the image layer in the chain that has 'bs' as its backing file.
> 

Thanks - I prefer your wording, that is clearer.


>> +/*
>> + * Deletes images above 'base' up to and including 'top', and sets the image
> 
> s/Deletes/Drops/
> 
>> +++ b/block.h
>> @@ -209,7 +209,10 @@ int bdrv_commit_all(void);
>>  int bdrv_change_backing_file(BlockDriverState *bs,
>>      const char *backing_file, const char *backing_fmt);
>>  void bdrv_register(BlockDriver *bdrv);
>> -
>> +int bdrv_drop_intermediate(BlockDriverState *active, BlockDriverState *top,
>> +                           BlockDriverState *base);
>> +BlockDriverState *bdrv_find_overlay(BlockDriverState *active,
>> +                                    BlockDriverState *bs);
>>  
>>  typedef struct BdrvCheckResult {
> 
> Changed from two blank lines to one before the typedef; was that
> intentional?
>

Nope, it was unintentional - thanks

  reply	other threads:[~2012-09-14 15:40 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-14 13:41 [Qemu-devel] [PATCH 0/8] Live block commit Jeff Cody
2012-09-14 13:41 ` [Qemu-devel] [PATCH 1/8] block: add support functions for live commit, to find and delete images Jeff Cody
2012-09-14 15:23   ` Eric Blake
2012-09-14 15:39     ` Jeff Cody [this message]
2012-09-14 13:41 ` [Qemu-devel] [PATCH 2/8] block: add live block commit functionality Jeff Cody
2012-09-14 15:45   ` Eric Blake
2012-09-14 16:07     ` Jeff Cody
2012-09-14 18:23       ` Eric Blake
2012-09-14 20:29         ` Jeff Cody
2012-09-14 13:41 ` [Qemu-devel] [PATCH 3/8] blockdev: rename block_stream_cb to a generic block_job_cb Jeff Cody
2012-09-14 13:41 ` [Qemu-devel] [PATCH 4/8] qerror: new error for live block commit, QERR_TOP_NOT_FOUND Jeff Cody
2012-09-14 16:01   ` Eric Blake
2012-09-14 13:41 ` [Qemu-devel] [PATCH 5/8] block: helper function, to find the base image of a chain Jeff Cody
2012-09-14 13:41 ` [Qemu-devel] [PATCH 6/8] QAPI: add command for live block commit, 'block-commit' Jeff Cody
2012-09-15  1:05   ` Eric Blake
2012-09-15  2:42     ` Jeff Cody
2012-09-14 13:41 ` [Qemu-devel] [PATCH 7/8] qemu-iotests: add initial tests for live block commit Jeff Cody
2012-09-14 13:41 ` [Qemu-devel] [PATCH 8/8] block: after creating a live snapshot, make old image read-only Jeff Cody

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=50534FC3.90109@redhat.com \
    --to=jcody@redhat.com \
    --cc=eblake@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@gmail.com \
    --cc=supriyak@linux.vnet.ibm.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).