summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorAl Viro2019-05-23 03:23:39 +0200
committerAl Viro2019-07-05 04:01:58 +0200
commitc23a0bbab30cc1714b6b1d6a1c153a5ccab3f0d8 (patch)
treeb58d6ed34a26200796664d1dca3c10629cfdb8ea /fs
parentconvenience helper get_tree_nodev() (diff)
downloadkernel-qcow2-linux-c23a0bbab30cc1714b6b1d6a1c153a5ccab3f0d8.tar.gz
kernel-qcow2-linux-c23a0bbab30cc1714b6b1d6a1c153a5ccab3f0d8.tar.xz
kernel-qcow2-linux-c23a0bbab30cc1714b6b1d6a1c153a5ccab3f0d8.zip
convenience helper: get_tree_single()
counterpart of mount_single(); switch fusectl to it Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs')
-rw-r--r--fs/fuse/control.c2
-rw-r--r--fs/super.c8
2 files changed, 9 insertions, 1 deletions
diff --git a/fs/fuse/control.c b/fs/fuse/control.c
index 14ce1e47f980..c23f6f243ad4 100644
--- a/fs/fuse/control.c
+++ b/fs/fuse/control.c
@@ -346,7 +346,7 @@ static int fuse_ctl_fill_super(struct super_block *sb, struct fs_context *fctx)
static int fuse_ctl_get_tree(struct fs_context *fc)
{
- return vfs_get_super(fc, vfs_get_single_super, fuse_ctl_fill_super);
+ return get_tree_single(fc, fuse_ctl_fill_super);
}
static const struct fs_context_operations fuse_ctl_context_ops = {
diff --git a/fs/super.c b/fs/super.c
index 3318225b0878..113c58f19425 100644
--- a/fs/super.c
+++ b/fs/super.c
@@ -1206,6 +1206,14 @@ int get_tree_nodev(struct fs_context *fc,
}
EXPORT_SYMBOL(get_tree_nodev);
+int get_tree_single(struct fs_context *fc,
+ int (*fill_super)(struct super_block *sb,
+ struct fs_context *fc))
+{
+ return vfs_get_super(fc, vfs_get_single_super, fill_super);
+}
+EXPORT_SYMBOL(get_tree_single);
+
#ifdef CONFIG_BLOCK
static int set_bdev_super(struct super_block *s, void *data)
{