mirror of
https://github.com/tbsdtv/linux_media.git
synced 2025-07-23 12:43:29 +02:00
Merge branch 'for-5.11-null-console' into for-linus
This commit is contained in:
10
init/main.c
10
init/main.c
@@ -1480,8 +1480,14 @@ void __init console_on_rootfs(void)
|
||||
struct file *file = filp_open("/dev/console", O_RDWR, 0);
|
||||
|
||||
if (IS_ERR(file)) {
|
||||
pr_err("Warning: unable to open an initial console.\n");
|
||||
return;
|
||||
pr_err("Warning: unable to open an initial console. Fallback to ttynull.\n");
|
||||
register_ttynull_console();
|
||||
|
||||
file = filp_open("/dev/console", O_RDWR, 0);
|
||||
if (IS_ERR(file)) {
|
||||
pr_err("Warning: Failed to add ttynull console. No stdin, stdout, and stderr for the init process!\n");
|
||||
return;
|
||||
}
|
||||
}
|
||||
init_dup(file);
|
||||
init_dup(file);
|
||||
|
Reference in New Issue
Block a user