diff options
Diffstat (limited to 'arch/x86_64/kernel/early_printk.c')
-rw-r--r-- | arch/x86_64/kernel/early_printk.c | 20 |
1 files changed, 5 insertions, 15 deletions
diff --git a/arch/x86_64/kernel/early_printk.c b/arch/x86_64/kernel/early_printk.c index 92213d2b7c11..56eaa259782b 100644 --- a/arch/x86_64/kernel/early_printk.c +++ b/arch/x86_64/kernel/early_printk.c | |||
@@ -243,22 +243,12 @@ static int __init setup_early_printk(char *buf) | |||
243 | early_console = &simnow_console; | 243 | early_console = &simnow_console; |
244 | keep_early = 1; | 244 | keep_early = 1; |
245 | } | 245 | } |
246 | |||
247 | if (keep_early) | ||
248 | early_console->flags &= ~CON_BOOT; | ||
249 | else | ||
250 | early_console->flags |= CON_BOOT; | ||
246 | register_console(early_console); | 251 | register_console(early_console); |
247 | return 0; | 252 | return 0; |
248 | } | 253 | } |
249 | |||
250 | early_param("earlyprintk", setup_early_printk); | 254 | early_param("earlyprintk", setup_early_printk); |
251 | |||
252 | void __init disable_early_printk(void) | ||
253 | { | ||
254 | if (!early_console_initialized || !early_console) | ||
255 | return; | ||
256 | if (!keep_early) { | ||
257 | printk("disabling early console\n"); | ||
258 | unregister_console(early_console); | ||
259 | early_console_initialized = 0; | ||
260 | } else { | ||
261 | printk("keeping early console\n"); | ||
262 | } | ||
263 | } | ||
264 | |||