mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cc: Li Zefan <lizf@cn.fujitsu.com>, Ingo Molnar <mingo@elte.hu>,
	Frederic Weisbecker <fweisbec@gmail.com>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 1/2] tracing: Add sysctl to enable/disable tracing on oops
Date: Wed, 09 Sep 2009 07:48:05 -0400	[thread overview]
Message-ID: <1252496885.27001.1.camel@gandalf.stny.rr.com> (raw)
In-Reply-To: <20090909122425.0CEF.A69D9226@jp.fujitsu.com>

On Wed, 2009-09-09 at 13:19 +0900, KOSAKI Motohiro wrote:
> > On Wed, 2009-09-09 at 10:40 +0800, Li Zefan wrote:
> > 
> > > > I have another silly question.
> > > > Why should we call tracing_off() in oops_enter()?
> > > > 
> > > 
> > > I guess it's because trace outputs generated during oops can
> > > overwrite/mess up those generated before oops?
> > > 
> > > It was added by this commit, but I can't find trace_printk_on_oops.
> > 
> > That's because Thomas did not bother looking up the actual variable he
> > was talking about. s/trace_printk_on_oops/ftrace_dump_on_oops/
> 
> After a bit thinking, I think ftrace_dump_on_oops and kernel dump with panic have
> very similar requirement.
> Then, I think we can reuse this infrastructure for kernel dump.
> 
> Requirement
>   - Need to know why the problem occur.
>   - Need to don't logging oops (panic) internal.
> 
> Unfortunately, panic() call panic_notifier after crash_kexec().
> it mean tracing_off() was not called when panic on the machine w/ kernel-dump.
> 
> 	NORET_TYPE void panic(const char * fmt, ...)
> 	{
> 	(snip)
> 	        crash_kexec(NULL);
> 	(snip)
> 	        atomic_notifier_call_chain(&panic_notifier_list, 0, buf);
> 
> I think we can insert tracing_off() into panic() directly. it only
> bit mask operation, it mean it don't have side effect risk.
> 
> Perhaps, There are other kernel dump specific requrement. but I guess
> it's very small. Maybe it can be handled by trace_die_handler() or something like.
> 
> What do you think?

Yes, a tracing_off() should be in the beginning of panic. I had a patch
to do this, but I never sent it out :-/

-- Steve



  reply	other threads:[~2009-09-09 11:48 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-09  1:15 Li Zefan
2009-09-09  1:15 ` [PATCH 2/2] tracing/events: Add kexec tracepoints Li Zefan
2009-09-09  1:20   ` Daniel Walker
2009-09-09  1:26     ` Li Zefan
2009-09-09  4:59       ` Daniel Walker
2009-09-09 11:46         ` Steven Rostedt
2009-09-09 14:12           ` Daniel Walker
2009-09-09 15:19             ` Steven Rostedt
2009-09-09 15:58               ` Daniel Walker
2009-09-09  1:27   ` Eric W. Biederman
2009-09-09  1:39     ` Steven Rostedt
2009-09-09  2:02       ` Eric W. Biederman
2009-09-09  1:34 ` [PATCH 1/2] tracing: Add sysctl to enable/disable tracing on oops Steven Rostedt
2009-09-09  1:37   ` Li Zefan
2009-09-09  1:42     ` Steven Rostedt
2009-09-09  1:47       ` Li Zefan
2009-09-09  2:04         ` Steven Rostedt
2009-09-09  2:33           ` KOSAKI Motohiro
2009-09-09  2:40             ` Li Zefan
2009-09-09  2:53               ` Steven Rostedt
2009-09-09  4:19                 ` KOSAKI Motohiro
2009-09-09 11:48                   ` Steven Rostedt [this message]
2009-09-09  3:01               ` KOSAKI Motohiro

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=1252496885.27001.1.camel@gandalf.stny.rr.com \
    --to=rostedt@goodmis.org \
    --cc=fweisbec@gmail.com \
    --cc=kosaki.motohiro@jp.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lizf@cn.fujitsu.com \
    --cc=mingo@elte.hu \
    /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

all inboxes | Powered by JetHome®