[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] hbitmap: fix hbitmap_status() return value for first dirty b
From: |
Eric Blake |
Subject: |
Re: [PATCH] hbitmap: fix hbitmap_status() return value for first dirty bit case |
Date: |
Thu, 2 Feb 2023 13:39:44 -0600 |
User-agent: |
NeoMutt/20220429 |
On Thu, Feb 02, 2023 at 09:15:23PM +0300, Andrey Zhadchenko via wrote:
> The last return statement should return true, as we already evaluated that
> start == next_dirty
>
> Also, fix hbitmap_status() description in header
>
> Cc: qemu-stable@nongnu.org
> Fixes: a6426475a75 ("block/dirty-bitmap: introduce
> bdrv_dirty_bitmap_status()")
> Signed-off-by: Andrey Zhadchenko <andrey.zhadchenko@virtuozzo.com>
> ---
> include/qemu/hbitmap.h | 2 +-
> util/hbitmap.c | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
Eww, nasty bug; looks like copy-before-write is the only curernt
client of this interface.
Reviewed-by: Eric Blake <eblake@redhat.com>
Is there any way to enhance an iotest to add coverage for this code?
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org