diff options
author | Hans de Goede <hdegoede@redhat.com> | 2022-11-17 14:02:42 +0300 |
---|---|---|
committer | Hans de Goede <hdegoede@redhat.com> | 2022-11-21 13:12:23 +0300 |
commit | 5829f8a897e4f030cd2d32a930eea8954ab5dcd3 (patch) | |
tree | 637833e101f545eae523b305b3feec7ef41307b8 /tools/perf/scripts/python/exported-sql-viewer.py | |
parent | c69e7d843d2c34b80b8731a5dc57c34ea04a3edf (diff) | |
download | linux-5829f8a897e4f030cd2d32a930eea8954ab5dcd3.tar.xz |
platform/x86: ideapad-laptop: Send KEY_TOUCHPAD_TOGGLE on some models
On recent Ideapad models the EC does not control the touchpad at all,
so instead of sending KEY_TOUCHPAD_ON/ _OFF on touchpad toggle hotkey
events, ideapad-laptop should send KEY_TOUCHPAD_TOGGLE and let userspace
handle the toggling.
Check for this by checking if the value read from VPCCMD_R_TOUCHPAD
actually changes when receiving a touchpad-toggle hotkey event; and
if it does not change send KEY_TOUCHPAD_TOGGLE to userspace to let
userspace enable/disable the touchpad in software.
Note this also drops the priv->features.touchpad_ctrl_via_ec check from
ideapad_sync_touchpad_state() so that KEY_TOUCHPAD_TOGGLE will be send
on laptops where this is not set too. This can be safely dropped now
because the i8042_command(I8042_CMD_AUX_ENABLE/_DISABLE) call is now
guarded by its own feature flag.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
Tested-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
Tested-by: Maxim Mikityanskiy <maxtram95@gmail.com>
Link: https://lore.kernel.org/r/20221117110244.67811-5-hdegoede@redhat.com
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions