From: Robert Richter Date: Thu, 16 Aug 2012 19:10:18 +0000 (+0200) Subject: perf tools: Report number of pmu type of unknown events X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=ca1b145761e9355f90bfae1f42c9d9194702066b;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git perf tools: Report number of pmu type of unknown events If detection fails and an event name is unknown, report the type number. Example perf header output: # Samples: 10K of event 'unknown attr type: 7' Signed-off-by: Robert Richter Cc: Ingo Molnar Cc: Jiri Olsa Cc: Peter Zijlstra Link: http://lkml.kernel.org/r/1345144224-27280-3-git-send-email-robert.richter@amd.com Signed-off-by: Arnaldo Carvalho de Melo --- diff --git a/tools/perf/util/evsel.c b/tools/perf/util/evsel.c index 6c7dcc1fde5a..7ff3c8fb736c 100644 --- a/tools/perf/util/evsel.c +++ b/tools/perf/util/evsel.c @@ -319,7 +319,8 @@ const char *perf_evsel__name(struct perf_evsel *evsel) break; default: - scnprintf(bf, sizeof(bf), "%s", "unknown attr type"); + scnprintf(bf, sizeof(bf), "unknown attr type: %d", + evsel->attr.type); break; }