From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:34088) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TSUvW-00061r-EI for qemu-devel@nongnu.org; Sun, 28 Oct 2012 11:37:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TSUvV-0007Ow-Ak for qemu-devel@nongnu.org; Sun, 28 Oct 2012 11:37:26 -0400 Received: from mail-vb0-f45.google.com ([209.85.212.45]:33112) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TSUvV-0007Or-6S for qemu-devel@nongnu.org; Sun, 28 Oct 2012 11:37:25 -0400 Received: by mail-vb0-f45.google.com with SMTP id p1so4295589vbi.4 for ; Sun, 28 Oct 2012 08:37:24 -0700 (PDT) Date: Sun, 28 Oct 2012 11:37:18 -0400 From: "Gabriel L. Somlo" Message-ID: <20121028153717.GD29280@hedwig.ini.cmu.edu> References: <20121024145527.GB2107@hedwig.ini.cmu.edu> <20121026202444.GA25597@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20121026202444.GA25597@redhat.com> Subject: Re: [Qemu-devel] q35: usb keyboard trouble List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Jason Baron Cc: pbonzini@redhat.com, kraxel@redhat.com, qemu-devel@nongnu.org, hdegoede@redhat.com On Fri, Oct 26, 2012 at 04:24:44PM -0400, Jason Baron wrote: > Thanks for the bug report! What OS are you running? I'm not seeing any > issue with -usbdevice keyboard on Fedora. I was using this: bin/qemu-system-x86_64 \ -M pc_q35 -L q35-seabios/out \ -usbdevice keyboard \ -hdd ./Fedora-14-x86_64-netinst.iso > Paolo pointed out that I was missing some ich9 specific initialization > from docs/ich9-ehci-uhci.cfg. I've added that in the patch below. I have > no idea if that will resolve this issue for you. This patch does indeed fix the problem for me, thanks for sending it ! The only small observation I have is that you seem to name all three UHCI devices "ich9-usb-uhci1". There's probably a better way than my patch below (on top of the one you just sent), but here's the general idea :) Thanks, --Gabriel --- a/hw/pc_q35.c +++ b/hw/pc_q35.c @@ -185,23 +185,25 @@ if (usb_enabled) { int i; PCIDevice *usb; DeviceState *usb_qdev; + char devname[] = "ich9-usb-uhciX"; /* Should we create 6 UHCI according to ich9 spec? */ usb = pci_create_multifunction( host_bus, PCI_DEVFN(ICH9_USB_DEV, ICH9_USB_EHCI1_FUNC), true, "ich9-usb-ehci1"); usb_qdev = &usb->qdev; usb_qdev->id = g_strdup("ich9-usb-bus"); qdev_init_nofail(usb_qdev); for (i = 0; i < 3; i++) { + sprintf(devname, "ich9-usb-uhci%d", i + 1); usb = pci_create_multifunction( host_bus, PCI_DEVFN(ICH9_USB_DEV, ICH9_USB_UHCI1_FUNC + i), - true, "ich9-usb-uhci1"); + true, devname); usb_qdev = &usb->qdev; qdev_prop_set_string(usb_qdev, "masterbus", "ich9-usb-bus.0"); qdev_prop_set_uint32(usb_qdev, "firstport", i * 2); qdev_init_nofail(usb_qdev); }