summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/probe-finder.c
diff options
context:
space:
mode:
authorBrian Norris <computersforpeace@gmail.com>2014-07-21 08:59:16 +0200
committerBrian Norris <computersforpeace@gmail.com>2014-07-21 09:01:16 +0200
commitd0d5864676dbccfb1337864a0ae6ce97e6342678 (patch)
tree7caa674ec05a1797054cd4304f0a047b6dacddd6 /tools/perf/util/probe-finder.c
parentmtd: cfi_cmdset_0002: fix do_write_buffer() timeout error (diff)
parentLinux 3.16-rc6 (diff)
downloadlinux-d0d5864676dbccfb1337864a0ae6ce97e6342678.tar.xz
linux-d0d5864676dbccfb1337864a0ae6ce97e6342678.zip
Merge tag 'v3.16-rc6' into MTD development branch
Linux 3.16-rc6
Diffstat (limited to 'tools/perf/util/probe-finder.c')
-rw-r--r--tools/perf/util/probe-finder.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/tools/perf/util/probe-finder.c b/tools/perf/util/probe-finder.c
index 9d8eb26f0533..98e304766416 100644
--- a/tools/perf/util/probe-finder.c
+++ b/tools/perf/util/probe-finder.c
@@ -573,14 +573,13 @@ static int find_variable(Dwarf_Die *sc_die, struct probe_finder *pf)
if (!die_find_variable_at(sc_die, pf->pvar->var, pf->addr, &vr_die)) {
/* Search again in global variables */
if (!die_find_variable_at(&pf->cu_die, pf->pvar->var, 0, &vr_die))
+ pr_warning("Failed to find '%s' in this function.\n",
+ pf->pvar->var);
ret = -ENOENT;
}
if (ret >= 0)
ret = convert_variable(&vr_die, pf);
- if (ret < 0)
- pr_warning("Failed to find '%s' in this function.\n",
- pf->pvar->var);
return ret;
}
@@ -1281,7 +1280,11 @@ out:
return ret;
}
-/* Find available variables at given probe point */
+/*
+ * Find available variables at given probe point
+ * Return the number of found probe points. Return 0 if there is no
+ * matched probe point. Return <0 if an error occurs.
+ */
int debuginfo__find_available_vars_at(struct debuginfo *dbg,
struct perf_probe_event *pev,
struct variable_list **vls,