diff options
author | Yinghai Lu <Yinghai.Lu@Sun.COM> | 2007-07-16 10:37:28 +0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-07-16 20:05:34 +0400 |
commit | d37bf60de0b4ddc1633cf278189d3c9bf28fe3d2 (patch) | |
tree | 7d76e5fe7059e320746d165ee26f70ed8ebca80e /kernel/printk.c | |
parent | eaa944afb206f3fc4393630811ee621b866e3255 (diff) | |
download | linux-d37bf60de0b4ddc1633cf278189d3c9bf28fe3d2.tar.xz |
console: console handover to preferred console
for earlyprintk=ttyS0,9600 console=tty0 console=ttyS0,9600n8
the handover will happen from earlyser0 to tty0. but what we want is to
hand over to ttyS0.
Later with serial-convert-early_uart-to-earlycon-for-8250.patch,
console=tty0 console=uart8250,io,0x3f8,9600n8
will handover to ttyS0 instead of tty0.
Signed-off-by: Yinghai Lu <yinghai.lu@sun.com>
Cc: Andi Kleen <ak@suse.de>
Cc: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Gerd Hoffmann <kraxel@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel/printk.c')
-rw-r--r-- | kernel/printk.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/kernel/printk.c b/kernel/printk.c index 4961410ba367..7ce9a8c13312 100644 --- a/kernel/printk.c +++ b/kernel/printk.c @@ -985,12 +985,15 @@ void register_console(struct console *console) if (!(console->flags & CON_ENABLED)) return; - if (bootconsole) { + if (bootconsole && (console->flags & CON_CONSDEV)) { printk(KERN_INFO "console handover: boot [%s%d] -> real [%s%d]\n", bootconsole->name, bootconsole->index, console->name, console->index); unregister_console(bootconsole); console->flags &= ~CON_PRINTBUFFER; + } else { + printk(KERN_INFO "console [%s%d] enabled\n", + console->name, console->index); } /* |