aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hid/wacom_wac.c
diff options
context:
space:
mode:
authorBenjamin Tissoires <benjamin.tissoires@redhat.com>2014-09-11 13:14:04 -0400
committerJiri Kosina <jkosina@suse.cz>2014-09-12 08:13:08 -0400
commit12969e3bdce5f63fbce2b6d616fdbc8eeb539f01 (patch)
tree60fee630cad6ce12e4ddda6ced5139c8d52a05dd /drivers/hid/wacom_wac.c
parent912ca216b548e0fe399f300b4511b0277fb874e4 (diff)
HID: wacom: make the WL connection friendly for the desktop
Currently, tablets connected to the WL receiver all share the same VID/PID. There is no way for the user space to know which one is which besides parsing the name. We can force the PID to be set to the actual hardware. This way, the input device will have the correct PID which can be match in libwacom. With only this trick, the pad input does not inherit the ID_INPUT_TABLET udev property from its parent. We can force udev to accept it by declaring a BTN_STYLUS which is never used. This way, tablets connected through WL can be used from the user point of view in the same way they are used while connected through wire. Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Reviewed-by: Ping Cheng <pingc@wacom.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid/wacom_wac.c')
-rw-r--r--drivers/hid/wacom_wac.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/hid/wacom_wac.c b/drivers/hid/wacom_wac.c
index c3cbbfb5811f..b8180e40534d 100644
--- a/drivers/hid/wacom_wac.c
+++ b/drivers/hid/wacom_wac.c
@@ -1990,6 +1990,9 @@ int wacom_setup_pad_input_capabilities(struct input_dev *input_dev,
1990 input_set_abs_params(input_dev, ABS_X, 0, 1, 0, 0); 1990 input_set_abs_params(input_dev, ABS_X, 0, 1, 0, 0);
1991 input_set_abs_params(input_dev, ABS_Y, 0, 1, 0, 0); 1991 input_set_abs_params(input_dev, ABS_Y, 0, 1, 0, 0);
1992 1992
1993 /* kept for making udev and libwacom accepting the pad */
1994 __set_bit(BTN_STYLUS, input_dev->keybit);
1995
1993 switch (features->type) { 1996 switch (features->type) {
1994 case GRAPHIRE_BT: 1997 case GRAPHIRE_BT:
1995 __set_bit(BTN_0, input_dev->keybit); 1998 __set_bit(BTN_0, input_dev->keybit);