summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/probe-file.c
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo2018-05-16 21:27:14 +0200
committerArnaldo Carvalho de Melo2018-05-16 21:27:14 +0200
commit17c257e867be1880eaf7c1b9dac286086d75d1ec (patch)
treedaa6a7bd9c5787796b12793f59d2de0d1490f7e8 /tools/perf/util/probe-file.c
parenttools lib api: The tracing_mnt variable doesn't need to be global (diff)
downloadkernel-qcow2-linux-17c257e867be1880eaf7c1b9dac286086d75d1ec.tar.gz
kernel-qcow2-linux-17c257e867be1880eaf7c1b9dac286086d75d1ec.tar.xz
kernel-qcow2-linux-17c257e867be1880eaf7c1b9dac286086d75d1ec.zip
tools lib api: Unexport 'tracing_path' variable
One should use tracing_path_mount() instead, so more things get done lazily instead of at every 'perf' tool call startup. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: https://lkml.kernel.org/n/tip-fci4yll35idd9yuslp67vqc2@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/probe-file.c')
-rw-r--r--tools/perf/util/probe-file.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/tools/perf/util/probe-file.c b/tools/perf/util/probe-file.c
index 4ae1123c6794..b76088fadf3d 100644
--- a/tools/perf/util/probe-file.c
+++ b/tools/perf/util/probe-file.c
@@ -84,8 +84,7 @@ int open_trace_file(const char *trace_file, bool readwrite)
char buf[PATH_MAX];
int ret;
- ret = e_snprintf(buf, PATH_MAX, "%s/%s",
- tracing_path, trace_file);
+ ret = e_snprintf(buf, PATH_MAX, "%s/%s", tracing_path_mount(), trace_file);
if (ret >= 0) {
pr_debug("Opening %s write=%d\n", buf, readwrite);
if (readwrite && !probe_event_dry_run)