36 |
#define ENTRY(x) .align TALIGN; .globl EXT(x); LEXT(x) |
#define ENTRY(x) .align TALIGN; .globl EXT(x); LEXT(x) |
37 |
|
|
38 |
#define CX(d, r) EXT(d)(, r, 4) |
#define CX(d, r) EXT(d)(, r, 4) |
39 |
|
|
40 |
|
#if NCPUS == 1 |
41 |
#define CPU_NUMBER(reg) movl $0, reg |
#define CPU_NUMBER(reg) movl $0, reg |
42 |
|
#else |
43 |
|
#define CPU_NUMBER(reg) movl apic_virtual_address, reg ;\ |
44 |
|
movl 0x20(reg), reg ;\ |
45 |
|
shr $24, reg ;\ |
46 |
|
movl apic_id_to_cpu_map(, reg, 4), reg |
47 |
|
#endif |
48 |
|
|
49 |
#endif /* i386-asm.h */ |
#endif /* i386-asm.h */ |