From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46249) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XZgK4-0008Jv-My for qemu-devel@nongnu.org; Thu, 02 Oct 2014 09:21:41 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XZgJv-0000Gs-0h for qemu-devel@nongnu.org; Thu, 02 Oct 2014 09:21:32 -0400 Received: from mail-wi0-x229.google.com ([2a00:1450:400c:c05::229]:35065) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XZgJu-0000Gk-QJ for qemu-devel@nongnu.org; Thu, 02 Oct 2014 09:21:22 -0400 Received: by mail-wi0-f169.google.com with SMTP id cc10so1501391wib.4 for ; Thu, 02 Oct 2014 06:21:22 -0700 (PDT) Date: Thu, 2 Oct 2014 14:21:19 +0100 From: Stefan Hajnoczi Message-ID: <20141002132119.GD30564@stefanha-thinkpad.redhat.com> References: <1412078370-3555-1-git-send-email-armbru@redhat.com> <87iok46kb8.fsf@blackfin.pond.sub.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="IMjqdzrDRly81ofr" Content-Disposition: inline In-Reply-To: <87iok46kb8.fsf@blackfin.pond.sub.org> Subject: Re: [Qemu-devel] IDs in QOM (was: [PATCH] util: Emancipate id_wellformed() from QemuOpts) List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster Cc: kwolf@redhat.com, peter.maydell@linaro.org, peter.crosthwaite@xilinx.com, Anthony Liguori , qemu-devel@nongnu.org, stefanha@redhat.com, Paolo Bonzini , Andreas =?iso-8859-1?Q?F=E4rber?= --IMjqdzrDRly81ofr Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Oct 01, 2014 at 02:33:47PM +0200, Markus Armbruster wrote: > Markus Armbruster writes: This discussion seems orthogonal to your patch. But I'm not applying it yet to give more time for discussion/review of the patch. > Is mangling array-ness into the name really a good idea? Isn't this > type matter, not name matter? I agree. It's nasty to hack the array selector into the name and will probably cause us pain down the line. > Backtracking a bit... Unlike QMP object-add, -object ) and HMP > object-add use QemuOpts. See object_create(), commit 68d98d3 "vl: add > -object option to create QOM objects from the command line", and > hmp_object_add(), commit cff8b2c "monitor: add object-add (QMP) and > object_add (HMP) command". Parameter 'id' is the QemuOpts ID, thus > bound by its well-formedness rule. >=20 > Therefore, -object and HMP object-add only support a subset of the > possible names. >=20 > In particular, they do not permit "automatic arrayification". >=20 > Should QOM names be (well-formed!) IDs? Yes, I think that is sane. Are there any invalid IDs used as QOM names today? Hopefully the answer is no and we can lock everything down using id_wellformed(). --IMjqdzrDRly81ofr Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAEBAgAGBQJULVFPAAoJEJykq7OBq3PIPGQH/1sT3Th0J0xpnLCIT27ApAUP xDeHa4Dpg/GKbWdtPj+G5hkMkDDUn7EBVFjFlHn7NfQSQ4jV4r1/D4y1rv7qNL2a UEXzV10zxHoNg8r0GQIFgIXMwu5NhdL1ehcYinNOK70gKLFB3oNhRb+Uqxs7G3z8 0rvyCZ8c9GCEEc8Y3WG9tnkQtEa07XPTR38v365vI38jAqbkwIcjrQNQgWk/GgOR nLeLzjJ7yUEmQWFN7WuMoU3KmLl2Bbld3ksbHIvI+EYl+Y2TfpmZkjvXHb0VNHor m3463BmkhFhShtZMQGaovlph6Rm1rBIB+i1wXDm5nPOqzFICDU0PRndpsxM/3nQ= =eXlz -----END PGP SIGNATURE----- --IMjqdzrDRly81ofr--