diff options
author | Steven Rostedt (VMware) <rostedt@goodmis.org> | 2017-04-04 13:39:59 -0400 |
---|---|---|
committer | Steven Rostedt (VMware) <rostedt@goodmis.org> | 2017-04-20 22:06:40 -0400 |
commit | 78f78e07d51e440d01e6b1aef172883821193771 (patch) | |
tree | a4ccc492cccd26effe963f8d199ff860516421b3 /kernel | |
parent | 0fe7e7e3f8391d4c9260b41cdb15c7917cb2e5b3 (diff) | |
download | linux-stable-78f78e07d51e440d01e6b1aef172883821193771.tar.gz linux-stable-78f78e07d51e440d01e6b1aef172883821193771.tar.bz2 linux-stable-78f78e07d51e440d01e6b1aef172883821193771.zip |
ftrace: Remove unused unregister_ftrace_function_probe_all() function
There are no users of unregister_ftrace_function_probe_all(). The only probe
function that is used is unregister_ftrace_function_probe_func(). Rename the
internal static function __unregister_ftrace_function_probe() to
unregister_ftrace_function_probe_func() and make it global.
Also remove the PROBE_TEST_FUNC as it would be always set.
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/trace/ftrace.c | 22 | ||||
-rw-r--r-- | kernel/trace/trace.h | 1 |
2 files changed, 3 insertions, 20 deletions
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c index 5448089e6028..1c31c74d0819 100644 --- a/kernel/trace/ftrace.c +++ b/kernel/trace/ftrace.c @@ -4059,13 +4059,8 @@ register_ftrace_function_probe(char *glob, struct ftrace_probe_ops *ops, return count; } -enum { - PROBE_TEST_FUNC = 1, -}; - -static void -__unregister_ftrace_function_probe(char *glob, struct ftrace_probe_ops *ops, - int flags) +void +unregister_ftrace_function_probe_func(char *glob, struct ftrace_probe_ops *ops) { struct ftrace_ops_hash old_hash_ops; struct ftrace_func_entry *rec_entry; @@ -4115,7 +4110,7 @@ __unregister_ftrace_function_probe(char *glob, struct ftrace_probe_ops *ops, hlist_for_each_entry_safe(entry, tmp, hhd, node) { /* break up if statements for readability */ - if ((flags & PROBE_TEST_FUNC) && entry->ops != ops) + if (entry->ops != ops) continue; /* do this last, since it is the most expensive */ @@ -4162,17 +4157,6 @@ __unregister_ftrace_function_probe(char *glob, struct ftrace_probe_ops *ops, free_ftrace_hash(hash); } -void -unregister_ftrace_function_probe_func(char *glob, struct ftrace_probe_ops *ops) -{ - __unregister_ftrace_function_probe(glob, ops, PROBE_TEST_FUNC); -} - -void unregister_ftrace_function_probe_all(char *glob) -{ - __unregister_ftrace_function_probe(glob, NULL, 0); -} - static LIST_HEAD(ftrace_commands); static DEFINE_MUTEX(ftrace_cmd_mutex); diff --git a/kernel/trace/trace.h b/kernel/trace/trace.h index 507a62e9192e..376d5a798489 100644 --- a/kernel/trace/trace.h +++ b/kernel/trace/trace.h @@ -965,7 +965,6 @@ register_ftrace_function_probe(char *glob, struct ftrace_probe_ops *ops, void *data); extern void unregister_ftrace_function_probe_func(char *glob, struct ftrace_probe_ops *ops); -extern void unregister_ftrace_function_probe_all(char *glob); int register_ftrace_command(struct ftrace_func_command *cmd); int unregister_ftrace_command(struct ftrace_func_command *cmd); |