touchpad: add quirk for the T450 and T460 generation hardware
authorPeter Hutterer <peter.hutterer@who-t.net>
Mon, 7 Mar 2016 06:05:25 +0000 (16:05 +1000)
committerPeter Hutterer <peter.hutterer@who-t.net>
Fri, 11 Mar 2016 00:02:26 +0000 (10:02 +1000)
commita608d9dc2c70c7915fc94466ed27c1684f65409e
tree72330e679e6f893e402523ebd158a40c9abd52f5
parent5d904b63191538b46d7fe8443990b55c42de0205
touchpad: add quirk for the T450 and T460 generation hardware

The touchpad's sensors are too far apart (or the firmware interferes), causing
in a jerky movement visible especially on slow motion. We get a bunch of
normal motion events, then only ABS_MT_PRESSURE updates without x/y updates.
After about one mm of movement x/y updates resume, with the first event
covering the distance between the last motion event. That event is usually
accelerated and thus causes a large jump. Subsequent events are sufficiently
fine-grained again.

This patch counts the number of non-motion events. Once we hit 10 in a row, we
mark the first motion update as non-dirty, effectively discarding the motion
and thus stopping the pointer jumps.

https://bugs.freedesktop.org/show_bug.cgi?id=94379

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Tested-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
src/evdev-mt-touchpad.c
src/evdev-mt-touchpad.h
src/evdev.c
src/evdev.h
udev/90-libinput-model-quirks.hwdb