summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/asm-i386/pda.h2
-rw-r--r--include/asm-i386/smp.h3
2 files changed, 4 insertions, 1 deletions
diff --git a/include/asm-i386/pda.h b/include/asm-i386/pda.h
index 4c39ccb1305c..f90fde22566d 100644
--- a/include/asm-i386/pda.h
+++ b/include/asm-i386/pda.h
@@ -11,6 +11,8 @@
struct i386_pda
{
struct i386_pda *_pda; /* pointer to self */
+
+ int cpu_number;
};
extern struct i386_pda *_cpu_pda[];
diff --git a/include/asm-i386/smp.h b/include/asm-i386/smp.h
index bd59c1508e71..64fe624c02ca 100644
--- a/include/asm-i386/smp.h
+++ b/include/asm-i386/smp.h
@@ -8,6 +8,7 @@
#include <linux/kernel.h>
#include <linux/threads.h>
#include <linux/cpumask.h>
+#include <asm/pda.h>
#endif
#ifdef CONFIG_X86_LOCAL_APIC
@@ -56,7 +57,7 @@ extern void cpu_uninit(void);
* from the initial startup. We map APIC_BASE very early in page_setup(),
* so this is correct in the x86 case.
*/
-#define raw_smp_processor_id() (current_thread_info()->cpu)
+#define raw_smp_processor_id() (read_pda(cpu_number))
extern cpumask_t cpu_callout_map;
extern cpumask_t cpu_callin_map;