perf evlist: Steal mmap reading routine from 'perf top'
Will be used in the upcoming 'perf test' entry for the evlist mmap
routines.
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Cc: Tom Zanussi <tzanussi@gmail.com>
LKML-Reference: <new-submission>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
diff --git a/tools/perf/util/evlist.h b/tools/perf/util/evlist.h
index dbfcc79..2871206 100644
--- a/tools/perf/util/evlist.h
+++ b/tools/perf/util/evlist.h
@@ -3,6 +3,7 @@
#include <linux/list.h>
#include "../perf.h"
+#include "event.h"
struct pollfd;
@@ -15,6 +16,7 @@
int nr_entries;
int nr_fds;
int mmap_len;
+ event_t event_copy;
struct perf_mmap *mmap;
struct pollfd *pollfd;
};
@@ -32,4 +34,6 @@
struct perf_evsel *perf_evlist__id2evsel(struct perf_evlist *evlist, u64 id);
+event_t *perf_evlist__read_on_cpu(struct perf_evlist *self, int cpu);
+
#endif /* __PERF_EVLIST_H */