[Top][All Lists]

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

Re: [Qemu-block] [PATCH] vmdk: Set vmdk parent backing_format to vmdk

From: Eric Blake
Subject: Re: [Qemu-block] [PATCH] vmdk: Set vmdk parent backing_format to vmdk
Date: Tue, 26 Mar 2019 19:35:13 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.0

On 3/26/19 2:58 PM, Sam Eiderman wrote:
> Commit fb2105b ("vmdk: Support version=3 in VMDK descriptor files") fixed
> the probe function to correctly guess vmdk descriptors with version=3.

All patches need to cc qemu-devel in addition to their maintainers (I've
added that now).

> This solves the issue where vmdk snapshot with parent vmdk descriptor
> containing "version=3" would be treated as raw instead vmdk.
> In the future case where a new vmdk version is introduced, we will again
> experience this issue, even if the user will provide "-f vmdk" it will
> only apply to the tip image and not to the underlying "misprobed" parent
> image.
> The code in vmdk.c already assumes that the backing file of vmdk must be
> vmdk (see vmdk_is_cid_valid which returns 0 if backing file is not
> vmdk).
> So let's make it official by supplying the backing_format as vmdk.
> Reviewed-by: Mark Kanda <address@hidden>
> Reviewed-By: Liran Alon <address@hidden>
> Reviewed-by: Arbel Moshe <address@hidden>
> Signed-off-by: Shmuel Eiderman <address@hidden>
> ---
>  block/vmdk.c | 2 ++
>  1 file changed, 2 insertions(+)
> diff --git a/block/vmdk.c b/block/vmdk.c
> index 8dec6ef767..de8cb859f8 100644
> --- a/block/vmdk.c
> +++ b/block/vmdk.c
> @@ -397,6 +397,8 @@ static int vmdk_parent_open(BlockDriverState *bs)
>          pstrcpy(bs->auto_backing_file, end_name - p_name + 1, p_name);
>          pstrcpy(bs->backing_file, sizeof(bs->backing_file),
>                  bs->auto_backing_file);
> +        pstrcpy(bs->backing_format, sizeof(bs->backing_format),
> +                "vmdk");
>      }

Reviewed-by: Eric Blake <address@hidden>

Makes sense for 4.0-rc2.

Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3226
Virtualization:  qemu.org | libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

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