Re: [RFC 2/2] rcu: Remove ->dynticks_nmi_nesting from struct rcu_dynticks

From: Steven Rostedt
Date: Fri Jun 22 2018 - 17:00:50 EST


On Fri, 22 Jun 2018 13:58:13 -0700
"Paul E. McKenney" <paulmck@xxxxxxxxxxxxxxxxxx> wrote:

> Something like this:
>
> IRQ entered
>
> And never exited. Ever. I actually saw this in 2011.

I still believe this was actually a bug. And perhaps you made the RCU
code robust enough to handle this bug ;-)

>
> Or something like this:
>
> IRQ exited
>
> Without a corresponding IRQ enter.
>
> The current code handles both of these situations, at least assuming
> that the interrupt entry/exit happens during a non-idle period.
>
> > > So why this function-call structure? Well, you see, NMI handlers can
> > > take what appear to RCU to be normal interrupts...
> > >
> > > (And I just added that fun fact to Requirements.html.)
> >
> > Yes, I'll definitely go through all the interrupt requirements in the doc and
> > thanks for referring me to it.
>
> My concern may well be obsolete. It would be good if it was! ;-)

I'd love to mandate that irq_enter() must be paired with irq_exit(). I
don't really see any rationale for it to be otherwise. If there is a
case, perhaps it needs to be fixed.

-- Steve