Andy Lutomirski <l...@kernel.org> writes:
> On Tue, May 19, 2020 at 1:20 PM Thomas Gleixner <t...@linutronix.de> wrote:
>> Thomas Gleixner <t...@linutronix.de> writes:
>> It's about this:
>>
>> rcu_nmi_enter()
>> {
>>         if (!rcu_is_watching()) {
>>             make it watch;
>>         } else if (!in_nmi()) {
>>             do_magic_nohz_dyntick_muck();
>>         }
>>
>> So if we do all irq/system vector entries conditional then the
>> do_magic() gets never executed. After that I got lost...
>
> I'm also baffled by that magic, but I'm also not suggesting doing this
> to *all* entries -- just the not-super-magic ones that use
> idtentry_enter().
>
> Paul, what is this code actually trying to do?

Citing Paul from IRC:

  "The way things are right now, you can leave out the rcu_irq_enter()
   if this is not a nohz_full CPU.

   Or if this is a nohz_full CPU, and the tick is already
   enabled, in that case you could also leave out the rcu_irq_enter().

   Or even if this is a nohz_full CPU and it does not have the tick
   enabled, if it has been in the kernel less than a few tens of
   milliseconds, still OK to avoid invoking rcu_irq_enter()

   But my guess is that it would be a lot simpler to just always call
   it.

Hope that helps.

Thanks,

        tglx

Reply via email to