summaryrefslogtreecommitdiff
path: root/arch/x86/include/asm/irq_work.h
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2017-08-28 08:47:35 +0200
committerIngo Molnar <mingo@kernel.org>2017-08-29 11:42:30 +0200
commita45525b5b47c10c0446eda21227792b39af233dc (patch)
tree96675f0341e2ac551ab6625def641fdb5c72e22b /arch/x86/include/asm/irq_work.h
parent0428e01a2f13a6b7dae8289fb10030dbea336dee (diff)
x86/irq_work: Make it depend on APIC
The irq work interrupt vector is only installed when CONFIG_X86_LOCAL_APIC is enabled, but the interrupt handler is compiled in unconditionally. Compile the cruft out when the APIC is disabled. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Link: http://lkml.kernel.org/r/20170828064957.691909010@linutronix.de Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch/x86/include/asm/irq_work.h')
-rw-r--r--arch/x86/include/asm/irq_work.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/x86/include/asm/irq_work.h b/arch/x86/include/asm/irq_work.h
index f70604125286..ddbb8ea0f5a9 100644
--- a/arch/x86/include/asm/irq_work.h
+++ b/arch/x86/include/asm/irq_work.h
@@ -3,9 +3,17 @@
#include <asm/cpufeature.h>
+#ifdef CONFIG_X86_LOCAL_APIC
static inline bool arch_irq_work_has_interrupt(void)
{
return boot_cpu_has(X86_FEATURE_APIC);
}
+extern void arch_irq_work_raise(void);
+#else
+static inline bool arch_irq_work_has_interrupt(void)
+{
+ return false;
+}
+#endif
#endif /* _ASM_IRQ_WORK_H */