[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-block] [PATCH 05/24] block: fix bdrv_dirty_bitmap_granularity sign
From: |
Vladimir Sementsov-Ogievskiy |
Subject: |
[Qemu-block] [PATCH 05/24] block: fix bdrv_dirty_bitmap_granularity signature |
Date: |
Thu, 2 Feb 2017 16:21:26 +0300 |
Make getter signature const-correct. This allows other functions with
const dirty bitmap parameter use bdrv_dirty_bitmap_granularity().
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: John Snow <address@hidden>
Reviewed-by: Kevin Wolf <address@hidden>
Signed-off-by: Vladimir Sementsov-Ogievskiy <address@hidden>
---
block/dirty-bitmap.c | 2 +-
include/block/dirty-bitmap.h | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/block/dirty-bitmap.c b/block/dirty-bitmap.c
index 519737c8d3..186941cfc3 100644
--- a/block/dirty-bitmap.c
+++ b/block/dirty-bitmap.c
@@ -388,7 +388,7 @@ uint32_t
bdrv_get_default_bitmap_granularity(BlockDriverState *bs)
return granularity;
}
-uint32_t bdrv_dirty_bitmap_granularity(BdrvDirtyBitmap *bitmap)
+uint32_t bdrv_dirty_bitmap_granularity(const BdrvDirtyBitmap *bitmap)
{
return BDRV_SECTOR_SIZE << hbitmap_granularity(bitmap->bitmap);
}
diff --git a/include/block/dirty-bitmap.h b/include/block/dirty-bitmap.h
index 9dea14ba03..7cbe623ba7 100644
--- a/include/block/dirty-bitmap.h
+++ b/include/block/dirty-bitmap.h
@@ -29,7 +29,7 @@ void bdrv_disable_dirty_bitmap(BdrvDirtyBitmap *bitmap);
void bdrv_enable_dirty_bitmap(BdrvDirtyBitmap *bitmap);
BlockDirtyInfoList *bdrv_query_dirty_bitmaps(BlockDriverState *bs);
uint32_t bdrv_get_default_bitmap_granularity(BlockDriverState *bs);
-uint32_t bdrv_dirty_bitmap_granularity(BdrvDirtyBitmap *bitmap);
+uint32_t bdrv_dirty_bitmap_granularity(const BdrvDirtyBitmap *bitmap);
uint32_t bdrv_dirty_bitmap_meta_granularity(BdrvDirtyBitmap *bitmap);
bool bdrv_dirty_bitmap_enabled(BdrvDirtyBitmap *bitmap);
bool bdrv_dirty_bitmap_frozen(BdrvDirtyBitmap *bitmap);
--
2.11.0
- [Qemu-block] [PATCH 12/24] block/dirty-bitmap: add bdrv_dirty_bitmap_next(), (continued)
- [Qemu-block] [PATCH 12/24] block/dirty-bitmap: add bdrv_dirty_bitmap_next(), Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 21/24] qcow2-bitmap: refcounts, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 22/24] block/dirty-bitmap: add bdrv_remove_persistent_dirty_bitmap, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 20/24] qcow2-refcount: rename inc_refcounts() and make it public, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 03/24] hbitmap: improve dirty iter, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 24/24] qmp: block-dirty-bitmap-remove: remove persistent, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 23/24] qcow2: add .bdrv_remove_persistent_dirty_bitmap, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 07/24] qcow2: add bitmaps extension, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 08/24] block: introduce auto-loading bitmaps, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 06/24] block/dirty-bitmap: add deserialize_ones func, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 05/24] block: fix bdrv_dirty_bitmap_granularity signature,
Vladimir Sementsov-Ogievskiy <=
- [Qemu-block] [PATCH 11/24] block: introduce persistent dirty bitmaps, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 15/24] qcow2: add .bdrv_can_store_new_dirty_bitmap, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 04/24] tests: add hbitmap iter test, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 13/24] qcow2: add .bdrv_store_persistent_dirty_bitmaps(), Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 17/24] qmp: add autoload parameter to block-dirty-bitmap-add, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 18/24] qmp: add x-debug-block-dirty-bitmap-sha256, Vladimir Sementsov-Ogievskiy, 2017/02/02
- [Qemu-block] [PATCH 09/24] qcow2: add .bdrv_load_autoloading_dirty_bitmaps, Vladimir Sementsov-Ogievskiy, 2017/02/02
- Re: [Qemu-block] [Qemu-devel] [PATCH v12 00/24] qcow2: persistent dirty bitmaps, no-reply, 2017/02/02