#include <kernel.h>
#include <proc.h>
#include <queue.h>
Go to the source code of this file.
Functions | |
short | insert (short pid, queue q, short key) |
Definition in file insert.c.
short insert | ( | short | pid, | |
queue | q, | |||
short | key | |||
) |
Insert a process into a queue in descending key order.
pid | process id to insert | |
q | queue in which process should be inserted | |
key | sorting key (priority, for example) |
Definition at line 20 of file insert.c.
References isbadpid, isbadqueue, qentry::key, qentry::next, memblock::next, OK, qentry::prev, queuehead, queuetab, queuetail, and SYSERR.
Referenced by ready(), resched(), and test_procQueue().