Skip to content

Commit

Permalink
tracing: ftrace_event_is_function() can return boolean
Browse files Browse the repository at this point in the history
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/[email protected]

Signed-off-by: Yaowei Bai <[email protected]>
Signed-off-by: Steven Rostedt <[email protected]>
  • Loading branch information
baihuahua authored and rostedt committed Nov 2, 2015
1 parent 907bff9 commit c6650b2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion kernel/trace/trace.h
Original file line number Diff line number Diff line change
Expand Up @@ -873,7 +873,7 @@ void ftrace_destroy_filter_files(struct ftrace_ops *ops);
#define ftrace_destroy_filter_files(ops) do { } while (0)
#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
Expand Down
2 changes: 1 addition & 1 deletion kernel/trace/trace_export.c
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ __attribute__((section("_ftrace_events"))) *__event_##call = &event_##call;
FTRACE_ENTRY_REG(call, struct_name, etype, \
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;
}
Expand Down

0 comments on commit c6650b2

Please sign in to comment.