aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-x86
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-x86')
-rw-r--r--include/asm-x86/genapic_64.h1
-rw-r--r--include/asm-x86/mach-default/mach_apic.h1
-rw-r--r--include/asm-x86/mach-default/mach_apicdef.h3
-rw-r--r--include/asm-x86/smp.h4
4 files changed, 5 insertions, 4 deletions
diff --git a/include/asm-x86/genapic_64.h b/include/asm-x86/genapic_64.h
index 647e4e5c2580..d567abc347a9 100644
--- a/include/asm-x86/genapic_64.h
+++ b/include/asm-x86/genapic_64.h
@@ -27,6 +27,7 @@ struct genapic {
27 /* */ 27 /* */
28 unsigned int (*cpu_mask_to_apicid)(cpumask_t cpumask); 28 unsigned int (*cpu_mask_to_apicid)(cpumask_t cpumask);
29 unsigned int (*phys_pkg_id)(int index_msb); 29 unsigned int (*phys_pkg_id)(int index_msb);
30 unsigned int (*read_apic_id)(void);
30}; 31};
31 32
32extern struct genapic *genapic; 33extern struct genapic *genapic;
diff --git a/include/asm-x86/mach-default/mach_apic.h b/include/asm-x86/mach-default/mach_apic.h
index 0b2cde5e1b74..d172c554ab9f 100644
--- a/include/asm-x86/mach-default/mach_apic.h
+++ b/include/asm-x86/mach-default/mach_apic.h
@@ -30,6 +30,7 @@ static inline cpumask_t target_cpus(void)
30#define cpu_mask_to_apicid (genapic->cpu_mask_to_apicid) 30#define cpu_mask_to_apicid (genapic->cpu_mask_to_apicid)
31#define phys_pkg_id (genapic->phys_pkg_id) 31#define phys_pkg_id (genapic->phys_pkg_id)
32#define vector_allocation_domain (genapic->vector_allocation_domain) 32#define vector_allocation_domain (genapic->vector_allocation_domain)
33#define read_apic_id (genapic->read_apic_id)
33extern void setup_apic_routing(void); 34extern void setup_apic_routing(void);
34#else 35#else
35#define INT_DELIVERY_MODE dest_LowestPrio 36#define INT_DELIVERY_MODE dest_LowestPrio
diff --git a/include/asm-x86/mach-default/mach_apicdef.h b/include/asm-x86/mach-default/mach_apicdef.h
index e4b29ba37de6..453b58a67e29 100644
--- a/include/asm-x86/mach-default/mach_apicdef.h
+++ b/include/asm-x86/mach-default/mach_apicdef.h
@@ -5,8 +5,9 @@
5 5
6#ifdef CONFIG_X86_64 6#ifdef CONFIG_X86_64
7#define APIC_ID_MASK (0xFFu<<24) 7#define APIC_ID_MASK (0xFFu<<24)
8#define GET_APIC_ID(x) (((x)>>24)&0xFFu) 8#define GET_APIC_ID(x) (x)
9#define SET_APIC_ID(x) (((x)<<24)) 9#define SET_APIC_ID(x) (((x)<<24))
10#define GET_XAPIC_ID(x) (((x) >> 24) & 0xFFu)
10#else 11#else
11#define APIC_ID_MASK (0xF<<24) 12#define APIC_ID_MASK (0xF<<24)
12static inline unsigned get_apic_id(unsigned long x) 13static inline unsigned get_apic_id(unsigned long x)
diff --git a/include/asm-x86/smp.h b/include/asm-x86/smp.h
index 2e221f1ce0b2..9848715fbd9e 100644
--- a/include/asm-x86/smp.h
+++ b/include/asm-x86/smp.h
@@ -169,12 +169,10 @@ static inline unsigned int read_apic_id(void)
169{ 169{
170 return *(u32 *)(APIC_BASE + APIC_ID); 170 return *(u32 *)(APIC_BASE + APIC_ID);
171} 171}
172#else
173extern unsigned int read_apic_id(void);
174#endif 172#endif
175 173
176 174
177# ifdef APIC_DEFINITION 175# if defined(APIC_DEFINITION) || defined(CONFIG_X86_64)
178extern int hard_smp_processor_id(void); 176extern int hard_smp_processor_id(void);
179# else 177# else
180# include <mach_apicdef.h> 178# include <mach_apicdef.h>