qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 5/5] block/qcow2-bitmap: Count queued bitmaps to


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH 5/5] block/qcow2-bitmap: Count queued bitmaps towards directory_size
Date: Thu, 6 Jun 2019 21:30:39 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1

On 6/6/19 1:41 PM, John Snow wrote:
> Similarly to the previous commit, we need to also keep a ledger of the
> additional directory size burden that we've not yet committed so we can
> reject new additions sooner instead of later.
> 
> Signed-off-by: John Snow <address@hidden>
> ---
>  block/qcow2.h        |  1 +
>  block/qcow2-bitmap.c | 13 ++++++++++++-
>  2 files changed, 13 insertions(+), 1 deletion(-)
> 
> diff --git a/block/qcow2.h b/block/qcow2.h
> index ebf60ac236..5aff97eb9c 100644
> --- a/block/qcow2.h
> +++ b/block/qcow2.h
> @@ -318,6 +318,7 @@ typedef struct BDRVQcow2State {
>  
>      uint32_t nb_bitmaps;
>      uint32_t nb_queued_bitmaps;
> +    uint32_t queued_directory_size;
>      uint64_t bitmap_directory_size;

Why can we get away with uint32_t for the queue size, but uint64_t for
the stored size? Something feels fishy.

-- 
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]