diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2018-04-25 17:46:28 -0300 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2018-04-26 13:47:15 -0300 |
commit | af07eeb04ca9c992b67a59aa8bc10118b610d518 (patch) | |
tree | 48afc86c41b4f6ffe8364bd68b482e4bed5e5afb /tools/perf/util/symbol.h | |
parent | dce0478b5fa05147a69dc6dd6cfcaac2f0e0eb2f (diff) | |
download | blackbird-op-linux-af07eeb04ca9c992b67a59aa8bc10118b610d518.tar.gz blackbird-op-linux-af07eeb04ca9c992b67a59aa8bc10118b610d518.zip |
perf symbols: Remove map_type arg from dso__find_symbol()
One more step to ditch MAP__{VARIABLE,FUNCTION}
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Wang Nan <wangnan0@huawei.com>
Link: https://lkml.kernel.org/n/tip-919d1k13ts62pjipnpibvgwd@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/symbol.h')
-rw-r--r-- | tools/perf/util/symbol.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/tools/perf/util/symbol.h b/tools/perf/util/symbol.h index 924f465307b1..2b985ff2e725 100644 --- a/tools/perf/util/symbol.h +++ b/tools/perf/util/symbol.h @@ -262,10 +262,14 @@ int dso__load_kallsyms(struct dso *dso, const char *filename, struct map *map); void dso__insert_symbol(struct dso *dso, enum map_type type, struct symbol *sym); -struct symbol *dso__find_symbol(struct dso *dso, enum map_type type, - u64 addr); -struct symbol *dso__find_symbol_by_name(struct dso *dso, enum map_type type, - const char *name); +struct symbol *__dso__find_symbol(struct dso *dso, enum map_type type, u64 addr); +struct symbol *__dso__find_symbol_by_name(struct dso *dso, enum map_type type, const char *name); + +static inline struct symbol *dso__find_symbol(struct dso *dso, u64 addr) +{ + return __dso__find_symbol(dso, MAP__FUNCTION, addr); +} + struct symbol *symbol__next_by_name(struct symbol *sym); struct symbol *dso__first_symbol(struct dso *dso); |