From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: linux-kernel@vger.kernel.org, Ingo Molnar <mingo@kernel.org>,
Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [PATCH 3/4] tracing: Add stack_tracer_disable/enable() functions
Date: Thu, 6 Apr 2017 15:08:21 -0700 [thread overview]
Message-ID: <20170406220821.GN1600@linux.vnet.ibm.com> (raw)
In-Reply-To: <20170406172348.6df0201b@gandalf.local.home>
On Thu, Apr 06, 2017 at 05:23:48PM -0400, Steven Rostedt wrote:
> On Thu, 6 Apr 2017 13:21:17 -0700
> "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> wrote:
>
> > > My worry is that we add another caller that doesn't disable interrupts
> > > or preemption.
> > >
> > > I could add a __stack_trace_disable() that skips the disabling of
> > > preemption, as the "__" usually denotes the call is "special".
> >
> > Given that interrupts are disabled at that point, and given also that
> > NMI skips stack tracing if growth is required, could we just leave
> > out the stack_tracer_disable() and stack_tracer_enable()?
>
> There may be other use cases. Hmm, maybe I'll just have it do a check
> to make sure preemption is disabled. Something like:
>
> if (IS_ENABLED(CONFIG_DEBUG_PREEMPT))
> WARN_ON_ONCE(!preempt_count());
This in the include/linux/ftrace.h file so that it can be inlined?
That makes sense to me.
Thanx, Paul
next prev parent reply other threads:[~2017-04-06 22:08 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-06 16:42 [PATCH 0/4] tracing: Add usecase of synchronize_rcu_tasks() and stack_tracer_disable() Steven Rostedt
2017-04-06 16:42 ` [PATCH 1/4] ftrace: Add use of synchronize_rcu_tasks() with dynamic trampolines Steven Rostedt
2017-04-06 18:05 ` Paul E. McKenney
2017-04-06 18:13 ` Steven Rostedt
2017-04-06 20:20 ` Paul E. McKenney
2017-04-06 16:42 ` [PATCH 2/4] tracing: Replace the per_cpu() with this_cpu() in trace_stack.c Steven Rostedt
2017-04-06 16:42 ` [PATCH 3/4] tracing: Add stack_tracer_disable/enable() functions Steven Rostedt
2017-04-06 18:12 ` Paul E. McKenney
2017-04-06 18:48 ` Steven Rostedt
2017-04-06 20:21 ` Paul E. McKenney
2017-04-06 21:23 ` Steven Rostedt
2017-04-06 22:08 ` Paul E. McKenney [this message]
2017-04-06 23:57 ` Steven Rostedt
2017-04-06 16:42 ` [PATCH 4/4] rcu: Fix dyntick-idle tracing Steven Rostedt
2017-04-06 18:01 ` Paul E. McKenney
2017-04-07 4:50 ` kbuild test robot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170406220821.GN1600@linux.vnet.ibm.com \
--to=paulmck@linux.vnet.ibm.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=rostedt@goodmis.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox