perf evlist: Fix the class prefix for 'struct evlist' strerror methods
authorArnaldo Carvalho de Melo <acme@redhat.com>
Wed, 17 Jun 2020 12:19:46 +0000 (09:19 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 22 Jun 2020 19:28:09 +0000 (16:28 -0300)
To differentiate from libperf's 'struct perf_evlist' methods.

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/builtin-trace.c
tools/perf/tests/code-reading.c
tools/perf/util/evlist.c
tools/perf/util/evlist.h

index b9c8b40..a333a9a 100644 (file)
@@ -4149,11 +4149,11 @@ out_error_raw_syscalls:
        goto out_error;
 
 out_error_mmap:
-       perf_evlist__strerror_mmap(evlist, errno, errbuf, sizeof(errbuf));
+       evlist__strerror_mmap(evlist, errno, errbuf, sizeof(errbuf));
        goto out_error;
 
 out_error_open:
-       perf_evlist__strerror_open(evlist, errno, errbuf, sizeof(errbuf));
+       evlist__strerror_open(evlist, errno, errbuf, sizeof(errbuf));
 
 out_error:
        fprintf(trace->output, "%s\n", errbuf);
index 6fe221d..035c912 100644 (file)
@@ -678,7 +678,7 @@ static int do_test_code_reading(bool try_kcore)
 
                        if (verbose > 0) {
                                char errbuf[512];
-                               perf_evlist__strerror_open(evlist, errno, errbuf, sizeof(errbuf));
+                               evlist__strerror_open(evlist, errno, errbuf, sizeof(errbuf));
                                pr_debug("perf_evlist__open() failed!\n%s\n", errbuf);
                        }
 
index d574e77..4b7f9f9 100644 (file)
@@ -1461,8 +1461,7 @@ int perf_evlist__parse_sample_timestamp(struct evlist *evlist,
        return evsel__parse_sample_timestamp(evsel, event, timestamp);
 }
 
-int perf_evlist__strerror_open(struct evlist *evlist,
-                              int err, char *buf, size_t size)
+int evlist__strerror_open(struct evlist *evlist, int err, char *buf, size_t size)
 {
        int printed, value;
        char sbuf[STRERR_BUFSIZE], *emsg = str_error_r(err, sbuf, sizeof(sbuf));
@@ -1515,7 +1514,7 @@ out_default:
        return 0;
 }
 
-int perf_evlist__strerror_mmap(struct evlist *evlist, int err, char *buf, size_t size)
+int evlist__strerror_mmap(struct evlist *evlist, int err, char *buf, size_t size)
 {
        char sbuf[STRERR_BUFSIZE], *emsg = str_error_r(err, sbuf, sizeof(sbuf));
        int pages_attempted = evlist->core.mmap_len / 1024, pages_max_per_user, printed = 0;
index 94f210d..a832639 100644 (file)
@@ -257,8 +257,8 @@ static inline struct evsel *evlist__last(struct evlist *evlist)
        return container_of(evsel, struct evsel, core);
 }
 
-int perf_evlist__strerror_open(struct evlist *evlist, int err, char *buf, size_t size);
-int perf_evlist__strerror_mmap(struct evlist *evlist, int err, char *buf, size_t size);
+int evlist__strerror_open(struct evlist *evlist, int err, char *buf, size_t size);
+int evlist__strerror_mmap(struct evlist *evlist, int err, char *buf, size_t size);
 
 bool perf_evlist__can_select_event(struct evlist *evlist, const char *str);
 void perf_evlist__to_front(struct evlist *evlist,