vm, kernel, top: report memory usage of vm, kernel
[minix.git] / servers / sched / schedproc.h
blob69f99e4c241b7a07c4bf49c8bc2d126b3add6a94
1 /* This table has one slot per process. It contains scheduling information
2 * for each process.
3 */
4 #include <limits.h>
6 #include <minix/bitmap.h>
8 /* EXTERN should be extern except in main.c, where we want to keep the struct */
9 #ifdef _MAIN
10 #undef EXTERN
11 #define EXTERN
12 #endif
14 #ifndef CONFIG_SMP
15 #define CONFIG_MAX_CPUS 1
16 #endif
18 /**
19 * We might later want to add more information to this table, such as the
20 * process owner, process group or cpumask.
23 EXTERN struct schedproc {
24 endpoint_t endpoint; /* process endpoint id */
25 endpoint_t parent; /* parent endpoint id */
26 unsigned flags; /* flag bits */
28 /* User space scheduling */
29 unsigned max_priority; /* this process' highest allowed priority */
30 unsigned priority; /* the process' current priority */
31 unsigned time_slice; /* this process's time slice */
32 unsigned cpu; /* what CPU is the process running on */
33 bitchunk_t cpu_mask[BITMAP_CHUNKS(CONFIG_MAX_CPUS)]; /* what CPUs is hte
34 process allowed
35 to run on */
36 } schedproc[NR_PROCS];
38 /* Flag values */
39 #define IN_USE 0x00001 /* set when 'schedproc' slot in use */