diff options
author | Masami Hiramatsu <mhiramat@kernel.org> | 2017-05-18 02:19:31 +0900 |
---|---|---|
committer | Richard Weinberger <richard@nod.at> | 2017-07-05 23:18:25 +0200 |
commit | 0936d4f3d5a3d5daf453bc341f02ba4e68cfe40e (patch) | |
tree | 494fd5cbbfe856c4677abf14b717313da76c2819 /arch/um/os-Linux/main.c | |
parent | 721ccae88d04f7e9334fde4cbb3eecfaa70a31ac (diff) |
um: Use os_warn to print out pre-boot warning/error messages
Use os_warn() instead of printf/fprintf to print out
pre-boot warning/error messages to stderr.
Note that the help message and version message are
kept to print out to stdout, because user explicitly
specifies those options to get such information.
Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org>
Signed-off-by: Richard Weinberger <richard@nod.at>
Diffstat (limited to 'arch/um/os-Linux/main.c')
-rw-r--r-- | arch/um/os-Linux/main.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/um/os-Linux/main.c b/arch/um/os-Linux/main.c index f880dcd6ecc9..5f970ece5ac3 100644 --- a/arch/um/os-Linux/main.c +++ b/arch/um/os-Linux/main.c @@ -74,8 +74,8 @@ static void install_fatal_handler(int sig) action.sa_restorer = NULL; action.sa_handler = last_ditch_exit; if (sigaction(sig, &action, NULL) < 0) { - printf("failed to install handler for signal %d - errno = %d\n", - sig, errno); + os_warn("failed to install handler for signal %d " + "- errno = %d\n", sig, errno); exit(1); } } @@ -175,7 +175,7 @@ int __init main(int argc, char **argv, char **envp) /* disable SIGIO for the fds and set SIGIO to be ignored */ err = deactivate_all_fds(); if (err) - printf("deactivate_all_fds failed, errno = %d\n", -err); + os_warn("deactivate_all_fds failed, errno = %d\n", -err); /* * Let any pending signals fire now. This ensures |