Commit 8253d42b authored by Jason Gerecke's avatar Jason Gerecke Committed by Jiri Kosina

HID: wacom: Fix ABS_MISC reporting for Cintiq Companion 2

The pad handling code introduced for the Cintiq Companion 2 (f7acb55c)
looks at the wrong bytes in the report when deciding whether ABS_MISC
should be sent. This does not cause any issues with the X driver now
that the pen and pad have been split to separate devices, but is
incorrect and has caused issues when backporting to distros with pre-
3.17 kernels.
Signed-off-by: default avatarJason Gerecke <jason.gerecke@wacom.com>
Reviewed-by: default avatarPing Cheng <pingc@wacom.com>
Signed-off-by: default avatarJiri Kosina <jkosina@suse.cz>
parent 6212aae0
...@@ -966,7 +966,7 @@ static int wacom_intuos_irq(struct wacom_wac *wacom) ...@@ -966,7 +966,7 @@ static int wacom_intuos_irq(struct wacom_wac *wacom)
input_report_key(input, BTN_A, (data[2] & 0x80)); /* Down */ input_report_key(input, BTN_A, (data[2] & 0x80)); /* Down */
input_report_key(input, BTN_0, (data[1] & 0x01)); /* Center */ input_report_key(input, BTN_0, (data[1] & 0x01)); /* Center */
if (data[4] | (data[3] & 0x01)) { if (data[2] | (data[1] & 0x07)) {
input_report_abs(input, ABS_MISC, PAD_DEVICE_ID); input_report_abs(input, ABS_MISC, PAD_DEVICE_ID);
} else { } else {
input_report_abs(input, ABS_MISC, 0); input_report_abs(input, ABS_MISC, 0);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment