[U-Boot] [PATCH 11/69] input: i8042: Make sure the keyboard is enabled

Simon Glass sjg at chromium.org
Mon Mar 7 03:27:54 CET 2016


Add one more step into the init sequence. This fixes the keyboard on samus,
which otherwise does not work.

Signed-off-by: Simon Glass <sjg at chromium.org>
---

 drivers/input/i8042.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/input/i8042.c b/drivers/input/i8042.c
index 661d7fd..12f8934 100644
--- a/drivers/input/i8042.c
+++ b/drivers/input/i8042.c
@@ -128,6 +128,12 @@ static int kbd_reset(int quirk)
 	if (kbd_cmd_read(CMD_SELF_TEST) != KBC_TEST_OK)
 		goto err;
 
+	if (kbd_write(I8042_DATA_REG, 0xf4) ||
+	    kbd_read(I8042_DATA_REG) != KBD_ACK) {
+		debug("Keyboard enable failed ACK\n");
+		goto err;
+	}
+
 	/* keyboard reset */
 	if (kbd_write(I8042_DATA_REG, CMD_RESET_KBD) ||
 	    kbd_read(I8042_DATA_REG) != KBD_ACK ||
-- 
2.7.0.rc3.207.g0ac5344



More information about the U-Boot mailing list