The kernel keeps its information about processes in several structures defined in /usr/icnlude/linux/sched.h The most important one, the task structure is explained first. It contains all information the scheduler needs.
Type | Name | Description |
---|---|---|
volatile long | state | -1 unrunnable, 0 runnable, >0 stopped |
long | counter | internal value for scheduling |
long | priority | Priority of the task |
unsinged long | signal | pending signals (ORed) |
unsigned long | blocked | blocked signals |
unsigned long | flags | Flags as defined below. |
int | errno |