qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v3 2/6] add basic backup support to block driver


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [PATCH v3 2/6] add basic backup support to block driver
Date: Wed, 20 Feb 2013 15:38:56 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130110 Thunderbird/17.0.2

Il 19/02/2013 12:31, Dietmar Maurer ha scritto:
> +    start = 0;
> +    end = (bs->total_sectors + BACKUP_BLOCKS_PER_CLUSTER - 1) /
> +        BACKUP_BLOCKS_PER_CLUSTER;
> +
> +    DPRINTF("backup_run start %s %zd %zd\n", bdrv_get_device_name(bs),
> +            start, end);
> +
> +    int ret = 0;
> +
> +    for (; start < end; start++) {
> +        if (block_job_is_cancelled(&job->common)) {
> +            ret = -1;
> +            break;
> +        }
> +

This should call bdrv_is_allocated_above like the other block jobs do.
It would be needed later anyway to backup only the topmost image.

Paolo



reply via email to

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