[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200306124023.GA12584@hirez.programming.kicks-ass.net>
Date: Fri, 6 Mar 2020 13:40:23 +0100
From: Peter Zijlstra <peterz@...radead.org>
To: linux-kernel@...r.kernel.org, linux-arch@...r.kernel.org,
rostedt@...dmis.org
Cc: mingo@...nel.org, joel@...lfernandes.org,
gregkh@...uxfoundation.org, gustavo@...eddedor.com,
tglx@...utronix.de, paulmck@...nel.org, josh@...htriplett.org,
mathieu.desnoyers@...icios.com, jiangshanlai@...il.com,
luto@...nel.org, tony.luck@...el.com, frederic@...nel.org,
dan.carpenter@...cle.com, mhiramat@...nel.org
Subject: Re: [PATCH v4 11/27] rcu,tracing: Create trace_rcu_{enter,exit}()
On Fri, Mar 06, 2020 at 12:50:42PM +0100, Peter Zijlstra wrote:
> > +static inline int trace_rcu_enter(void)
> > +{
> > + int state = !rcu_is_watching();
> > + if (state)
> > + rcu_irq_enter_irqsave();
> > + return state;
> > +}
> > +
> > +static inline void trace_rcu_exit(int state)
> > +{
> > + if (state)
> > + rcu_irq_exit_irqsave();
> > +}
> > +
> > /*
> > * The init_rcu_head_on_stack() and destroy_rcu_head_on_stack() calls
> > * are needed for dynamic initialization and destruction of rcu_head
Also, I just noticed these read like tracepoints, so I'm going to rename
them: rcu_trace_{enter,exit}().
Powered by blists - more mailing lists