diff options
author | Benji Dial <benji6283@gmail.com> | 2020-09-13 17:12:29 -0400 |
---|---|---|
committer | Benji Dial <benji6283@gmail.com> | 2020-09-13 17:12:29 -0400 |
commit | 5481848e27fdd4fc859def9841a0283665531a46 (patch) | |
tree | 990a8df008214d85141a3bd10bd96898e64b0c37 /src/user/init | |
parent | 1e4a254674f668839e5de273916024c16814b045 (diff) | |
download | portland-os-5481848e27fdd4fc859def9841a0283665531a46.tar.gz |
fixed some paging bugs, added fault handlers and new programs
Diffstat (limited to 'src/user/init')
-rw-r--r-- | src/user/init/init.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/user/init/init.c b/src/user/init/init.c index 64c534e..390b731 100644 --- a/src/user/init/init.c +++ b/src/user/init/init.c @@ -3,25 +3,28 @@ #include <knob/task.h> void start(const char *cmd) { + tell_user_sz("[init] Starting "); tell_user_sz(cmd); tell_user_sz(": "); tell_user_sz( try_run_command(cmd) - ? "success\n" - : "failed\n" + ? "Succeded.\n" + : "Failed.\n" ); + tell_user_sz("[init] Yielding.\n"); + yield_task(); } -#define STARTUP_FILE_PATH "SYS/STARTUP.RC" +#define STARTUP_FILE_PATH "sys/startup.rc" void main() { struct file *f = open_file(STARTUP_FILE_PATH); if (!f) { - tell_user_sz("Could not open " STARTUP_FILE_PATH "\n"); + tell_user_sz("Could not open " STARTUP_FILE_PATH ".\n"); return; } - tell_user_sz("[init] Reading from " STARTUP_FILE_PATH ":\n"); + tell_user_sz("[init] Reading from " STARTUP_FILE_PATH ".\n"); char buf[1024]; char *bufp = buf; @@ -43,5 +46,5 @@ void main() { close_file(f); - tell_user_sz("[init] Done.\n"); + tell_user_sz("[init] Done starting programs.\n"); } |