diff options
-rw-r--r-- | arch/x86/kernel/early_printk.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/x86/kernel/early_printk.c b/arch/x86/kernel/early_printk.c index 2acfd3fdc0cc..41fd965c80c6 100644 --- a/arch/x86/kernel/early_printk.c +++ b/arch/x86/kernel/early_printk.c | |||
@@ -178,6 +178,11 @@ asmlinkage void early_printk(const char *fmt, ...) | |||
178 | 178 | ||
179 | static inline void early_console_register(struct console *con, int keep_early) | 179 | static inline void early_console_register(struct console *con, int keep_early) |
180 | { | 180 | { |
181 | if (early_console->index != -1) { | ||
182 | printk(KERN_CRIT "ERROR: earlyprintk= %s already used\n", | ||
183 | con->name); | ||
184 | return; | ||
185 | } | ||
181 | early_console = con; | 186 | early_console = con; |
182 | if (keep_early) | 187 | if (keep_early) |
183 | early_console->flags &= ~CON_BOOT; | 188 | early_console->flags &= ~CON_BOOT; |