aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-10-29 11:06:25 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2010-10-29 11:06:25 -0400
commit53113b06e48c6c38f7612c1f8043b8a0d2adf72b (patch)
treeb50f098b72b6389fde956d8272c08169ff2b53cc /drivers
parent37542b6a7e73e81f8c066a48e6911e476ee3b22f (diff)
parenta4cdbd8bfb87ceff455aae85727077889b75001b (diff)
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6: (29 commits) braino in internal.h convert simple cases of nfs-related ->get_sb() to ->mount() convert btrfs convert ceph convert gfs2 convert afs convert ecryptfs convert sysfs convert cgroup and cpuset switch get_sb_ns() users switch procfs to ->mount() setting ->proc_mnt doesn't belong in proc_get_sb() convert cifs convert nilfs switch logfs to ->mount() logfs: fix a leak in get_sb logfs get_sb, part 3 logfs get_sb, part 2 logfs get_sb massage, part 1 convert v9fs ...
Diffstat (limited to 'drivers')
-rw-r--r--drivers/base/devtmpfs.c18
-rw-r--r--drivers/infiniband/hw/ipath/ipath_fs.c14
-rw-r--r--drivers/infiniband/hw/qib/qib_fs.c14
-rw-r--r--drivers/isdn/capi/capifs.c8
-rw-r--r--drivers/misc/ibmasm/ibmasmfs.c9
-rw-r--r--drivers/mtd/mtdchar.c10
-rw-r--r--drivers/mtd/mtdsuper.c54
-rw-r--r--drivers/oprofile/oprofilefs.c8
-rw-r--r--drivers/staging/autofs/init.c8
-rw-r--r--drivers/staging/pohmelfs/inode.c9
-rw-r--r--drivers/staging/smbfs/inode.c8
-rw-r--r--drivers/usb/core/inode.c8
-rw-r--r--drivers/usb/gadget/f_fs.c14
-rw-r--r--drivers/usb/gadget/inode.c10
-rw-r--r--drivers/xen/xenfs/super.c8
15 files changed, 93 insertions, 107 deletions
diff --git a/drivers/base/devtmpfs.c b/drivers/base/devtmpfs.c
index af0600143d1c..82bbb5967aa9 100644
--- a/drivers/base/devtmpfs.c
+++ b/drivers/base/devtmpfs.c
@@ -29,33 +29,33 @@
29static struct vfsmount *dev_mnt; 29static struct vfsmount *dev_mnt;
30 30
31#if defined CONFIG_DEVTMPFS_MOUNT 31#if defined CONFIG_DEVTMPFS_MOUNT
32static int dev_mount = 1; 32static int mount_dev = 1;
33#else 33#else
34static int dev_mount; 34static int mount_dev;
35#endif 35#endif
36 36
37static DEFINE_MUTEX(dirlock); 37static DEFINE_MUTEX(dirlock);
38 38
39static int __init mount_param(char *str) 39static int __init mount_param(char *str)
40{ 40{
41 dev_mount = simple_strtoul(str, NULL, 0); 41 mount_dev = simple_strtoul(str, NULL, 0);
42 return 1; 42 return 1;
43} 43}
44__setup("devtmpfs.mount=", mount_param); 44__setup("devtmpfs.mount=", mount_param);
45 45
46static int dev_get_sb(struct file_system_type *fs_type, int flags, 46static struct dentry *dev_mount(struct file_system_type *fs_type, int flags,
47 const char *dev_name, void *data, struct vfsmount *mnt) 47 const char *dev_name, void *data)
48{ 48{
49#ifdef CONFIG_TMPFS 49#ifdef CONFIG_TMPFS
50 return get_sb_single(fs_type, flags, data, shmem_fill_super, mnt); 50 return mount_single(fs_type, flags, data, shmem_fill_super);
51#else 51#else
52 return get_sb_single(fs_type, flags, data, ramfs_fill_super, mnt); 52 return mount_single(fs_type, flags, data, ramfs_fill_super);
53#endif 53#endif
54} 54}
55 55
56static struct file_system_type dev_fs_type = { 56static struct file_system_type dev_fs_type = {
57 .name = "devtmpfs", 57 .name = "devtmpfs",
58 .get_sb = dev_get_sb, 58 .mount = dev_mount,
59 .kill_sb = kill_litter_super, 59 .kill_sb = kill_litter_super,
60}; 60};
61 61
@@ -351,7 +351,7 @@ int devtmpfs_mount(const char *mntdir)
351{ 351{
352 int err; 352 int err;
353 353
354 if (!dev_mount) 354 if (!mount_dev)
355 return 0; 355 return 0;
356 356
357 if (!dev_mnt) 357 if (!dev_mnt)
diff --git a/drivers/infiniband/hw/ipath/ipath_fs.c b/drivers/infiniband/hw/ipath/ipath_fs.c
index 12d5bf76302c..8c8afc716b98 100644
--- a/drivers/infiniband/hw/ipath/ipath_fs.c
+++ b/drivers/infiniband/hw/ipath/ipath_fs.c
@@ -362,13 +362,13 @@ bail:
362 return ret; 362 return ret;
363} 363}
364 364
365static int ipathfs_get_sb(struct file_system_type *fs_type, int flags, 365static struct dentry *ipathfs_mount(struct file_system_type *fs_type,
366 const char *dev_name, void *data, struct vfsmount *mnt) 366 int flags, const char *dev_name, void *data)
367{ 367{
368 int ret = get_sb_single(fs_type, flags, data, 368 struct dentry *ret;
369 ipathfs_fill_super, mnt); 369 ret = mount_single(fs_type, flags, data, ipathfs_fill_super);
370 if (ret >= 0) 370 if (!IS_ERR(ret))
371 ipath_super = mnt->mnt_sb; 371 ipath_super = ret->d_sb;
372 return ret; 372 return ret;
373} 373}
374 374
@@ -411,7 +411,7 @@ bail:
411static struct file_system_type ipathfs_fs_type = { 411static struct file_system_type ipathfs_fs_type = {
412 .owner = THIS_MODULE, 412 .owner = THIS_MODULE,
413 .name = "ipathfs", 413 .name = "ipathfs",
414 .get_sb = ipathfs_get_sb, 414 .mount = ipathfs_mount,
415 .kill_sb = ipathfs_kill_super, 415 .kill_sb = ipathfs_kill_super,
416}; 416};
417 417
diff --git a/drivers/infiniband/hw/qib/qib_fs.c b/drivers/infiniband/hw/qib/qib_fs.c
index 7e433d75c775..f99bddc01716 100644
--- a/drivers/infiniband/hw/qib/qib_fs.c
+++ b/drivers/infiniband/hw/qib/qib_fs.c
@@ -555,13 +555,13 @@ bail:
555 return ret; 555 return ret;
556} 556}
557 557
558static int qibfs_get_sb(struct file_system_type *fs_type, int flags, 558static struct dentry *qibfs_mount(struct file_system_type *fs_type, int flags,
559 const char *dev_name, void *data, struct vfsmount *mnt) 559 const char *dev_name, void *data)
560{ 560{
561 int ret = get_sb_single(fs_type, flags, data, 561 struct dentry *ret;
562 qibfs_fill_super, mnt); 562 ret = mount_single(fs_type, flags, data, qibfs_fill_super);
563 if (ret >= 0) 563 if (!IS_ERR(ret))
564 qib_super = mnt->mnt_sb; 564 qib_super = ret->d_sb;
565 return ret; 565 return ret;
566} 566}
567 567
@@ -603,7 +603,7 @@ int qibfs_remove(struct qib_devdata *dd)
603static struct file_system_type qibfs_fs_type = { 603static struct file_system_type qibfs_fs_type = {
604 .owner = THIS_MODULE, 604 .owner = THIS_MODULE,
605 .name = "ipathfs", 605 .name = "ipathfs",
606 .get_sb = qibfs_get_sb, 606 .mount = qibfs_mount,
607 .kill_sb = qibfs_kill_super, 607 .kill_sb = qibfs_kill_super,
608}; 608};
609 609
diff --git a/drivers/isdn/capi/capifs.c b/drivers/isdn/capi/capifs.c
index 2b83850997c3..b4faed7fe0d3 100644
--- a/drivers/isdn/capi/capifs.c
+++ b/drivers/isdn/capi/capifs.c
@@ -125,16 +125,16 @@ fail:
125 return -ENOMEM; 125 return -ENOMEM;
126} 126}
127 127
128static int capifs_get_sb(struct file_system_type *fs_type, 128static struct dentry *capifs_mount(struct file_system_type *fs_type,
129 int flags, const char *dev_name, void *data, struct vfsmount *mnt) 129 int flags, const char *dev_name, void *data)
130{ 130{
131 return get_sb_single(fs_type, flags, data, capifs_fill_super, mnt); 131 return mount_single(fs_type, flags, data, capifs_fill_super);
132} 132}
133 133
134static struct file_system_type capifs_fs_type = { 134static struct file_system_type capifs_fs_type = {
135 .owner = THIS_MODULE, 135 .owner = THIS_MODULE,
136 .name = "capifs", 136 .name = "capifs",
137 .get_sb = capifs_get_sb, 137 .mount = capifs_mount,
138 .kill_sb = kill_anon_super, 138 .kill_sb = kill_anon_super,
139}; 139};
140 140
diff --git a/drivers/misc/ibmasm/ibmasmfs.c b/drivers/misc/ibmasm/ibmasmfs.c
index 0a53500636c9..d2d5d23416dd 100644
--- a/drivers/misc/ibmasm/ibmasmfs.c
+++ b/drivers/misc/ibmasm/ibmasmfs.c
@@ -91,11 +91,10 @@ static void ibmasmfs_create_files (struct super_block *sb, struct dentry *root);
91static int ibmasmfs_fill_super (struct super_block *sb, void *data, int silent); 91static int ibmasmfs_fill_super (struct super_block *sb, void *data, int silent);
92 92
93 93
94static int ibmasmfs_get_super(struct file_system_type *fst, 94static struct dentry *ibmasmfs_mount(struct file_system_type *fst,
95 int flags, const char *name, void *data, 95 int flags, const char *name, void *data)
96 struct vfsmount *mnt)
97{ 96{
98 return get_sb_single(fst, flags, data, ibmasmfs_fill_super, mnt); 97 return mount_single(fst, flags, data, ibmasmfs_fill_super);
99} 98}
100 99
101static const struct super_operations ibmasmfs_s_ops = { 100static const struct super_operations ibmasmfs_s_ops = {
@@ -108,7 +107,7 @@ static const struct file_operations *ibmasmfs_dir_ops = &simple_dir_operations;
108static struct file_system_type ibmasmfs_type = { 107static struct file_system_type ibmasmfs_type = {
109 .owner = THIS_MODULE, 108 .owner = THIS_MODULE,
110 .name = "ibmasmfs", 109 .name = "ibmasmfs",
111 .get_sb = ibmasmfs_get_super, 110 .mount = ibmasmfs_mount,
112 .kill_sb = kill_litter_super, 111 .kill_sb = kill_litter_super,
113}; 112};
114 113
diff --git a/drivers/mtd/mtdchar.c b/drivers/mtd/mtdchar.c
index 5ef45487b65f..a34a0fe14884 100644
--- a/drivers/mtd/mtdchar.c
+++ b/drivers/mtd/mtdchar.c
@@ -1030,17 +1030,15 @@ static const struct file_operations mtd_fops = {
1030#endif 1030#endif
1031}; 1031};
1032 1032
1033static int mtd_inodefs_get_sb(struct file_system_type *fs_type, int flags, 1033static struct dentry *mtd_inodefs_mount(struct file_system_type *fs_type,
1034 const char *dev_name, void *data, 1034 int flags, const char *dev_name, void *data)
1035 struct vfsmount *mnt)
1036{ 1035{
1037 return get_sb_pseudo(fs_type, "mtd_inode:", NULL, MTD_INODE_FS_MAGIC, 1036 return mount_pseudo(fs_type, "mtd_inode:", NULL, MTD_INODE_FS_MAGIC);
1038 mnt);
1039} 1037}
1040 1038
1041static struct file_system_type mtd_inodefs_type = { 1039static struct file_system_type mtd_inodefs_type = {
1042 .name = "mtd_inodefs", 1040 .name = "mtd_inodefs",
1043 .get_sb = mtd_inodefs_get_sb, 1041 .mount = mtd_inodefs_mount,
1044 .kill_sb = kill_anon_super, 1042 .kill_sb = kill_anon_super,
1045}; 1043};
1046 1044
diff --git a/drivers/mtd/mtdsuper.c b/drivers/mtd/mtdsuper.c
index 38e2ab07e7a3..16b02a1fc100 100644
--- a/drivers/mtd/mtdsuper.c
+++ b/drivers/mtd/mtdsuper.c
@@ -54,11 +54,10 @@ static int get_sb_mtd_set(struct super_block *sb, void *_mtd)
54/* 54/*
55 * get a superblock on an MTD-backed filesystem 55 * get a superblock on an MTD-backed filesystem
56 */ 56 */
57static int get_sb_mtd_aux(struct file_system_type *fs_type, int flags, 57static struct dentry *mount_mtd_aux(struct file_system_type *fs_type, int flags,
58 const char *dev_name, void *data, 58 const char *dev_name, void *data,
59 struct mtd_info *mtd, 59 struct mtd_info *mtd,
60 int (*fill_super)(struct super_block *, void *, int), 60 int (*fill_super)(struct super_block *, void *, int))
61 struct vfsmount *mnt)
62{ 61{
63 struct super_block *sb; 62 struct super_block *sb;
64 int ret; 63 int ret;
@@ -79,57 +78,49 @@ static int get_sb_mtd_aux(struct file_system_type *fs_type, int flags,
79 ret = fill_super(sb, data, flags & MS_SILENT ? 1 : 0); 78 ret = fill_super(sb, data, flags & MS_SILENT ? 1 : 0);
80 if (ret < 0) { 79 if (ret < 0) {
81 deactivate_locked_super(sb); 80 deactivate_locked_super(sb);
82 return ret; 81 return ERR_PTR(ret);
83 } 82 }
84 83
85 /* go */ 84 /* go */
86 sb->s_flags |= MS_ACTIVE; 85 sb->s_flags |= MS_ACTIVE;
87 simple_set_mnt(mnt, sb); 86 return dget(sb->s_root);
88
89 return 0;
90 87
91 /* new mountpoint for an already mounted superblock */ 88 /* new mountpoint for an already mounted superblock */
92already_mounted: 89already_mounted:
93 DEBUG(1, "MTDSB: Device %d (\"%s\") is already mounted\n", 90 DEBUG(1, "MTDSB: Device %d (\"%s\") is already mounted\n",
94 mtd->index, mtd->name); 91 mtd->index, mtd->name);
95 simple_set_mnt(mnt, sb); 92 put_mtd_device(mtd);
96 ret = 0; 93 return dget(sb->s_root);
97 goto out_put;
98 94
99out_error: 95out_error:
100 ret = PTR_ERR(sb);
101out_put:
102 put_mtd_device(mtd); 96 put_mtd_device(mtd);
103 return ret; 97 return ERR_CAST(sb);
104} 98}
105 99
106/* 100/*
107 * get a superblock on an MTD-backed filesystem by MTD device number 101 * get a superblock on an MTD-backed filesystem by MTD device number
108 */ 102 */
109static int get_sb_mtd_nr(struct file_system_type *fs_type, int flags, 103static struct dentry *mount_mtd_nr(struct file_system_type *fs_type, int flags,
110 const char *dev_name, void *data, int mtdnr, 104 const char *dev_name, void *data, int mtdnr,
111 int (*fill_super)(struct super_block *, void *, int), 105 int (*fill_super)(struct super_block *, void *, int))
112 struct vfsmount *mnt)
113{ 106{
114 struct mtd_info *mtd; 107 struct mtd_info *mtd;
115 108
116 mtd = get_mtd_device(NULL, mtdnr); 109 mtd = get_mtd_device(NULL, mtdnr);
117 if (IS_ERR(mtd)) { 110 if (IS_ERR(mtd)) {
118 DEBUG(0, "MTDSB: Device #%u doesn't appear to exist\n", mtdnr); 111 DEBUG(0, "MTDSB: Device #%u doesn't appear to exist\n", mtdnr);
119 return PTR_ERR(mtd); 112 return ERR_CAST(mtd);
120 } 113 }
121 114
122 return get_sb_mtd_aux(fs_type, flags, dev_name, data, mtd, fill_super, 115 return mount_mtd_aux(fs_type, flags, dev_name, data, mtd, fill_super);
123 mnt);
124} 116}
125 117
126/* 118/*
127 * set up an MTD-based superblock 119 * set up an MTD-based superblock
128 */ 120 */
129int get_sb_mtd(struct file_system_type *fs_type, int flags, 121struct dentry *mount_mtd(struct file_system_type *fs_type, int flags,
130 const char *dev_name, void *data, 122 const char *dev_name, void *data,
131 int (*fill_super)(struct super_block *, void *, int), 123 int (*fill_super)(struct super_block *, void *, int))
132 struct vfsmount *mnt)
133{ 124{
134#ifdef CONFIG_BLOCK 125#ifdef CONFIG_BLOCK
135 struct block_device *bdev; 126 struct block_device *bdev;
@@ -138,7 +129,7 @@ int get_sb_mtd(struct file_system_type *fs_type, int flags,
138 int mtdnr; 129 int mtdnr;
139 130
140 if (!dev_name) 131 if (!dev_name)
141 return -EINVAL; 132 return ERR_PTR(-EINVAL);
142 133
143 DEBUG(2, "MTDSB: dev_name \"%s\"\n", dev_name); 134 DEBUG(2, "MTDSB: dev_name \"%s\"\n", dev_name);
144 135
@@ -156,10 +147,10 @@ int get_sb_mtd(struct file_system_type *fs_type, int flags,
156 147
157 mtd = get_mtd_device_nm(dev_name + 4); 148 mtd = get_mtd_device_nm(dev_name + 4);
158 if (!IS_ERR(mtd)) 149 if (!IS_ERR(mtd))
159 return get_sb_mtd_aux( 150 return mount_mtd_aux(
160 fs_type, flags, 151 fs_type, flags,
161 dev_name, data, mtd, 152 dev_name, data, mtd,
162 fill_super, mnt); 153 fill_super);
163 154
164 printk(KERN_NOTICE "MTD:" 155 printk(KERN_NOTICE "MTD:"
165 " MTD device with name \"%s\" not found.\n", 156 " MTD device with name \"%s\" not found.\n",
@@ -174,9 +165,9 @@ int get_sb_mtd(struct file_system_type *fs_type, int flags,
174 /* It was a valid number */ 165 /* It was a valid number */
175 DEBUG(1, "MTDSB: mtd%%d, mtdnr %d\n", 166 DEBUG(1, "MTDSB: mtd%%d, mtdnr %d\n",
176 mtdnr); 167 mtdnr);
177 return get_sb_mtd_nr(fs_type, flags, 168 return mount_mtd_nr(fs_type, flags,
178 dev_name, data, 169 dev_name, data,
179 mtdnr, fill_super, mnt); 170 mtdnr, fill_super);
180 } 171 }
181 } 172 }
182 } 173 }
@@ -189,7 +180,7 @@ int get_sb_mtd(struct file_system_type *fs_type, int flags,
189 if (IS_ERR(bdev)) { 180 if (IS_ERR(bdev)) {
190 ret = PTR_ERR(bdev); 181 ret = PTR_ERR(bdev);
191 DEBUG(1, "MTDSB: lookup_bdev() returned %d\n", ret); 182 DEBUG(1, "MTDSB: lookup_bdev() returned %d\n", ret);
192 return ret; 183 return ERR_PTR(ret);
193 } 184 }
194 DEBUG(1, "MTDSB: lookup_bdev() returned 0\n"); 185 DEBUG(1, "MTDSB: lookup_bdev() returned 0\n");
195 186
@@ -202,8 +193,7 @@ int get_sb_mtd(struct file_system_type *fs_type, int flags,
202 if (major != MTD_BLOCK_MAJOR) 193 if (major != MTD_BLOCK_MAJOR)
203 goto not_an_MTD_device; 194 goto not_an_MTD_device;
204 195
205 return get_sb_mtd_nr(fs_type, flags, dev_name, data, mtdnr, fill_super, 196 return mount_mtd_nr(fs_type, flags, dev_name, data, mtdnr, fill_super);
206 mnt);
207 197
208not_an_MTD_device: 198not_an_MTD_device:
209#endif /* CONFIG_BLOCK */ 199#endif /* CONFIG_BLOCK */
@@ -212,10 +202,10 @@ not_an_MTD_device:
212 printk(KERN_NOTICE 202 printk(KERN_NOTICE
213 "MTD: Attempt to mount non-MTD device \"%s\"\n", 203 "MTD: Attempt to mount non-MTD device \"%s\"\n",
214 dev_name); 204 dev_name);
215 return -EINVAL; 205 return ERR_PTR(-EINVAL);
216} 206}
217 207
218EXPORT_SYMBOL_GPL(get_sb_mtd); 208EXPORT_SYMBOL_GPL(mount_mtd);
219 209
220/* 210/*
221 * destroy an MTD-based superblock 211 * destroy an MTD-based superblock
diff --git a/drivers/oprofile/oprofilefs.c b/drivers/oprofile/oprofilefs.c
index 449de59bf35b..e9ff6f7770be 100644
--- a/drivers/oprofile/oprofilefs.c
+++ b/drivers/oprofile/oprofilefs.c
@@ -259,17 +259,17 @@ static int oprofilefs_fill_super(struct super_block *sb, void *data, int silent)
259} 259}
260 260
261 261
262static int oprofilefs_get_sb(struct file_system_type *fs_type, 262static struct dentry *oprofilefs_mount(struct file_system_type *fs_type,
263 int flags, const char *dev_name, void *data, struct vfsmount *mnt) 263 int flags, const char *dev_name, void *data)
264{ 264{
265 return get_sb_single(fs_type, flags, data, oprofilefs_fill_super, mnt); 265 return mount_single(fs_type, flags, data, oprofilefs_fill_super);
266} 266}
267 267
268 268
269static struct file_system_type oprofilefs_type = { 269static struct file_system_type oprofilefs_type = {
270 .owner = THIS_MODULE, 270 .owner = THIS_MODULE,
271 .name = "oprofilefs", 271 .name = "oprofilefs",
272 .get_sb = oprofilefs_get_sb, 272 .mount = oprofilefs_mount,
273 .kill_sb = kill_litter_super, 273 .kill_sb = kill_litter_super,
274}; 274};
275 275
diff --git a/drivers/staging/autofs/init.c b/drivers/staging/autofs/init.c
index 765c72f42976..5e4b372ea663 100644
--- a/drivers/staging/autofs/init.c
+++ b/drivers/staging/autofs/init.c
@@ -14,16 +14,16 @@
14#include <linux/init.h> 14#include <linux/init.h>
15#include "autofs_i.h" 15#include "autofs_i.h"
16 16
17static int autofs_get_sb(struct file_system_type *fs_type, 17static struct dentry *autofs_mount(struct file_system_type *fs_type,
18 int flags, const char *dev_name, void *data, struct vfsmount *mnt) 18 int flags, const char *dev_name, void *data)
19{ 19{
20 return get_sb_nodev(fs_type, flags, data, autofs_fill_super, mnt); 20 return mount_nodev(fs_type, flags, data, autofs_fill_super);
21} 21}
22 22
23static struct file_system_type autofs_fs_type = { 23static struct file_system_type autofs_fs_type = {
24 .owner = THIS_MODULE, 24 .owner = THIS_MODULE,
25 .name = "autofs", 25 .name = "autofs",
26 .get_sb = autofs_get_sb, 26 .mount = autofs_mount,
27 .kill_sb = autofs_kill_sb, 27 .kill_sb = autofs_kill_sb,
28}; 28};
29 29
diff --git a/drivers/staging/pohmelfs/inode.c b/drivers/staging/pohmelfs/inode.c
index c62d30017c07..61685ccceda8 100644
--- a/drivers/staging/pohmelfs/inode.c
+++ b/drivers/staging/pohmelfs/inode.c
@@ -1937,11 +1937,10 @@ err_out_exit:
1937/* 1937/*
1938 * Some VFS magic here... 1938 * Some VFS magic here...
1939 */ 1939 */
1940static int pohmelfs_get_sb(struct file_system_type *fs_type, 1940static struct dentry *pohmelfs_mount(struct file_system_type *fs_type,
1941 int flags, const char *dev_name, void *data, struct vfsmount *mnt) 1941 int flags, const char *dev_name, void *data)
1942{ 1942{
1943 return get_sb_nodev(fs_type, flags, data, pohmelfs_fill_super, 1943 return mount_nodev(fs_type, flags, data, pohmelfs_fill_super);
1944 mnt);
1945} 1944}
1946 1945
1947/* 1946/*
@@ -1958,7 +1957,7 @@ static void pohmelfs_kill_super(struct super_block *sb)
1958static struct file_system_type pohmel_fs_type = { 1957static struct file_system_type pohmel_fs_type = {
1959 .owner = THIS_MODULE, 1958 .owner = THIS_MODULE,
1960 .name = "pohmel", 1959 .name = "pohmel",
1961 .get_sb = pohmelfs_get_sb, 1960 .mount = pohmelfs_mount,
1962 .kill_sb = pohmelfs_kill_super, 1961 .kill_sb = pohmelfs_kill_super,
1963}; 1962};
1964 1963
diff --git a/drivers/staging/smbfs/inode.c b/drivers/staging/smbfs/inode.c
index 552951aa7498..f9c493591ce7 100644
--- a/drivers/staging/smbfs/inode.c
+++ b/drivers/staging/smbfs/inode.c
@@ -793,16 +793,16 @@ out:
793 return error; 793 return error;
794} 794}
795 795
796static int smb_get_sb(struct file_system_type *fs_type, 796static struct dentry *smb_mount(struct file_system_type *fs_type,
797 int flags, const char *dev_name, void *data, struct vfsmount *mnt) 797 int flags, const char *dev_name, void *data)
798{ 798{
799 return get_sb_nodev(fs_type, flags, data, smb_fill_super, mnt); 799 return mount_nodev(fs_type, flags, data, smb_fill_super);
800} 800}
801 801
802static struct file_system_type smb_fs_type = { 802static struct file_system_type smb_fs_type = {
803 .owner = THIS_MODULE, 803 .owner = THIS_MODULE,
804 .name = "smbfs", 804 .name = "smbfs",
805 .get_sb = smb_get_sb, 805 .mount = smb_mount,
806 .kill_sb = kill_anon_super, 806 .kill_sb = kill_anon_super,
807 .fs_flags = FS_BINARY_MOUNTDATA, 807 .fs_flags = FS_BINARY_MOUNTDATA,
808}; 808};
diff --git a/drivers/usb/core/inode.c b/drivers/usb/core/inode.c
index e2f63c0ea09d..9819a4cc3b26 100644
--- a/drivers/usb/core/inode.c
+++ b/drivers/usb/core/inode.c
@@ -574,16 +574,16 @@ static void fs_remove_file (struct dentry *dentry)
574 574
575/* --------------------------------------------------------------------- */ 575/* --------------------------------------------------------------------- */
576 576
577static int usb_get_sb(struct file_system_type *fs_type, 577static struct dentry *usb_mount(struct file_system_type *fs_type,
578 int flags, const char *dev_name, void *data, struct vfsmount *mnt) 578 int flags, const char *dev_name, void *data)
579{ 579{
580 return get_sb_single(fs_type, flags, data, usbfs_fill_super, mnt); 580 return mount_single(fs_type, flags, data, usbfs_fill_super);
581} 581}
582 582
583static struct file_system_type usb_fs_type = { 583static struct file_system_type usb_fs_type = {
584 .owner = THIS_MODULE, 584 .owner = THIS_MODULE,
585 .name = "usbfs", 585 .name = "usbfs",
586 .get_sb = usb_get_sb, 586 .mount = usb_mount,
587 .kill_sb = kill_litter_super, 587 .kill_sb = kill_litter_super,
588}; 588};
589 589
diff --git a/drivers/usb/gadget/f_fs.c b/drivers/usb/gadget/f_fs.c
index f276e9594f00..4a830df4fc31 100644
--- a/drivers/usb/gadget/f_fs.c
+++ b/drivers/usb/gadget/f_fs.c
@@ -1176,9 +1176,9 @@ invalid:
1176 1176
1177/* "mount -t functionfs dev_name /dev/function" ends up here */ 1177/* "mount -t functionfs dev_name /dev/function" ends up here */
1178 1178
1179static int 1179static struct dentry *
1180ffs_fs_get_sb(struct file_system_type *t, int flags, 1180ffs_fs_mount(struct file_system_type *t, int flags,
1181 const char *dev_name, void *opts, struct vfsmount *mnt) 1181 const char *dev_name, void *opts)
1182{ 1182{
1183 struct ffs_sb_fill_data data = { 1183 struct ffs_sb_fill_data data = {
1184 .perms = { 1184 .perms = {
@@ -1194,14 +1194,14 @@ ffs_fs_get_sb(struct file_system_type *t, int flags,
1194 1194
1195 ret = functionfs_check_dev_callback(dev_name); 1195 ret = functionfs_check_dev_callback(dev_name);
1196 if (unlikely(ret < 0)) 1196 if (unlikely(ret < 0))
1197 return ret; 1197 return ERR_PTR(ret);
1198 1198
1199 ret = ffs_fs_parse_opts(&data, opts); 1199 ret = ffs_fs_parse_opts(&data, opts);
1200 if (unlikely(ret < 0)) 1200 if (unlikely(ret < 0))
1201 return ret; 1201 return ERR_PTR(ret);
1202 1202
1203 data.dev_name = dev_name; 1203 data.dev_name = dev_name;
1204 return get_sb_single(t, flags, &data, ffs_sb_fill, mnt); 1204 return mount_single(t, flags, &data, ffs_sb_fill);
1205} 1205}
1206 1206
1207static void 1207static void
@@ -1220,7 +1220,7 @@ ffs_fs_kill_sb(struct super_block *sb)
1220static struct file_system_type ffs_fs_type = { 1220static struct file_system_type ffs_fs_type = {
1221 .owner = THIS_MODULE, 1221 .owner = THIS_MODULE,
1222 .name = "functionfs", 1222 .name = "functionfs",
1223 .get_sb = ffs_fs_get_sb, 1223 .mount = ffs_fs_mount,
1224 .kill_sb = ffs_fs_kill_sb, 1224 .kill_sb = ffs_fs_kill_sb,
1225}; 1225};
1226 1226
diff --git a/drivers/usb/gadget/inode.c b/drivers/usb/gadget/inode.c
index ba145e7fbe03..3ed73f49cf18 100644
--- a/drivers/usb/gadget/inode.c
+++ b/drivers/usb/gadget/inode.c
@@ -2097,11 +2097,11 @@ enomem0:
2097} 2097}
2098 2098
2099/* "mount -t gadgetfs path /dev/gadget" ends up here */ 2099/* "mount -t gadgetfs path /dev/gadget" ends up here */
2100static int 2100static struct dentry *
2101gadgetfs_get_sb (struct file_system_type *t, int flags, 2101gadgetfs_mount (struct file_system_type *t, int flags,
2102 const char *path, void *opts, struct vfsmount *mnt) 2102 const char *path, void *opts)
2103{ 2103{
2104 return get_sb_single (t, flags, opts, gadgetfs_fill_super, mnt); 2104 return mount_single (t, flags, opts, gadgetfs_fill_super);
2105} 2105}
2106 2106
2107static void 2107static void
@@ -2119,7 +2119,7 @@ gadgetfs_kill_sb (struct super_block *sb)
2119static struct file_system_type gadgetfs_type = { 2119static struct file_system_type gadgetfs_type = {
2120 .owner = THIS_MODULE, 2120 .owner = THIS_MODULE,
2121 .name = shortname, 2121 .name = shortname,
2122 .get_sb = gadgetfs_get_sb, 2122 .mount = gadgetfs_mount,
2123 .kill_sb = gadgetfs_kill_sb, 2123 .kill_sb = gadgetfs_kill_sb,
2124}; 2124};
2125 2125
diff --git a/drivers/xen/xenfs/super.c b/drivers/xen/xenfs/super.c
index d6662b789b6b..f6339d11d59c 100644
--- a/drivers/xen/xenfs/super.c
+++ b/drivers/xen/xenfs/super.c
@@ -121,17 +121,17 @@ static int xenfs_fill_super(struct super_block *sb, void *data, int silent)
121 return rc; 121 return rc;
122} 122}
123 123
124static int xenfs_get_sb(struct file_system_type *fs_type, 124static int xenfs_mount(struct file_system_type *fs_type,
125 int flags, const char *dev_name, 125 int flags, const char *dev_name,
126 void *data, struct vfsmount *mnt) 126 void *data)
127{ 127{
128 return get_sb_single(fs_type, flags, data, xenfs_fill_super, mnt); 128 return mount_single(fs_type, flags, data, xenfs_fill_super);
129} 129}
130 130
131static struct file_system_type xenfs_type = { 131static struct file_system_type xenfs_type = {
132 .owner = THIS_MODULE, 132 .owner = THIS_MODULE,
133 .name = "xenfs", 133 .name = "xenfs",
134 .get_sb = xenfs_get_sb, 134 .mount = xenfs_mount,
135 .kill_sb = kill_litter_super, 135 .kill_sb = kill_litter_super,
136}; 136};
137 137