csky: Send stop IPI to send to online CPUs
PATCH 1/1 csky: Send stop IPI to send to online CPUs
Unfortunately I do not have any HW to test this patch. Hopefully someone on the cc list can help me out?
P.
---8<---
This issue was noticed while debugging a shutdown issue where some secondary CPUs are not being shutdown correctly. A fix for that [1] requires that secondary cpus be offlined using the cpu_online_mask so that the stop operation is a no-op if CPU HOTPLUG is disabled. I, like the author in
[1] looked at the architectures and found that csky is one of two architectures that executes smp_send_stop() on all possible CPUs.
On csky, smp_send_stop() sends an IPI to all possible CPUs but only needs to send them to online CPUs.
Send the stop IPI to only the online CPUs.
Signed-off-by Prarit Bhargava <[email protected]>
Cc Guo Ren <[email protected]>
--- arch/csky/kernel/smp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/csky/kernel/smp.c +1 -1
@@ -137,7 +137,7 @@ static void ipi_stop(void *unused)void smp_send_stop (void ) { -on_each_cpu (ipi_stop,NULL ,1 ); +on_each_cpu_mask (cpu_online_mask, ipi_stop,NULL ,1 ); }void smp_send_reschedule (int cpu)
Signature · 1 line
2.29.2