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.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/kernel/trace/trace_functions_graph.c b/kernel/trace/trace_functions_graph.c
index 4f0d72ae6362..2561460d7baf 100644
--- a/kernel/trace/trace_functions_graph.c
+++ b/kernel/trace/trace_functions_graph.c
@@ -188,15 +188,17 @@ int function_graph_enter(unsigned long ret, unsigned long func,
188 trace.func = func; 188 trace.func = func;
189 trace.depth = ++current->curr_ret_depth; 189 trace.depth = ++current->curr_ret_depth;
190 190
191 /* Only trace if the calling function expects to */
192 if (!ftrace_graph_entry(&trace))
193 goto out;
194
195 if (ftrace_push_return_trace(ret, func, 191 if (ftrace_push_return_trace(ret, func,
196 frame_pointer, retp)) 192 frame_pointer, retp))
197 goto out; 193 goto out;
198 194
195 /* Only trace if the calling function expects to */
196 if (!ftrace_graph_entry(&trace))
197 goto out_ret;
198
199 return 0; 199 return 0;
200 out_ret:
201 current->curr_ret_stack--;
200 out: 202 out:
201 current->curr_ret_depth--; 203 current->curr_ret_depth--;
202 return -EBUSY; 204 return -EBUSY;