aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Duggan <aduggan@synaptics.com>2014-07-17 19:14:45 -0400
committerJiri Kosina <jkosina@suse.cz>2014-07-29 05:28:49 -0400
commite19ff99f256aeeff6c07b373e01883b72e049552 (patch)
tree2fc5fdecb458aeee7f8e91744f549fb1e4587864
parentdd3edeb6a0267029bc3ffc480fb41dffb9081844 (diff)
HID: rmi: only bind the hid-rmi driver to the mouse interface of composite USB devices
On composite HID devices there may be multiple HID devices on separate interfaces, but hid-rmi should only bind to the mouse interface. One example is the Dell Venue 11 Pro's keyboard dock which contains a composite USB device with a HID touchpad and HID keyboard on separate intefaces. Since the USB Vendor ID is Synaptic's, hid-core is currently trying to bind hid-rmi to all\of the HID devices. This patch ensures that hid-rmi only binds to the mouse interface. related bug: https://bugzilla.kernel.org/show_bug.cgi?id=80091 Signed-off-by: Andrew Duggan <aduggan@synaptics.com> Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
-rw-r--r--drivers/hid/hid-core.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c
index 8ed66fd1ea87..f10e768b4caf 100644
--- a/drivers/hid/hid-core.c
+++ b/drivers/hid/hid-core.c
@@ -783,7 +783,9 @@ static int hid_scan_report(struct hid_device *hid)
783 * Vendor specific handlings 783 * Vendor specific handlings
784 */ 784 */
785 if ((hid->vendor == USB_VENDOR_ID_SYNAPTICS) && 785 if ((hid->vendor == USB_VENDOR_ID_SYNAPTICS) &&
786 (hid->group == HID_GROUP_GENERIC)) 786 (hid->group == HID_GROUP_GENERIC) &&
787 /* only bind to the mouse interface of composite USB devices */
788 (hid->bus != BUS_USB || hid->type == HID_TYPE_USBMOUSE))
787 /* hid-rmi should take care of them, not hid-generic */ 789 /* hid-rmi should take care of them, not hid-generic */
788 hid->group = HID_GROUP_RMI; 790 hid->group = HID_GROUP_RMI;
789 791