]> git.proxmox.com Git - mirror_qemu.git/commit
block/dirty-bitmap: add _next_dirty API
authorVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Wed, 5 Feb 2020 11:20:37 +0000 (14:20 +0300)
committerJohn Snow <jsnow@redhat.com>
Wed, 18 Mar 2020 18:03:46 +0000 (14:03 -0400)
commit9399c54b7557a20bc78aaecf2d51983cfafbbf41
tree19261c083bb14e67cdf630a36f08398daf778d7b
parent642700fda029ed6b4051db7eab8f704131217643
block/dirty-bitmap: add _next_dirty API

We have bdrv_dirty_bitmap_next_zero, let's add corresponding
bdrv_dirty_bitmap_next_dirty, which is more comfortable to use than
bitmap iterators in some cases.

For test modify test_hbitmap_next_zero_check_range to check both
next_zero and next_dirty and add some new checks.

Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Reviewed-by: John Snow <jsnow@redhat.com>
Message-id: 20200205112041.6003-7-vsementsov@virtuozzo.com
Signed-off-by: John Snow <jsnow@redhat.com>
block/dirty-bitmap.c
include/block/dirty-bitmap.h
include/qemu/hbitmap.h
tests/test-hbitmap.c
util/hbitmap.c