platform/x86: ideapad-laptop: map Fn + R key to KEY_REFRESH_RATE_TOGGLE
authorGergo Koteles <soyer@irl.hu>
Sun, 10 Mar 2024 11:31:42 +0000 (12:31 +0100)
committerIlpo Järvinen <ilpo.jarvinen@linux.intel.com>
Tue, 12 Mar 2024 10:44:50 +0000 (12:44 +0200)
commitf492f5f3e4e54043baeb38bfb494b2f959a636b7
treea8cfa2116a2c2b9afea3bdbc253bf9473be5925a
parentcfeb98b95fff25c442f78a6f616c627bc48a26b7
platform/x86: ideapad-laptop: map Fn + R key to KEY_REFRESH_RATE_TOGGLE

Newer Lenovo Yogas and Legions with 60Hz/90Hz displays send a wmi event
when Fn + R is pressed. This is intended for use to switch between the
two refresh rates.

The Fn + R key was incorrectly assigned to KEY_DISPLAYTOGGLE because it
is used to toggle the display on and off.

Map Fn + R key to the KEY_REFRESH_RATE_TOGGLE event code.

Signed-off-by: Gergo Koteles <soyer@irl.hu>
Link: https://lore.kernel.org/r/8fd36f0f016dde700396d8afaba1979d5dbc30a1.1710065750.git.soyer@irl.hu
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
drivers/platform/x86/ideapad-laptop.c