diff options
author | Vineet Gupta <vgupta@synopsys.com> | 2015-10-14 11:08:02 +0200 |
---|---|---|
committer | Vineet Gupta <vgupta@synopsys.com> | 2015-10-28 11:43:41 +0100 |
commit | 286130ebf196d9643800977d57bdb7cda266b49e (patch) | |
tree | 0048c504925232821d822b201a6f58b87f0b6e9f /arch/arc/kernel | |
parent | ARC: smp: Rename platform hook @init_smp -> @init_cpu_smp (diff) | |
download | linux-286130ebf196d9643800977d57bdb7cda266b49e.tar.xz linux-286130ebf196d9643800977d57bdb7cda266b49e.zip |
ARC: smp: Introduce smp hook @init_irq_cpu called for all cores
Note this is not part of platform owned static machine_desc,
but more of device owned plat_smp_ops (rather misnamed) which a IPI
provider or some such typically defines.
This will help us seperate out the IPI registration from platform
specific init_cpu_smp() into device specific init_irq_cpu()
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
Diffstat (limited to 'arch/arc/kernel')
-rw-r--r-- | arch/arc/kernel/irq.c | 6 | ||||
-rw-r--r-- | arch/arc/kernel/smp.c | 4 |
2 files changed, 9 insertions, 1 deletions
diff --git a/arch/arc/kernel/irq.c b/arch/arc/kernel/irq.c index 1dd8f2685afc..2ee226546c6a 100644 --- a/arch/arc/kernel/irq.c +++ b/arch/arc/kernel/irq.c @@ -10,6 +10,7 @@ #include <linux/interrupt.h> #include <linux/irqchip.h> #include <asm/mach_desc.h> +#include <asm/smp.h> /* * Late Interrupt system init called from start_kernel for Boot CPU only @@ -27,7 +28,10 @@ void __init init_IRQ(void) irqchip_init(); #ifdef CONFIG_SMP - /* Master CPU can initialize it's side of IPI */ + /* a SMP H/w block could do IPI IRQ request here */ + if (plat_smp_ops.init_irq_cpu) + plat_smp_ops.init_irq_cpu(smp_processor_id()); + if (machine_desc->init_cpu_smp) machine_desc->init_cpu_smp(smp_processor_id()); #endif diff --git a/arch/arc/kernel/smp.c b/arch/arc/kernel/smp.c index 35ee18f1de58..580587805fa3 100644 --- a/arch/arc/kernel/smp.c +++ b/arch/arc/kernel/smp.c @@ -131,6 +131,10 @@ void start_kernel_secondary(void) pr_info("## CPU%u LIVE ##: Executing Code...\n", cpu); + /* Some SMP H/w setup - for each cpu */ + if (plat_smp_ops.init_irq_cpu) + plat_smp_ops.init_irq_cpu(cpu); + if (machine_desc->init_cpu_smp) machine_desc->init_cpu_smp(cpu); |