From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:56074) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UgmFe-0004fw-8o for qemu-devel@nongnu.org; Sun, 26 May 2013 21:29:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UgmFc-0002SM-Kz for qemu-devel@nongnu.org; Sun, 26 May 2013 21:29:30 -0400 Received: from e23smtp06.au.ibm.com ([202.81.31.148]:50796) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UgmFc-0002S7-2Y for qemu-devel@nongnu.org; Sun, 26 May 2013 21:29:28 -0400 Received: from /spool/local by e23smtp06.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 27 May 2013 11:22:44 +1000 Received: from d23relay05.au.ibm.com (d23relay05.au.ibm.com [9.190.235.152]) by d23dlp02.au.ibm.com (Postfix) with ESMTP id EC7CB2BB0023 for ; Mon, 27 May 2013 11:29:17 +1000 (EST) Received: from d23av03.au.ibm.com (d23av03.au.ibm.com [9.190.234.97]) by d23relay05.au.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id r4R1Esui24641684 for ; Mon, 27 May 2013 11:14:55 +1000 Received: from d23av03.au.ibm.com (loopback [127.0.0.1]) by d23av03.au.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id r4R1TG69002428 for ; Mon, 27 May 2013 11:29:17 +1000 Message-ID: <51A2B6DB.5030206@linux.vnet.ibm.com> Date: Mon, 27 May 2013 09:28:59 +0800 From: Wenchao Xia MIME-Version: 1.0 References: <1369455886-30677-1-git-send-email-xiawenc@linux.vnet.ibm.com> <1369455886-30677-4-git-send-email-xiawenc@linux.vnet.ibm.com> <51A0E26A.7020703@redhat.com> In-Reply-To: <51A0E26A.7020703@redhat.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Subject: Re: [Qemu-devel] [PATCH V13 3/6] qmp: add recursive member in ImageInfo List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake Cc: kwolf@redhat.com, phrdina@redhat.com, stefanha@gmail.com, qemu-devel@nongnu.org, lcapitulino@redhat.com, pbonzini@redhat.com, armbru@redhat.com 于 2013-5-26 0:10, Eric Blake 写道: > On 05/24/2013 10:24 PM, Wenchao Xia wrote: >> New member *backing-image is added to reflect the backing chain >> status. >> >> Signed-off-by: Wenchao Xia >> --- >> block/qapi.c | 16 +++++++++++++++- >> qapi-schema.json | 5 ++++- >> 2 files changed, 19 insertions(+), 2 deletions(-) >> >> diff --git a/block/qapi.c b/block/qapi.c >> index 680ec23..cbef584 100644 >> --- a/block/qapi.c >> +++ b/block/qapi.c >> @@ -88,7 +88,21 @@ int bdrv_query_snapshot_info_list(BlockDriverState *bs, >> return 0; >> } >> >> -/* @p_info will be set only on success. */ >> +/** >> + * bdrv_query_image_info: >> + * @bs: block device to examine >> + * @p_info: location to store image information >> + * @errp: location to store error information >> + * >> + * Store "flat" image inforation in @p_info. > > s/inforation/information/ > >> + * >> + * "Flat" means it does *not* query backing image information, >> + * i.e. (*pinfo)->has_backing_image will be set to false and >> + * (*pinfo)->backing_image to NULL even when the image does in fact have >> + * a backing image. >> + * >> + * @p_info will be set only on success. On error, store error in @errp. >> + */ > > Does this comment hunk belong in the previous patch? > Yes, it got modified again in this one, will move it. >> void bdrv_query_image_info(BlockDriverState *bs, >> ImageInfo **p_info, >> Error **errp) >> diff --git a/qapi-schema.json b/qapi-schema.json >> index ef1f657..a02999d 100644 >> --- a/qapi-schema.json >> +++ b/qapi-schema.json >> @@ -236,6 +236,8 @@ >> # >> # @snapshots: #optional list of VM snapshots >> # >> +# @backing-image: #optional info of the backing image (since 1.6) >> +# >> # Since: 1.3 >> # >> ## >> @@ -245,7 +247,8 @@ >> '*actual-size': 'int', 'virtual-size': 'int', >> '*cluster-size': 'int', '*encrypted': 'bool', >> '*backing-filename': 'str', '*full-backing-filename': 'str', >> - '*backing-filename-format': 'str', '*snapshots': ['SnapshotInfo'] } } >> + '*backing-filename-format': 'str', '*snapshots': ['SnapshotInfo'], >> + '*backing-image': 'ImageInfo' } } > > The API change looks fine, except there is no code change to actually > populate the new field. This hunk should probably be squashed with the > patch that implements the field. Also, are you missing any changes to > qmp-commands.hx? > nop, in next patch qmp-commands.hx parts is added. Just to make review easier, after that I am fine to squash them. -- Best Regards Wenchao Xia