Skip to contentSkip to conversation

perf script: Fix event ordering settings to work with older kernels

tip:perf/core tip-bot for Arnaldo Carvalho de Melo 1 participant 1 message Jan 4, 2011 perf events

lore
Share & tools
lore
#0 lore raw
Commit-ID:  ce0ac9e1851364fa67c991659ce1db05ab82c6ae
Gitweb:     http://git.kernel.org/tip/ce0ac9e1851364fa67c991659ce1db05ab82c6ae
Author:     Arnaldo Carvalho de Melo <[email protected]>
AuthorDate: Sat, 25 Dec 2010 18:33:12 -0200
Committer:  Arnaldo Carvalho de Melo <[email protected]>
CommitDate: Sat, 25 Dec 2010 18:33:12 -0200

perf script: Fix event ordering settings to work with older kernels

If we don't use .ordering_requires_timestamps we'll end up trying to order events with no timestamps when running on older kernels.

Problem introduced in eac23d1c.

After the last three fixes, perf scripting is back working, tested with new perf userspace on old and new (with sample_id_all) kernels.

Cc: Frederic Weisbecker <[email protected]>
Cc: Ian Munsie <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: Mike Galbraith <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Cc: Stephane Eranian <[email protected]>
Cc: Tom Zanussi <[email protected]>
Cc: Torok Edwin <[email protected]>
LKML-Reference: <new-submission>

---
 tools/perf/builtin-script.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
tools/perf/builtin-script.c +1 -0
index 6ef65c0..43480fd 100644
@@ -117,6 +117,7 @@ static struct perf_event_ops event_ops = {
 	.tracing_data = event__process_tracing_data,
 	.build_id = event__process_build_id,
 	.lost = process_lost_event,
+	.ordering_requires_timestamps = true,
 	.ordered_samples = true,
 };