diff mbox series

[v2,1/2] Input: atkbd - Map FN-key for TongFang barebones

Message ID 20250311180643.1107430-1-wse@tuxedocomputers.com (mailing list archive)
State New
Headers show
Series [v2,1/2] Input: atkbd - Map FN-key for TongFang barebones | expand

Commit Message

Werner Sembach March 11, 2025, 6:06 p.m. UTC
TongFangs firmware sends scancode 0xe0 0x78 upon pressing the FN key.

This patch maps this scancode to avoid a dmesg warning printed every FN-keypress
and to enable userspace to use they key in other shortcuts than the firmware
builtin ones.

Signed-off-by: Werner Sembach <wse@tuxedocomputers.com>
---
 drivers/input/keyboard/atkbd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Werner Sembach March 11, 2025, 6:07 p.m. UTC | #1
Am 11.03.25 um 19:06 schrieb Werner Sembach:
> TongFangs firmware sends scancode 0xe0 0x78 upon pressing the FN key.
>
> This patch maps this scancode to avoid a dmesg warning printed every FN-keypress
> and to enable userspace to use they key in other shortcuts than the firmware
> builtin ones.
v2: fixed typo
>
> Signed-off-by: Werner Sembach <wse@tuxedocomputers.com>
> ---
>   drivers/input/keyboard/atkbd.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/input/keyboard/atkbd.c b/drivers/input/keyboard/atkbd.c
> index adf0f311996c9..3598a21d9d014 100644
> --- a/drivers/input/keyboard/atkbd.c
> +++ b/drivers/input/keyboard/atkbd.c
> @@ -98,7 +98,7 @@ static const unsigned short atkbd_set2_keycode[ATKBD_KEYMAP_SIZE] = {
>   	173,114,  0,113,  0,  0,  0,126,128,  0,  0,140,  0,  0,  0,127,
>   	159,  0,115,  0,164,  0,  0,116,158,  0,172,166,  0,  0,  0,142,
>   	157,  0,  0,  0,  0,  0,  0,  0,155,  0, 98,  0,  0,163,  0,  0,
> -	226,  0,  0,  0,  0,  0,  0,  0,  0,255, 96,  0,  0,  0,143,  0,
> +	226,  0,  0,464,  0,  0,  0,  0,  0,255, 96,  0,  0,  0,143,  0,
>   	  0,  0,  0,  0,  0,  0,  0,  0,  0,107,  0,105,102,  0,  0,112,
>   	110,111,108,112,106,103,  0,119,  0,118,109,  0, 99,104,119,  0,
>
diff mbox series

Patch

diff --git a/drivers/input/keyboard/atkbd.c b/drivers/input/keyboard/atkbd.c
index adf0f311996c9..3598a21d9d014 100644
--- a/drivers/input/keyboard/atkbd.c
+++ b/drivers/input/keyboard/atkbd.c
@@ -98,7 +98,7 @@  static const unsigned short atkbd_set2_keycode[ATKBD_KEYMAP_SIZE] = {
 	173,114,  0,113,  0,  0,  0,126,128,  0,  0,140,  0,  0,  0,127,
 	159,  0,115,  0,164,  0,  0,116,158,  0,172,166,  0,  0,  0,142,
 	157,  0,  0,  0,  0,  0,  0,  0,155,  0, 98,  0,  0,163,  0,  0,
-	226,  0,  0,  0,  0,  0,  0,  0,  0,255, 96,  0,  0,  0,143,  0,
+	226,  0,  0,464,  0,  0,  0,  0,  0,255, 96,  0,  0,  0,143,  0,
 	  0,  0,  0,  0,  0,  0,  0,  0,  0,107,  0,105,102,  0,  0,112,
 	110,111,108,112,106,103,  0,119,  0,118,109,  0, 99,104,119,  0,