Kernel: Map interrupt handlers for all processors

This doesn't mean that processors will actually handle the irqs
This commit is contained in:
Bananymous 2024-03-09 23:49:31 +02:00
parent 2420886c2c
commit 55d2a64f54
3 changed files with 4 additions and 8 deletions

View File

@ -356,7 +356,7 @@ done:
extern "C" void syscall_asm();
IDT* IDT::create(bool is_bsb)
IDT* IDT::create()
{
auto* idt = new IDT();
ASSERT(idt);
@ -367,12 +367,8 @@ done:
ISR_LIST_X
#undef X
// FIXME: distribute IRQs more evenly?
#define X(num) idt->register_interrupt_handler(IRQ_VECTOR_BASE + num, irq ## num);
if (is_bsb)
{
IRQ_LIST_X
}
IRQ_LIST_X
#undef X
idt->register_syscall_handler(0x80, syscall_asm);

View File

@ -34,7 +34,7 @@ namespace Kernel
BAN_NON_MOVABLE(IDT);
public:
static IDT* create(bool is_bsb);
static IDT* create();
[[noreturn]] static void force_triple_fault();

View File

@ -42,7 +42,7 @@ namespace Kernel
processor.m_gdt = GDT::create();
ASSERT(processor.m_gdt);
processor.m_idt = IDT::create(id == s_bsb_id);
processor.m_idt = IDT::create();
ASSERT(processor.m_idt);
return processor;