diff options
author | kolya <kolya> | 2008-10-15 05:15:32 +0000 |
---|---|---|
committer | kolya <kolya> | 2008-10-15 05:15:32 +0000 |
commit | deca9fef83450fa9659b750497d46e7887064aa5 (patch) | |
tree | 3564fa380453e00c1fc813851ce30d258989c786 /proc.h | |
parent | c100d9ee2d7d02253b55349bf55796efb3be5699 (diff) | |
download | xv6-labs-deca9fef83450fa9659b750497d46e7887064aa5.tar.gz xv6-labs-deca9fef83450fa9659b750497d46e7887064aa5.tar.bz2 xv6-labs-deca9fef83450fa9659b750497d46e7887064aa5.zip |
indent
Diffstat (limited to 'proc.h')
-rw-r--r-- | proc.h | 38 |
1 files changed, 19 insertions, 19 deletions
@@ -24,19 +24,19 @@ enum proc_state { UNUSED, EMBRYO, SLEEPING, RUNNABLE, RUNNING, ZOMBIE }; // Per-process state struct proc { - char *mem; // Start of process memory (kernel address) - uint sz; // Size of process memory (bytes) - char *kstack; // Bottom of kernel stack for this process - enum proc_state state; // Process state - int pid; // Process ID - struct proc *parent; // Parent process - void *chan; // If non-zero, sleeping on chan - int killed; // If non-zero, have been killed + char *mem; // Start of process memory (kernel address) + uint sz; // Size of process memory (bytes) + char *kstack; // Bottom of kernel stack for this process + enum proc_state state; // Process state + int pid; // Process ID + struct proc *parent; // Parent process + void *chan; // If non-zero, sleeping on chan + int killed; // If non-zero, have been killed struct file *ofile[NOFILE]; // Open files - struct inode *cwd; // Current directory - struct context *context; // Switch here to run process - struct trapframe *tf; // Trap frame for current syscall - char name[16]; // Process name (debugging) + struct inode *cwd; // Current directory + struct context *context; // Switch here to run process + struct trapframe *tf; // Trap frame for current syscall + char name[16]; // Process name (debugging) }; // Process memory is laid out contiguously, low addresses first: @@ -47,14 +47,14 @@ struct proc { // Per-CPU state struct cpu { - uchar apicid; // Local APIC ID - struct proc *curproc; // Process currently running. - struct context *context; // Switch here to enter scheduler - struct taskstate ts; // Used by x86 to find stack for interrupt - struct segdesc gdt[NSEGS]; // x86 global descriptor table + uchar apicid; // Local APIC ID + struct proc *curproc; // Process currently running. + struct context *context; // Switch here to enter scheduler + struct taskstate ts; // Used by x86 to find stack for interrupt + struct segdesc gdt[NSEGS]; // x86 global descriptor table volatile uint booted; // Has the CPU started? - int ncli; // Depth of pushcli nesting. - int intena; // Were interrupts enabled before pushcli? + int ncli; // Depth of pushcli nesting. + int intena; // Were interrupts enabled before pushcli? }; extern struct cpu cpus[NCPU]; |