From 8ae84716d6cc664bfb497951a84a5f25affa4a11 Mon Sep 17 00:00:00 2001 From: Josh Holtrop Date: Mon, 19 Oct 2020 22:12:17 -0400 Subject: [PATCH] rename kernel_main() to hos_main() --- src/boot.S | 14 +------------- src/kernel_main.c | 2 +- 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/src/boot.S b/src/boot.S index 90b5149..b1c0205 100644 --- a/src/boot.S +++ b/src/boot.S @@ -68,20 +68,8 @@ _start: push $0 push $0 push %ebx - call kernel_main + call hos_main - /* - If the system has nothing more to do, put the computer into an - infinite loop. To do that: - 1) Disable interrupts with cli (clear interrupt enable in eflags). - They are already disabled by the bootloader, so this is not needed. - Mind that you might later enable interrupts and return from - kernel_main (which is sort of nonsensical to do). - 2) Wait for the next interrupt to arrive with hlt (halt instruction). - Since they are disabled, this will lock up the computer. - 3) Jump to the hlt instruction if it ever wakes up due to a - non-maskable interrupt occurring or due to system management mode. - */ cli 1: hlt jmp 1b diff --git a/src/kernel_main.c b/src/kernel_main.c index 1f33847..8249cfe 100644 --- a/src/kernel_main.c +++ b/src/kernel_main.c @@ -27,7 +27,7 @@ static void process_mbinfo(uint32_t * mbinfo) } while (mbinfo != (uint32_t *)0u); } -void kernel_main(uint32_t * mbinfo) +void hos_main(uint32_t * mbinfo) { process_mbinfo(mbinfo); }