1
0
Fork 0

feat/kernel: idek

This commit is contained in:
Kevin Alavik 2025-05-17 12:47:15 +02:00
parent c10028d366
commit d9a5f8e3c0
Signed by: cmpsb
GPG key ID: 10D1CC0526FDC6D7
3 changed files with 31 additions and 17 deletions

View file

@ -72,7 +72,7 @@ void timer_init()
outb(0x43, 0x36);
outb(0x40, divisor & 0xFF);
outb(0x40, (divisor >> 8) & 0xFF);
idt_register_handler(0x32, tick);
idt_register_handler(32, tick);
}
void emk_entry(void)
@ -185,6 +185,16 @@ void emk_entry(void)
kfree(c);
log_early("Initialized kernel heap");
/* Setup SMP */
if (!mp_request.response)
{
kpanic(NULL, "Failed to get MP request");
}
mp_response = mp_request.response;
smp_init();
log_early("Initialized SMP");
/* Setup ACPI and APIC */
rsdp_response = rsdp_request.response;
if (!rsdp_response)
@ -204,15 +214,5 @@ void emk_entry(void)
/* Setup timer */
timer_init();
/* Setup SMP */
if (!mp_request.response)
{
kpanic(NULL, "Failed to get MP request");
}
mp_response = mp_request.response;
smp_init();
log_early("Initialized SMP");
hlt();
}