perf evlist: Rename perf_evlist__open() to evlist__open()
authorJiri Olsa <jolsa@kernel.org>
Sun, 21 Jul 2019 11:24:06 +0000 (13:24 +0200)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 29 Jul 2019 21:34:43 +0000 (18:34 -0300)
Rename perf_evlist__open() to evlist__open(), so we don't have a name
clash when we add perf_evlist__open() in libperf.

Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Alexey Budankov <alexey.budankov@linux.intel.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Michael Petlan <mpetlan@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/20190721112506.12306-20-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
16 files changed:
tools/perf/arch/x86/tests/perf-time-to-tsc.c
tools/perf/builtin-kvm.c
tools/perf/builtin-trace.c
tools/perf/tests/backward-ring-buffer.c
tools/perf/tests/bpf.c
tools/perf/tests/code-reading.c
tools/perf/tests/event-times.c
tools/perf/tests/keep-tracking.c
tools/perf/tests/openat-syscall-tp-fields.c
tools/perf/tests/perf-record.c
tools/perf/tests/sw-clock.c
tools/perf/tests/switch-tracking.c
tools/perf/tests/task-exit.c
tools/perf/util/evlist.c
tools/perf/util/evlist.h
tools/perf/util/python.c

index 09b6cef76f5b85404db95a872b03b5fcbfbc5397..ea4cf1d367a6bfb301f36569021e23991bfad265 100644 (file)
@@ -83,7 +83,7 @@ int test__perf_time_to_tsc(struct test *test __maybe_unused, int subtest __maybe
        evsel->attr.disabled = 1;
        evsel->attr.enable_on_exec = 0;
 
-       CHECK__(perf_evlist__open(evlist));
+       CHECK__(evlist__open(evlist));
 
        CHECK__(perf_evlist__mmap(evlist, UINT_MAX));
 
index 8f54bdfb5743f25a6fc7ce8aecb598f98a210023..85604d11755805dd033ef5d98d8f5f6e5a6ce28d 100644 (file)
@@ -1048,7 +1048,7 @@ static int kvm_live_open_events(struct perf_kvm_stat *kvm)
                attr->disabled = 1;
        }
 
-       err = perf_evlist__open(evlist);
+       err = evlist__open(evlist);
        if (err < 0) {
                printf("Couldn't create the events: %s\n",
                       str_error_r(errno, sbuf, sizeof(sbuf)));
index 95ecefa9ff7e8c2eee47f3ecbad66ddd1afb832b..e508fdb770997a3a6f1a91808ad0f4e48558e8c2 100644 (file)
@@ -3342,7 +3342,7 @@ static int trace__run(struct trace *trace, int argc, const char **argv)
                }
        }
 
-       err = perf_evlist__open(evlist);
+       err = evlist__open(evlist);
        if (err < 0)
                goto out_error_open;
 
