function_graph: Make ftrace_push_return_trace() static
authorSteven Rostedt (VMware) <rostedt@goodmis.org>
Mon, 19 Nov 2018 12:40:39 +0000 (07:40 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 5 Dec 2018 18:32:10 +0000 (19:32 +0100)
commit d125f3f866df88da5a85df00291f88f0baa89f7c upstream.

As all architectures now call function_graph_enter() to do the entry work,
no architecture should ever call ftrace_push_return_trace(). Make it static.

This is needed to prepare for a fix of a design bug on how the curr_ret_stack
is used.

Cc: stable@kernel.org
Fixes: 03274a3ffb449 ("tracing/fgraph: Adjust fgraph depth before calling trace return callback")
Reviewed-by: Masami Hiramatsu <mhiramat@kernel.org>
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
include/linux/ftrace.h
kernel/trace/trace_functions_graph.c

index 5717e8f..dd16e82 100644 (file)
@@ -777,9 +777,6 @@ struct ftrace_ret_stack {
 extern void return_to_handler(void);
 
 extern int
-ftrace_push_return_trace(unsigned long ret, unsigned long func, int *depth,
-                        unsigned long frame_pointer, unsigned long *retp);
-extern int
 function_graph_enter(unsigned long ret, unsigned long func,
                     unsigned long frame_pointer, unsigned long *retp);
 
index 28f2602..88ca787 100644 (file)
@@ -118,7 +118,7 @@ print_graph_duration(struct trace_array *tr, unsigned long long duration,
                     struct trace_seq *s, u32 flags);
 
 /* Add a function return address to the trace stack on thread info.*/
-int
+static int
 ftrace_push_return_trace(unsigned long ret, unsigned long func, int *depth,
                         unsigned long frame_pointer, unsigned long *retp)
 {