A simpler test whether to use kernel's default scheduling
- this is a small addition to the userspace scheduling. proc_kernel_scheduler() tests whether to use the default scheduling policy in kernel. It is true if the process' scheduler is NULL _or_ self. Currently none of the tests was complete.
This commit is contained in:
@@ -148,6 +148,10 @@ struct proc {
|
||||
#define proc_no_quantum(p) ((p)->p_rts_flags & RTS_NO_QUANTUM)
|
||||
#define proc_ptr_ok(p) ((p)->p_magic == PMAGIC)
|
||||
|
||||
/* test whether the process is scheduled by the kernel's default policy */
|
||||
#define proc_kernel_scheduler(p) ((p)->p_scheduler == NULL || \
|
||||
(p)->p_scheduler == (p))
|
||||
|
||||
/* Macro to return: on which process is a certain process blocked?
|
||||
* return endpoint number (can be ANY) or NONE. It's important to
|
||||
* check RTS_SENDING first, and then RTS_RECEIVING, as they could
|
||||
|
||||
Reference in New Issue
Block a user