From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58426) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YAhtz-0000NK-7q for qemu-devel@nongnu.org; Mon, 12 Jan 2015 11:31:39 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YAhty-0005N3-C6 for qemu-devel@nongnu.org; Mon, 12 Jan 2015 11:31:39 -0500 Received: from mx1.redhat.com ([209.132.183.28]:38302) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YAhty-0005Ms-48 for qemu-devel@nongnu.org; Mon, 12 Jan 2015 11:31:38 -0500 From: John Snow Date: Mon, 12 Jan 2015 11:31:03 -0500 Message-Id: <1421080265-2228-12-git-send-email-jsnow@redhat.com> In-Reply-To: <1421080265-2228-1-git-send-email-jsnow@redhat.com> References: <1421080265-2228-1-git-send-email-jsnow@redhat.com> Subject: [Qemu-devel] [PATCH v11 11/13] qmp: Add dirty bitmap status fields in query-block List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: kwolf@redhat.com, famz@redhat.com, John Snow , armbru@redhat.com, mreitz@redhat.com, vsementsov@parallels.com, stefanha@redhat.com From: Fam Zheng Adds the "enabled" and "frozen" status booleans. Signed-off-by: Fam Zheng Signed-off-by: John Snow --- block.c | 2 ++ qapi/block-core.json | 7 ++++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/block.c b/block.c index 5eb6788..9e2b8c0 100644 --- a/block.c +++ b/block.c @@ -5531,6 +5531,8 @@ BlockDirtyInfoList *bdrv_query_dirty_bitmaps(BlockDriverState *bs) info->granularity = bdrv_dirty_bitmap_granularity(bs, bm); info->has_name = !!bm->name; info->name = g_strdup(bm->name); + info->enabled = bm->enabled; + info->frozen = bm->frozen; entry->value = info; *plist = entry; plist = &entry->next; diff --git a/qapi/block-core.json b/qapi/block-core.json index 92c3a84..5f82cf3 100644 --- a/qapi/block-core.json +++ b/qapi/block-core.json @@ -328,10 +328,15 @@ # # @granularity: granularity of the dirty bitmap in bytes (since 1.4) # +# @enabled: whether the dirty bitmap is enabled (Since 2.3) +# +# @frozen: whether the dirty bitmap is frozen (Since 2.3) +# # Since: 1.3 ## { 'type': 'BlockDirtyInfo', - 'data': {'*name': 'str', 'count': 'int', 'granularity': 'int'} } + 'data': {'*name': 'str', 'count': 'int', 'granularity': 'int', + 'enabled': 'bool', 'frozen': 'bool'} } ## # @BlockInfo: -- 1.9.3