aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/trace/trace_functions_graph.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/trace/trace_functions_graph.c')
-rw-r--r--kernel/trace/trace_functions_graph.c17
1 files changed, 7 insertions, 10 deletions
diff --git a/kernel/trace/trace_functions_graph.c b/kernel/trace/trace_functions_graph.c
index 69ebf3c2f1b5..78af97163147 100644
--- a/kernel/trace/trace_functions_graph.c
+++ b/kernel/trace/trace_functions_graph.c
@@ -137,6 +137,13 @@ int trace_graph_entry(struct ftrace_graph_ent *trace)
137 if (trace_recursion_test(TRACE_GRAPH_NOTRACE_BIT)) 137 if (trace_recursion_test(TRACE_GRAPH_NOTRACE_BIT))
138 return 0; 138 return 0;
139 139
140 /*
141 * Do not trace a function if it's filtered by set_graph_notrace.
142 * Make the index of ret stack negative to indicate that it should
143 * ignore further functions. But it needs its own ret stack entry
144 * to recover the original index in order to continue tracing after
145 * returning from the function.
146 */
140 if (ftrace_graph_notrace_addr(trace->func)) { 147 if (ftrace_graph_notrace_addr(trace->func)) {
141 trace_recursion_set(TRACE_GRAPH_NOTRACE_BIT); 148 trace_recursion_set(TRACE_GRAPH_NOTRACE_BIT);
142 /* 149 /*
@@ -156,16 +163,6 @@ int trace_graph_entry(struct ftrace_graph_ent *trace)
156 return 0; 163 return 0;
157 164
158 /* 165 /*
159 * Do not trace a function if it's filtered by set_graph_notrace.
160 * Make the index of ret stack negative to indicate that it should
161 * ignore further functions. But it needs its own ret stack entry
162 * to recover the original index in order to continue tracing after
163 * returning from the function.
164 */
165 if (ftrace_graph_notrace_addr(trace->func))
166 return 1;
167
168 /*
169 * Stop here if tracing_threshold is set. We only write function return 166 * Stop here if tracing_threshold is set. We only write function return
170 * events to the ring buffer. 167 * events to the ring buffer.
171 */ 168 */