Skip to content

Commit 3631073

Browse files
committed
arm64: Tell irq work about self IPI support
ARM64 irq work self-IPI 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_interrupt() accordingly. Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Cc: Ingo Molnar <mingo@kernel.org> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
1 parent 09f6edd commit 3631073

4 files changed

Lines changed: 14 additions & 2 deletions

File tree

‎arch/arm64/include/asm/Kbuild‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ generic-y += ioctl.h
1919
generic-y += ioctls.h
2020
generic-y += ipcbuf.h
2121
generic-y += irq_regs.h
22-
generic-y += irq_work.h
2322
generic-y += kdebug.h
2423
generic-y += kmap_types.h
2524
generic-y += kvm_para.h

‎arch/arm64/include/asm/irq_work.h‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
#ifndef __ASM_IRQ_WORK_H
2+
#define __ASM_IRQ_WORK_H
3+
4+
#include <asm/smp.h>
5+
6+
static inline bool arch_irq_work_has_interrupt(void)
7+
{
8+
return !!__smp_cross_call;
9+
}
10+
11+
#endif /* __ASM_IRQ_WORK_H */

‎arch/arm64/include/asm/smp.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ extern void smp_init_cpus(void);
4848
*/
4949
extern void set_smp_cross_call(void (*)(const struct cpumask *, unsigned int));
5050

51+
extern void (*__smp_cross_call)(const struct cpumask *, unsigned int);
52+
5153
/*
5254
* Called from the secondary holding pen, this is the secondary CPU entry point.
5355
*/

‎arch/arm64/kernel/smp.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -470,7 +470,7 @@ void __init smp_prepare_cpus(unsigned int max_cpus)
470470
}
471471
}
472472

473-
static void (*__smp_cross_call)(const struct cpumask *, unsigned int);
473+
void (*__smp_cross_call)(const struct cpumask *, unsigned int);
474474

475475
void __init set_smp_cross_call(void (*fn)(const struct cpumask *, unsigned int))
476476
{

0 commit comments

Comments
 (0)