diff options
| author | Arnaldo Carvalho de Melo <[email protected]> | 2018-05-17 17:42:39 +0000 |
|---|---|---|
| committer | Arnaldo Carvalho de Melo <[email protected]> | 2018-05-17 17:50:38 +0000 |
| commit | 7014e0e3bf9b0d0b6221eb7d2f8a1f690423dd73 (patch) | |
| tree | 37da2c3997d4b2c03a4e1698481e8608925b11cd /tools/lib/api/fs/tracing_path.h | |
| parent | perf parse-events: Use get/put_events_file() (diff) | |
| download | kernel-7014e0e3bf9b0d0b6221eb7d2f8a1f690423dd73.tar.gz kernel-7014e0e3bf9b0d0b6221eb7d2f8a1f690423dd73.zip | |
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 <[email protected]>
Cc: David Ahern <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Wang Nan <[email protected]>
Link: https://lkml.kernel.org/n/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
Diffstat (limited to 'tools/lib/api/fs/tracing_path.h')
| -rw-r--r-- | tools/lib/api/fs/tracing_path.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tools/lib/api/fs/tracing_path.h b/tools/lib/api/fs/tracing_path.h index 3b32fb439f12..904d085b2ae7 100644 --- a/tools/lib/api/fs/tracing_path.h +++ b/tools/lib/api/fs/tracing_path.h @@ -3,9 +3,12 @@ #define __API_FS_TRACING_PATH_H #include <linux/types.h> +#include <dirent.h> extern char tracing_events_path[]; +DIR *tracing_events__opendir(void); + void tracing_path_set(const char *mountpoint); const char *tracing_path_mount(void); |
