From 26801b76fdca23f876d804124fae5c3b46ca8e76 Mon Sep 17 00:00:00 2001 From: "K. Lange" Date: Mon, 29 Oct 2018 20:56:51 +0900 Subject: [PATCH] init: don't actually open serial by default --- apps/init.c | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/apps/init.c b/apps/init.c index 0b01aeff..6f52c95f 100644 --- a/apps/init.c +++ b/apps/init.c @@ -44,18 +44,9 @@ /* Initialize fd 0, 1, 2 */ void set_console(void) { - /* default to /dev/ttyS0 (serial COM1) */ - int _stdin = syscall_open("/dev/ttyS0", 0, 0); - if (_stdin < 0) { - /* if /dev/ttyS0 failed to open, fall back to /dev/null */ - syscall_open("/dev/null", 0, 0); - syscall_open("/dev/null", 1, 0); - syscall_open("/dev/null", 1, 0); - } else { - /* otherwise also use /dev/ttyS0 for stdout, stderr */ - syscall_open("/dev/ttyS0", 1, 0); - syscall_open("/dev/ttyS0", 1, 0); - } + syscall_open("/dev/null", 0, 0); + syscall_open("/dev/null", 1, 0); + syscall_open("/dev/null", 1, 0); } /* Run a startup script and wait for it to finish */