]> www.infradead.org Git - users/dwmw2/linux.git/commit
platform/x86: lenovo-ymc: Ignore the 0x0 state
authorGergo Koteles <soyer@irl.hu>
Thu, 22 Aug 2024 15:38:57 +0000 (17:38 +0200)
committerHans de Goede <hdegoede@redhat.com>
Wed, 4 Sep 2024 18:17:31 +0000 (20:17 +0200)
commitd9dca215708d32e7f88ac0591fbb187cbf368adb
tree0482eb0a52bcb9e200de18a6a7f1c2492cdd3075
parent298c9babadb83844632144369cc6bb2a43221aea
platform/x86: lenovo-ymc: Ignore the 0x0 state

While booting, Lenovo 14ARB7 reports 'lenovo-ymc: Unknown key 0 pressed'
warning. This is caused by lenovo_ymc_probe() calling lenovo_ymc_notify()
at probe time to get the initial tablet-mode-switch state and the key-code
lenovo_ymc_notify() reads from the firmware is not initialized at probe
time yet on the Lenovo 14ARB7.

The hardware/firmware does an ACPI notify on the WMI device itself when
it initializes the tablet-mode-switch state later on.

Add 0x0 YMC state to the sparse keymap to silence the warning.

Signed-off-by: Gergo Koteles <soyer@irl.hu>
Link: https://lore.kernel.org/r/08ab73bb74c4ad448409f2ce707b1148874a05ce.1724340562.git.soyer@irl.hu
[hdegoede@redhat.com: Reword commit message]
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
drivers/platform/x86/lenovo-ymc.c