From 8673b5bfa5e825adba98f44d075f0c351cbe19f1 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Thu, 18 Aug 2016 10:48:31 +1000 Subject: [PATCH libinput] Force the HP Stream 11 touchpad as a clickpad INPUT_PROP_BUTTONPAD is not set on this device and RMI4 which should fix this is a bit too far into the future at this point. Hack around it. Signed-off-by: Peter Hutterer --- src/evdev.c | 7 +++++++ src/evdev.h | 1 + udev/90-libinput-model-quirks.hwdb | 7 +++++++ 3 files changed, 15 insertions(+) diff --git a/src/evdev.c b/src/evdev.c index e906a50..9de5b67 100644 --- a/src/evdev.c +++ b/src/evdev.c @@ -1927,6 +1927,7 @@ evdev_read_model_flags(struct evdev_device *device) MODEL(APPLE_INTERNAL_KEYBOARD), MODEL(CYBORG_RAT), MODEL(CYAPA), + MODEL(HP_STREAM11_TOUCHPAD), MODEL(LENOVO_T450_TOUCHPAD), MODEL(DELL_TOUCHPAD), MODEL(TRACKBALL), @@ -2496,6 +2497,12 @@ evdev_pre_configure_model_quirks(struct evdev_device *device) */ if (device->model_flags & EVDEV_MODEL_APPLE_MAGICMOUSE) libevdev_disable_event_type(device->evdev, EV_ABS); + + /* Touchpad is a clickpad but INPUT_PROP_BUTTONPAD is not set, see + * fdo bug 97147. Remove when RMI4 is commonplace */ + if (device->model_flags & EVDEV_MODEL_HP_STREAM11_TOUCHPAD) + libevdev_enable_property(device->evdev, + INPUT_PROP_BUTTONPAD); } struct evdev_device * diff --git a/src/evdev.h b/src/evdev.h index 1a2f1ff..9e26583 100644 --- a/src/evdev.h +++ b/src/evdev.h @@ -114,6 +114,7 @@ enum evdev_device_model { EVDEV_MODEL_APPLE_INTERNAL_KEYBOARD = (1 << 13), EVDEV_MODEL_CYBORG_RAT = (1 << 14), EVDEV_MODEL_CYAPA = (1 << 15), + EVDEV_MODEL_HP_STREAM11_TOUCHPAD = (1 << 16), EVDEV_MODEL_LENOVO_T450_TOUCHPAD= (1 << 17), EVDEV_MODEL_DELL_TOUCHPAD = (1 << 18), EVDEV_MODEL_TRACKBALL = (1 << 19), diff --git a/udev/90-libinput-model-quirks.hwdb b/udev/90-libinput-model-quirks.hwdb index ebce8d2..0eca845 100644 --- a/udev/90-libinput-model-quirks.hwdb +++ b/udev/90-libinput-model-quirks.hwdb @@ -87,6 +87,13 @@ libinput:name:Cypress APA Trackpad ?cyapa?:dmi:* LIBINPUT_MODEL_CYAPA=1 ########################################## +# HP +########################################## +# HP Stream 11 +evdev:name:SYN1EDE:00 06CB:7442:dmi:*svnHewlett-Packard:pnHPStreamNotebookPC11* + LIBINPUT_MODEL_HP_STREAM11_TOUCHPAD=1 + +########################################## # LENOVO ########################################## -- 2.7.4