aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tools/perf/builtin-record.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/tools/perf/builtin-record.c b/tools/perf/builtin-record.c
index 42e24149c791..1a9098c697b4 100644
--- a/tools/perf/builtin-record.c
+++ b/tools/perf/builtin-record.c
@@ -242,9 +242,13 @@ try_again:
242 /* 242 /*
243 * If it's cycles then fall back to hrtimer 243 * If it's cycles then fall back to hrtimer
244 * based cpu-clock-tick sw counter, which 244 * based cpu-clock-tick sw counter, which
245 * is always available even if no PMU support: 245 * is always available even if no PMU support.
246 *
247 * PPC returns ENXIO until 2.6.37 (behavior changed
248 * with commit b0a873e).
246 */ 249 */
247 if (err == ENOENT && attr->type == PERF_TYPE_HARDWARE 250 if ((err == ENOENT || err == ENXIO)
251 && attr->type == PERF_TYPE_HARDWARE
248 && attr->config == PERF_COUNT_HW_CPU_CYCLES) { 252 && attr->config == PERF_COUNT_HW_CPU_CYCLES) {
249 253
250 if (verbose) 254 if (verbose)