diff options
Diffstat (limited to 'kernel/entry.cpp')
-rw-r--r-- | kernel/entry.cpp | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/kernel/entry.cpp b/kernel/entry.cpp index f7ba71d..cce8066 100644 --- a/kernel/entry.cpp +++ b/kernel/entry.cpp @@ -184,15 +184,6 @@ extern "C" [[noreturn]] void entry() { } -static void print_mem() { - uint64_t used_vram_mib = (paging::get_used_vram_page_count() + 128) / 256; - uint64_t free_pram_mib = (paging::get_free_pram_page_count() + 128) / 256; - terminal::put_int_decimal(used_vram_mib); - terminal::put_string_sz(" MiB kernel memory mapped.\n"); - terminal::put_int_decimal(free_pram_mib); - terminal::put_string_sz(" MiB physical memory free.\n"); -} - [[noreturn]] static void print_and_halt(const char *msg) { terminal::put_string_sz(msg); while (1) @@ -230,25 +221,11 @@ extern "C" [[noreturn]] void start_user_mode( if (!init_file) print_and_halt("/bin/init.elf does not exist."); - terminal::put_string_sz("/bin/init.elf is "); - terminal::put_int_decimal(init_file->dir_entry.length); - terminal::put_string_sz(" bytes long.\n"); - application::app_instance *init; if (application::create_app(*init_file, init) != application::create_app_result::success) print_and_halt("failed to parse /bin/init.elf."); - terminal::put_string_sz("/bin/init.elf loaded:\n instruction pointer 0x"); - terminal::put_int_hex(init->saved_regs.rip, 8); - terminal::put_string_sz("\n stack pointer 0x"); - terminal::put_int_hex(init->saved_regs.rsp, 8); - terminal::put_string_sz("\n "); - terminal::put_int_decimal(init->count_mapped_vram_pages() * 2); - terminal::put_string_sz(" MiB userspace memory used\n"); - - print_mem(); - terminal::put_string_sz("switching to /bin/init.elf.\n"); application::running_app = init; start_user_mode(init->saved_regs.rip, init->saved_regs.rsp, init->p4_paddr); |