schedule(): do not preempt while holding spinlocks or while in offloaded syscall

This commit is contained in:
Balazs Gerofi
2015-08-06 10:36:13 +09:00
parent b77755d0f7
commit 328e69a335
7 changed files with 39 additions and 0 deletions

View File

@ -192,6 +192,7 @@ long do_syscall(struct syscall_request *req, int cpu, int pid)
unsigned long irqstate;
struct process *proc = cpu_local_var(current);
++proc->in_syscall_offload;
dkprintf("SC(%d)[%3d] sending syscall\n",
ihk_mc_get_processor_id(),
req->number);
@ -252,6 +253,7 @@ long do_syscall(struct syscall_request *req, int cpu, int pid)
ihk_mc_spinlock_unlock(&syscall_lock, irqstate);
}
--proc->in_syscall_offload;
return rc;
}