X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=include%2Fasm-x86%2Fsmp_64.h;h=ab612b0ff270a173a4300d1d6ed6bf2bdd9b3d65;hb=92f98b19bcce8b56ec6fc067702e211c36f19e88;hp=3f303d2365ed68d9b207b43976bd1c3aa2282e51;hpb=1ef3e36251e4edc77a48967d015a87ca3c4283ea;p=powerpc.git diff --git a/include/asm-x86/smp_64.h b/include/asm-x86/smp_64.h index 3f303d2365..ab612b0ff2 100644 --- a/include/asm-x86/smp_64.h +++ b/include/asm-x86/smp_64.h @@ -37,10 +37,19 @@ extern void lock_ipi_call_lock(void); extern void unlock_ipi_call_lock(void); extern int smp_num_siblings; extern void smp_send_reschedule(int cpu); +extern int smp_call_function_mask(cpumask_t mask, void (*func)(void *), + void *info, int wait); -extern cpumask_t cpu_sibling_map[NR_CPUS]; -extern cpumask_t cpu_core_map[NR_CPUS]; -extern u8 cpu_llc_id[NR_CPUS]; +/* + * cpu_sibling_map and cpu_core_map now live + * in the per cpu area + * + * extern cpumask_t cpu_sibling_map[NR_CPUS]; + * extern cpumask_t cpu_core_map[NR_CPUS]; + */ +DECLARE_PER_CPU(cpumask_t, cpu_sibling_map); +DECLARE_PER_CPU(cpumask_t, cpu_core_map); +DECLARE_PER_CPU(u8, cpu_llc_id); #define SMP_TRAMPOLINE_BASE 0x6000 @@ -67,6 +76,8 @@ extern unsigned __cpuinitdata disabled_cpus; #endif /* CONFIG_SMP */ +#define safe_smp_processor_id() smp_processor_id() + static inline int hard_smp_processor_id(void) { /* we don't want to mark this access volatile - bad code generation */ @@ -77,8 +88,9 @@ static inline int hard_smp_processor_id(void) * Some lowlevel functions might want to know about * the real APIC ID <-> CPU # mapping. */ -extern u8 x86_cpu_to_apicid[NR_CPUS]; /* physical ID */ -extern u8 x86_cpu_to_log_apicid[NR_CPUS]; +extern u8 __initdata x86_cpu_to_apicid_init[]; +extern void *x86_cpu_to_apicid_ptr; +DECLARE_PER_CPU(u8, x86_cpu_to_apicid); /* physical ID */ extern u8 bios_cpu_apicid[]; static inline int cpu_present_to_apicid(int mps_cpu) @@ -109,8 +121,9 @@ static __inline int logical_smp_processor_id(void) } #ifdef CONFIG_SMP -#define cpu_physical_id(cpu) x86_cpu_to_apicid[cpu] +#define cpu_physical_id(cpu) per_cpu(x86_cpu_to_apicid, cpu) #else +extern unsigned int boot_cpu_id; #define cpu_physical_id(cpu) boot_cpu_id #endif /* !CONFIG_SMP */ #endif