aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/arc/kernel/head.S14
-rw-r--r--arch/arc/kernel/smp.c6
2 files changed, 11 insertions, 9 deletions
diff --git a/arch/arc/kernel/head.S b/arch/arc/kernel/head.S
index 689dd867fdff..8b90d25a15cc 100644
--- a/arch/arc/kernel/head.S
+++ b/arch/arc/kernel/head.S
@@ -71,14 +71,14 @@ ENTRY(stext)
71 GET_CPU_ID r5 71 GET_CPU_ID r5
72 cmp r5, 0 72 cmp r5, 0
73 mov.nz r0, r5 73 mov.nz r0, r5
74#ifdef CONFIG_ARC_SMP_HALT_ON_RESET 74 bz .Lmaster_proceed
75 ; Non-Master can proceed as system would be booted sufficiently 75
76 jnz first_lines_of_secondary
77#else
78 ; Non-Masters wait for Master to boot enough and bring them up 76 ; Non-Masters wait for Master to boot enough and bring them up
79 jnz arc_platform_smp_wait_to_boot 77 ; when they resume, tail-call to entry point
80#endif 78 mov blink, @first_lines_of_secondary
81 ; Master falls thru 79 j arc_platform_smp_wait_to_boot
80
81.Lmaster_proceed:
82#endif 82#endif
83 83
84 ; Clear BSS before updating any globals 84 ; Clear BSS before updating any globals
diff --git a/arch/arc/kernel/smp.c b/arch/arc/kernel/smp.c
index 88674d972c9d..44a0d21ed342 100644
--- a/arch/arc/kernel/smp.c
+++ b/arch/arc/kernel/smp.c
@@ -98,14 +98,16 @@ static void arc_default_smp_cpu_kick(int cpu, unsigned long pc)
98 98
99void arc_platform_smp_wait_to_boot(int cpu) 99void arc_platform_smp_wait_to_boot(int cpu)
100{ 100{
101 /* for halt-on-reset, we've waited already */
102 if (IS_ENABLED(CONFIG_ARC_SMP_HALT_ON_RESET))
103 return;
104
101 while (wake_flag != cpu) 105 while (wake_flag != cpu)
102 ; 106 ;
103 107
104 wake_flag = 0; 108 wake_flag = 0;
105 __asm__ __volatile__("j @first_lines_of_secondary \n");
106} 109}
107 110
108
109const char *arc_platform_smp_cpuinfo(void) 111const char *arc_platform_smp_cpuinfo(void)
110{ 112{
111 return plat_smp_ops.info ? : ""; 113 return plat_smp_ops.info ? : "";