From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37671) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vgwhu-0001cu-MX for qemu-devel@nongnu.org; Thu, 14 Nov 2013 08:11:43 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vgwhp-00019M-NR for qemu-devel@nongnu.org; Thu, 14 Nov 2013 08:11:38 -0500 Message-ID: <5284CBFB.4070200@redhat.com> Date: Thu, 14 Nov 2013 06:11:23 -0700 From: Eric Blake MIME-Version: 1.0 References: <52845915.4030201@ozlabs.ru> In-Reply-To: <52845915.4030201@ozlabs.ru> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="EK0u42slwVm91Fbsp4bhgjU3uX8fDgo6j" Subject: Re: [Qemu-devel] -vga std vs. -device VGA List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alexey Kardashevskiy , "qemu-devel@nongnu.org" , "qemu-ppc@nongnu.org" Cc: "libvir-list@redhat.com" , Paul Mackerras , Alex Graf , Nikunj A Dadhania , Avik Sil This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --EK0u42slwVm91Fbsp4bhgjU3uX8fDgo6j Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable [adding libvirt] On 11/13/2013 10:01 PM, Alexey Kardashevskiy wrote: > Hi everyone. >=20 > Here is a problem with the SPAPR machine and a libvirt's habit to use > "-nodefaults". >=20 > When we run QEMU with "-vga std", a VGA device is created from the > machine_init callback and if VGA is added, then we automatically add a = PCI > USB OHCI adapter with a keyboard and everybody (SLOF, yaboot, guest ker= nel) > is happy - there are both input and output devices. >=20 > However libvirt uses "-device VGA" to create a VGA device. In this case= the > actual VGA device is created in vl.c and we (SPAPR) do not have control= > over this process so we do not automatically create anything in additio= n to > VGA. As a result, yaboot fails as there is no input device. >=20 > x86 creates a whole bunch of various devices including a keyboard > controller (i8042) even with "-nodefaults" but this is not true for SPA= PR. Then libvirt needs to be taught to provide the same devices via -device that would be present during -vga. >=20 > Since we (POWERPC folks) want everything to work as close to x86 as > possible, we need to do something about it :) Hmm, but adding automatic devices in a future qemu release compared to what you do now could be a regression - once libvirt is taught how to provide the correct devices for the qemu that exists now, wouldn't that mean that your automatic device adding creates duplicates? Libvirt uses -nodefaults for a reason - we really don't like automatic devices (especially when the set of WHAT is automatic is prone to change between qemu builds), and would much rather call out everything explicitly so that we can guarantee guest ABI stability across qemu upgrades. >=20 > So the question is - is there any proper (i. e. qemu-upstreamable) way = to > detect a VGA device presence and create additional devices (OHCI, keybo= ard, > mouse) as "-vga" does it now? The machine reset callback is too late fo= r that. >=20 > Or we should just print an error (in QEMU or SLOF) and do nothing and l= et > the user configure all required devices in libvirt? I'm in favor of printing an error if not enough devices were supplied, and fixing libvirt to supply the correct devices when it doesn't use -vga= =2E --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --EK0u42slwVm91Fbsp4bhgjU3uX8fDgo6j Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.15 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJShMv8AAoJEKeha0olJ0Nqd/gH/AlLr/QwWYh/Zscyz1VfMgOy h+/z5qU9yPBrwserXEZwwsxeedXxQrQPibLf6DxGN/pTba+deiMDI5y1OmUOFIdv +JufJbE0PVXc1F7fNxEKmHy+lRjrtfpHa8o+fyCfXF//7k7BYkQwUqhP5zbIEoNA jftzW+0T4vsz6m2/9KWbt823wvG5lYCu7TSBKszQUahXZmrU7jY9wYdJorPFfYdN 3+5fTtTm6PHs2svi75NnaOBJtq44t23jjA6iKaqRK7kn+H5otf72h44aVnw5Io0g UKvfFO3zaINpjjx4iJaiW9kg5DTahCjeJCNYDxz8LqVdZieXD9rN7/AhtI0IdyQ= =qqV8 -----END PGP SIGNATURE----- --EK0u42slwVm91Fbsp4bhgjU3uX8fDgo6j--