diff options
author | Russ Cox <rsc@x40.(none)> | 2009-09-02 10:07:59 -0700 |
---|---|---|
committer | Russ Cox <rsc@x40.(none)> | 2009-09-02 10:07:59 -0700 |
commit | 7e0cc8e36ea91d0299f375f3b3476ab58ab71dde (patch) | |
tree | 0b02d5f1c1708ffeeb26ae84a4545cbc9a4c4265 /main.c | |
parent | 374362c55c7e1268ce6c52b029458ef22144c114 (diff) | |
download | xv6-labs-7e0cc8e36ea91d0299f375f3b3476ab58ab71dde.tar.gz xv6-labs-7e0cc8e36ea91d0299f375f3b3476ab58ab71dde.tar.bz2 xv6-labs-7e0cc8e36ea91d0299f375f3b3476ab58ab71dde.zip |
another attempt at cpu-local variables.
this time do it ourselves instead of piggybacking on TLS.
add -fno-pic to Makefile; pic code breaks our fake TLS.
Diffstat (limited to 'main.c')
-rw-r--r-- | main.c | 4 |
1 files changed, 1 insertions, 3 deletions
@@ -5,9 +5,6 @@ #include "proc.h" #include "x86.h" -__thread struct cpu *cpu; -__thread struct proc *proc; - static void bootothers(void); static void mpmain(void) __attribute__((noreturn)); @@ -22,6 +19,7 @@ main(void) ioapicinit(); // another interrupt controller consoleinit(); // I/O devices & their interrupts uartinit(); // serial port +cprintf("cpus %p cpu %p\n", cpus, cpu); cprintf("\ncpu%d: starting xv6\n\n", cpu->id); kinit(); // physical memory allocator |