aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/hid.h
diff options
context:
space:
mode:
authorBenjamin Tissoires <benjamin.tissoires@redhat.com>2013-08-22 08:51:08 -0400
committerJiri Kosina <jkosina@suse.cz>2013-08-27 04:00:00 -0400
commitf961bd3516e4f699bbacff5d7f5247d6d87c59f0 (patch)
treeecc8cb61c11e00419a8fed6f277517c4f8aed711 /include/linux/hid.h
parent3dc8fc083dbfeede7b63a0c07581192e97711365 (diff)
HID: detect Win 8 multitouch devices in core
Detecting Win 8 multitouch devices in core allows us to set quirks before the device is parsed through hid_hw_start(). It also simplifies the detection of those devices in hid-multitouch and makes the handling of those devices cleaner. As Win 8 multitouch panels are in the group multitouch and rely on a special feature to be detected, this patch adds a bitfield in the parser. Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Reviewed-by: Henrik Rydberg <rydberg@euromail.se> Tested-by: Srinivas Pandruvada<srinivas.pandruvada@linux.intel.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'include/linux/hid.h')
-rw-r--r--include/linux/hid.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/hid.h b/include/linux/hid.h
index 0c48991b0402..cef1e9b86cc4 100644
--- a/include/linux/hid.h
+++ b/include/linux/hid.h
@@ -295,6 +295,7 @@ struct hid_item {
295#define HID_GROUP_GENERIC 0x0001 295#define HID_GROUP_GENERIC 0x0001
296#define HID_GROUP_MULTITOUCH 0x0002 296#define HID_GROUP_MULTITOUCH 0x0002
297#define HID_GROUP_SENSOR_HUB 0x0003 297#define HID_GROUP_SENSOR_HUB 0x0003
298#define HID_GROUP_MULTITOUCH_WIN_8 0x0004
298 299
299/* 300/*
300 * This is the global environment of the parser. This information is 301 * This is the global environment of the parser. This information is
@@ -532,6 +533,8 @@ static inline void hid_set_drvdata(struct hid_device *hdev, void *data)
532#define HID_GLOBAL_STACK_SIZE 4 533#define HID_GLOBAL_STACK_SIZE 4
533#define HID_COLLECTION_STACK_SIZE 4 534#define HID_COLLECTION_STACK_SIZE 4
534 535
536#define HID_SCAN_FLAG_MT_WIN_8 0x00000001
537
535struct hid_parser { 538struct hid_parser {
536 struct hid_global global; 539 struct hid_global global;
537 struct hid_global global_stack[HID_GLOBAL_STACK_SIZE]; 540 struct hid_global global_stack[HID_GLOBAL_STACK_SIZE];
@@ -540,6 +543,7 @@ struct hid_parser {
540 unsigned collection_stack[HID_COLLECTION_STACK_SIZE]; 543 unsigned collection_stack[HID_COLLECTION_STACK_SIZE];
541 unsigned collection_stack_ptr; 544 unsigned collection_stack_ptr;
542 struct hid_device *device; 545 struct hid_device *device;
546 unsigned scan_flags;
543}; 547};
544 548
545struct hid_class_descriptor { 549struct hid_class_descriptor {