[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1435162623-20075-1-git-send-email-will.deacon@arm.com>
Date: Wed, 24 Jun 2015 17:17:03 +0100
From: Will Deacon <will.deacon@....com>
To: acme@...hat.com
Cc: linux-kernel@...r.kernel.org, kristina.martsenko@....com,
Will Deacon <will.deacon@....com>,
Vladimir Nikulichev <nvs@...icks.com>,
Adrian Hunter <adrian.hunter@...el.com>,
Namhyung Kim <namhyung@...nel.org>
Subject: [PATCH] perf tools: don't adjust symbols in vDSO
Commit 922d0e4d9f04 ("perf tools: Adjust symbols in VDSO") changed the
ELF symbol parsing so that the vDSO is treated the same as ET_EXEC and
ET_REL binaries despite being an ET_DYN.
This causes objdump, which expects relative addresses, not to produce
any output in conjunction with perf annotate, which cheerfully passes
absolute addresses when trying to disassemble vDSO functions.
This patch avoids marking the vDSO as requiring adjustment of symbol
addresses, allowing the relative program counter to be used instead.
Cc: Vladimir Nikulichev <nvs@...icks.com>
Cc: Adrian Hunter <adrian.hunter@...el.com>
Cc: Namhyung Kim <namhyung@...nel.org>
Reported-by: Kristina Martsenko <kristina.martsenko@....com>
Signed-off-by: Will Deacon <will.deacon@....com>
---
Not sure why I've just started seeing this, but it appears to affect
both x86 and arm64. Also, if I revert the patch above then the issue
it supposedly fixed doesn't resurface. Maybe it was just masking another
bug that has since been addressed?
tools/perf/util/symbol-elf.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/tools/perf/util/symbol-elf.c b/tools/perf/util/symbol-elf.c
index a7ab6063e038..ba4f9bf2765d 100644
--- a/tools/perf/util/symbol-elf.c
+++ b/tools/perf/util/symbol-elf.c
@@ -706,7 +706,6 @@ int symsrc__init(struct symsrc *ss, struct dso *dso, const char *name,
GElf_Shdr shdr;
ss->adjust_symbols = (ehdr.e_type == ET_EXEC ||
ehdr.e_type == ET_REL ||
- dso__is_vdso(dso) ||
elf_section_by_name(elf, &ehdr, &shdr,
".gnu.prelink_undo",
NULL) != NULL);
--
2.1.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists