[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v4 3/8] block: don't make snapshots for filters
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH v4 3/8] block: don't make snapshots for filters |
Date: |
Wed, 21 Sep 2016 17:37:01 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0 |
On 21/09/2016 13:33, Pavel Dovgalyuk wrote:
> This patch disables snapshotting for block driver filters.
> It is needed, because snapshots should be created
> in underlying disk images, not in filters itself.
I don't understand this patch. Who would take care of doing the
bdrv_snapshot_goto on the underlying image?
Paolo
> Signed-off-by: Pavel Dovgalyuk <address@hidden>
> ---
> block/snapshot.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/block/snapshot.c b/block/snapshot.c
> index bf5c2ca..8998b8b 100644
> --- a/block/snapshot.c
> +++ b/block/snapshot.c
> @@ -184,6 +184,9 @@ int bdrv_snapshot_goto(BlockDriverState *bs,
> if (!drv) {
> return -ENOMEDIUM;
> }
> + if (drv->is_filter) {
> + return 0;
> + }
> if (drv->bdrv_snapshot_goto) {
> return drv->bdrv_snapshot_goto(bs, snapshot_id);
> }
>