public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] dump_stack on panic
@ 2007-10-31  0:02 Steven Rostedt
  2007-10-31  0:14 ` Andi Kleen
  2007-10-31 14:19 ` Arjan van de Ven
  0 siblings, 2 replies; 14+ messages in thread
From: Steven Rostedt @ 2007-10-31  0:02 UTC (permalink / raw)
  To: LKML
  Cc: Linus Torvalds, Andrew Morton, Ingo Molnar, Christoph Hellwig,
	Daniel Walker

Is there any reason why we don't do a dump_stack on panic?

I find this soooo useful in the -rt patch, where Ingo has placed a
dump_stack on panic. With mainline, when I hit a panic, I don't always
know how it got there. So I find myself adding the dump_stack and trying
to create the bug again.

This patch simply adds dump_stack to panic.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>

diff --git a/kernel/panic.c b/kernel/panic.c
index 6f6e03e..bd481d7 100644
--- a/kernel/panic.c
+++ b/kernel/panic.c
@@ -78,6 +78,7 @@ NORET_TYPE void panic(const char * fmt, ...)
 	vsnprintf(buf, sizeof(buf), fmt, args);
 	va_end(args);
 	printk(KERN_EMERG "Kernel panic - not syncing: %s\n",buf);
+	dump_stack();
 	bust_spinlocks(0);
 
 	/*



^ permalink raw reply related	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2007-10-31 16:40 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-10-31  0:02 [PATCH] dump_stack on panic Steven Rostedt
2007-10-31  0:14 ` Andi Kleen
2007-10-31  0:30   ` Steven Rostedt
2007-10-31  8:15   ` Christoph Hellwig
2007-10-31 10:17     ` Ingo Molnar
2007-10-31 10:41     ` Andi Kleen
2007-10-31 10:58       ` Steven Rostedt
2007-10-31 11:17         ` Andi Kleen
2007-10-31 11:39           ` Steven Rostedt
2007-10-31 11:53             ` Andi Kleen
2007-10-31 14:19 ` Arjan van de Ven
2007-10-31 15:00   ` Steven Rostedt
2007-10-31 16:28     ` Arjan van de Ven
2007-10-31 16:39       ` Steven Rostedt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox