Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1213891
| From | Jiri Olsa <jolsa@kernel.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH 08/11] perf tools: Do not export debugfs_mountpoint and tracefs_mountpoint |
| Date | 2015-08-26 15:50 +0200 |
| Message-ID | <q1Jft-7l6-37@gated-at.bofh.it> (permalink) |
| References | <q1Jfs-7l6-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Both debugfs_mountpoint and tracefs_mountpoint should not be changed
externally. Both mounpoints are returned by following interface:
debugfs_find_mountpoint
tracefs_find_mountpoint
Link: http://lkml.kernel.org/n/tip-ptrbv90c13ebticnfu1ysye7@git.kernel.org
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/lib/api/fs/debugfs.c | 2 +-
tools/lib/api/fs/debugfs.h | 2 --
tools/lib/api/fs/tracefs.c | 2 +-
tools/lib/api/fs/tracefs.h | 2 --
4 files changed, 2 insertions(+), 6 deletions(-)
diff --git a/tools/lib/api/fs/debugfs.c b/tools/lib/api/fs/debugfs.c
index 896c3595c9df..9e7e039a99ae 100644
--- a/tools/lib/api/fs/debugfs.c
+++ b/tools/lib/api/fs/debugfs.c
@@ -18,7 +18,7 @@
#define DEBUGFS_DEFAULT_PATH "/sys/kernel/debug"
#endif
-char debugfs_mountpoint[PATH_MAX + 1] = DEBUGFS_DEFAULT_PATH;
+static char debugfs_mountpoint[PATH_MAX + 1] = DEBUGFS_DEFAULT_PATH;
static const char * const debugfs_known_mountpoints[] = {
DEBUGFS_DEFAULT_PATH,
diff --git a/tools/lib/api/fs/debugfs.h b/tools/lib/api/fs/debugfs.h
index 19a618e9dbc1..0eb57ecbbb5f 100644
--- a/tools/lib/api/fs/debugfs.h
+++ b/tools/lib/api/fs/debugfs.h
@@ -15,6 +15,4 @@ bool debugfs_configured(void);
const char *debugfs_find_mountpoint(void);
char *debugfs_mount(const char *mountpoint);
-extern char debugfs_mountpoint[];
-
#endif /* __API_DEBUGFS_H__ */
diff --git a/tools/lib/api/fs/tracefs.c b/tools/lib/api/fs/tracefs.c
index e4aa9688b71e..b5d34ee3cddc 100644
--- a/tools/lib/api/fs/tracefs.c
+++ b/tools/lib/api/fs/tracefs.c
@@ -16,7 +16,7 @@
#define TRACEFS_DEFAULT_PATH "/sys/kernel/tracing"
#endif
-char tracefs_mountpoint[PATH_MAX + 1] = TRACEFS_DEFAULT_PATH;
+static char tracefs_mountpoint[PATH_MAX + 1] = TRACEFS_DEFAULT_PATH;
static const char * const tracefs_known_mountpoints[] = {
TRACEFS_DEFAULT_PATH,
diff --git a/tools/lib/api/fs/tracefs.h b/tools/lib/api/fs/tracefs.h
index da780ac49acb..be7d4c543de5 100644
--- a/tools/lib/api/fs/tracefs.h
+++ b/tools/lib/api/fs/tracefs.h
@@ -16,6 +16,4 @@ const char *tracefs_find_mountpoint(void);
int tracefs_valid_mountpoint(const char *debugfs);
char *tracefs_mount(const char *mountpoint);
-extern char tracefs_mountpoint[];
-
#endif /* __API_DEBUGFS_H__ */
--
2.4.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next | Find similar | Unroll thread
[PATCH 08/11] perf tools: Do not export debugfs_mountpoint and tracefs_mountpoint Jiri Olsa <jolsa@kernel.org> - 2015-08-26 15:50 +0200
csiph-web