index ef3c6db2fae4117ee8668ee007dbf9956a6e8423..8de2d6ad93cebe3c3d3dd039126ee48d0f4f97c7 100644 (file)
@@ -125,7 +125,7 @@ int test__backward_ring_buffer(struct test *test __maybe_unused, int subtest __m
 
        perf_evlist__config(evlist, &opts, NULL);
 
-       err = perf_evlist__open(evlist);
+       err = evlist__open(evlist);
        if (err < 0) {
                pr_debug("perf_evlist__open: %s\n",
                         str_error_r(errno, sbuf, sizeof(sbuf)));
index 313ff1aadd9c1c0b0cce53b611f86ab464bddc05..b41c4148228376a546e541287f938e2d9e6fdcd1 100644 (file)
@@ -157,7 +157,7 @@ static int do_test(struct bpf_object *obj, int (*func)(void),
 
        perf_evlist__config(evlist, &opts, NULL);
 
-       err = perf_evlist__open(evlist);
+       err = evlist__open(evlist);
        if (err < 0) {
                pr_debug("perf_evlist__open: %s\n",
                         str_error_r(errno, sbuf, sizeof(sbuf)));
index 1c7f092a73882839b2d9e6606e582a1ffb411401..23abc775a69c28c892922c3567f4babed282ad43 100644 (file)
@@ -646,7 +646,7 @@ static int do_test_code_reading(bool try_kcore)
                evsel->attr.disabled = 1;
                evsel->attr.enable_on_exec = 0;
 
-               ret = perf_evlist__open(evlist);
+               ret = evlist__open(evlist);
                if (ret < 0) {
                        if (!excl_kernel) {
                                excl_kernel = true;
index 6f9995df2c27da3c450eb201ddf936cbc1a6620f..bf00d3d792fb65beb41ba891eb7cbacba936e96c 100644 (file)
@@ -38,7 +38,7 @@ static int attach__enable_on_exec(struct evlist *evlist)
 
        evsel->attr.enable_on_exec = 1;
 
-       err = perf_evlist__open(evlist);
+       err = evlist__open(evlist);
        if (err < 0) {
                pr_debug("perf_evlist__open: %s\n",
                         str_error_r(errno, sbuf, sizeof(sbuf)));
index 1976ccb3c8126110867c2b11b6d478f95d24cc82..c55bc062e2000665102d00417dd1ac3d9b229a69 100644 (file)
@@ -94,7 +94,7 @@ int test__keep_tracking(struct test *test __maybe_unused, int subtest __maybe_un
        evsel->attr.disabled = 1;
        evsel->attr.enable_on_exec = 0;
 
-       if (perf_evlist__open(evlist) < 0) {
+       if (evlist__open(evlist) < 0) {
                pr_debug("Unable to open dummy and cycles event\n");
                err = TEST_SKIP;
                goto out_err;
index f822c3c181f35c0d3ca2c29ce6736fcfb83718ae..233447af9d03fc340da1ff804891cda7b62ed3df 100644 (file)
@@ -60,7 +60,7 @@ int test__syscall_openat_tp_fields(struct test *test __maybe_unused, int subtest
 
        thread_map__set_pid(evlist->threads, 0, getpid());
 
-       err = perf_evlist__open(evlist);
+       err = evlist__open(evlist);
        if (err < 0) {
                pr_debug("perf_evlist__open: %s\n",
                         str_error_r(errno, sbuf, sizeof(sbuf)));
index 779d5996428be77ba4ba21f98a7c5fe3b388592d..f5d1e7f1b58b4cbb222e923e877be1fa7740a0eb 100644 (file)
@@ -130,7 +130,7 @@ int test__PERF_RECORD(struct test *test __maybe_unused, int subtest __maybe_unus
         * Call sys_perf_event_open on all the fds on all the evsels,
         * grouping them if asked to.
         */
-       err = perf_evlist__open(evlist);
+       err = evlist__open(evlist);
        if (err < 0) {
                pr_debug("perf_evlist__open: %s\n",
                         str_error_r(errno, sbuf, sizeof(sbuf)));
index 3ab11291174cffe79f4a8fb0504cc0901f89b9e9..528a2dff06e086a2dde4f72b076562e2018044bb 100644 (file)
@@ -69,7 +69,7 @@ static int __test__sw_clock_freq(enum perf_sw_ids clock_id)
        cpus    = NULL;
        threads = NULL;
 
-       if (perf_evlist__open(evlist)) {
+       if (evlist__open(evlist)) {
                const char *knob = "/proc/sys/kernel/perf_event_max_sample_rate";
 
                err = -errno;
index 5662dc1c6bd3845c919d44fad0977c3f572fbdad..47f9895ba807bf6a28d298fc9f53406244663b6b 100644 (file)
@@ -450,7 +450,7 @@ int test__switch_tracking(struct test *test __maybe_unused, int subtest __maybe_
                }
        }
 
-       if (perf_evlist__open(evlist) < 0) {
+       if (evlist__open(evlist) < 0) {
                pr_debug("Not supported\n");
                err = 0;
                goto out;
index 698ee5369c0216dc66f1481a99fd97ae1cc2906b..d17effdd55c8b9c226171fb6265e9eb988760798 100644 (file)
@@ -95,7 +95,7 @@ int test__task_exit(struct test *test __maybe_unused, int subtest __maybe_unused
        evsel->attr.wakeup_events = 1;
        evsel->attr.exclude_kernel = 1;
 
-       err = perf_evlist__open(evlist);
+       err = evlist__open(evlist);
        if (err < 0) {
                pr_debug("Couldn't open the evlist: %s\n",
                         str_error_r(-err, sbuf, sizeof(sbuf)));
index e71c3cc939246010753e92622fccf1c6f3656feb..7d44e05dfaa4e0a44fd3bb684516567271f4b635 100644 (file)
@@ -1387,7 +1387,7 @@ out_put:
        goto out;
 }
 
-int perf_evlist__open(struct evlist *evlist)
+int evlist__open(struct evlist *evlist)
 {
        struct evsel *evsel;
        int err;
index b3a44e2eed08e242c27393b87152f0c835f60df9..f4b3152c879e2b415fe3b05c254385b6bd50eef6 100644 (file)
@@ -146,7 +146,7 @@ void perf_evlist__toggle_bkw_mmap(struct evlist *evlist, enum bkw_mmap_state sta
 
 void perf_evlist__mmap_consume(struct evlist *evlist, int idx);
 
-int perf_evlist__open(struct evlist *evlist);
+int evlist__open(struct evlist *evlist);
 void perf_evlist__close(struct evlist *evlist);
 
 struct callchain_param;
index 3eb7348d29f89dfc198832fca38b51a639aaa57d..cc4af99ab190f4a39efed009dae34c338154da7f 100644 (file)
@@ -1059,7 +1059,7 @@ static PyObject *pyrf_evlist__open(struct pyrf_evlist *pevlist,
        if (group)
                perf_evlist__set_leader(evlist);
 
-       if (perf_evlist__open(evlist) < 0) {
+       if (evlist__open(evlist) < 0) {
                PyErr_SetFromErrno(PyExc_OSError);
                return NULL;
        }