diff options
author | Steven Rostedt (Red Hat) <rostedt@goodmis.org> | 2014-05-06 21:57:49 -0400 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2014-05-14 11:37:25 -0400 |
commit | 66209a5bd4825e8890bfb65d48efa8a47c647fea (patch) | |
tree | af341436b09b04b83e33477b9d4197c5b0d718e6 /kernel/trace | |
parent | 7c65bbc7dcface00b295bbd18bce82fe1db3d633 (diff) |
ftrace: Remove boolean of hash_enable and hash_disable
Commit 4104d326b670 "ftrace: Remove global function list and call
function directly" cleaned up the global_ops filtering and made
the code simpler, but it left a variable "hash_enable" that was used
to know if the hash functions should be updated or not. It was
updated if the global_ops did not override them. As the global_ops
are now no different than any other ftrace_ops, the hash always
gets updated and there's no reason to use the hash_enable boolean.
The same goes for hash_disable used in ftrace_shutdown().
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel/trace')
-rw-r--r-- | kernel/trace/ftrace.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c index 38e5cf73b9ae..2c99d1f7caf1 100644 --- a/kernel/trace/ftrace.c +++ b/kernel/trace/ftrace.c @@ -2042,7 +2042,6 @@ static void ftrace_startup_enable(int command) static int ftrace_startup(struct ftrace_ops *ops, int command) { - bool hash_enable = true; int ret; if (unlikely(ftrace_disabled)) @@ -2056,8 +2055,8 @@ static int ftrace_startup(struct ftrace_ops *ops, int command) command |= FTRACE_UPDATE_CALLS; ops->flags |= FTRACE_OPS_FL_ENABLED; - if (hash_enable) - ftrace_hash_rec_enable(ops, 1); + + ftrace_hash_rec_enable(ops, 1); ftrace_startup_enable(command); @@ -2066,7 +2065,6 @@ static int ftrace_startup(struct ftrace_ops *ops, int command) static int ftrace_shutdown(struct ftrace_ops *ops, int command) { - bool hash_disable = true; int ret; if (unlikely(ftrace_disabled)) @@ -2084,8 +2082,7 @@ static int ftrace_shutdown(struct ftrace_ops *ops, int command) */ WARN_ON_ONCE(ftrace_start_up < 0); - if (hash_disable) - ftrace_hash_rec_disable(ops, 1); + ftrace_hash_rec_disable(ops, 1); if (!global_start_up) ops->flags &= ~FTRACE_OPS_FL_ENABLED; |