summaryrefslogtreecommitdiff
path: root/src/kernel/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/kernel/main.c')
-rw-r--r--src/kernel/main.c23
1 files changed, 9 insertions, 14 deletions
diff --git a/src/kernel/main.c b/src/kernel/main.c
index 2f63d71..d99b595 100644
--- a/src/kernel/main.c
+++ b/src/kernel/main.c
@@ -124,30 +124,25 @@ void main() {
logch('\n');
}
- if (!try_elf_run(drives, "BIN/INIT.ELF"))
- panic("Failed to load init program.");
-
if (BOOT_INFO->support_flags & BIS_PAE)
- logsz("Processor supports PAE (but Portland OS does not yet).\n\n");
+ logsz("Processor supports PAE (but Portland OS does not yet).\n");
else
- logsz("Processor does not support PAE.\n\n");
+ logsz("Processor does not support PAE.\n");
- u32_dec(kernel_pages_left * 4, nbuf);
- logsz(nbuf);
- logsz("k / ");
+ logsz("Kernel dynamic area size: ");
u32_dec(max_kernel_pages * 4, nbuf);
logsz(nbuf);
- logsz("k kernel heap free.\n");
- u32_dec(user_pages_left * 4, nbuf);
- logsz(nbuf);
- logsz("k / ");
+ logsz("k\nUserspace area size: ");
u32_dec(max_user_pages * 4, nbuf);
logsz(nbuf);
- logsz("k user memory free.\n");
+ logsz("k\n\n");
+
+ if (!try_elf_run(drives, "BIN/INIT.ELF"))
+ panic("Failed to load init program.");
init_idt();
+ logsz("Switching to init task.\n");
set_log_mode(LOG_USER);
- logch('\n');
_start_user_mode();
} \ No newline at end of file