From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47644) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XZgP2-0001UK-Iz for qemu-devel@nongnu.org; Thu, 02 Oct 2014 09:26:48 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XZgOu-0002Uo-3e for qemu-devel@nongnu.org; Thu, 02 Oct 2014 09:26:40 -0400 Received: from cantor2.suse.de ([195.135.220.15]:44385 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XZgOt-0002UU-OM for qemu-devel@nongnu.org; Thu, 02 Oct 2014 09:26:32 -0400 Message-ID: <542D5284.1060201@suse.de> Date: Thu, 02 Oct 2014 15:26:28 +0200 From: =?windows-1252?Q?Andreas_F=E4rber?= MIME-Version: 1.0 References: <1412078370-3555-1-git-send-email-armbru@redhat.com> <87iok46kb8.fsf@blackfin.pond.sub.org> <20141002132119.GD30564@stefanha-thinkpad.redhat.com> In-Reply-To: <20141002132119.GD30564@stefanha-thinkpad.redhat.com> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="xNu7PCBbrIxBXojc5LE05rktWvN8VB72n" Subject: Re: [Qemu-devel] IDs in QOM List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Hajnoczi , 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 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --xNu7PCBbrIxBXojc5LE05rktWvN8VB72n Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Am 02.10.2014 um 15:21 schrieb Stefan Hajnoczi: > On Wed, Oct 01, 2014 at 02:33:47PM +0200, Markus Armbruster wrote: >> Markus Armbruster writes: >=20 > This discussion seems orthogonal to your patch. But I'm not applying i= t > yet to give more time for discussion/review of the patch. >=20 >> Is mangling array-ness into the name really a good idea? Isn't this >> type matter, not name matter? >=20 > I agree. It's nasty to hack the array selector into the name and will > probably cause us pain down the line. >=20 >> 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. >> >> Therefore, -object and HMP object-add only support a subset of the >> possible names. >> >> In particular, they do not permit "automatic arrayification". >> >> Should QOM names be (well-formed!) IDs? >=20 > Yes, I think that is sane. >=20 > Are there any invalid IDs used as QOM names today? >=20 > Hopefully the answer is no and we can lock everything down using > id_wellformed(). On IRC I was arguing against that, preferring some more specific object_property_name_wellformed() or so. This could be called from object_property_add(), with invalid names returning an Error *. Only thing to check for would be '/'? Regards, Andreas --=20 SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N=FCrnberg, Germany GF: Jeff Hawn, Jennifer Guild, Felix Imend=F6rffer; HRB 16746 AG N=FCrnbe= rg --xNu7PCBbrIxBXojc5LE05rktWvN8VB72n Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQIcBAEBAgAGBQJULVKEAAoJEPou0S0+fgE/C0MP/0WhDMAZfiheX8Rsc/9yl2Sx Q5knHcKWnbJ+O7uT2LCbcmqBKFtuYCUJ/y9NOopCDzDIcc8y6Z1X+8rV5ZJxvkvP hw+3IS6CTAQugJ54+aqX1GQw//rJQpp8EbJiYz9LZvy/y9v6YQ6QsDMd+MLG4AwM MlaNLMm9INR8jQg+zS7O8374frAf1+rX5blUNy089pfaZInKfFvDxFA5inFWIToq gWNQmg7S1XGleyFyMM5GA11DFonQIjvmm2GHBxNUVMmFg1Y+VRNp8L4VfT6OK7Av vlRl6H7ek9YHbSdKnnhzvVFk3s0kmQX2MBdZu4NMDC85x6thQObdmjx3KmQjjQ3F 1cZiMGJENewyqcY0RcQflcMfEobZUbHNaowq2kyWQteMeMwjxrLhtZyVGCZ95pQN czqG87YjBNkpZtloAgxQeVsNEgVhm2UHBCHy+jlrllm9Nj0dUeQzLZnP/vm72Jbe KZKsCGkgtozg2OCJ3qB/zdDu/CTbdIQd06zHZxCcL3kVK46jughx9WLdN+5EHHGW w+hTZ888omdOZvXjiraKvCsV8psf9o9gGejG7ZGXYThRO158F1hTyon7e/7NN+ar zJfnUlr1fUFcjEGwAOea1ghNOm8tUde9u9RwMQTzl/6vuZddVUndIyoOsI2G2wBW wmcGWz/4IFem0Ek0rDRt =RAd8 -----END PGP SIGNATURE----- --xNu7PCBbrIxBXojc5LE05rktWvN8VB72n--