Hi,
On 12/29/2013 08:44 AM, Stewart Adam wrote:
Hi,
I have been attempting to attach a USB keyboard & mouse from the host to a Windows 7
guest using QEMU's USB2 controller. The keyboard seems to attach correctly, however I
have trouble with certain mice and devices. When starting the guest, the devices remain
attached for a second or two, then they disconnect. the libvirt logs show that it no
longer sees the USB device, and I see this in dmesg:
[ 10.876071] usb 3-13: reset full-speed USB device number 2 using xhci_hcd
[ 10.888206] xhci_hcd 0000:00:14.0: xHCI xhci_drop_endpoint called with disabled ep
ffff88041917f740
[ 10.888209] xhci_hcd 0000:00:14.0: xHCI xhci_drop_endpoint called with disabled ep
ffff88041917f800
[ 10.888210] xhci_hcd 0000:00:14.0: xHCI xhci_drop_endpoint called with disabled ep
ffff88041917f7c0
[ 11.041209] usb 3-14: reset full-speed USB device number 3 using xhci_hcd
[ 11.054379] xhci_hcd 0000:00:14.0: xHCI xhci_drop_endpoint called with disabled ep
ffff8800c8d559c0
[ 11.054383] xhci_hcd 0000:00:14.0: xHCI xhci_drop_endpoint called with disabled ep
ffff8800c8d55440
<repeats for some time>
[ 87.476806] usb 3-14: new full-speed USB device number 4 using xhci_hcd
[ 87.491908] usb 3-14: New USB device found, idVendor=046d, idProduct=c066
[ 87.491911] usb 3-14: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 87.491912] usb 3-14: Product: G9x Laser Mouse
[ 87.491914] usb 3-14: Manufacturer: Logitech
[ 87.491914] usb 3-14: SerialNumber: 081BB92CA70018
[ 87.494697] input: Logitech G9x Laser Mouse as
/devices/pci0000:00/0000:00:14.0/usb3/3-14/3-14:1.0/input/input16
[ 87.494994] hid-generic 0003:046D:C066.0008: input,hidraw0: USB HID v1.11 Mouse
[Logitech G9x Laser Mouse] on usb-0000:00:14.0-14/input0
[ 87.498834] input: Logitech G9x Laser Mouse as
/devices/pci0000:00/0000:00:14.0/usb3/3-14/3-14:1.1/input/input17
[ 87.499078] hid-generic 0003:046D:C066.0009: input,hiddev0,hidraw1: USB HID v1.11
Keyboard [Logitech G9x Laser Mouse] on usb-0000:00:14.0-14/input1
As you can see the device re-attaches to the host. The device is plugged into a USB2
port, but it appears to be controlled by Intel's XHCI controller:
00:14.0 USB controller [0c03]: Intel Corporation 8 Series/C220 Series Chipset Family USB
xHCI [8086:8c31] (rev 04)
What seems to be happening is that the guest is getting errors when talking to the device
and keeps resetting
the device. And at one point in time the many resets lead to a disconnect / reset.
So the problem is the many resets. What usb redirection are you using, are you using
qemu's host redirection,
or are you using spice's usb redirection. If you don't know please describe how
you're redirecting the
devices (ie which cmdline you use, or which gui options you choose).
If you're using qemu's host redirection code can you retry with spice's
usbredir code ?
Regards,
Hans