summaryrefslogtreecommitdiffstats
path: root/drivers/hid/wacom_wac.c
diff options
context:
space:
mode:
authorJason Gerecke <jason.gerecke@wacom.com>2019-05-07 20:53:20 +0200
committerBenjamin Tissoires <benjamin.tissoires@redhat.com>2019-05-17 18:21:41 +0200
commitfe7f8d73d1af19b678171170e4e5384deb57833d (patch)
tree2db211752d75061da65934fc9a73e5a550d14a6c /drivers/hid/wacom_wac.c
parentHID: wacom: Don't report anything prior to the tool entering range (diff)
downloadlinux-fe7f8d73d1af19b678171170e4e5384deb57833d.tar.xz
linux-fe7f8d73d1af19b678171170e4e5384deb57833d.zip
HID: wacom: Send BTN_TOUCH in response to INTUOSP2_BT eraser contact
The Bluetooth reports from the 2nd-gen Intuos Pro have separate bits for indicating if the tip or eraser is in contact with the tablet. At the moment, only the tip contact bit controls the state of the BTN_TOUCH event. This prevents the eraser from working as expected. This commit changes the driver to send BTN_TOUCH whenever either the tip or eraser contact bit is set. Fixes: 4922cd26f03c ("HID: wacom: Support 2nd-gen Intuos Pro's Bluetooth classic interface") Cc: <stable@vger.kernel.org> # 4.11+ Signed-off-by: Jason Gerecke <jason.gerecke@wacom.com> Reviewed-by: Aaron Skomra <aaron.skomra@wacom.com> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Diffstat (limited to 'drivers/hid/wacom_wac.c')
-rw-r--r--drivers/hid/wacom_wac.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hid/wacom_wac.c b/drivers/hid/wacom_wac.c
index 613342bb9d6b..af62a630fee9 100644
--- a/drivers/hid/wacom_wac.c
+++ b/drivers/hid/wacom_wac.c
@@ -1301,7 +1301,7 @@ static void wacom_intuos_pro2_bt_pen(struct wacom_wac *wacom)
range ? frame[7] : wacom->features.distance_max);
}
- input_report_key(pen_input, BTN_TOUCH, frame[0] & 0x01);
+ input_report_key(pen_input, BTN_TOUCH, frame[0] & 0x09);
input_report_key(pen_input, BTN_STYLUS, frame[0] & 0x02);
input_report_key(pen_input, BTN_STYLUS2, frame[0] & 0x04);