Suspend process waiting for keyboard input
All checks were successful
Build documentation / build-and-deploy (push) Successful in 1m35s

This commit is contained in:
2026-02-15 15:21:18 +01:00
parent 60f201ab55
commit 0f5bd48328
14 changed files with 87 additions and 45 deletions

View File

@@ -121,7 +121,6 @@ static void amd64_idt_init (void) {
IDT_ENTRY (44, 1); IDT_ENTRY (45, 1); IDT_ENTRY (46, 1); IDT_ENTRY (47, 1);
IDT_ENTRY (SCHED_PREEMPT_TIMER, 1);
IDT_ENTRY (TLB_SHOOTDOWN, 1);
IDT_ENTRY (CPU_REQUEST_SCHED, 1);
IDT_ENTRY (CPU_SPURIOUS, 1);
/* clang-format on */
@@ -187,7 +186,11 @@ void amd64_intr_handler (void* stack_ptr) {
struct irq* irq = irq_find (regs->trap);
if (irq != NULL) {
irq->func (irq->arg, stack_ptr);
struct cpu* reschedule_cpu = NULL;
bool reschedule = irq->func (&reschedule_cpu, irq->arg, stack_ptr);
if (reschedule)
cpu_request_sched (reschedule_cpu);
}
}
}