Mercurial > hg > CbC > CbC_xv6
comparison src/proc.h @ 149:654f2dadd744
add inode.h
author | menikon |
---|---|
date | Mon, 16 Dec 2019 15:45:51 +0900 |
parents | a4307abefd0b |
children | 650fac123133 |
comparison
equal
deleted
inserted
replaced
148:86cd551e5b38 | 149:654f2dadd744 |
---|---|
1 #include "typedefData.h" | 1 #include "typedefData.h" |
2 #ifndef PROC_INCLUDE_ | 2 #ifndef PROC_INCLUDE_ |
3 #define PROC_INCLUDE_ | 3 #define PROC_INCLUDE_ |
4 #include "context.h" | 4 #include "context.h" |
5 | |
5 | 6 |
6 // Per-CPU state, now we only support one CPU | 7 // Per-CPU state, now we only support one CPU |
7 struct cpu { | 8 struct cpu { |
8 uchar id; // index into cpus[] below | 9 uchar id; // index into cpus[] below |
9 struct context* scheduler; // swtch() here to enter scheduler | 10 struct context* scheduler; // swtch() here to enter scheduler |
17 struct proc* proc; // The currently-running process. | 18 struct proc* proc; // The currently-running process. |
18 }; | 19 }; |
19 | 20 |
20 extern struct cpu cpus[NCPU]; | 21 extern struct cpu cpus[NCPU]; |
21 extern int ncpu; | 22 extern int ncpu; |
22 | |
23 | 23 |
24 extern struct cpu* cpu; | 24 extern struct cpu* cpu; |
25 extern struct proc* proc; | 25 extern struct proc* proc; |
26 | 26 |
27 //PAGEBREAK: 17 | 27 //PAGEBREAK: 17 |