Desktop/xinu_mips-1.0.2.tar/xinu_mips-1.0.2/system/initialize.c File Reference

#include <kernel.h>
#include <platform.h>
#include <proc.h>
#include <queue.h>
#include <semaphore.h>
#include <memory.h>
#include <clock.h>
#include <device.h>
#include <stdio.h>
#include <string.h>
#include <mips.h>
#include <gpio.h>

Include dependency graph for initialize.c:

Go to the source code of this file.

Functions

void _start (void)
void main (void)
void xdone (void)
local platforminit (void)
local sysinit (void)
int nulluser ()

Variables

void * end
struct pentry proctab [NPROC]
struct sentry semtab [NSEM]
queue readylist
struct memblock freelist
ushort numproc
ushort currpid
void * minheap
ulong cpuid
struct platform platform


Detailed Description

nulluser, sysinit

Id
initialize.c 242 2007-07-13 22:28:23Z brylow

Definition in file initialize.c.


Function Documentation

void _start ( void   ) 

The system begins intializing after the C environment has been established. After intialization, the null process remains always in a ready (PRREADY) or running (PRCURR) state.

void main ( void   ) 

Referenced by nulluser().

int nulluser ( void   ) 

Intializes the system and becomes the null process. This is where the system begins after the C environment has been established. Interrupts are initially DISABLED, and must eventually be enabled explicitly. This routine turns itself into the null process after initialization. Because the null process must always remain ready to run, it cannot execute code that might cause it to be suspended, wait for a semaphore, or put to sleep, or exit. In particular, it must not do I/O unless it uses kprintf for synchronous output.

Definition at line 64 of file initialize.c.

References _start(), CONSOLE, cpuid, create(), enable(), end, INITPRIO, INITSTK, kprintf(), KSEG0_BASE, main(), minheap, nonempty, NULL, numproc, open(), platforminit(), ready(), readylist, resched(), RESCHED_NO, SERIAL0, sysinit(), and xdone().

local platforminit ( void   ) 

local sysinit ( void   ) 

void xdone ( void   ) 

Print system completion message as last process exits.

Definition at line 18 of file xdone.c.

Referenced by nulluser().


Variable Documentation

Definition at line 50 of file initialize.c.

Referenced by nulluser(), and platforminit().

currently executing process

Definition at line 46 of file initialize.c.

Referenced by getpid(), receive(), resched(), sleep(), sysinit(), t4(), t5(), and wait().

void* end

head of free memory list

Definition at line 42 of file initialize.c.

Referenced by freemem(), getmem(), sysinit(), and xsh_memstat().

void* minheap

bottom of heap

Definition at line 49 of file initialize.c.

Referenced by freemem(), nulluser(), and sysinit().

currently active processes

Definition at line 45 of file initialize.c.

Referenced by create(), kill(), nulluser(), and sysinit().

Definition at line 52 of file initialize.c.

struct pentry proctab[NPROC]

Definition at line 41 of file initialize.c.

Referenced by nulluser(), ready(), resched(), and sysinit().

struct sentry semtab[NSEM]


Generated on Thu Oct 9 22:35:04 2008 for xinu by  doxygen 1.5.5