]> nv-tegra.nvidia Code Review - linux-2.6.git/commitdiff
tracing: Fix return of trace_dump_stack()
authorSteven Rostedt <srostedt@redhat.com>
Mon, 14 Dec 2009 20:58:33 +0000 (15:58 -0500)
committerIngo Molnar <mingo@elte.hu>
Tue, 15 Dec 2009 07:36:11 +0000 (08:36 +0100)
The trace_dump_stack() returned a value for a void function.

Also, added the missing stub for trace_dump_stack() when tracing is
not configured.

Reported-by: Ingo Molnar <mingo@elte.hu>
LKML-Reference: <20091214162713.GA31060@elte.hu>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
include/linux/kernel.h
kernel/trace/trace.c

index 5ad4199fb0738ee21af6769ef99412b8cc6cee09..f1dc752da0d2a5dc0476ec2ed85b9f5397ec3676 100644 (file)
@@ -527,6 +527,7 @@ trace_printk(const char *fmt, ...) __attribute__ ((format (printf, 1, 2)));
 static inline void tracing_start(void) { }
 static inline void tracing_stop(void) { }
 static inline void ftrace_off_permanent(void) { }
+static inline void trace_dump_stack(void) { }
 static inline int
 trace_printk(const char *fmt, ...)
 {
index bd7b969a729acdf7a42c897739ea09cd360d93a3..ee61915935d55568bc1455d52d0619ab5850e17a 100644 (file)
@@ -1158,7 +1158,7 @@ void trace_dump_stack(void)
        unsigned long flags;
 
        if (tracing_disabled || tracing_selftest_running)
-               return 0;
+               return;
 
        local_save_flags(flags);