Re: [PATCH v2][GIT PULL] tracing: add trace_stack interface

From: Ingo Molnar
Date: Thu Jun 04 2009 - 07:53:53 EST



* Frederic Weisbecker <fweisbec@xxxxxxxxx> wrote:

> On Tue, May 19, 2009 at 09:09:40PM -0400, Steven Rostedt wrote:
> >
> > Ingo,
> >
> > I rebased because I forgot to add EXPORT_SYMBOL_GPL.
> >
> > -- Steve
> >
> > Please pull the latest tip/tracing/ftrace tree, which can be found at:
> >
> > git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-2.6-trace.git
> > tip/tracing/ftrace
> >
> >
> > Steven Rostedt (1):
> > tracing: add trace_stack interface
> >
> > ----
> > include/linux/kernel.h | 2 ++
> > kernel/trace/trace.c | 16 ++++++++++++++++
> > 2 files changed, 18 insertions(+), 0 deletions(-)
> > ---------------------------
> > commit 9f6b28655254b91c48f684b367ac14bfec0e180a
> > Author: Steven Rostedt <srostedt@xxxxxxxxxx>
> > Date: Tue May 19 18:54:16 2009 -0400
> >
> > tracing: add trace_stack interface
> >
> > This patch adds the global function
> >
> > void trace_stack(void)
> >
> > This allows a developer to find where a function is called. For example,
> > if you want to know who calls __netif_reschedule, you can add
> >
> > static inline void __netif_reschedule(struct Qdisc *q)
> > {
> > struct softnet_data *sd;
> > unsigned long flags;
> >
> > + trace_stack();
> > local_irq_save(flags);
> > sd = &__get_cpu_var(softnet_data);
> > q->next_sched = sd->output_queue;
> >
> > And see the following in the trace output:
> >
> > <= __ftrace_trace_stack
> > <= trace_stack
> > <= __netif_schedule
> > <= dev_watchdog
> > <= run_timer_softirq
> > <= __do_softirq
> > <= call_softirq
> > <= do_softirq
> > <= irq_exit
> >
> > Signed-off-by: Steven Rostedt <rostedt@xxxxxxxxxxx>
>
>
> I wanted to use it to get the recursive locking points in reiserfs
> but I can't find it.
>
> Has it been merged in -tip ?

hm, Steve has not sent it along AFAICS. There were no objections
from me.

Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/