summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/header.c
diff options
context:
space:
mode:
authorJiri Olsa <jolsa@kernel.org>2016-10-10 09:38:02 +0200
committerArnaldo Carvalho de Melo <acme@redhat.com>2016-10-24 11:07:34 -0300
commit0c2aff4c78e83f3185bf5affa434618815ab77bf (patch)
treef6b829747233e9cf17211fac93a50a2aa2972fde /tools/perf/util/header.c
parentaabae165759994d1b9bca1fac7759f1d8bef5dad (diff)
downloadop-kernel-dev-0c2aff4c78e83f3185bf5affa434618815ab77bf.zip
op-kernel-dev-0c2aff4c78e83f3185bf5affa434618815ab77bf.tar.gz
perf header: Display feature name on write failure
Display name of feature instead of just the number during recording data. Before: failed to write feature 13 Now: failed to write feature HEADER_CPU_TOPOLOGY Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-k9d9trozi5kkx737cy8n5xh5@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/header.c')
-rw-r--r--tools/perf/util/header.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/util/header.c b/tools/perf/util/header.c
index d6310c6..d89c9c7 100644
--- a/tools/perf/util/header.c
+++ b/tools/perf/util/header.c
@@ -2290,7 +2290,7 @@ static int do_write_feat(int fd, struct perf_header *h, int type,
err = feat_ops[type].write(fd, h, evlist);
if (err < 0) {
- pr_debug("failed to write feature %d\n", type);
+ pr_debug("failed to write feature %s\n", feat_ops[type].name);
/* undo anything written */
lseek(fd, (*p)->offset, SEEK_SET);
OpenPOWER on IntegriCloud