From 5a7cae6594a7544cd51070f980ee09c0c786ffbc Mon Sep 17 00:00:00 2001 From: "E. Almqvist" Date: Tue, 1 Feb 2022 18:37:53 +0100 Subject: [PATCH 1/2] Minor header refactor --- kernel/kernel.c | 18 ------------------ kernel/kernel.h | 7 +++++++ 2 files changed, 7 insertions(+), 18 deletions(-) diff --git a/kernel/kernel.c b/kernel/kernel.c index 56843b8..0805398 100644 --- a/kernel/kernel.c +++ b/kernel/kernel.c @@ -1,9 +1,4 @@ #include "kernel.h" -#include "memory.h" -#include "paging.h" -#include "../drivers/vga.h" -#include "../lib/str.h" -#include "../lib/conv.h" void init() { vga_init(); // Initialize the screen first @@ -15,19 +10,6 @@ void init() { println("Allocating VGA memory...", DEFAULT_COLOR); pm_malloc_range(VGA_ADDRESS, VGA_ADDRESS_MAX, true); // force alloc the VGA range - /* - // TODO: MAKE THESE DYNAMIC - print("Kernel offset: ", DEFAULT_COLOR); - println("0x1000", DEFAULT_COLOR); - - println("-VGA Stats-", DEFAULT_COLOR); - print("Start: ", DEFAULT_COLOR); - println("0xb7000", DEFAULT_COLOR); - - print("End: ", DEFAULT_COLOR); - println("0xb8fa0", DEFAULT_COLOR); - */ - // ENABLE PAGING // TODO: make this work // enable_paging(); diff --git a/kernel/kernel.h b/kernel/kernel.h index 2e61e23..d06c4ff 100644 --- a/kernel/kernel.h +++ b/kernel/kernel.h @@ -1,3 +1,10 @@ + +#include "memory.h" +#include "paging.h" +#include "../drivers/vga.h" +#include "../lib/str.h" +#include "../lib/conv.h" + #define STATUS_TEXT_COLOR 0x0f void init(); From 32aa8e968e776f4d5e96185bef0c974f500f508b Mon Sep 17 00:00:00 2001 From: "E. Almqvist" Date: Tue, 1 Feb 2022 21:47:19 +0100 Subject: [PATCH 2/2] Minor stuff --- kernel/kernel_entry.asm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kernel/kernel_entry.asm b/kernel/kernel_entry.asm index 13b7cd7..3482850 100644 --- a/kernel/kernel_entry.asm +++ b/kernel/kernel_entry.asm @@ -1,5 +1,8 @@ [bits 32] [extern init] +multiboot2: + dw 0xE85250D6 + call init jmp $