Commit c6650b2e authored by Yaowei Bai's avatar Yaowei Bai Committed by Steven Rostedt

tracing: ftrace_event_is_function() can return boolean

Make ftrace_event_is_function() return bool to improve readability
due to this particular function only using either one or zero as its
return value.

No functional change.

Link: http://lkml.kernel.org/r/1443537816-5788-9-git-send-email-bywxiaobai@163.comSigned-off-by: default avatarYaowei Bai <bywxiaobai@163.com>
Signed-off-by: default avatarSteven Rostedt <rostedt@goodmis.org>
parent 907bff91
...@@ -873,7 +873,7 @@ void ftrace_destroy_filter_files(struct ftrace_ops *ops); ...@@ -873,7 +873,7 @@ void ftrace_destroy_filter_files(struct ftrace_ops *ops);
#define ftrace_destroy_filter_files(ops) do { } while (0) #define ftrace_destroy_filter_files(ops) do { } while (0)
#endif /* CONFIG_FUNCTION_TRACER && CONFIG_DYNAMIC_FTRACE */ #endif /* CONFIG_FUNCTION_TRACER && CONFIG_DYNAMIC_FTRACE */
int ftrace_event_is_function(struct trace_event_call *call); bool ftrace_event_is_function(struct trace_event_call *call);
/* /*
* struct trace_parser - servers for reading the user input separated by spaces * struct trace_parser - servers for reading the user input separated by spaces
......
...@@ -187,7 +187,7 @@ __attribute__((section("_ftrace_events"))) *__event_##call = &event_##call; ...@@ -187,7 +187,7 @@ __attribute__((section("_ftrace_events"))) *__event_##call = &event_##call;
FTRACE_ENTRY_REG(call, struct_name, etype, \ FTRACE_ENTRY_REG(call, struct_name, etype, \
PARAMS(tstruct), PARAMS(print), filter, NULL) PARAMS(tstruct), PARAMS(print), filter, NULL)
int ftrace_event_is_function(struct trace_event_call *call) bool ftrace_event_is_function(struct trace_event_call *call)
{ {
return call == &event_function; return call == &event_function;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment