UNIX xv6 (rev8, 9/1/15)
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
Functions | Variables
proc.c File Reference
#include "types.h"
#include "defs.h"
#include "param.h"
#include "memlayout.h"
#include "mmu.h"
#include "x86.h"
#include "proc.h"
#include "spinlock.h"

Go to the source code of this file.

Functions

void forkret (void)
 
void trapret (void)
 
void pinit (void)
 
void userinit (void)
 
int growproc (int n)
 
int fork (void)
 
void exit (void)
 
int wait (void)
 
void scheduler (void)
 
void sched (void)
 
void yield (void)
 
void sleep (void *chan, struct spinlock *lk)
 
void wakeup (void *chan)
 
int kill (int pid)
 
void procdump (void)
 

Variables

struct {
   struct spinlock   lock
 
   struct proc   proc [NPROC]
 
ptable
 
int nextpid = 1
 

Function Documentation

void exit ( void  )

Definition at line 173 of file proc.c.

int fork ( void  )

Definition at line 129 of file proc.c.

void forkret ( void  )

Definition at line 331 of file proc.c.

int growproc ( int  n)

Definition at line 108 of file proc.c.

int kill ( int  pid)

Definition at line 412 of file proc.c.

void pinit ( void  )

Definition at line 24 of file proc.c.

void procdump ( void  )

Definition at line 436 of file proc.c.

void sched ( void  )

Definition at line 301 of file proc.c.

void scheduler ( void  )

Definition at line 266 of file proc.c.

void sleep ( void *  chan,
struct spinlock lk 
)

Definition at line 352 of file proc.c.

void trapret ( void  )
void userinit ( void  )

Definition at line 79 of file proc.c.

int wait ( void  )

Definition at line 217 of file proc.c.

void wakeup ( void *  chan)

Definition at line 401 of file proc.c.

void yield ( void  )

Definition at line 320 of file proc.c.

Variable Documentation

struct spinlock lock

Definition at line 11 of file proc.c.

int nextpid = 1

Definition at line 17 of file proc.c.

struct proc proc[NPROC]

Definition at line 12 of file proc.c.

struct { ... } ptable