[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [PATCH v5 04/21] qmp: Add block-dirty-bitmap-add and bl
From: |
Eric Blake |
Subject: |
Re: [Qemu-block] [PATCH v5 04/21] qmp: Add block-dirty-bitmap-add and block-dirty-bitmap-remove |
Date: |
Fri, 17 Apr 2015 08:54:04 -0600 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 |
On 04/08/2015 04:19 PM, John Snow wrote:
> The new command pair is added to manage a user created dirty bitmap. The
> dirty bitmap's name is mandatory and must be unique for the same device,
> but different devices can have bitmaps with the same names.
>
> The granularity is an optional field. If it is not specified, we will
> choose a default granularity based on the cluster size if available,
> clamped to between 4K and 64K to mirror how the 'mirror' code was
> already choosing granularity. If we do not have cluster size info
> available, we choose 64K. This code has been factored out into a helper
> shared with block/mirror.
>
> This patch also introduces the 'block_dirty_bitmap_lookup' helper,
> which takes a device name and a dirty bitmap name and validates the
> lookup, returning NULL and setting errp if there is a problem with
> either field. This helper will be re-used in future patches in this
> series.
>
> The types added to block-core.json will be re-used in future patches
> in this series, see:
> 'qapi: Add transaction support to block-dirty-bitmap-{add, enable, disable}'
>
> Signed-off-by: John Snow <address@hidden>
> Reviewed-by: Max Reitz <address@hidden>
> Reviewed-by: Stefan Hajnoczi <address@hidden>
> ---
> block.c | 20 +++++++++
> block/mirror.c | 10 +----
> blockdev.c | 117
> ++++++++++++++++++++++++++++++++++++++++++++++++++
> include/block/block.h | 1 +
> qapi/block-core.json | 55 ++++++++++++++++++++++++
> qmp-commands.hx | 56 ++++++++++++++++++++++++
> 6 files changed, 250 insertions(+), 9 deletions(-)
>
Reviewed-by: Eric Blake <address@hidden>
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
- [Qemu-block] [PATCH v5 00/21] block: transactionless incremental backup series, John Snow, 2015/04/08
- [Qemu-block] [PATCH v5 03/21] qmp: Ensure consistent granularity type, John Snow, 2015/04/08
- [Qemu-block] [PATCH v5 05/21] block: Introduce bdrv_dirty_bitmap_granularity(), John Snow, 2015/04/08
- [Qemu-block] [PATCH v5 06/21] hbitmap: cache array lengths, John Snow, 2015/04/08
- [Qemu-block] [PATCH v5 04/21] qmp: Add block-dirty-bitmap-add and block-dirty-bitmap-remove, John Snow, 2015/04/08
- Re: [Qemu-block] [PATCH v5 04/21] qmp: Add block-dirty-bitmap-add and block-dirty-bitmap-remove,
Eric Blake <=
- [Qemu-block] [PATCH v5 07/21] hbitmap: add hbitmap_merge, John Snow, 2015/04/08
- [Qemu-block] [PATCH v5 02/21] qapi: Add optional field "name" to block dirty bitmap, John Snow, 2015/04/08
- [Qemu-block] [PATCH v5 09/21] block: Add bitmap successors, John Snow, 2015/04/08
- [Qemu-block] [PATCH v5 08/21] block: Add bitmap disabled status, John Snow, 2015/04/08
- [Qemu-block] [PATCH v5 13/21] block: add BdrvDirtyBitmap documentation, John Snow, 2015/04/08
- [Qemu-block] [PATCH v5 12/21] qmp: Add dirty bitmap status field in query-block, John Snow, 2015/04/08