Re: [PATCH HACK RFC] cpu: Prevent late-arriving interrupts from disrupting offline
From: Peter Zijlstra
Date: Tue Jun 04 2019 - 08:11:00 EST
On Tue, Jun 04, 2019 at 01:14:35AM -0700, Paul E. McKenney wrote:
> On Mon, Jun 03, 2019 at 10:38:48AM +0200, Peter Zijlstra wrote:
> > And then there's powerpc which for some obscure reason thinks it needs
> > to enable preemption when dying ?! pseries_cpu_die() actually calls
> > msleep() ?!?!
>
> Isn't pseries_cpu_die() invoked via the smp_ops->cpu_die() function
> pointer, whch is invoked from __cpu_die() in arch/powerpc/kernel/smp.c?
> Then, if I am reading the code correctly, __cpu_die() is invoked from
> takedown_cpu(), which is invoked not from the dying CPU but rather from
> a surviving CPU. Or am I misreading the code?
Argh..
arch_cpu_idle_dead() -> cpu_die() -> ppc_md.cpu_die()
which is _NOT_ smp_ops.cpu_die()
this one ends in pseries_mach_cpu_die()