From 28f261cd7da53124a5aeb71e1f473cd473a33489 Mon Sep 17 00:00:00 2001 From: Jussi Kukkonen Date: Wed, 19 Aug 2015 17:06:48 +0300 Subject: libinput: Upgrade 0.18.0 -> 0.21.0 Include a workaround patch suggested by upstream when using kernel 4.1.x. Signed-off-by: Jussi Kukkonen Signed-off-by: Ross Burton --- ...ics-need-to-fake-new-touches-on-TRIPLETAP.patch | 72 ++++++++++++++++++++++ meta/recipes-graphics/wayland/libinput_0.18.0.bb | 22 ------- meta/recipes-graphics/wayland/libinput_0.21.0.bb | 23 +++++++ 3 files changed, 95 insertions(+), 22 deletions(-) create mode 100644 meta/recipes-graphics/wayland/libinput/touchpad-serial-synaptics-need-to-fake-new-touches-on-TRIPLETAP.patch delete mode 100644 meta/recipes-graphics/wayland/libinput_0.18.0.bb create mode 100644 meta/recipes-graphics/wayland/libinput_0.21.0.bb diff --git a/meta/recipes-graphics/wayland/libinput/touchpad-serial-synaptics-need-to-fake-new-touches-on-TRIPLETAP.patch b/meta/recipes-graphics/wayland/libinput/touchpad-serial-synaptics-need-to-fake-new-touches-on-TRIPLETAP.patch new file mode 100644 index 0000000000..97c63bd377 --- /dev/null +++ b/meta/recipes-graphics/wayland/libinput/touchpad-serial-synaptics-need-to-fake-new-touches-on-TRIPLETAP.patch @@ -0,0 +1,72 @@ +This is a workaround upstream suggests for use with kernel 4.1. + +Upstream-Status: Inappropriate [temporary work-around] +Signed-Off-By: Jussi Kukkonen + + + +From: Peter Hutterer +Date: Mon Aug 3 18:23:12 PDT 2015 +Subject: [PATCH v3 libinput] touchpad: serial synaptics need to fake new touches on TRIPLETAP + +On the 4.1 kernels synaptics pretends to have 3 slots (the serial fw only does +2). This was added to avoid cursor jumps but has since been reverted for 4.2 +(kernel commit dbf3c37086, 4.1.3 is still buggy). In some cases a TRIPLETAP +may be triggered without slot 2 ever activating. + +While there are still those kernels out there, work around this bug by opening +a new touch point where none exists if the fake finger count exceeds the slot +count. + +Reported-by: Jan Alexander Steffens +Signed-off-by: Peter Hutterer +Tested-by: Jan Alexander Steffens +Reviewed-by: Hans de Goede +--- +Changes to v2: +- split out the handling instead of having a tmp state variable, see Hans' + comments from v2 + +Mainly sending this to the list again so I have a link to point people to. +If you're on 4.1.x add this patch to your distribution package. + + src/evdev-mt-touchpad.c | 22 ++++++++++++++++------ + 1 file changed, 16 insertions(+), 6 deletions(-) + +diff --git a/src/evdev-mt-touchpad.c b/src/evdev-mt-touchpad.c +index a683d9a..5ef03d5 100644 +--- a/src/evdev-mt-touchpad.c ++++ b/src/evdev-mt-touchpad.c +@@ -369,13 +369,23 @@ tp_restore_synaptics_touches(struct tp_dispatch *tp, + for (i = 0; i < tp->num_slots; i++) { + struct tp_touch *t = tp_get_touch(tp, i); + +- if (t->state != TOUCH_END) ++ switch(t->state) { ++ case TOUCH_HOVERING: ++ case TOUCH_BEGIN: ++ case TOUCH_UPDATE: + continue; +- +- /* new touch, move it through begin to update immediately */ +- tp_new_touch(tp, t, time); +- tp_begin_touch(tp, t, time); +- t->state = TOUCH_UPDATE; ++ case TOUCH_NONE: ++ /* new touch, move it through to begin immediately */ ++ tp_new_touch(tp, t, time); ++ tp_begin_touch(tp, t, time); ++ break; ++ case TOUCH_END: ++ /* touch just ended ,we need need to restore it to update */ ++ tp_new_touch(tp, t, time); ++ tp_begin_touch(tp, t, time); ++ t->state = TOUCH_UPDATE; ++ break; ++ } + } + } + +-- +2.4.3 + diff --git a/meta/recipes-graphics/wayland/libinput_0.18.0.bb b/meta/recipes-graphics/wayland/libinput_0.18.0.bb deleted file mode 100644 index 8e8e6a7c41..0000000000 --- a/meta/recipes-graphics/wayland/libinput_0.18.0.bb +++ /dev/null @@ -1,22 +0,0 @@ -SUMMARY = "Library to handle input devices in Wayland compositors" -HOMEPAGE = "http://www.freedesktop.org/wiki/Software/libinput/" -SECTION = "libs" - -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://COPYING;md5=2184aef38ff137ed33ce9a63b9d1eb8f" - -DEPENDS = "libevdev udev mtdev" - -SRC_URI = "http://www.freedesktop.org/software/${BPN}/${BP}.tar.xz \ - file://libinput-configure.ac-add-arg-with-libunwind.patch \ -" -SRC_URI[md5sum] = "0ddbb0d53d58dec0a86de6791560011a" -SRC_URI[sha256sum] = "64a70f96bab17a22eaf2fd7af17cf83def3388374096c7623be9448f62808cda" - -inherit autotools pkgconfig - -PACKAGECONFIG ??= "" -PACKAGECONFIG[libunwind] = "--with-libunwind,--without-libunwind,libunwind" - -FILES_${PN} += "${libdir}/udev/" -FILES_${PN}-dbg += "${libdir}/udev/.debug" diff --git a/meta/recipes-graphics/wayland/libinput_0.21.0.bb b/meta/recipes-graphics/wayland/libinput_0.21.0.bb new file mode 100644 index 0000000000..d51fb372d7 --- /dev/null +++ b/meta/recipes-graphics/wayland/libinput_0.21.0.bb @@ -0,0 +1,23 @@ +SUMMARY = "Library to handle input devices in Wayland compositors" +HOMEPAGE = "http://www.freedesktop.org/wiki/Software/libinput/" +SECTION = "libs" + +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://COPYING;md5=2184aef38ff137ed33ce9a63b9d1eb8f" + +DEPENDS = "libevdev udev mtdev" + +SRC_URI = "http://www.freedesktop.org/software/${BPN}/${BP}.tar.xz \ + file://libinput-configure.ac-add-arg-with-libunwind.patch \ + file://touchpad-serial-synaptics-need-to-fake-new-touches-on-TRIPLETAP.patch \ +" +SRC_URI[md5sum] = "f91d8f4ced986f1ae16d52ea02bc7837" +SRC_URI[sha256sum] = "7cce7a9e510dfe5c4a19ad00e9350808d4f59f8611fd2b5e87213c507283f550" + +inherit autotools pkgconfig + +PACKAGECONFIG ??= "" +PACKAGECONFIG[libunwind] = "--with-libunwind,--without-libunwind,libunwind" + +FILES_${PN} += "${libdir}/udev/" +FILES_${PN}-dbg += "${libdir}/udev/.debug" -- cgit v1.2.3