aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/session.c
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2010-12-07 07:48:53 -0500
committerArnaldo Carvalho de Melo <acme@redhat.com>2010-12-09 09:09:51 -0500
commitf74725dcf2f6931c26bc65e77e34e693eeb8441c (patch)
treebee0c22121538824e9e0cbfb3ea7a660717c3d0e /tools/perf/util/session.c
parente4c2df132fef60a28b851abc1859a531e64f350c (diff)
perf session: Add file_offset to event delivery function
Preparatory patch for ordered output of perf report -D Acked-by: Ian Munsie <imunsie@au1.ibm.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ian Munsie <imunsie@au1.ibm.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Peter Zijlstra <peterz@infradead.org> LKML-Reference: <20101207124550.818568607@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/session.c')
-rw-r--r--tools/perf/util/session.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/tools/perf/util/session.c b/tools/perf/util/session.c
index a4339548de67..d43e56cd6f28 100644
--- a/tools/perf/util/session.c
+++ b/tools/perf/util/session.c
@@ -465,7 +465,8 @@ static void perf_session_free_sample_buffers(struct perf_session *session)
465static int perf_session_deliver_event(struct perf_session *session, 465static int perf_session_deliver_event(struct perf_session *session,
466 event_t *event, 466 event_t *event,
467 struct sample_data *sample, 467 struct sample_data *sample,
468 struct perf_event_ops *ops); 468 struct perf_event_ops *ops,
469 u64 file_offset);
469 470
470static void flush_sample_queue(struct perf_session *s, 471static void flush_sample_queue(struct perf_session *s,
471 struct perf_event_ops *ops) 472 struct perf_event_ops *ops)
@@ -485,7 +486,8 @@ static void flush_sample_queue(struct perf_session *s,
485 break; 486 break;
486 487
487 event__parse_sample(iter->event, s, &sample); 488 event__parse_sample(iter->event, s, &sample);
488 perf_session_deliver_event(s, iter->event, &sample, ops); 489 perf_session_deliver_event(s, iter->event, &sample, ops,
490 iter->file_offset);
489 491
490 os->last_flush = iter->timestamp; 492 os->last_flush = iter->timestamp;
491 list_del(&iter->list); 493 list_del(&iter->list);
@@ -699,7 +701,8 @@ static void dump_sample(struct perf_session *session, event_t *event,
699static int perf_session_deliver_event(struct perf_session *session, 701static int perf_session_deliver_event(struct perf_session *session,
700 event_t *event, 702 event_t *event,
701 struct sample_data *sample, 703 struct sample_data *sample,
702 struct perf_event_ops *ops) 704 struct perf_event_ops *ops,
705 u64 file_offset __used)
703{ 706{
704 switch (event->header.type) { 707 switch (event->header.type) {
705 case PERF_RECORD_SAMPLE: 708 case PERF_RECORD_SAMPLE:
@@ -788,7 +791,8 @@ static int perf_session__process_event(struct perf_session *session,
788 return ret; 791 return ret;
789 } 792 }
790 793
791 return perf_session_deliver_event(session, event, &sample, ops); 794 return perf_session_deliver_event(session, event, &sample, ops,
795 file_offset);
792} 796}
793 797
794void perf_event_header__bswap(struct perf_event_header *self) 798void perf_event_header__bswap(struct perf_event_header *self)