aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorJiri Olsa <jolsa@kernel.org>2019-07-28 06:45:35 -0400
committerArnaldo Carvalho de Melo <acme@redhat.com>2019-09-25 08:51:44 -0400
commit9521b5f2d9d3e3fd6092fb9d7b00c914e7fa7d33 (patch)
tree9d6f1bb10838a772250f827006999c8d01bbb10c /tools
parenta583053299c1e66e6202b494cbc3acd93cedc4cc (diff)
perf tools: Rename perf_evlist__mmap() to evlist__mmap()
Rename perf_evlist__mmap() to evlist__mmap(), so we don't have a name clash when we add perf_evlist__mmap() in libperf. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Michael Petlan <mpetlan@redhat.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lore.kernel.org/lkml/20190913132355.21634-5-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/perf/arch/x86/tests/perf-time-to-tsc.c2
-rw-r--r--tools/perf/builtin-kvm.c2
-rw-r--r--tools/perf/builtin-record.c6
-rw-r--r--tools/perf/builtin-top.c2
-rw-r--r--tools/perf/builtin-trace.c2
-rw-r--r--tools/perf/tests/backward-ring-buffer.c4
-rw-r--r--tools/perf/tests/bpf.c4
-rw-r--r--tools/perf/tests/code-reading.c4
-rw-r--r--tools/perf/tests/keep-tracking.c2
-rw-r--r--tools/perf/tests/mmap-basic.c2
-rw-r--r--tools/perf/tests/openat-syscall-tp-fields.c4
-rw-r--r--tools/perf/tests/perf-record.c4
-rw-r--r--tools/perf/tests/sw-clock.c2
-rw-r--r--tools/perf/tests/switch-tracking.c4
-rw-r--r--tools/perf/tests/task-exit.c2
-rw-r--r--tools/perf/util/evlist.c30
-rw-r--r--tools/perf/util/evlist.h8
-rw-r--r--tools/perf/util/python.c2
18 files changed, 43 insertions, 43 deletions
diff --git a/tools/perf/arch/x86/tests/perf-time-to-tsc.c b/tools/perf/arch/x86/tests/perf-time-to-tsc.c
index c83abb1ed0ff..42ae47525a76 100644
--- a/tools/perf/arch/x86/tests/perf-time-to-tsc.c
+++ b/tools/perf/arch/x86/tests/perf-time-to-tsc.c
@@ -90,7 +90,7 @@ int test__perf_time_to_tsc(struct test *test __maybe_unused, int subtest __maybe
90 90
91 CHECK__(evlist__open(evlist)); 91 CHECK__(evlist__open(evlist));
92 92
93 CHECK__(perf_evlist__mmap(evlist, UINT_MAX)); 93 CHECK__(evlist__mmap(evlist, UINT_MAX));
94 94
95 pc = evlist->mmap[0].base; 95 pc = evlist->mmap[0].base;
96 ret = perf_read_tsc_conversion(pc, &tc); 96 ret = perf_read_tsc_conversion(pc, &tc);
diff --git a/tools/perf/builtin-kvm.c b/tools/perf/builtin-kvm.c
index 7354b77e9137..72debb7bd20d 100644
--- a/tools/perf/builtin-kvm.c
+++ b/tools/perf/builtin-kvm.c
@@ -1060,7 +1060,7 @@ static int kvm_live_open_events(struct perf_kvm_stat *kvm)
1060 goto out; 1060 goto out;
1061 } 1061 }
1062 1062
1063 if (perf_evlist__mmap(evlist, kvm->opts.mmap_pages) < 0) { 1063 if (evlist__mmap(evlist, kvm->opts.mmap_pages) < 0) {
1064 ui__error("Failed to mmap the events: %s\n", 1064 ui__error("Failed to mmap the events: %s\n",
1065 str_error_r(errno, sbuf, sizeof(sbuf))); 1065 str_error_r(errno, sbuf, sizeof(sbuf)));
1066 evlist__close(evlist); 1066 evlist__close(evlist);
diff --git a/tools/perf/builtin-record.c b/tools/perf/builtin-record.c
index 1528fb686f96..093d9ab5633e 100644
--- a/tools/perf/builtin-record.c
+++ b/tools/perf/builtin-record.c
@@ -439,7 +439,7 @@ static int record__mmap_flush_parse(const struct option *opt,
439 if (!opts->mmap_flush) 439 if (!opts->mmap_flush)
440 opts->mmap_flush = MMAP_FLUSH_DEFAULT; 440 opts->mmap_flush = MMAP_FLUSH_DEFAULT;
441 441
442 flush_max = perf_evlist__mmap_size(opts->mmap_pages); 442 flush_max = evlist__mmap_size(opts->mmap_pages);
443 flush_max /= 4; 443 flush_max /= 4;
444 if (opts->mmap_flush > flush_max) 444 if (opts->mmap_flush > flush_max)
445 opts->mmap_flush = flush_max; 445 opts->mmap_flush = flush_max;
@@ -707,7 +707,7 @@ static int record__mmap_evlist(struct record *rec,
707 if (opts->affinity != PERF_AFFINITY_SYS) 707 if (opts->affinity != PERF_AFFINITY_SYS)
708 cpu__setup_cpunode_map(); 708 cpu__setup_cpunode_map();
709 709
710 if (perf_evlist__mmap_ex(evlist, opts->mmap_pages, 710 if (evlist__mmap_ex(evlist, opts->mmap_pages,
711 opts->auxtrace_mmap_pages, 711 opts->auxtrace_mmap_pages,
712 opts->auxtrace_snapshot_mode, 712 opts->auxtrace_snapshot_mode,
713 opts->nr_cblocks, opts->affinity, 713 opts->nr_cblocks, opts->affinity,
@@ -1980,7 +1980,7 @@ out_free:
1980 1980
1981static void switch_output_size_warn(struct record *rec) 1981static void switch_output_size_warn(struct record *rec)
1982{ 1982{
1983 u64 wakeup_size = perf_evlist__mmap_size(rec->opts.mmap_pages); 1983 u64 wakeup_size = evlist__mmap_size(rec->opts.mmap_pages);
1984 struct switch_output *s = &rec->switch_output; 1984 struct switch_output *s = &rec->switch_output;
1985 1985
1986 wakeup_size /= 2; 1986 wakeup_size /= 2;
diff --git a/tools/perf/builtin-top.c b/tools/perf/builtin-top.c
index 834a927107c4..771b3ff47dc3 100644
--- a/tools/perf/builtin-top.c
+++ b/tools/perf/builtin-top.c
@@ -1042,7 +1042,7 @@ try_again:
1042 } 1042 }
1043 } 1043 }
1044 1044
1045 if (perf_evlist__mmap(evlist, opts->mmap_pages) < 0) { 1045 if (evlist__mmap(evlist, opts->mmap_pages) < 0) {
1046 ui__error("Failed to mmap with %d (%s)\n", 1046 ui__error("Failed to mmap with %d (%s)\n",
1047 errno, str_error_r(errno, msg, sizeof(msg))); 1047 errno, str_error_r(errno, msg, sizeof(msg)));
1048 goto out_err; 1048 goto out_err;
diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
index 2f853870d68d..ff989351567d 100644
--- a/tools/perf/builtin-trace.c
+++ b/tools/perf/builtin-trace.c
@@ -3409,7 +3409,7 @@ static int trace__run(struct trace *trace, int argc, const char **argv)
3409 if (trace->dump.map) 3409 if (trace->dump.map)
3410 bpf_map__fprintf(trace->dump.map, trace->output); 3410 bpf_map__fprintf(trace->dump.map, trace->output);
3411 3411
3412 err = perf_evlist__mmap(evlist, trace->opts.mmap_pages); 3412 err = evlist__mmap(evlist, trace->opts.mmap_pages);
3413 if (err < 0) 3413 if (err < 0)
3414 goto out_error_mmap; 3414 goto out_error_mmap;
3415 3415
diff --git a/tools/perf/tests/backward-ring-buffer.c b/tools/perf/tests/backward-ring-buffer.c
index 0a046096e6f4..f1eb7e9c1d7d 100644
--- a/tools/perf/tests/backward-ring-buffer.c
+++ b/tools/perf/tests/backward-ring-buffer.c
@@ -63,9 +63,9 @@ static int do_test(struct evlist *evlist, int mmap_pages,
63 int err; 63 int err;
64 char sbuf[STRERR_BUFSIZE]; 64 char sbuf[STRERR_BUFSIZE];
65 65
66 err = perf_evlist__mmap(evlist, mmap_pages); 66 err = evlist__mmap(evlist, mmap_pages);
67 if (err < 0) { 67 if (err < 0) {
68 pr_debug("perf_evlist__mmap: %s\n", 68 pr_debug("evlist__mmap: %s\n",
69 str_error_r(errno, sbuf, sizeof(sbuf))); 69 str_error_r(errno, sbuf, sizeof(sbuf)));
70 return TEST_FAIL; 70 return TEST_FAIL;
71 } 71 }
diff --git a/tools/perf/tests/bpf.c b/tools/perf/tests/bpf.c
index cf9776aceb82..964731915498 100644
--- a/tools/perf/tests/bpf.c
+++ b/tools/perf/tests/bpf.c
@@ -167,9 +167,9 @@ static int do_test(struct bpf_object *obj, int (*func)(void),
167 goto out_delete_evlist; 167 goto out_delete_evlist;
168 } 168 }
169 169
170 err = perf_evlist__mmap(evlist, opts.mmap_pages); 170 err = evlist__mmap(evlist, opts.mmap_pages);
171 if (err < 0) { 171 if (err < 0) {
172 pr_debug("perf_evlist__mmap: %s\n", 172 pr_debug("evlist__mmap: %s\n",
173 str_error_r(errno, sbuf, sizeof(sbuf))); 173 str_error_r(errno, sbuf, sizeof(sbuf)));
174 goto out_delete_evlist; 174 goto out_delete_evlist;
175 } 175 }
diff --git a/tools/perf/tests/code-reading.c b/tools/perf/tests/code-reading.c
index df96cbb9ffe5..413783b69006 100644
--- a/tools/perf/tests/code-reading.c
+++ b/tools/perf/tests/code-reading.c
@@ -685,9 +685,9 @@ static int do_test_code_reading(bool try_kcore)
685 break; 685 break;
686 } 686 }
687 687
688 ret = perf_evlist__mmap(evlist, UINT_MAX); 688 ret = evlist__mmap(evlist, UINT_MAX);
689 if (ret < 0) { 689 if (ret < 0) {
690 pr_debug("perf_evlist__mmap failed\n"); 690 pr_debug("evlist__mmap failed\n");
691 goto out_put; 691 goto out_put;
692 } 692 }
693 693
diff --git a/tools/perf/tests/keep-tracking.c b/tools/perf/tests/keep-tracking.c
index 67a87f507bbd..8e2ec5f72042 100644
--- a/tools/perf/tests/keep-tracking.c
+++ b/tools/perf/tests/keep-tracking.c
@@ -104,7 +104,7 @@ int test__keep_tracking(struct test *test __maybe_unused, int subtest __maybe_un
104 goto out_err; 104 goto out_err;
105 } 105 }
106 106
107 CHECK__(perf_evlist__mmap(evlist, UINT_MAX)); 107 CHECK__(evlist__mmap(evlist, UINT_MAX));
108 108
109 /* 109 /*
110 * First, test that a 'comm' event can be found when the event is 110 * First, test that a 'comm' event can be found when the event is
diff --git a/tools/perf/tests/mmap-basic.c b/tools/perf/tests/mmap-basic.c
index accca3d78fa3..4d42e455feb7 100644
--- a/tools/perf/tests/mmap-basic.c
+++ b/tools/perf/tests/mmap-basic.c
@@ -99,7 +99,7 @@ int test__basic_mmap(struct test *test __maybe_unused, int subtest __maybe_unuse
99 expected_nr_events[i] = 1 + rand() % 127; 99 expected_nr_events[i] = 1 + rand() % 127;
100 } 100 }
101 101
102 if (perf_evlist__mmap(evlist, 128) < 0) { 102 if (evlist__mmap(evlist, 128) < 0) {
103 pr_debug("failed to mmap events: %d (%s)\n", errno, 103 pr_debug("failed to mmap events: %d (%s)\n", errno,
104 str_error_r(errno, sbuf, sizeof(sbuf))); 104 str_error_r(errno, sbuf, sizeof(sbuf)));
105 goto out_delete_evlist; 105 goto out_delete_evlist;
diff --git a/tools/perf/tests/openat-syscall-tp-fields.c b/tools/perf/tests/openat-syscall-tp-fields.c
index e5ef74d4e925..5c2576174ae9 100644
--- a/tools/perf/tests/openat-syscall-tp-fields.c
+++ b/tools/perf/tests/openat-syscall-tp-fields.c
@@ -69,9 +69,9 @@ int test__syscall_openat_tp_fields(struct test *test __maybe_unused, int subtest
69 goto out_delete_evlist; 69 goto out_delete_evlist;
70 } 70 }
71 71
72 err = perf_evlist__mmap(evlist, UINT_MAX); 72 err = evlist__mmap(evlist, UINT_MAX);
73 if (err < 0) { 73 if (err < 0) {
74 pr_debug("perf_evlist__mmap: %s\n", 74 pr_debug("evlist__mmap: %s\n",
75 str_error_r(errno, sbuf, sizeof(sbuf))); 75 str_error_r(errno, sbuf, sizeof(sbuf)));
76 goto out_delete_evlist; 76 goto out_delete_evlist;
77 } 77 }
diff --git a/tools/perf/tests/perf-record.c b/tools/perf/tests/perf-record.c
index 49d2d4c5956d..669fd88e7f30 100644
--- a/tools/perf/tests/perf-record.c
+++ b/tools/perf/tests/perf-record.c
@@ -143,9 +143,9 @@ int test__PERF_RECORD(struct test *test __maybe_unused, int subtest __maybe_unus
143 * fds in the same CPU to be injected in the same mmap ring buffer 143 * fds in the same CPU to be injected in the same mmap ring buffer
144 * (using ioctl(PERF_EVENT_IOC_SET_OUTPUT)). 144 * (using ioctl(PERF_EVENT_IOC_SET_OUTPUT)).
145 */ 145 */
146 err = perf_evlist__mmap(evlist, opts.mmap_pages); 146 err = evlist__mmap(evlist, opts.mmap_pages);
147 if (err < 0) { 147 if (err < 0) {
148 pr_debug("perf_evlist__mmap: %s\n", 148 pr_debug("evlist__mmap: %s\n",
149 str_error_r(errno, sbuf, sizeof(sbuf))); 149 str_error_r(errno, sbuf, sizeof(sbuf)));
150 goto out_delete_evlist; 150 goto out_delete_evlist;
151 } 151 }
diff --git a/tools/perf/tests/sw-clock.c b/tools/perf/tests/sw-clock.c
index 7abe0b6aabb7..fbff60815be8 100644
--- a/tools/perf/tests/sw-clock.c
+++ b/tools/perf/tests/sw-clock.c
@@ -82,7 +82,7 @@ static int __test__sw_clock_freq(enum perf_sw_ids clock_id)
82 goto out_delete_evlist; 82 goto out_delete_evlist;
83 } 83 }
84 84
85 err = perf_evlist__mmap(evlist, 128); 85 err = evlist__mmap(evlist, 128);
86 if (err < 0) { 86 if (err < 0) {
87 pr_debug("failed to mmap event: %d (%s)\n", errno, 87 pr_debug("failed to mmap event: %d (%s)\n", errno,
88 str_error_r(errno, sbuf, sizeof(sbuf))); 88 str_error_r(errno, sbuf, sizeof(sbuf)));
diff --git a/tools/perf/tests/switch-tracking.c b/tools/perf/tests/switch-tracking.c
index e7888ddd69a3..c92e287e0f53 100644
--- a/tools/perf/tests/switch-tracking.c
+++ b/tools/perf/tests/switch-tracking.c
@@ -460,9 +460,9 @@ int test__switch_tracking(struct test *test __maybe_unused, int subtest __maybe_
460 goto out; 460 goto out;
461 } 461 }
462 462
463 err = perf_evlist__mmap(evlist, UINT_MAX); 463 err = evlist__mmap(evlist, UINT_MAX);
464 if (err) { 464 if (err) {
465 pr_debug("perf_evlist__mmap failed!\n"); 465 pr_debug("evlist__mmap failed!\n");
466 goto out_err; 466 goto out_err;
467 } 467 }
468 468
diff --git a/tools/perf/tests/task-exit.c b/tools/perf/tests/task-exit.c
index cff99707cc9d..718838b5e724 100644
--- a/tools/perf/tests/task-exit.c
+++ b/tools/perf/tests/task-exit.c
@@ -106,7 +106,7 @@ int test__task_exit(struct test *test __maybe_unused, int subtest __maybe_unused
106 goto out_delete_evlist; 106 goto out_delete_evlist;
107 } 107 }
108 108
109 if (perf_evlist__mmap(evlist, 128) < 0) { 109 if (evlist__mmap(evlist, 128) < 0) {
110 pr_debug("failed to mmap events: %d (%s)\n", errno, 110 pr_debug("failed to mmap events: %d (%s)\n", errno,
111 str_error_r(errno, sbuf, sizeof(sbuf))); 111 str_error_r(errno, sbuf, sizeof(sbuf)));
112 goto out_delete_evlist; 112 goto out_delete_evlist;
diff --git a/tools/perf/util/evlist.c b/tools/perf/util/evlist.c
index ceab9fb7f7f9..e8afe4fdc1b2 100644
--- a/tools/perf/util/evlist.c
+++ b/tools/perf/util/evlist.c
@@ -732,7 +732,7 @@ perf_evlist__should_poll(struct evlist *evlist __maybe_unused,
732 return true; 732 return true;
733} 733}
734 734
735static int perf_evlist__mmap_per_evsel(struct evlist *evlist, int idx, 735static int evlist__mmap_per_evsel(struct evlist *evlist, int idx,
736 struct mmap_params *mp, int cpu_idx, 736 struct mmap_params *mp, int cpu_idx,
737 int thread, int *_output, int *_output_overwrite) 737 int thread, int *_output, int *_output_overwrite)
738{ 738{
@@ -810,7 +810,7 @@ static int perf_evlist__mmap_per_evsel(struct evlist *evlist, int idx,
810 return 0; 810 return 0;
811} 811}
812 812
813static int perf_evlist__mmap_per_cpu(struct evlist *evlist, 813static int evlist__mmap_per_cpu(struct evlist *evlist,
814 struct mmap_params *mp) 814 struct mmap_params *mp)
815{ 815{
816 int cpu, thread; 816 int cpu, thread;
@@ -826,7 +826,7 @@ static int perf_evlist__mmap_per_cpu(struct evlist *evlist,
826 true); 826 true);
827 827
828 for (thread = 0; thread < nr_threads; thread++) { 828 for (thread = 0; thread < nr_threads; thread++) {
829 if (perf_evlist__mmap_per_evsel(evlist, cpu, mp, cpu, 829 if (evlist__mmap_per_evsel(evlist, cpu, mp, cpu,
830 thread, &output, &output_overwrite)) 830 thread, &output, &output_overwrite))
831 goto out_unmap; 831 goto out_unmap;
832 } 832 }
@@ -839,7 +839,7 @@ out_unmap:
839 return -1; 839 return -1;
840} 840}
841 841
842static int perf_evlist__mmap_per_thread(struct evlist *evlist, 842static int evlist__mmap_per_thread(struct evlist *evlist,
843 struct mmap_params *mp) 843 struct mmap_params *mp)
844{ 844{
845 int thread; 845 int thread;
@@ -853,7 +853,7 @@ static int perf_evlist__mmap_per_thread(struct evlist *evlist,
853 auxtrace_mmap_params__set_idx(&mp->auxtrace_mp, evlist, thread, 853 auxtrace_mmap_params__set_idx(&mp->auxtrace_mp, evlist, thread,
854 false); 854 false);
855 855
856 if (perf_evlist__mmap_per_evsel(evlist, thread, mp, 0, thread, 856 if (evlist__mmap_per_evsel(evlist, thread, mp, 0, thread,
857 &output, &output_overwrite)) 857 &output, &output_overwrite))
858 goto out_unmap; 858 goto out_unmap;
859 } 859 }
@@ -888,7 +888,7 @@ unsigned long perf_event_mlock_kb_in_pages(void)
888 return pages; 888 return pages;
889} 889}
890 890
891size_t perf_evlist__mmap_size(unsigned long pages) 891size_t evlist__mmap_size(unsigned long pages)
892{ 892{
893 if (pages == UINT_MAX) 893 if (pages == UINT_MAX)
894 pages = perf_event_mlock_kb_in_pages(); 894 pages = perf_event_mlock_kb_in_pages();
@@ -971,7 +971,7 @@ int perf_evlist__parse_mmap_pages(const struct option *opt, const char *str,
971} 971}
972 972
973/** 973/**
974 * perf_evlist__mmap_ex - Create mmaps to receive events. 974 * evlist__mmap_ex - Create mmaps to receive events.
975 * @evlist: list of events 975 * @evlist: list of events
976 * @pages: map length in pages 976 * @pages: map length in pages
977 * @overwrite: overwrite older events? 977 * @overwrite: overwrite older events?
@@ -979,7 +979,7 @@ int perf_evlist__parse_mmap_pages(const struct option *opt, const char *str,
979 * @auxtrace_overwrite - overwrite older auxtrace data? 979 * @auxtrace_overwrite - overwrite older auxtrace data?
980 * 980 *
981 * If @overwrite is %false the user needs to signal event consumption using 981 * If @overwrite is %false the user needs to signal event consumption using
982 * perf_mmap__write_tail(). Using perf_evlist__mmap_read() does this 982 * perf_mmap__write_tail(). Using evlist__mmap_read() does this
983 * automatically. 983 * automatically.
984 * 984 *
985 * Similarly, if @auxtrace_overwrite is %false the user needs to signal data 985 * Similarly, if @auxtrace_overwrite is %false the user needs to signal data
@@ -987,7 +987,7 @@ int perf_evlist__parse_mmap_pages(const struct option *opt, const char *str,
987 * 987 *
988 * Return: %0 on success, negative error code otherwise. 988 * Return: %0 on success, negative error code otherwise.
989 */ 989 */
990int perf_evlist__mmap_ex(struct evlist *evlist, unsigned int pages, 990int evlist__mmap_ex(struct evlist *evlist, unsigned int pages,
991 unsigned int auxtrace_pages, 991 unsigned int auxtrace_pages,
992 bool auxtrace_overwrite, int nr_cblocks, int affinity, int flush, 992 bool auxtrace_overwrite, int nr_cblocks, int affinity, int flush,
993 int comp_level) 993 int comp_level)
@@ -1011,7 +1011,7 @@ int perf_evlist__mmap_ex(struct evlist *evlist, unsigned int pages,
1011 if (evlist->pollfd.entries == NULL && perf_evlist__alloc_pollfd(evlist) < 0) 1011 if (evlist->pollfd.entries == NULL && perf_evlist__alloc_pollfd(evlist) < 0)
1012 return -ENOMEM; 1012 return -ENOMEM;
1013 1013
1014 evlist->mmap_len = perf_evlist__mmap_size(pages); 1014 evlist->mmap_len = evlist__mmap_size(pages);
1015 pr_debug("mmap size %zuB\n", evlist->mmap_len); 1015 pr_debug("mmap size %zuB\n", evlist->mmap_len);
1016 mp.mask = evlist->mmap_len - page_size - 1; 1016 mp.mask = evlist->mmap_len - page_size - 1;
1017 1017
@@ -1026,14 +1026,14 @@ int perf_evlist__mmap_ex(struct evlist *evlist, unsigned int pages,
1026 } 1026 }
1027 1027
1028 if (perf_cpu_map__empty(cpus)) 1028 if (perf_cpu_map__empty(cpus))
1029 return perf_evlist__mmap_per_thread(evlist, &mp); 1029 return evlist__mmap_per_thread(evlist, &mp);
1030 1030
1031 return perf_evlist__mmap_per_cpu(evlist, &mp); 1031 return evlist__mmap_per_cpu(evlist, &mp);
1032} 1032}
1033 1033
1034int perf_evlist__mmap(struct evlist *evlist, unsigned int pages) 1034int evlist__mmap(struct evlist *evlist, unsigned int pages)
1035{ 1035{
1036 return perf_evlist__mmap_ex(evlist, pages, 0, false, 0, PERF_AFFINITY_SYS, 1, 0); 1036 return evlist__mmap_ex(evlist, pages, 0, false, 0, PERF_AFFINITY_SYS, 1, 0);
1037} 1037}
1038 1038
1039int perf_evlist__create_maps(struct evlist *evlist, struct target *target) 1039int perf_evlist__create_maps(struct evlist *evlist, struct target *target)
@@ -1889,7 +1889,7 @@ int perf_evlist__start_sb_thread(struct evlist *evlist,
1889 goto out_delete_evlist; 1889 goto out_delete_evlist;
1890 } 1890 }
1891 1891
1892 if (perf_evlist__mmap(evlist, UINT_MAX)) 1892 if (evlist__mmap(evlist, UINT_MAX))
1893 goto out_delete_evlist; 1893 goto out_delete_evlist;
1894 1894
1895 evlist__for_each_entry(evlist, counter) { 1895 evlist__for_each_entry(evlist, counter) {
diff --git a/tools/perf/util/evlist.h b/tools/perf/util/evlist.h
index 129786361572..aaf06182c1b8 100644
--- a/tools/perf/util/evlist.h
+++ b/tools/perf/util/evlist.h
@@ -139,7 +139,7 @@ struct perf_sample_id *perf_evlist__id2sid(struct evlist *evlist, u64 id);
139 139
140void perf_evlist__toggle_bkw_mmap(struct evlist *evlist, enum bkw_mmap_state state); 140void perf_evlist__toggle_bkw_mmap(struct evlist *evlist, enum bkw_mmap_state state);
141 141
142void perf_evlist__mmap_consume(struct evlist *evlist, int idx); 142void evlist__mmap_consume(struct evlist *evlist, int idx);
143 143
144int evlist__open(struct evlist *evlist); 144int evlist__open(struct evlist *evlist);
145void evlist__close(struct evlist *evlist); 145void evlist__close(struct evlist *evlist);
@@ -170,14 +170,14 @@ int perf_evlist__parse_mmap_pages(const struct option *opt,
170 170
171unsigned long perf_event_mlock_kb_in_pages(void); 171unsigned long perf_event_mlock_kb_in_pages(void);
172 172
173int perf_evlist__mmap_ex(struct evlist *evlist, unsigned int pages, 173int evlist__mmap_ex(struct evlist *evlist, unsigned int pages,
174 unsigned int auxtrace_pages, 174 unsigned int auxtrace_pages,
175 bool auxtrace_overwrite, int nr_cblocks, 175 bool auxtrace_overwrite, int nr_cblocks,
176 int affinity, int flush, int comp_level); 176 int affinity, int flush, int comp_level);
177int perf_evlist__mmap(struct evlist *evlist, unsigned int pages); 177int evlist__mmap(struct evlist *evlist, unsigned int pages);
178void perf_evlist__munmap(struct evlist *evlist); 178void perf_evlist__munmap(struct evlist *evlist);
179 179
180size_t perf_evlist__mmap_size(unsigned long pages); 180size_t evlist__mmap_size(unsigned long pages);
181 181
182void evlist__disable(struct evlist *evlist); 182void evlist__disable(struct evlist *evlist);
183void evlist__enable(struct evlist *evlist); 183void evlist__enable(struct evlist *evlist);
diff --git a/tools/perf/util/python.c b/tools/perf/util/python.c
index 1e1247cffea8..b102d174b868 100644
--- a/tools/perf/util/python.c
+++ b/tools/perf/util/python.c
@@ -899,7 +899,7 @@ static PyObject *pyrf_evlist__mmap(struct pyrf_evlist *pevlist,
899 &pages, &overwrite)) 899 &pages, &overwrite))
900 return NULL; 900 return NULL;
901 901
902 if (perf_evlist__mmap(evlist, pages) < 0) { 902 if (evlist__mmap(evlist, pages) < 0) {
903 PyErr_SetFromErrno(PyExc_OSError); 903 PyErr_SetFromErrno(PyExc_OSError);
904 return NULL; 904 return NULL;
905 } 905 }