aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/sort.c
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2018-04-26 12:36:37 -0300
committerArnaldo Carvalho de Melo <acme@redhat.com>2018-04-26 13:47:20 -0300
commitd1fd8d9e6b7b72c8a51bd43b17409c37d82cddef (patch)
treed1c149db1a10111f8838ccac9d5ca3214727282c /tools/perf/util/sort.c
parentperf sort: Use mmap->prot on "dcacheline" formatting (diff)
downloadlinux-dev-d1fd8d9e6b7b72c8a51bd43b17409c37d82cddef.tar.xz
linux-dev-d1fd8d9e6b7b72c8a51bd43b17409c37d82cddef.zip
perf symbols: No need to special case MAP__FUNCTION in fixup
In 39b12f781271 ("perf tools: Make it possible to read object code from vmlinux") we special case MAP__FUNCTION maps inconsistently, the first test tests the map type while the following tests added by this patch don't do that, be consistent and elliminate this special case. 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-khmi5jccpcwqa9nybefluzqp@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/sort.c')
-rw-r--r--tools/perf/util/sort.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/util/sort.c b/tools/perf/util/sort.c
index 49a41b4b59cf..e65903a695a6 100644
--- a/tools/perf/util/sort.c
+++ b/tools/perf/util/sort.c
@@ -282,7 +282,7 @@ static int _hist_entry__sym_snprintf(struct map *map, struct symbol *sym,
ret += repsep_snprintf(bf + ret, size - ret, "[%c] ", level);
if (sym && map) {
- if (map->type == MAP__VARIABLE) {
+ if (sym->type == STT_OBJECT) {
ret += repsep_snprintf(bf + ret, size - ret, "%s", sym->name);
ret += repsep_snprintf(bf + ret, size - ret, "+0x%llx",
ip - map->unmap_ip(map, sym->start));