diff options
author | Steven Rostedt (Red Hat) <rostedt@goodmis.org> | 2015-09-29 17:15:10 +0300 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2015-09-29 20:23:58 +0300 |
commit | 729358da95a1b3850ef892e9384f58932da1dc69 (patch) | |
tree | d7d4ad01b17ed7490e9689d1eb79396b9dbb7099 /kernel/trace/trace_sched_wakeup.c | |
parent | a3418a364ec3c8f0c29bf3f4cfc71dc6f240150e (diff) | |
download | linux-729358da95a1b3850ef892e9384f58932da1dc69.tar.xz |
tracing: Only create function graph options when it is compiled in
Do not create fuction graph tracer options when function graph tracer is not
even compiled in.
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel/trace/trace_sched_wakeup.c')
-rw-r--r-- | kernel/trace/trace_sched_wakeup.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/kernel/trace/trace_sched_wakeup.c b/kernel/trace/trace_sched_wakeup.c index f5d2e65e7c92..a6c350c681cc 100644 --- a/kernel/trace/trace_sched_wakeup.c +++ b/kernel/trace/trace_sched_wakeup.c @@ -40,15 +40,15 @@ static void wakeup_graph_return(struct ftrace_graph_ret *trace); static int save_flags; static bool function_enabled; -#define is_graph() (trace_flags & TRACE_ITER_DISPLAY_GRAPH) - #ifdef CONFIG_FUNCTION_GRAPH_TRACER static int wakeup_display_graph(struct trace_array *tr, int set); +# define is_graph() (trace_flags & TRACE_ITER_DISPLAY_GRAPH) #else static inline int wakeup_display_graph(struct trace_array *tr, int set) { return -EINVAL; } +# define is_graph() false #endif @@ -174,8 +174,10 @@ static int wakeup_flag_changed(struct trace_array *tr, u32 mask, int set) if (mask & TRACE_ITER_FUNCTION) return wakeup_function_set(tr, set); +#ifdef CONFIG_FUNCTION_GRAPH_TRACER if (mask & TRACE_ITER_DISPLAY_GRAPH) return wakeup_display_graph(tr, set); +#endif return trace_keep_overwrite(tracer, mask, set); } |