[PATCH 2/4] input - wacom: don't retrieve touch_max when it is predefined

DORMANTno replies REVIEWED: 1 (0M)

From: Ping Cheng <hidden>
Date: 2012-06-25 21:32:13
Subsystem: input (keyboard, mouse, joystick, touchscreen) drivers, the rest · Maintainers: Dmitry Torokhov, Linus Torvalds

1 review trailer.

Some models, such as 0xE6, report more fingers than we process.

Reported-by: Jonathan Nieder <redacted>
Tested-by: Nils Kanning <redacted>
Signed-off-by: Ping Cheng <redacted>
---
 drivers/input/tablet/wacom_sys.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/drivers/input/tablet/wacom_sys.c b/drivers/input/tablet/wacom_sys.c
index c2fb698..2714ce6 100644
--- a/drivers/input/tablet/wacom_sys.c
+++ b/drivers/input/tablet/wacom_sys.c
@@ -398,7 +398,9 @@ static int wacom_parse_hid(struct usb_interface *intf,
 				break;
 
 			case HID_USAGE_CONTACTMAX:
-				wacom_retrieve_report_data(intf, features);
+				/* leave touch_max as is if predefined */
+				if (!features->touch_max)
+					wacom_retrieve_report_data(intf, features);
 				i++;
 				break;
 			}
-- 
1.7.7.6
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help