mirror of
https://github.com/cowmonk/cowos.git
synced 2025-10-27 14:33:27 +00:00
31 lines
562 B
C
31 lines
562 B
C
#include <gdt.h>
|
|
#include <klibc/string.h>
|
|
#include <stddef.h>
|
|
#include <bootloader.h>
|
|
#include <drivers/video/framebuffer.h>
|
|
|
|
static void
|
|
hcf(void)
|
|
{
|
|
for (;;) {
|
|
__asm__("hlt");
|
|
}
|
|
}
|
|
|
|
void
|
|
kernel_main(void)
|
|
{
|
|
/* Make sure the bootloader understands our base revision */
|
|
if (LIMINE_BASE_REVISION_SUPPORTED == 0) hcf();
|
|
|
|
/* Initialize framebuffer console */
|
|
fb_init();
|
|
|
|
/* Test print */
|
|
fb_puts("Hello World\n");
|
|
|
|
initGDT();
|
|
|
|
/* done so now hang */
|
|
hcf();
|
|
}
|