From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43148) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZcyIO-0001BS-7k for qemu-devel@nongnu.org; Fri, 18 Sep 2015 12:13:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZcyIJ-00038J-ON for qemu-devel@nongnu.org; Fri, 18 Sep 2015 12:13:56 -0400 References: <1442577640-11612-1-git-send-email-armbru@redhat.com> <1442577640-11612-7-git-send-email-armbru@redhat.com> From: Eric Blake Message-ID: <55FC383D.3020000@redhat.com> Date: Fri, 18 Sep 2015 10:13:49 -0600 MIME-Version: 1.0 In-Reply-To: <1442577640-11612-7-git-send-email-armbru@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="uHAnjWtrAKkKADIR7KbAovfgJbPcJNHGm" Subject: Re: [Qemu-devel] [PATCH 6/7] Revert "qdev: Use qdev_get_device_class() for -device , help" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster , qemu-devel@nongnu.org Cc: ehabkost@redhat.com, qemu-stable@nongnu.org, stefanha@redhat.com, afaerber@suse.de This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --uHAnjWtrAKkKADIR7KbAovfgJbPcJNHGm Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 09/18/2015 06:00 AM, Markus Armbruster wrote: > This reverts commit 31bed5509dfcbdfc293154ce81086a4dbd7a80b6. >=20 > The reverted commit changed qdev_device_help() to reject abstract > devices and devices that have cannot_instantiate_with_device_add_yet > set, to fix crash bugs like -device x86_64-cpu,help. >=20 > Rejecting abstract devices makes sense: they're purely internal, and > the implementation of the help feature can't cope with them. >=20 > Rejecting non-pluggable devices makes less sense: even though you > can't use them with -device, the help may still be useful elsewhere, > for instance with -global. This is a regression: -device FOO,help > used to help even for FOO that aren't pluggable. >=20 > The previous two commits fixed the crash bug at a lower layer, so > reverting this one is now safe. Fixes the -device FOO,help > regression, except for the broken devices marked > cannot_even_create_with_object_new_yet. For those, the error message > is improved. >=20 > Example of a device where the regression is fixed: >=20 > $ qemu-system-x86_64 -device PIIX4_PM,help > PIIX4_PM.command_serr_enable=3Dbool (on/off) > PIIX4_PM.multifunction=3Dbool (on/off) > PIIX4_PM.rombar=3Duint32 > PIIX4_PM.romfile=3Dstr > PIIX4_PM.addr=3Dint32 (Slot and optional function number, example: = 06.0 or 06) > PIIX4_PM.memory-hotplug-support=3Dbool > PIIX4_PM.acpi-pci-hotplug-with-bridge-support=3Dbool > PIIX4_PM.s4_val=3Duint8 > PIIX4_PM.disable_s4=3Duint8 > PIIX4_PM.disable_s3=3Duint8 > PIIX4_PM.smb_io_base=3Duint32 >=20 > Example of a device where it isn't fixed: >=20 > $ qemu-system-x86_64 -device host-x86_64-cpu,help > Can't list properties of device 'host-x86_64-cpu' >=20 > Both failed with "Parameter 'driver' expects pluggable device type" > before. >=20 > Cc: qemu-stable@nongnu.org > Signed-off-by: Markus Armbruster > --- > qdev-monitor.c | 9 ++++++--- > 1 file changed, 6 insertions(+), 3 deletions(-) Reviewed-by: Eric Blake --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --uHAnjWtrAKkKADIR7KbAovfgJbPcJNHGm 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 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJV/Dg+AAoJEKeha0olJ0NqbKwIAJ9Q19KopG4Qdks9PCtwHG// x61dVeDDZgP1vzYJ4uOZPfs51p6HyFSxp+iIQmQ4w5gEDkpHi8uZzBBG6mRGNmEI XoD55c0R4reShkJNzwmVDwaE/ryRadngl6jvoTowGmdnFZu+pclzEieQgn0tsXMd bR6kRFRFZmAFxxTN+bK/glWH75JSlhRB67IW5unoXqDMh1zzHDwmm6PgowhkBUZU rj2mNJKYz++dIn+ge1fSlyqDPIvEXJp0N4xnaHO/+7ISUb/Cu/F/DPhH/MT4mkf8 wfnGx42PJ/Rw2r19KVuPbGal7XFsPMhREIsUbM7C3OjOF0ZFMvEv6NetPKcHl/c= =n/Um -----END PGP SIGNATURE----- --uHAnjWtrAKkKADIR7KbAovfgJbPcJNHGm--