diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2010-01-15 15:08:27 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2010-01-16 04:58:50 -0500 |
commit | 881516eb828a3f7276c378bcef96b7788fc99016 (patch) | |
tree | e0fc433a53dc610f51eeb1b9130e3b745575a25e /tools | |
parent | f5a2c3dce03621b55f84496f58adc2d1a87ca16f (diff) |
perf symbols: Accept an alias when looking for "_text"
As it is in PARISC64:
parisc:~# uname -a
Linux parisc 2.6.33-rc4-tip+ #1 SMP Thu Jan 14 13:33:34 BRST
2010 parisc64 GNU/Linux parisc:~# grep -w _text /proc/kallsyms
0000000040100000 A _text
parisc:~# grep 0000000040100000 /proc/kallsyms
0000000040100000 T stext
0000000040100000 T _stext
0000000040100000 A _text
parisc:~#
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Frédéric Weisbecker <fweisbec@gmail.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Paul Mackerras <paulus@samba.org>
LKML-Reference: <1263586107-1756-2-git-send-email-acme@infradead.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'tools')
-rw-r--r-- | tools/perf/util/event.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/perf/util/event.c b/tools/perf/util/event.c index 966d207a1509..dc13cad828d7 100644 --- a/tools/perf/util/event.c +++ b/tools/perf/util/event.c | |||
@@ -227,7 +227,12 @@ static int find_symbol_cb(void *arg, const char *name, char type, u64 start) | |||
227 | { | 227 | { |
228 | struct process_symbol_args *args = arg; | 228 | struct process_symbol_args *args = arg; |
229 | 229 | ||
230 | if (!symbol_type__is_a(type, MAP__FUNCTION) || strcmp(name, args->name)) | 230 | /* |
231 | * Must be a function or at least an alias, as in PARISC64, where "_text" is | ||
232 | * an 'A' to the same address as "_stext". | ||
233 | */ | ||
234 | if (!(symbol_type__is_a(type, MAP__FUNCTION) || | ||
235 | type == 'A') || strcmp(name, args->name)) | ||
231 | return 0; | 236 | return 0; |
232 | 237 | ||
233 | args->start = start; | 238 | args->start = start; |