Re: [PATCH] riscv: Report dying CPU to RCU in IPI_CPU_STOP

From: Paul Walmsley

Date: Mon Nov 30 2026 - 20:42:42 EST


On Mon, 22 Jun 2026, Guo Ren wrote:

> From: "Guo Ren (Alibaba DAMO Academy)" <guoren@xxxxxxxxxx>
>
> This is a port of MIPS commit 9f3f3bdc6d9dac1 ("MIPS: smp: report
> dying CPU to RCU in stop_this_cpu()") inspired by the Loongarch
> mailing thread.
>
> The smp_send_stop() parks all secondary CPUs in IPI_CPU_STOP, which
> marks the CPU offline for the scheduler via set_cpu_online(false),
> but never informs RCU, so RCU keeps expecting a quiescent state
> from CPUs that are now spinning forever with interrupts disabled.
>
> Please read the MIPS commit mentioned before for details.

The MIPS commit message implies that this is a concern when
arch_irq_work_has_interrupt() returns false. This only happens on RISC-V
when !CONFIG_SMP. So I'm curious - were you able to observe the
failure on RISC-V that was observed on MIPS?

thanks,


- Paul