]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
HID: lenovo: Map mic-mute button to KEY_F20 instead of KEY_MICMUTE
authorHans de Goede <hdegoede@redhat.com>
Sun, 4 Apr 2021 08:04:29 +0000 (10:04 +0200)
committerKelsey Skunberg <kelsey.skunberg@canonical.com>
Mon, 24 May 2021 23:46:35 +0000 (17:46 -0600)
commit7fb7ce7bf830079ff657faf7f37f15c0c6594fbe
tree60f934911d7f23f2461a38ade48ca00c357eb8d8
parentc87bd003bd02911147dc601c26cab9141ff18fcd
HID: lenovo: Map mic-mute button to KEY_F20 instead of KEY_MICMUTE

BugLink: https://bugs.launchpad.net/bugs/1929455
[ Upstream commit 617103246cfd19af837e4cb614ba9f877c4f7779 ]

Mapping the mic-mute button to KEY_MICMUTE is technically correct but
KEY_MICMUTE translates to a scancode of 256 (248 + 8) under X,
which does not fit in 8 bits, so it does not work.

Because of this userspace is expecting KEY_F20 instead,
theoretically KEY_MICMUTE should work under Wayland but even
there it does not work, because the desktop-environment is
listening only for KEY_F20 and not for KEY_MICMUTE.

Fixes: bc04b37ea0ec ("HID: lenovo: Add ThinkPad 10 Ultrabook Keyboard support")
Reviewed-by: Marek BehĂșn <kabel@kernel.org>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Kelsey Skunberg <kelsey.skunberg@canonical.com>
drivers/hid/hid-lenovo.c