aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-x86/hw_irq.h
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2008-08-09 18:09:02 -0400
committerIngo Molnar <mingo@elte.hu>2008-08-11 04:37:34 -0400
commitd388e5fdc461344d04307a3fa83862b9ed429647 (patch)
tree61a9a4311b165038423a0f3412e93b8811796c6b /include/asm-x86/hw_irq.h
parent31343d8a5079cda57ffd539fcf4f00cea344fe98 (diff)
x86: Restore proper vector locking during cpu hotplug
Having cpu_online_map change during assign_irq_vector can result in some really nasty and weird things happening. The one that bit me last time was accessing non existent per cpu memory for non existent cpus. This locking was removed in a sloppy x86_64 and x86_32 merge patch. Guys can we please try and avoid subtly breaking x86 when we are merging files together? Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'include/asm-x86/hw_irq.h')
-rw-r--r--include/asm-x86/hw_irq.h12
1 files changed, 10 insertions, 2 deletions
diff --git a/include/asm-x86/hw_irq.h b/include/asm-x86/hw_irq.h
index 77ba51df5668..edd0b95f14d0 100644
--- a/include/asm-x86/hw_irq.h
+++ b/include/asm-x86/hw_irq.h
@@ -98,9 +98,17 @@ extern void (*const interrupt[NR_IRQS])(void);
98#else 98#else
99typedef int vector_irq_t[NR_VECTORS]; 99typedef int vector_irq_t[NR_VECTORS];
100DECLARE_PER_CPU(vector_irq_t, vector_irq); 100DECLARE_PER_CPU(vector_irq_t, vector_irq);
101extern spinlock_t vector_lock;
102#endif 101#endif
103extern void setup_vector_irq(int cpu); 102
103#if defined(CONFIG_X86_IO_APIC) && defined(CONFIG_X86_64)
104extern void lock_vector_lock(void);
105extern void unlock_vector_lock(void);
106extern void __setup_vector_irq(int cpu);
107#else
108static inline void lock_vector_lock(void) {}
109static inline void unlock_vector_lock(void) {}
110static inline void __setup_vector_irq(int cpu) {}
111#endif
104 112
105#endif /* !ASSEMBLY_ */ 113#endif /* !ASSEMBLY_ */
106 114