diff options
author | Steven Rostedt (Red Hat) <rostedt@goodmis.org> | 2015-09-29 15:38:55 -0400 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2015-09-29 15:38:55 -0400 |
commit | 73dddbb57bb08d465dd0ecab93db0c5209e50cfe (patch) | |
tree | 63f5adc345c08a15d42b9dff1d9d394ceddb1740 /kernel/trace/trace.h | |
parent | 8179e8a15b76eaec1e757da7a0f96de9f0c466c6 (diff) | |
download | op-kernel-dev-73dddbb57bb08d465dd0ecab93db0c5209e50cfe.zip op-kernel-dev-73dddbb57bb08d465dd0ecab93db0c5209e50cfe.tar.gz |
tracing: Only create stacktrace option when STACKTRACE is configured
Only create the stacktrace trace option when CONFIG_STACKTRACE is
configured.
Cleaned up the ftrace_trace_stack() function call a little to allow better
encapsulation of the stacktrace trace flag.
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel/trace/trace.h')
-rw-r--r-- | kernel/trace/trace.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/kernel/trace/trace.h b/kernel/trace/trace.h index b389d40..af34e18 100644 --- a/kernel/trace/trace.h +++ b/kernel/trace/trace.h @@ -911,6 +911,13 @@ extern int trace_get_user(struct trace_parser *parser, const char __user *ubuf, # define FUNCTION_DEFAULT_FLAGS 0UL #endif +#ifdef CONFIG_STACKTRACE +# define STACK_FLAGS \ + C(STACKTRACE, "stacktrace"), +#else +# define STACK_FLAGS +#endif + /* * trace_iterator_flags is an enumeration that defines bit * positions into trace_flags that controls the output. @@ -927,7 +934,6 @@ extern int trace_get_user(struct trace_parser *parser, const char __user *ubuf, C(HEX, "hex"), \ C(BIN, "bin"), \ C(BLOCK, "block"), \ - C(STACKTRACE, "stacktrace"), \ C(PRINTK, "trace_printk"), \ C(ANNOTATE, "annotate"), \ C(USERSTACKTRACE, "userstacktrace"), \ @@ -942,6 +948,7 @@ extern int trace_get_user(struct trace_parser *parser, const char __user *ubuf, C(MARKERS, "markers"), \ FUNCTION_FLAGS \ FGRAPH_FLAGS \ + STACK_FLAGS \ BRANCH_FLAGS /* |