Re: Regression with suspicious RCU usage splats with cpu_pm change

From: Paul E. McKenney
Date: Mon Jul 17 2017 - 08:39:49 EST


On Sun, Jul 16, 2017 at 11:08:07PM -0700, Tony Lindgren wrote:
> * Alex Shi <alex.shi@xxxxxxxxxx> [170716 16:25]:
> > I reused the rcu_irq_enter_irqson() from RCU_NONIDLE to avoid this issue.
> > It works fine.
> >
> > Tony, Could you like to give a tested-by if this patch works for you.
>
> Yeah that keeps things booting for me with no splats so:
>
> Tested-by: Tony Lindgren <tony@xxxxxxxxxxx>
>
> In general, it seems we're missing the knowledge in Linux kernel
> of when the entire system is idle. Right now it seems that only
> cpuidle_coupled knows that?
>
> We could probably simplify things by adding some PM state for
> entire system idle. Then cpuidle code and timer code could use
> that to test when it's safe to do whatever the SoC needs to do
> to enter deeper power states.
>
> If we already have something like that, please do let me know :)

Well, we used to have CONFIG_NO_HZ_FULL_SYSIDLE, which detected
full-system idle lazily so as to avoid scalability bottlenecks.
https://lwn.net/Articles/558284/

No one was using it, so I removed it last merge window. The
patch that removed it is at sysidle.2017.05.11a, which can
probably still be reverted cleanly. Or just use v4.11 or earlier.

Thanx, Paul