From fb4d8d98dc24f66f7f98e6506fad63e1c320cd82 Mon Sep 17 00:00:00 2001 From: Benjamin Tissoires Date: Fri, 22 Mar 2013 18:38:34 +0100 Subject: HID: multitouch: force BTN_STYLUS for pen devices The "tablet" udev rule relies on BTN_STYLUS to be set. Signed-off-by: Benjamin Tissoires Signed-off-by: Jiri Kosina --- drivers/hid/hid-multitouch.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'drivers/hid/hid-multitouch.c') diff --git a/drivers/hid/hid-multitouch.c b/drivers/hid/hid-multitouch.c index 55551746d235..aceaf6c08878 100644 --- a/drivers/hid/hid-multitouch.c +++ b/drivers/hid/hid-multitouch.c @@ -418,6 +418,9 @@ static void mt_pen_input_configured(struct hid_device *hdev, mt_free_input_name(hi); hi->input->name = name; } + + /* force BTN_STYLUS to allow tablet matching in udev */ + __set_bit(BTN_STYLUS, hi->input->keybit); } static int mt_touch_input_mapping(struct hid_device *hdev, struct hid_input *hi, -- cgit v1.2.2