[patch 2/9] perf: session: Dont queue events w/o timestamps

From: Thomas Gleixner
Date: Tue Dec 07 2010 - 07:51:26 EST


If the event has no timestamp assigned then the parse code sets it to
~0ULL which causes the ordering code to enqueue it at the end.

Process it right away.

Reported-by: Ian Munsie <imunsie@xxxxxxxxxxx>
Signed-off-by: Thomas Gleixner <tglx@xxxxxxxxxxxxx>
---
tools/perf/util/session.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

Index: linux-2.6-tip/tools/perf/util/session.c
===================================================================
--- linux-2.6-tip.orig/tools/perf/util/session.c
+++ linux-2.6-tip/tools/perf/util/session.c
@@ -603,7 +603,7 @@ static int perf_session_queue_event(stru
u64 timestamp = data->time;
struct sample_queue *new;

- if (!timestamp)
+ if (!timestamp || timestamp == ~0ULL)
return -ETIME;

if (timestamp < s->ordered_samples.last_flush) {


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/