[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1427330363-17733-1-git-send-email-namhyung@kernel.org>
Date: Thu, 26 Mar 2015 09:39:23 +0900
From: Namhyung Kim <namhyung@...nel.org>
To: Steven Rostedt <rostedt@...dmis.org>
Cc: LKML <linux-kernel@...r.kernel.org>,
Tom Zanussi <tom.zanussi@...ux.intel.com>,
Minchan Kim <minchan@...nel.org>
Subject: [PATCH] tracing: Increase stack skip on event trigger
When 'stacktrace' trigger is used for event tracing, it should skip 4
functions instead of 3. Otherwise it'll contain ftrace_raw_event_XXX
like below:
# echo stacktrace > events/sched/sched_switch/trigger
# tail trace
=> rcu_gp_kthread
=> kthread
=> ret_from_fork
ksoftirqd/0-3 [000] d..3 53.343993: <stack trace>
=> ftrace_raw_event_sched_switch
=> __schedule
=> schedule
=> smpboot_thread_fn
=> kthread
=> ret_from_fork
Reported-by: Minchan Kim <minchan@...nel.org>
Cc: Tom Zanussi <tom.zanussi@...ux.intel.com>
Signed-off-by: Namhyung Kim <namhyung@...nel.org>
---
kernel/trace/trace_events_trigger.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/kernel/trace/trace_events_trigger.c b/kernel/trace/trace_events_trigger.c
index 8712df9decb4..c58fbdd3053e 100644
--- a/kernel/trace/trace_events_trigger.c
+++ b/kernel/trace/trace_events_trigger.c
@@ -965,12 +965,13 @@ static __init int register_trigger_snapshot_cmd(void) { return 0; }
#ifdef CONFIG_STACKTRACE
/*
- * Skip 3:
+ * Skip 4:
* stacktrace_trigger()
* event_triggers_post_call()
+ * ftrace_event_buffer_commit()
* ftrace_raw_event_xxx()
*/
-#define STACK_SKIP 3
+#define STACK_SKIP 4
static void
stacktrace_trigger(struct event_trigger_data *data)
--
2.3.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists