From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=54653 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OWUr3-0006Aq-ID for qemu-devel@nongnu.org; Wed, 07 Jul 2010 09:40:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OWUr1-0008TO-U0 for qemu-devel@nongnu.org; Wed, 07 Jul 2010 09:40:01 -0400 Received: from mx1.redhat.com ([209.132.183.28]:13437) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OWUr1-0008TA-Ko for qemu-devel@nongnu.org; Wed, 07 Jul 2010 09:39:59 -0400 Date: Wed, 7 Jul 2010 14:39:53 +0100 From: "Daniel P. Berrange" Message-ID: <20100707133953.GR24755@redhat.com> References: <1278106023-9966-1-git-send-email-miguel.filho@gmail.com> <1278106023-9966-2-git-send-email-miguel.filho@gmail.com> <20100705122253.5d771107@redhat.com> <20100707100709.27a9a9e7@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20100707100709.27a9a9e7@redhat.com> Subject: [Qemu-devel] Re: [PATCH 1/2] QMP: Introduce the documentation for query-qdm Reply-To: "Daniel P. Berrange" List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Luiz Capitulino Cc: avi@redhat.com, Miguel Di Ciurcio Filho , qemu-devel@nongnu.org, armbru@redhat.com On Wed, Jul 07, 2010 at 10:07:09AM -0300, Luiz Capitulino wrote: > On Mon, 5 Jul 2010 16:34:22 -0300 > Miguel Di Ciurcio Filho wrote: > > > Possible values for "type" are defined in the patch on the > > qdev_property_type_to_string() function. To spot them in the current > > code, hw/qdev.c:77: > > > > enum PropertyType { > > PROP_TYPE_UNSPEC = 0, > > PROP_TYPE_UINT8, > > PROP_TYPE_UINT16, > > PROP_TYPE_UINT32, > > PROP_TYPE_INT32, > > PROP_TYPE_UINT64, > > PROP_TYPE_TADDR, > > PROP_TYPE_MACADDR, > > PROP_TYPE_DRIVE, > > PROP_TYPE_CHR, > > PROP_TYPE_STRING, > > PROP_TYPE_NETDEV, > > PROP_TYPE_VLAN, > > PROP_TYPE_PTR, > > PROP_TYPE_BIT, > > }; > > > > So it is a mix of json-(string|integer|boolean). It seams to me that a > > device_add using QMP will use just use strings. Need to confirm that. > > There are integers too. > > Daniel, can you clarify how libvirt is going to use this member? We're not actively planning to use this field. When I wrote the patch originally, I was aiming to provide the maximim semantically useful information possible, rather than just the generic json data type. This ensures that this is fully self-documenting. > Maybe we could have something like this: > > "type": { "qdev": "macaddr", "qmp": "string" } Daniel -- |: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :| |: http://libvirt.org -o- http://virt-manager.org -o- http://deltacloud.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|