From caca6dc701ffca0f2230bfcbf4770577fa986503 Mon Sep 17 00:00:00 2001 From: Bananymous Date: Sun, 11 Jun 2023 01:36:21 +0300 Subject: [PATCH] Kernel: Exceptions will now enable interrupts before calling exit() this allows scheduler verification on reschedule() not panic --- kernel/arch/x86_64/IDT.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/kernel/arch/x86_64/IDT.cpp b/kernel/arch/x86_64/IDT.cpp index 124febd790..1d19857d72 100644 --- a/kernel/arch/x86_64/IDT.cpp +++ b/kernel/arch/x86_64/IDT.cpp @@ -122,6 +122,7 @@ namespace IDT { auto message = BAN::String::formatted("{}, aborting\n", isr_exceptions[isr]); (void)Kernel::Process::current().write(STDERR_FILENO, message.data(), message.size()); + asm volatile("sti"); Kernel::Process::current().exit(1); } else