Received: from eggs.gnu.org ([2001:4830:134:3::10]:60013) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bhhSs-0003cE-Pr for qemu-devel@nongnu.org; Wed, 07 Sep 2016 14:20:51 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bhhSm-0006TZ-NI for qemu-devel@nongnu.org; Wed, 07 Sep 2016 14:20:49 -0400 Received: from mx1.redhat.com ([209.132.183.28]:58648) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bhhSm-0006TO-F1 for qemu-devel@nongnu.org; Wed, 07 Sep 2016 14:20:44 -0400 References: <1472736127-18137-1-git-send-email-marcel@redhat.com> <6c9103e7-70ad-55c6-5533-d6d9bbaa39b4@redhat.com> <1473161728.31857.20.camel@redhat.com> <4cabe465-75bc-434b-be4f-c9a4b915f435@redhat.com> <1473231880.28663.34.camel@redhat.com> From: Laine Stump Message-ID: <31ce90c6-8775-dd71-5aaa-ead4a4b24733@redhat.com> Date: Wed, 7 Sep 2016 14:20:41 -0400 MIME-Version: 1.0 In-Reply-To: <1473231880.28663.34.camel@redhat.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH RFC] docs: add PCIe devices placement guidelines List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Gerd Hoffmann , qemu-devel@nongnu.org Cc: Laszlo Ersek , Marcel Apfelbaum , mst@redhat.com, Peter Maydell , Drew Jones , Andrea Bolognani , Alex Williamson On 09/07/2016 03:04 AM, Gerd Hoffmann wrote: > Hi, > >>> Side note for usb: In practice you don't want to use the tons of >>> uhci/ehci controllers present in the original q35 but plug xhci into one >>> of the pcie root ports instead (unless your guest doesn't support xhci). >> >> I've wondered about that recently. For i440fx machinetypes if you don't >> specify a USB controller in libvirt's domain config, you will >> automatically get the PIIX3 USB controller added. In order to maintain >> consistency on the topic of "auto-adding USB when not specified", if the >> machinetype is Q35 we will autoadd a set of USB2 (uhci/ehci) controllers >> (I think I added that based on your comments at the time :-). But >> recently I've mostly been hearing that people should use xhci instead. >> So should libvirt add a single xhci (rather than the uhci/ehci set) at >> the same port when no USB is specified? > > Big advantage of xhci is that the hardware design is much more > virtualization friendly, i.e. it needs alot less cpu cycles to emulate > than uhci/ohci/ehci. Also xhci can handle all usb speeds, so you don't > need the complicated uhci/ehci companion setup with uhci for usb1 and > ehci for usb2 devices. > > The problem with xhci is guest support. Which becomes less and less of > a problem over time of course. All our firmware (seabios/edk2/slof) has > xhci support meanwhile. ppc64 switched from ohci to xhci by default in > rhel-7.3. Finding linux guests without xhci support is pretty hard > meanwhile. Maybe RHEL-5 qualifies. Windows 8 + newer ships with xhci > drivers. > > So, yea, maybe it's time to switch the default for q35 to xhci, > especially if we keep uhci as default for i440fx and suggest to use that > machine type for oldish guests. But I'd suggest to place xhci in a pcie > root port then, so maybe wait with that until libvirt can auto-add pcie > root ports as needed ... I'm doing that right now (giving libvirt the ability to auto-add root ports) :-) I had understood that the xhci could be a legacy PCI device or a PCI Express device depending on the socket it was plugged into (or was that possibly just someone doing some hand-waving over the fact that obscuring the PCI Express capabilities effectively turns it into a legacy PCI device?). If that's the case, why do you prefer the default USB controller to be added in a root-port rather than as an integrated device (which is what we do with the group of USB2 controllers, as well as the primary video device)