Compare commits

...

2 Commits

Author SHA1 Message Date
81dc694a23 schedrelease() don't schedule if current interrupt frame is NULL 2025-09-19 23:48:30 +02:00
5b6408b06b tb fix call to schedrelease() 2025-09-19 23:47:55 +02:00
2 changed files with 5 additions and 3 deletions

View File

@ -11,7 +11,9 @@ int32_t SYSCALL0(sys_schedrelease) {
Proc *proc = PROCS.current; Proc *proc = PROCS.current;
spinlock_release(&PROCS.spinlock); spinlock_release(&PROCS.spinlock);
if (INTR_CURRENT_FRAME != NULL) {
proc_sched((void *)INTR_CURRENT_FRAME); proc_sched((void *)INTR_CURRENT_FRAME);
}
return E_OK; return E_OK;
} }

View File

@ -124,8 +124,6 @@ void do_mode_interactive(void) {
uprintf(ANSIQ_SCR_CLR_ALL); uprintf(ANSIQ_SCR_CLR_ALL);
goto begin; goto begin;
break; break;
} else {
schedrelease();
} }
if (b == '\n') { if (b == '\n') {
@ -136,6 +134,8 @@ void do_mode_interactive(void) {
linebuf[cursor++] = b; linebuf[cursor++] = b;
uprintf("%c", b); uprintf("%c", b);
} }
} else {
schedrelease();
} }
} }