summaryrefslogtreecommitdiff
path: root/tools/perf/tests
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2018-05-17 14:42:39 -0300
committerArnaldo Carvalho de Melo <acme@redhat.com>2018-05-17 14:50:38 -0300
commit7014e0e3bf9b0d0b6221eb7d2f8a1f690423dd73 (patch)
tree37da2c3997d4b2c03a4e1698481e8608925b11cd /tools/perf/tests
parent25a7d914274de38637c5199342eb90a297361386 (diff)
tools lib api fs tracing_path: Introduce opendir() method
That takes care of using the right call to get the tracing_path directory, the one that will end up calling tracing_path_set() to figure out where tracefs is mounted. One more step in doing just lazy reading of system structures to reduce the number of operations done unconditionaly at 'perf' start. 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-42zzi0f274909bg9mxzl81bu@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/tests')
-rw-r--r--tools/perf/tests/parse-events.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/tests/parse-events.c b/tools/perf/tests/parse-events.c
index 6d57d7082637..b9ebe15afb13 100644
--- a/tools/perf/tests/parse-events.c
+++ b/tools/perf/tests/parse-events.c
@@ -1323,7 +1323,7 @@ static int count_tracepoints(void)
DIR *events_dir;
int cnt = 0;
- events_dir = opendir(tracing_events_path);
+ events_dir = tracing_events__opendir();
TEST_ASSERT_VAL("Can't open events dir", events_dir);