diff options
author | Ian Rogers <irogers@google.com> | 2024-07-03 18:17:45 -0700 |
---|---|---|
committer | Namhyung Kim <namhyung@kernel.org> | 2024-07-12 09:38:41 -0700 |
commit | 1553419c3c10cf386496e68b90b5d0ce966ac614 (patch) | |
tree | e8747f117a878c4d92ef2bd67112f051520549a2 /tools/perf/util/disasm.c | |
parent | 14b0fffa25ce4a9ef5d4448b20b80217b2caa0e8 (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/disasm.c')
-rw-r--r-- | tools/perf/util/disasm.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tools/perf/util/disasm.c b/tools/perf/util/disasm.c index 72aec8f61b94..e10558b79504 100644 --- a/tools/perf/util/disasm.c +++ b/tools/perf/util/disasm.c @@ -1199,7 +1199,7 @@ static int symbol__disassemble_bpf(struct symbol *sym, int ret; FILE *s; - if (dso->binary_type != DSO_BINARY_TYPE__BPF_PROG_INFO) + if (dso__binary_type(dso) != DSO_BINARY_TYPE__BPF_PROG_INFO) return SYMBOL_ANNOTATE_ERRNO__BPF_INVALID_FILE; pr_debug("%s: handling sym %s addr %" PRIx64 " len %" PRIx64 "\n", __func__, @@ -1226,14 +1226,14 @@ static int symbol__disassemble_bpf(struct symbol *sym, info.arch = bfd_get_arch(bfdf); info.mach = bfd_get_mach(bfdf); - info_node = perf_env__find_bpf_prog_info(dso->bpf_prog.env, - dso->bpf_prog.id); + info_node = perf_env__find_bpf_prog_info(dso__bpf_prog(dso)->env, + dso__bpf_prog(dso)->id); if (!info_node) { ret = SYMBOL_ANNOTATE_ERRNO__BPF_MISSING_BTF; goto out; } info_linear = info_node->info_linear; - sub_id = dso->bpf_prog.sub_id; + sub_id = dso__bpf_prog(dso)->sub_id; info.buffer = (void *)(uintptr_t)(info_linear->info.jited_prog_insns); info.buffer_length = info_linear->info.jited_prog_len; @@ -1244,7 +1244,7 @@ static int symbol__disassemble_bpf(struct symbol *sym, if (info_linear->info.btf_id) { struct btf_node *node; - node = perf_env__find_btf(dso->bpf_prog.env, + node = perf_env__find_btf(dso__bpf_prog(dso)->env, info_linear->info.btf_id); if (node) btf = btf__new((__u8 *)(node->data), |