diff options
author | Namhyung Kim <namhyung@kernel.org> | 2017-01-20 11:44:46 +0900 |
---|---|---|
committer | Steven Rostedt (VMware) <rostedt@goodmis.org> | 2017-01-20 14:50:21 -0500 |
commit | 4046bf023b0647d09704a32d9fe8aecbcee3e4c3 (patch) | |
tree | 9c3ef245b59ed01b9374f70a76390bf719abf25e /kernel/trace/ftrace.c | |
parent | 3e278c0dc1cf5070d9462ececde1c07369b469b2 (diff) | |
download | linux-stable-4046bf023b0647d09704a32d9fe8aecbcee3e4c3.tar.gz linux-stable-4046bf023b0647d09704a32d9fe8aecbcee3e4c3.tar.bz2 linux-stable-4046bf023b0647d09704a32d9fe8aecbcee3e4c3.zip |
ftrace: Expose ftrace_hash_empty and ftrace_lookup_ip
It will be used when checking graph filter hashes later.
Link: http://lkml.kernel.org/r/20170120024447.26097-2-namhyung@kernel.org
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
[ Moved ftrace_hash dec and functions outside of FUNCTION_GRAPH define ]
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Diffstat (limited to 'kernel/trace/ftrace.c')
-rw-r--r-- | kernel/trace/ftrace.c | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c index 37b0e948d924..0470e373b9b4 100644 --- a/kernel/trace/ftrace.c +++ b/kernel/trace/ftrace.c @@ -1110,13 +1110,6 @@ struct ftrace_func_entry { unsigned long ip; }; -struct ftrace_hash { - unsigned long size_bits; - struct hlist_head *buckets; - unsigned long count; - struct rcu_head rcu; -}; - /* * We make these constant because no one should touch them, * but they are used as the default "empty hash", to avoid allocating @@ -1192,12 +1185,7 @@ struct ftrace_page { static struct ftrace_page *ftrace_pages_start; static struct ftrace_page *ftrace_pages; -static bool __always_inline ftrace_hash_empty(struct ftrace_hash *hash) -{ - return !hash || !hash->count; -} - -static struct ftrace_func_entry * +struct ftrace_func_entry * ftrace_lookup_ip(struct ftrace_hash *hash, unsigned long ip) { unsigned long key; |