From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43141) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VzzVJ-0005Pv-6f for qemu-devel@nongnu.org; Sun, 05 Jan 2014 21:01:30 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VzzV8-0001G2-AG for qemu-devel@nongnu.org; Sun, 05 Jan 2014 21:01:21 -0500 Received: from e28smtp08.in.ibm.com ([122.248.162.8]:51208) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VzzV7-0001Fj-N0 for qemu-devel@nongnu.org; Sun, 05 Jan 2014 21:01:10 -0500 Received: from /spool/local by e28smtp08.in.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 6 Jan 2014 07:31:06 +0530 Received: from d28relay01.in.ibm.com (d28relay01.in.ibm.com [9.184.220.58]) by d28dlp02.in.ibm.com (Postfix) with ESMTP id E08983940023 for ; Mon, 6 Jan 2014 07:31:04 +0530 (IST) Received: from d28av05.in.ibm.com (d28av05.in.ibm.com [9.184.220.67]) by d28relay01.in.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id s0620xlO57933936 for ; Mon, 6 Jan 2014 07:31:00 +0530 Received: from d28av05.in.ibm.com (localhost [127.0.0.1]) by d28av05.in.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id s0621342011416 for ; Mon, 6 Jan 2014 07:31:04 +0530 Message-ID: <52CA0E5E.9090409@linux.vnet.ibm.com> Date: Mon, 06 Jan 2014 10:01:02 +0800 From: Wenchao Xia MIME-Version: 1.0 References: <1387516996-27531-1-git-send-email-xiawenc@linux.vnet.ibm.com> <1387516996-27531-8-git-send-email-xiawenc@linux.vnet.ibm.com> In-Reply-To: <1387516996-27531-8-git-send-email-xiawenc@linux.vnet.ibm.com> Content-Type: text/plain; charset=GB2312 Content-Transfer-Encoding: 8bit Subject: Re: [Qemu-devel] [PATCH V5 07/10] qapi: convert BlockdevOptions to use enum discriminator List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: kwolf@redhat.com, Wenchao Xia , lcapitulino@redhat.com, mdroth@linux.vnet.ibm.com, armbru@redhat.com ÓÚ 2013/12/20 13:23, Wenchao Xia дµÀ: > After this patch, hidden enum type BlockdevOptionsKind will not > be generated, and other API can use enum BlockdevDriver. > > Signed-off-by: Wenchao Xia > Reviewed-by: Eric Blake > --- > qapi-schema.json | 14 +++++++++++++- > 1 files changed, 13 insertions(+), 1 deletions(-) > > diff --git a/qapi-schema.json b/qapi-schema.json > index c3c939c..9b51dcc 100644 > --- a/qapi-schema.json > +++ b/qapi-schema.json > @@ -4046,6 +4046,18 @@ > '*no-flush': 'bool' } } > > ## > +# @BlockdevDriver > +# > +# Drivers that are supported in block device operations. > +# > +# Since: 2.0 > +## > +{ 'enum': 'BlockdevDriver', > + 'data': [ 'file', 'http', 'https', 'ftp', 'ftps', 'tftp', 'vvfat', 'bochs', > + 'cloop', 'cow', 'dmg', 'parallels', 'qcow', 'qcow2', 'qed', 'raw', > + 'vdi', 'vhdx', 'vmdk', 'vpc' ] } > + > +## > # @BlockdevOptionsBase > # > # Options that are available for all block devices, independent of the block > @@ -4068,7 +4080,7 @@ > # Since: 1.7 > ## > { 'type': 'BlockdevOptionsBase', > - 'data': { 'driver': 'str', > + 'data': { 'driver': 'BlockdevDriver', > '*id': 'str', > '*discard': 'BlockdevDiscardOptions', > '*cache': 'BlockdevCacheOptions', > Hi Kevin, Could u take a look at this patch?