aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexey Brodkin <Alexey.Brodkin@synopsys.com>2017-11-29 03:21:45 -0500
committerVineet Gupta <vgupta@synopsys.com>2018-06-20 19:12:06 -0400
commit2f24ef7413a4d91657ef04e77c27ce0b313e6c95 (patch)
tree07accc0f1b4b2a5e906b4e6bde4f91ca88b29170
parent74c11e300c103af47db5b658fdcf28002421e250 (diff)
ARC: Enable machine_desc->init_per_cpu for !CONFIG_SMP
machine_desc->init_per_cpu() hook is supposed to be per cpu initialization and would seem to apply equally to UP and/or SMP. Infact the comment in header file seems to suggest it works for UP too, which was not the case and this patch. This enables !CONFIG_SMP build for platforms such as hsdk. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> [vgupta: trimmeed changelog]
-rw-r--r--arch/arc/include/asm/mach_desc.h2
-rw-r--r--arch/arc/kernel/irq.c2
2 files changed, 1 insertions, 3 deletions
diff --git a/arch/arc/include/asm/mach_desc.h b/arch/arc/include/asm/mach_desc.h
index c28e6c347b49..871f3cb16af9 100644
--- a/arch/arc/include/asm/mach_desc.h
+++ b/arch/arc/include/asm/mach_desc.h
@@ -34,9 +34,7 @@ struct machine_desc {
34 const char *name; 34 const char *name;
35 const char **dt_compat; 35 const char **dt_compat;
36 void (*init_early)(void); 36 void (*init_early)(void);
37#ifdef CONFIG_SMP
38 void (*init_per_cpu)(unsigned int); 37 void (*init_per_cpu)(unsigned int);
39#endif
40 void (*init_machine)(void); 38 void (*init_machine)(void);
41 void (*init_late)(void); 39 void (*init_late)(void);
42 40
diff --git a/arch/arc/kernel/irq.c b/arch/arc/kernel/irq.c
index 538b36afe89e..62b185057c04 100644
--- a/arch/arc/kernel/irq.c
+++ b/arch/arc/kernel/irq.c
@@ -31,10 +31,10 @@ void __init init_IRQ(void)
31 /* a SMP H/w block could do IPI IRQ request here */ 31 /* a SMP H/w block could do IPI IRQ request here */
32 if (plat_smp_ops.init_per_cpu) 32 if (plat_smp_ops.init_per_cpu)
33 plat_smp_ops.init_per_cpu(smp_processor_id()); 33 plat_smp_ops.init_per_cpu(smp_processor_id());
34#endif
34 35
35 if (machine_desc->init_per_cpu) 36 if (machine_desc->init_per_cpu)
36 machine_desc->init_per_cpu(smp_processor_id()); 37 machine_desc->init_per_cpu(smp_processor_id());
37#endif
38} 38}
39 39
40/* 40/*