summaryrefslogtreecommitdiff
path: root/tools/perf/util/unwind-libdw.c
diff options
context:
space:
mode:
authorIan Rogers <irogers@google.com>2024-07-03 18:17:45 -0700
committerNamhyung Kim <namhyung@kernel.org>2024-07-12 09:38:41 -0700
commit1553419c3c10cf386496e68b90b5d0ce966ac614 (patch)
treee8747f117a878c4d92ef2bd67112f051520549a2 /tools/perf/util/unwind-libdw.c
parent14b0fffa25ce4a9ef5d4448b20b80217b2caa0e8 (diff)
perf dso: Fix address sanitizer build
Various files had been missed from having accessor functions added for the sake of dso reference count checking. Add the function calls and missing dso accessor functions. Fixes: ee756ef7491e ("perf dso: Add reference count checking and accessor functions") Signed-off-by: Ian Rogers <irogers@google.com> Cc: James Clark <james.clark@linaro.org> Cc: Suzuki K Poulose <suzuki.poulose@arm.com> Cc: Yunseong Kim <yskelg@gmail.com> Cc: Will Deacon <will@kernel.org> Cc: Mike Leach <mike.leach@linaro.org> Cc: Leo Yan <leo.yan@linux.dev> Cc: Athira Rajeev <atrajeev@linux.vnet.ibm.com> Cc: John Garry <john.g.garry@oracle.com> Link: https://lore.kernel.org/r/20240704011745.1021288-1-irogers@google.com Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Diffstat (limited to 'tools/perf/util/unwind-libdw.c')
-rw-r--r--tools/perf/util/unwind-libdw.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/tools/perf/util/unwind-libdw.c b/tools/perf/util/unwind-libdw.c
index b38d322734b4..bde216e630d2 100644
--- a/tools/perf/util/unwind-libdw.c
+++ b/tools/perf/util/unwind-libdw.c
@@ -29,8 +29,8 @@ static int __find_debuginfo(Dwfl_Module *mod __maybe_unused, void **userdata,
const struct dso *dso = *userdata;
assert(dso);
- if (dso->symsrc_filename && strcmp (file_name, dso->symsrc_filename))
- *debuginfo_file_name = strdup(dso->symsrc_filename);
+ if (dso__symsrc_filename(dso) && strcmp(file_name, dso__symsrc_filename(dso)))
+ *debuginfo_file_name = strdup(dso__symsrc_filename(dso));
return -1;
}
@@ -66,7 +66,7 @@ static int __report_module(struct addr_location *al, u64 ip,
* a different code in another DSO. So just use the map->start
* directly to pick the correct one.
*/
- if (!strncmp(dso->long_name, "/tmp/jitted-", 12))
+ if (!strncmp(dso__long_name(dso), "/tmp/jitted-", 12))
base = map__start(al->map);
else
base = map__start(al->map) - map__pgoff(al->map);
@@ -83,15 +83,15 @@ static int __report_module(struct addr_location *al, u64 ip,
if (!mod) {
char filename[PATH_MAX];
- __symbol__join_symfs(filename, sizeof(filename), dso->long_name);
- mod = dwfl_report_elf(ui->dwfl, dso->short_name, filename, -1,
+ __symbol__join_symfs(filename, sizeof(filename), dso__long_name(dso));
+ mod = dwfl_report_elf(ui->dwfl, dso__short_name(dso), filename, -1,
base, false);
}
if (!mod) {
char filename[PATH_MAX];
if (dso__build_id_filename(dso, filename, sizeof(filename), false))
- mod = dwfl_report_elf(ui->dwfl, dso->short_name, filename, -1,
+ mod = dwfl_report_elf(ui->dwfl, dso__short_name(dso), filename, -1,
base, false);
}