You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

37 lines
1.2 KiB

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Vladimir Serbinenko <phcoder@gmail.com>
Date: Sun, 26 Jan 2014 03:31:10 +0100
Subject: [PATCH] * grub-core/term/at_keyboard.c: Tolerate missing keyboard.
---
grub-core/term/at_keyboard.c | 3 +++
ChangeLog | 4 ++++
2 files changed, 7 insertions(+)
diff --git a/grub-core/term/at_keyboard.c b/grub-core/term/at_keyboard.c
index f5071ce69e8..b4257e84a04 100644
--- a/grub-core/term/at_keyboard.c
+++ b/grub-core/term/at_keyboard.c
@@ -396,6 +396,9 @@ fetch_key (int *is_break)
if (! KEYBOARD_ISREADY (grub_inb (KEYBOARD_REG_STATUS)))
return -1;
at_key = grub_inb (KEYBOARD_REG_DATA);
+ /* May happen if no keyboard is connected. Just ignore this. */
+ if (at_key == 0xff)
+ return -1;
if (at_key == 0xe0)
{
e0_received = 1;
diff --git a/ChangeLog b/ChangeLog
index bbec1e70bbd..d37d4a6fc16 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2014-01-26 Vladimir Serbinenko <phcoder@gmail.com>
+
+ * grub-core/term/at_keyboard.c: Tolerate missing keyboard.
+
2014-01-26 Mike Gilbert <floppym@gentoo.org>
grub-install: support for partitioned partx loop devices.