do_syscall(): allow descheduling threads in offloaded syscalls if CPU core oversubscribed

This commit is contained in:
Balazs Gerofi
2016-08-16 08:58:22 +09:00
parent c897a56c34
commit 3aa06444f4
4 changed files with 65 additions and 24 deletions

View File

@@ -2576,13 +2576,8 @@ void schedule(void)
struct thread *last;
if (cpu_local_var(no_preempt)) {
dkprintf("no schedule() while no preemption! \n");
return;
}
if (cpu_local_var(current)
&& cpu_local_var(current)->in_syscall_offload) {
dkprintf("no schedule() while syscall offload!\n");
kprintf("%s: WARNING can't schedule() while no preemption, cnt: %d\n",
__FUNCTION__, cpu_local_var(no_preempt));
return;
}