From 1392c1f3ac4f148b8597436d622ae1d228aef4f5 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Thu, 3 May 2018 09:55:51 +1000 Subject: [PATCH] evdev: mask out MSC_TIMESTAMP, we don't need it Not really an issue at this point, but some HID devices like sending MSC_TIMESTAMP. Since we don't use them in libinput, all we do is drag ourselves out of sleep, look at the event, frown because it's not our morning coffee, and go back to sleep. Instead, disable the code altogether, libevdev will mask it transparently and then the kernel will let us sleep. Signed-off-by: Peter Hutterer --- src/evdev.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/evdev.c b/src/evdev.c index 98e937ee..4f69d8e0 100644 --- a/src/evdev.c +++ b/src/evdev.c @@ -1942,6 +1942,9 @@ evdev_pre_configure_model_quirks(struct evdev_device *device) libevdev_disable_event_code(device->evdev, EV_ABS, ABS_MT_TOOL_TYPE); + + /* We don't care about them and it can cause unnecessary wakeups */ + libevdev_disable_event_code(device->evdev, EV_MSC, MSC_TIMESTAMP); } static void