From d87bbde169f84b8c723b0d5289f39df164251b52 Mon Sep 17 00:00:00 2001 From: Duncan Laurie Date: Wed, 28 Apr 2021 09:40:26 -0700 Subject: libpayload: i8042: Enable keyboard translation by default on exit Add a Kconfig option to set the keyboard translation state on exit and set the default to true. This restores the keyboard to the power-up defaults for firmware that does not always run libpayload keyboard init to have consistent state, and provides an option to disable translation for keyboards that might need it. Change-Id: I25dfe3f425a5bb57e97476564886672b707aa3bd Signed-off-by: Duncan Laurie Reviewed-on: https://review.coreboot.org/c/coreboot/+/52737 Tested-by: build bot (Jenkins) Reviewed-by: Furquan Shaikh Reviewed-by: Angel Pons Reviewed-by: Felix Singer Reviewed-by: Raul Rangel Reviewed-by: Nico Huber --- payloads/libpayload/drivers/i8042/keyboard.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'payloads/libpayload/drivers/i8042') diff --git a/payloads/libpayload/drivers/i8042/keyboard.c b/payloads/libpayload/drivers/i8042/keyboard.c index a695723a06..952f5f1456 100644 --- a/payloads/libpayload/drivers/i8042/keyboard.c +++ b/payloads/libpayload/drivers/i8042/keyboard.c @@ -658,7 +658,7 @@ void keyboard_disconnect(void) /* Nobody but us seems to still use scancode set #1. So try to hand over with more modern settings. */ set_scancode_set(2); - i8042_set_kbd_translation(false); + i8042_set_kbd_translation(CONFIG(LP_PC_KEYBOARD_TRANSLATION)); /* Send keyboard disconnect command */ i8042_cmd(I8042_CMD_DIS_KB); -- cgit v1.2.3