Skip to content

Commit a3088ab

Browse files
author
Jiri Kosina
committed
HID: wacom: fixup quirks setup for WACOM_DEVICETYPE_PAD
Given that INTUOSHT < BAMBOO_PT features->type >= INTUOSHT || features->type <= BAMBOO_PT condition is always true, and therefore device_type is under certain circumstances wrongly set with WACOM_DEVICETYPE_PAD bit set. Fix the condition so that it actually represents the range as intended. Reported-by: David Binderman <[email protected]> Signed-off-by: Jiri Kosina <[email protected]>
1 parent ff38e82 commit a3088ab

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/hid/wacom_wac.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2481,7 +2481,7 @@ void wacom_setup_device_quirks(struct wacom *wacom)
24812481
if (features->pktlen == WACOM_PKGLEN_BBTOUCH3) {
24822482
if (features->touch_max)
24832483
features->device_type |= WACOM_DEVICETYPE_TOUCH;
2484-
if (features->type >= INTUOSHT || features->type <= BAMBOO_PT)
2484+
if (features->type >= INTUOSHT && features->type <= BAMBOO_PT)
24852485
features->device_type |= WACOM_DEVICETYPE_PAD;
24862486

24872487
features->x_max = 4096;

0 commit comments

Comments
 (0)