Patchwork small keyboard.c fix

login
register
about
Submitter Stefan Reinauer
Date 2010-03-24 20:27:29
Message ID <4BAA75B1.6090407@coresystems.de>
Download mbox | patch
Permalink /patch/1136/
State Accepted
Headers show

Comments

Stefan Reinauer - 2010-03-24 20:27:29
Some keyboards need a longer timeout. Also increase error level, because
a not-connected keyboard should normally not raise an error.
Some keyboards need a longer timeout.

Signed-off-by: Stefan Reinauer <stepan@coresystems.de>
Myles Watson - 2010-03-24 20:44:38
Acked-by: Myles Watson <mylesgw@gmail.com>

Thanks,
Myles

Patch

--- src/pc80/keyboard.c
+++ src/pc80/keyboard.c
@@ -60,8 +60,8 @@ 
 #define KBD_REPLY_ACK		0xFA    // Command ACK
 #define KBD_REPLY_RESEND	0xFE    // Command NACK, send command again
 
-/* Wait 200ms for keyboard controller answers */
-#define KBC_TIMEOUT_IN_MS 200
+/* Wait 400ms for keyboard controller answers */
+#define KBC_TIMEOUT_IN_MS 400
 
 static int kbc_input_buffer_empty(void)
 {
@@ -85,7 +85,7 @@ 
 	}
 
 	if (!timeout) {
-		printk_warning("Keyboard controller output buffer result timeout\n");
+		printk_info("Keyboard controller output buffer result timeout\n");
 	}
 	return !!timeout;
 }