perf fs: Rename NAME_find_mountpoint() to NAME__mountpoint()
Shorten it, "finding" it is an implementation detail, what callers want
is the pathname, not to ask for it to _always_ do the lookup.
And the existing implementation already caches it, i.e. it doesn't
"finds" it on every call.
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-r24wa4bvtccg7mnkessrbbdj@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
diff --git a/tools/perf/util/fs.c b/tools/perf/util/fs.c
index a2413e8..77bac4e4 100644
--- a/tools/perf/util/fs.c
+++ b/tools/perf/util/fs.c
@@ -88,7 +88,7 @@
return fs__read_mounts(fs) ? fs->path : NULL;
}
-static const char *fs__find_mountpoint(int idx)
+static const char *fs__mountpoint(int idx)
{
struct fs *fs = &fs__entries[idx];
@@ -98,10 +98,10 @@
return fs__get_mountpoint(fs);
}
-#define FIND_MOUNTPOINT(name, idx) \
-const char *name##_find_mountpoint(void) \
-{ \
- return fs__find_mountpoint(idx); \
+#define FS__MOUNTPOINT(name, idx) \
+const char *name##__mountpoint(void) \
+{ \
+ return fs__mountpoint(idx); \
}
-FIND_MOUNTPOINT(sysfs, FS__SYSFS);
+FS__MOUNTPOINT(sysfs, FS__SYSFS);