diff options
author | kaashoek <kaashoek> | 2006-06-22 01:28:57 +0000 |
---|---|---|
committer | kaashoek <kaashoek> | 2006-06-22 01:28:57 +0000 |
commit | 21a88fd487177841c882d9017bd9f4476801c6f6 (patch) | |
tree | bfa061e00662efde2186d6c0498fc78f889356ce /main.c | |
parent | 7baa34a421e4c970ee90c2537ceacd7230f2474e (diff) | |
download | xv6-labs-21a88fd487177841c882d9017bd9f4476801c6f6.tar.gz xv6-labs-21a88fd487177841c882d9017bd9f4476801c6f6.tar.bz2 xv6-labs-21a88fd487177841c882d9017bd9f4476801c6f6.zip |
checkpoint. booting second processor. stack is messed up, but thanks to cliff
and plan 9 code, at least boots and gets into C code.
Diffstat (limited to 'main.c')
-rw-r--r-- | main.c | 11 |
1 files changed, 9 insertions, 2 deletions
@@ -8,6 +8,7 @@ #include "syscall.h" extern char edata[], end[]; +extern int acpu; char buf[512]; @@ -16,13 +17,19 @@ main() { struct proc *p; int i; - + + if (acpu) { + cprintf("an application processor\n"); + release_spinlock(&kernel_lock); + while (1) ; + } + acpu = 1; // clear BSS memset(edata, 0, end - edata); cprintf("\nxV6\n\n"); - mpinit(); // multiprocessor + mp_init(); // multiprocessor kinit(); // physical memory allocator tinit(); // traps and interrupts pic_init(); |