summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/machine.h
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2016-01-25 22:01:57 +0100
committerArnaldo Carvalho de Melo <acme@redhat.com>2016-01-26 15:52:51 +0100
commit8acd3da03c3f6e4e31472c5c73402b95a5d0f6cb (patch)
tree89c9c95fb92909d97fd0188161affb1ddef09bef /tools/perf/util/machine.h
parentperf hists browser: Offer non-symbol specific menu options for --sort without... (diff)
downloadlinux-8acd3da03c3f6e4e31472c5c73402b95a5d0f6cb.tar.xz
linux-8acd3da03c3f6e4e31472c5c73402b95a5d0f6cb.zip
perf machine: Introduce machine__find_kernel_symbol_by_name()
To be used in the 'vmlinux matches kallsyms' 'perf test' entry. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-m56g1853lz2c6nhnqxibq4jd@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/machine.h')
-rw-r--r--tools/perf/util/machine.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/tools/perf/util/machine.h b/tools/perf/util/machine.h
index 2c2b443df5ba..1a3e45baf97f 100644
--- a/tools/perf/util/machine.h
+++ b/tools/perf/util/machine.h
@@ -180,6 +180,16 @@ struct symbol *machine__find_kernel_symbol(struct machine *machine,
}
static inline
+struct symbol *machine__find_kernel_symbol_by_name(struct machine *machine,
+ enum map_type type, const char *name,
+ struct map **mapp,
+ symbol_filter_t filter)
+{
+ return map_groups__find_symbol_by_name(&machine->kmaps, type, name,
+ mapp, filter);
+}
+
+static inline
struct symbol *machine__find_kernel_function(struct machine *machine, u64 addr,
struct map **mapp,
symbol_filter_t filter)