aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/python.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf/util/python.c')
-rw-r--r--tools/perf/util/python.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/tools/perf/util/python.c b/tools/perf/util/python.c
index 71b5412bbbb9..4bf8ace7f511 100644
--- a/tools/perf/util/python.c
+++ b/tools/perf/util/python.c
@@ -33,13 +33,6 @@ int eprintf(int level, const char *fmt, ...)
33# define PyVarObject_HEAD_INIT(type, size) PyObject_HEAD_INIT(type) size, 33# define PyVarObject_HEAD_INIT(type, size) PyObject_HEAD_INIT(type) size,
34#endif 34#endif
35 35
36struct throttle_event {
37 struct perf_event_header header;
38 u64 time;
39 u64 id;
40 u64 stream_id;
41};
42
43PyMODINIT_FUNC initperf(void); 36PyMODINIT_FUNC initperf(void);
44 37
45#define member_def(type, member, ptype, help) \ 38#define member_def(type, member, ptype, help) \
@@ -822,6 +815,8 @@ static PyObject *pyrf_evlist__read_on_cpu(struct pyrf_evlist *pevlist,
822 PyObject *pyevent = pyrf_event__new(event); 815 PyObject *pyevent = pyrf_event__new(event);
823 struct pyrf_event *pevent = (struct pyrf_event *)pyevent; 816 struct pyrf_event *pevent = (struct pyrf_event *)pyevent;
824 817
818 perf_evlist__mmap_consume(evlist, cpu);
819
825 if (pyevent == NULL) 820 if (pyevent == NULL)
826 return PyErr_NoMemory(); 821 return PyErr_NoMemory();
827 822
@@ -1036,6 +1031,7 @@ PyMODINIT_FUNC initperf(void)
1036 pyrf_cpu_map__setup_types() < 0) 1031 pyrf_cpu_map__setup_types() < 0)
1037 return; 1032 return;
1038 1033
1034 /* The page_size is placed in util object. */
1039 page_size = sysconf(_SC_PAGE_SIZE); 1035 page_size = sysconf(_SC_PAGE_SIZE);
1040 1036
1041 Py_INCREF(&pyrf_evlist__type); 1037 Py_INCREF(&pyrf_evlist__type);