qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v5 5/7] block: Parse "backing" option to referen


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [PATCH v5 5/7] block: Parse "backing" option to reference existing BDS
Date: Tue, 26 Nov 2013 17:18:07 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130923 Thunderbird/17.0.9

Il 26/11/2013 05:05, Fam Zheng ha scritto:
> +    if (backing_bs && *backing_bs != '\0') {
> +        bs->backing_hd = bdrv_find(backing_bs);
> +        if (!bs->backing_hd) {
> +            error_setg(errp, "Backing device not found: %s", backing_bs);
> +            return -ENOENT;
> +        }
> +        bdrv_ref(bs->backing_hd);
> +        assert(!bs->backing_blocker);
> +        error_setg(&bs->backing_blocker,
> +                   "device is used as backing hd of '%s'",
> +                   bs->device_name);
> +        bdrv_op_block_all(bs->backing_hd, bs->backing_blocker);

Why should this blocker only apply to the "named backing file" case, and
not to all backing files?

Paolo

> +        pstrcpy(bs->backing_file, sizeof(bs->backing_file),
> +                bs->backing_hd->filename);
> +        pstrcpy(bs->backing_format, sizeof(bs->backing_format),
> +                bs->backing_hd->drv->format_name);
> +    }





reply via email to

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