From ca93f5077b495431c1efd1ec1f7e8a08f8ae0e75 Mon Sep 17 00:00:00 2001 From: hippoz <10706925-hippoz@users.noreply.gitlab.com> Date: Thu, 24 Feb 2022 21:53:44 +0200 Subject: [PATCH] add rest of exceptions to exception.c --- cpu/exception.c | 78 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) diff --git a/cpu/exception.c b/cpu/exception.c index d101a15..3e94c5f 100644 --- a/cpu/exception.c +++ b/cpu/exception.c @@ -107,6 +107,71 @@ static void isr18(struct interrupt_descriptor_32 *frame) { generic_exception_handler(frame, 18); } +__attribute__((interrupt)) +static void isr19(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 19); +} + +__attribute__((interrupt)) +static void isr20(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 20); +} + +__attribute__((interrupt)) +static void isr21(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 21); +} + +__attribute__((interrupt)) +static void isr22(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 22); +} + +__attribute__((interrupt)) +static void isr23(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 23); +} + +__attribute__((interrupt)) +static void isr24(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 24); +} + +__attribute__((interrupt)) +static void isr25(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 25); +} + +__attribute__((interrupt)) +static void isr26(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 26); +} + +__attribute__((interrupt)) +static void isr27(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 27); +} + +__attribute__((interrupt)) +static void isr28(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 28); +} + +__attribute__((interrupt)) +static void isr29(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 29); +} + +__attribute__((interrupt)) +static void isr30(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 30); +} + +__attribute__((interrupt)) +static void isr31(struct interrupt_descriptor_32 *frame) { + generic_exception_handler(frame, 31); +} + void exception_handlers_init() { idt_register_handler(0, (size_t)isr0); @@ -128,4 +193,17 @@ void exception_handlers_init() { idt_register_handler(16, (size_t)isr16); idt_register_handler(17, (size_t)isr17); idt_register_handler(18, (size_t)isr18); + idt_register_handler(19, (size_t)isr19); + idt_register_handler(20, (size_t)isr20); + idt_register_handler(21, (size_t)isr21); + idt_register_handler(22, (size_t)isr22); + idt_register_handler(23, (size_t)isr23); + idt_register_handler(24, (size_t)isr24); + idt_register_handler(25, (size_t)isr25); + idt_register_handler(26, (size_t)isr26); + idt_register_handler(27, (size_t)isr27); + idt_register_handler(28, (size_t)isr28); + idt_register_handler(29, (size_t)isr29); + idt_register_handler(30, (size_t)isr30); + idt_register_handler(31, (size_t)isr31); }