qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-block] [PATCH v2 13/16] block: Implement bdrv_append() without


From: Max Reitz
Subject: Re: [Qemu-block] [PATCH v2 13/16] block: Implement bdrv_append() without bdrv_swap()
Date: Fri, 2 Oct 2015 19:32:47 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0

On 01.10.2015 15:13, Kevin Wolf wrote:
> Remember all parent nodes and just change the pointers there instead of
> swapping the contents of the BlockDriverState.
> 
> Handling of snapshot=on must be moved further down in bdrv_open()
> because *pbs (which is the bs pointer in the BlockBackend) must already
> be set before bdrv_append() is called. Otherwise bdrv_append() changes
> the BB's pointer to the temporary snapshot, but bdrv_open() overwrites
> it with the read-only original image.
> 
> We also need to be careful to update callers as the interface changes
> (becomes less insane): Previously, the meaning of the two parameters was
> inverted when bdrv_append() returns. Now any BDS pointers keep pointing
> to the same node.
> 
> Signed-off-by: Kevin Wolf <address@hidden>
> ---
>  block.c    | 112 
> +++++++++++++++++++++++++++++++++++++++++++++----------------
>  blockdev.c |   2 +-
>  2 files changed, 85 insertions(+), 29 deletions(-)

Reviewed-by: Max Reitz <address@hidden>

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]