]> git.proxmox.com Git - pve-qemu-kvm.git/commitdiff
usb-hid-fix-tablet-activation
authorDerumier Alexandre <aderumier@odiso.com>
Wed, 29 Feb 2012 08:02:34 +0000 (09:02 +0100)
committerDietmar Maurer <dietmar@proxmox.com>
Wed, 29 Feb 2012 08:53:19 +0000 (09:53 +0100)
Signed-off-by: Derumier Alexandre <aderumier@odiso.com>
debian/patches/series
debian/patches/usb-hid-fix-tablet-activation.diff [new file with mode: 0644]

index d2988da4bcb601c8b27389efbda1b954efb4cfa0..af0e8239d94c5b148baeb7015c3dea0b29b9ffe0 100644 (file)
@@ -5,3 +5,4 @@ keymap.diff
 set-max-nics.patch
 pve-auth.patch
 update-target-x86_64.conf-to-rhel6.2-version.patch
+usb-hid-fix-tablet-activation.diff
diff --git a/debian/patches/usb-hid-fix-tablet-activation.diff b/debian/patches/usb-hid-fix-tablet-activation.diff
new file mode 100644 (file)
index 0000000..c6ee81c
--- /dev/null
@@ -0,0 +1,24 @@
+Activate usb hid pointer devices (mouse+tablet) unconditionally
+on polls, even if we NAK the poll due to lack of new events.
+
+Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
+---
+ hw/usb-hid.c |    3 +++
+ 1 files changed, 3 insertions(+), 0 deletions(-)
+
+diff --git a/hw/usb-hid.c b/hw/usb-hid.c
+index 7fc0bd8..37bca78 100644
+--- a/hw/usb-hid.c
++++ b/hw/usb-hid.c
+@@ -466,6 +466,9 @@ static int usb_hid_handle_data(USBDevice *dev, USBPacket *p)
+     case USB_TOKEN_IN:
+         if (p->ep->nr == 1) {
+             int64_t curtime = qemu_get_clock_ns(vm_clock);
++            if (hs->kind == HID_MOUSE || hs->kind == HID_TABLET) {
++                hid_pointer_activate(hs);
++            }
+             if (!hid_has_events(hs) &&
+                 (!hs->idle || hs->next_idle_clock - curtime > 0)) {
+                 return USB_RET_NAK;
+-- 
+1.7.1