From 730e065e0bba1394750b3172bb7e2f1c0fd42c73 Mon Sep 17 00:00:00 2001 From: Anton Kling Date: Tue, 24 Oct 2023 19:22:27 +0200 Subject: Kernel: Add basic PCI and very basic rtl8139 support --- cpu/idt.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'cpu/idt.c') diff --git a/cpu/idt.c b/cpu/idt.c index 832162c..60ab441 100644 --- a/cpu/idt.c +++ b/cpu/idt.c @@ -108,6 +108,7 @@ __attribute__((interrupt)) void general_protection_fault(registers_t *regs) { __attribute__((interrupt)) void double_fault(registers_t *regs) { (void)regs; klog("DOUBLE FAULT, THIS IS REALLY BAD", LOG_ERROR); + asm("cli"); asm("hlt"); for (;;) ; @@ -258,6 +259,7 @@ void idt_init(void) { // IRQ_set_mask(0xc); IRQ_set_mask(0xe); IRQ_clear_mask(2); + IRQ_set_mask(0xB); idtr.interrupt_table = (struct IDT_Descriptor **)&IDT_Entry; idtr.size = (sizeof(struct IDT_Descriptor) * IDT_MAX_ENTRY) - 1; -- cgit v1.2.3