summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/probe-finder.c
diff options
context:
space:
mode:
authorMasami Hiramatsu2009-11-04 01:12:30 +0100
committerIngo Molnar2009-11-04 13:02:47 +0100
commita225a1d911f0e434dc0407df29fd08e4388f3fa4 (patch)
treed7b298174ffe1ce6d2e849aa89f9ace55e41e419 /tools/perf/util/probe-finder.c
parentperf/probes: Improve error messages (diff)
downloadkernel-qcow2-linux-a225a1d911f0e434dc0407df29fd08e4388f3fa4.tar.gz
kernel-qcow2-linux-a225a1d911f0e434dc0407df29fd08e4388f3fa4.tar.xz
kernel-qcow2-linux-a225a1d911f0e434dc0407df29fd08e4388f3fa4.zip
perf/probes: Fall back to non-dwarf if possible
Fall back to non-dwarf probe point if the probe definition may not need dwarf analysis, when perf can't find vmlinux/debuginfo. This might skip some inlined code of target function. Signed-off-by: Masami Hiramatsu <mhiramat@redhat.com> Acked-by: Frederic Weisbecker <fweisbec@gmail.com> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Jim Keniston <jkenisto@us.ibm.com> Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com> Cc: Christoph Hellwig <hch@infradead.org> Cc: Frank Ch. Eigler <fche@redhat.com> Cc: Jason Baron <jbaron@redhat.com> Cc: K.Prasad <prasad@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Srikar Dronamraju <srikar@linux.vnet.ibm.com> LKML-Reference: <20091104001229.3454.63987.stgit@harusame> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'tools/perf/util/probe-finder.c')
-rw-r--r--tools/perf/util/probe-finder.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/perf/util/probe-finder.c b/tools/perf/util/probe-finder.c
index 35d5a69aaf9b..293cdfc1b8ca 100644
--- a/tools/perf/util/probe-finder.c
+++ b/tools/perf/util/probe-finder.c
@@ -687,8 +687,10 @@ int find_probepoint(int fd, struct probe_point *pp)
struct probe_finder pf = {.pp = pp};
ret = dwarf_init(fd, DW_DLC_READ, 0, 0, &__dw_debug, &__dw_error);
- if (ret != DW_DLV_OK)
- die("No dwarf info found in the vmlinux - please rebuild with CONFIG_DEBUG_INFO.\n");
+ if (ret != DW_DLV_OK) {
+ pr_warning("No dwarf info found in the vmlinux - please rebuild with CONFIG_DEBUG_INFO.\n");
+ return -ENOENT;
+ }
pp->found = 0;
while (++cu_number) {