X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=include%2Fasm-i386%2Ftopology.h;h=b94e5eeef917ea92d9f7339593e1bda8dcc3bafd;hb=27b07da7332f03a935cd13b6a6beb780bf19e7a4;hp=d7e19eb344b7ab4f83c6611ec3afb675edf86d13;hpb=12dbf3fc4d06d2c0c4c44dc0612df04248b3cfd3;p=powerpc.git diff --git a/include/asm-i386/topology.h b/include/asm-i386/topology.h index d7e19eb344..b94e5eeef9 100644 --- a/include/asm-i386/topology.h +++ b/include/asm-i386/topology.h @@ -27,6 +27,15 @@ #ifndef _ASM_I386_TOPOLOGY_H #define _ASM_I386_TOPOLOGY_H +#ifdef CONFIG_X86_HT +#define topology_physical_package_id(cpu) \ + (phys_proc_id[cpu] == BAD_APICID ? -1 : phys_proc_id[cpu]) +#define topology_core_id(cpu) \ + (cpu_core_id[cpu] == BAD_APICID ? 0 : cpu_core_id[cpu]) +#define topology_core_siblings(cpu) (cpu_core_map[cpu]) +#define topology_thread_siblings(cpu) (cpu_sibling_map[cpu]) +#endif + #ifdef CONFIG_NUMA #include @@ -103,4 +112,6 @@ extern unsigned long node_remap_size[]; #endif /* CONFIG_NUMA */ +extern cpumask_t cpu_coregroup_map(int cpu); + #endif /* _ASM_I386_TOPOLOGY_H */