summaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/early_printk.c
diff options
context:
space:
mode:
authorMatt Fleming <matt.fleming@intel.com>2013-10-04 09:36:56 +0100
committerMatt Fleming <matt.fleming@intel.com>2013-10-28 18:09:58 +0000
commit72548e836b0c4abbb652e791dee9c91203a9a4c6 (patch)
tree2eead15738f173ed08ecbedc88adbb0bf2937022 /arch/x86/kernel/early_printk.c
parentc158c3bf59951bbb44bd7ccca9e6665dfd1617c5 (diff)
downloadlinux-72548e836b0c4abbb652e791dee9c91203a9a4c6.tar.gz
linux-72548e836b0c4abbb652e791dee9c91203a9a4c6.tar.bz2
linux-72548e836b0c4abbb652e791dee9c91203a9a4c6.zip
x86/efi: Add EFI framebuffer earlyprintk support
It's incredibly difficult to diagnose early EFI boot issues without special hardware because earlyprintk=vga doesn't work on EFI systems. Add support for writing to the EFI framebuffer, via earlyprintk=efi, which will actually give users a chance of providing debug output. Cc: H. Peter Anvin <hpa@zytor.com> Acked-by: Ingo Molnar <mingo@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Peter Jones <pjones@redhat.com> Signed-off-by: Matt Fleming <matt.fleming@intel.com>
Diffstat (limited to 'arch/x86/kernel/early_printk.c')
-rw-r--r--arch/x86/kernel/early_printk.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/x86/kernel/early_printk.c b/arch/x86/kernel/early_printk.c
index d15f575a861b..6d3d20073615 100644
--- a/arch/x86/kernel/early_printk.c
+++ b/arch/x86/kernel/early_printk.c
@@ -17,6 +17,8 @@
#include <asm/mrst.h>
#include <asm/pgtable.h>
#include <linux/usb/ehci_def.h>
+#include <linux/efi.h>
+#include <asm/efi.h>
/* Simple VGA output */
#define VGABASE (__ISA_IO_base + 0xb8000)
@@ -234,6 +236,11 @@ static int __init setup_early_printk(char *buf)
early_console_register(&early_hsu_console, keep);
}
#endif
+#ifdef CONFIG_EARLY_PRINTK_EFI
+ if (!strncmp(buf, "efi", 3))
+ early_console_register(&early_efi_console, keep);
+#endif
+
buf++;
}
return 0;