diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2010-03-30 17:27:39 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2010-05-13 01:55:29 -0400 |
commit | 46db2c3205ca6e24adbb9b038441bc8f65360535 (patch) | |
tree | 28a70cdb69e82795b699d3184f51faf7903d1088 /tools | |
parent | 829e92458532b1dbfeb972435d45bb060cdbf5a3 (diff) |
perf record: Add a fallback to the reference relocation symbol
Usually "_text" is enough, but I received reports that its not always
available, so fallback to "_stext" for the symbol we use to check if we
need to apply any relocation to all the symbols in the kernel symtab,
for when, for instance, kexec is being used.
Reported-by: Darren Hart <dvhltc@us.ibm.com>
Reported-by: Steven Rostedt <rostedt@goodmis.org>
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>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'tools')
-rw-r--r-- | tools/perf/builtin-record.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tools/perf/builtin-record.c b/tools/perf/builtin-record.c index 3b8b6387c47c..f1411e9cdf47 100644 --- a/tools/perf/builtin-record.c +++ b/tools/perf/builtin-record.c | |||
@@ -563,6 +563,9 @@ static int __cmd_record(int argc, const char **argv) | |||
563 | 563 | ||
564 | err = event__synthesize_kernel_mmap(process_synthesized_event, | 564 | err = event__synthesize_kernel_mmap(process_synthesized_event, |
565 | session, "_text"); | 565 | session, "_text"); |
566 | if (err < 0) | ||
567 | err = event__synthesize_kernel_mmap(process_synthesized_event, | ||
568 | session, "_stext"); | ||
566 | if (err < 0) { | 569 | if (err < 0) { |
567 | pr_err("Couldn't record kernel reference relocation symbol.\n"); | 570 | pr_err("Couldn't record kernel reference relocation symbol.\n"); |
568 | return err; | 571 | return err; |