perf symbols: Fix reading of build-id from vDSO
authorBen Hutchings <ben@decadent.org.uk>
Wed, 13 Jan 2016 17:23:01 +0000 (17:23 +0000)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 15 Jan 2016 19:31:58 +0000 (16:31 -0300)
We need to use the long name (the filename) when reading the build-id
from a DSO.  Using the short name doesn't work for (at least) vDSOs.

Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/20160113172301.GT28542@decadent.org.uk
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/symbol.c

index 3b2de6eb33763b0ab1a23195529fda8d6367eb1d..ab02209a7cf3b162431bfc006287f5fbd8c68f43 100644 (file)
@@ -1466,7 +1466,7 @@ int dso__load(struct dso *dso, struct map *map, symbol_filter_t filter)
         * Read the build id if possible. This is required for
         * DSO_BINARY_TYPE__BUILDID_DEBUGINFO to work
         */
-       if (filename__read_build_id(dso->name, build_id, BUILD_ID_SIZE) > 0)
+       if (filename__read_build_id(dso->long_name, build_id, BUILD_ID_SIZE) > 0)
                dso__set_build_id(dso, build_id);
 
        /*
This page took 0.025008 seconds and 5 git commands to generate.