[RFC PATCH 7/9] arm64: Tell irq work about self IPI support

Frederic Weisbecker
2014-08-21T14:53:41Z

ARM64 irq work support depends on __smp_cross_call to point to some
relevant IRQ controller operations. This information should be available
after the call to init_IRQ().

Lets implement arch_irq_work_has_own_interrupt() accordingly.

Cc: Catalin Iacob <iacobcatalin@gmail.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Dave Jones <davej@redhat.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Larry Bassel <larry.bassel@linaro.org>
Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
---
arch/arm64/kernel/smp.c | 5 +++++
1 file changed, 5 insertions(+)

diff --git a/arch/arm64/kernel/smp.c b/arch/arm64/kernel/smp.c
index 4743397..b3e8b9e 100644
--- a/arch/arm64/kernel/smp.c
+++ b/arch/arm64/kernel/smp.c
@@ -534,6 +534,11 @@ void arch_irq_work_raise(void)
if (__smp_cross_call)
smp_cross_call(cpumask_of(smp_processor_id()), IPI_IRQ_WORK);
}
+
+int __init arch_irq_work_has_own_interrupt(void)
+{
+ return !!__smp_cross_call;
+}
#endif

static DEFINE_RAW_SPINLOCK(stop_lock);
--
1.8.3.1