From 0677694455a056b1a45ddcc6ad5044a1b08f5902 Mon Sep 17 00:00:00 2001 From: Vladimir 'phcoder' Serbinenko Date: Sun, 22 Aug 2010 17:10:39 +0200 Subject: [PATCH] * term/at_keyboard.c (grub_at_keyboard_getkey_noblock): Don't discard a key after CapsLock or NumLock. It's just a qemu bug. --- ChangeLog | 5 +++++ term/at_keyboard.c | 6 ------ 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index 6b6a82a35..758b5cb5f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2010-08-22 Vladimir Serbinenko + + * term/at_keyboard.c (grub_at_keyboard_getkey_noblock): Don't discard + a key after CapsLock or NumLock. It's just a qemu bug. + 2010-08-21 Vladimir Serbinenko * include/grub/usb.h (grub_usb_device): Add 'data' field back. It's diff --git a/term/at_keyboard.c b/term/at_keyboard.c index c3e71ea2d..25f32a0a5 100644 --- a/term/at_keyboard.c +++ b/term/at_keyboard.c @@ -181,9 +181,6 @@ grub_at_keyboard_getkey_noblock (void) switch (code) { case CAPS_LOCK: - /* Caps lock sends scan code twice. Get the second one and discard it. */ - while (grub_keyboard_getkey () == -1); - at_keyboard_status ^= KEYBOARD_STATUS_CAPS_LOCK; led_status ^= KEYBOARD_LED_CAPS; keyboard_controller_led (led_status); @@ -194,9 +191,6 @@ grub_at_keyboard_getkey_noblock (void) key = -1; break; case NUM_LOCK: - /* Num lock sends scan code twice. Get the second one and discard it. */ - while (grub_keyboard_getkey () == -1); - at_keyboard_status ^= KEYBOARD_STATUS_NUM_LOCK; led_status ^= KEYBOARD_LED_NUM; keyboard_controller_led (led_status);