lkml.org 
[lkml]   [2020]   [Feb]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] tracing/perf: Move rcu_irq_enter/exit_irqson() to perf trace point hook
On Tue, 11 Feb 2020 13:00:15 +0100
Peter Zijlstra <peterz@infradead.org> wrote:

> As per nmi_enter() calling rcu_nmi_enter() I've always assumed that NMIs
> are fully covered by RCU.
>
> If this isn't so, RCU it terminally broken :-)

Most of the time it is. But for tracing that injects callbacks at
arbitrary points of code, it can break. I've always said that tracing
is a more sensitive context than NMI itself. The reason NMIs are
sensitive is because they can happen pretty much anywhere. But tracing
can happen also in the context switch that enters NMI.

This is why function tracing does the "rude" RCU flavor (yes Paul, I'd
love you to add that flavor!), that performs a schedule_on_each_cpu()
before freeing anything. Because it traces when RCU is not watching.

But RCU really shouldn't have to bend over backward for tracing, as
tracing is the exception and not the norm.

-- Steve

\
 
 \ /
  Last update: 2020-02-11 15:11    [W:0.076 / U:0.336 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site