diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2011-12-08 23:01:06 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2012-01-03 22:52:42 -0500 |
commit | c972b4bc8331b432f51a5f1bc3ca7e020172717f (patch) | |
tree | 2eefe85d32357b53c51a14c84bca7ea4ff47876b | |
parent | 4c1d5a64f134b254552b6211f6f79a1da667eab7 (diff) |
vfs: live vfsmounts never have NULL ->mnt_sb
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r-- | drivers/usb/core/inode.c | 5 | ||||
-rw-r--r-- | fs/configfs/dir.c | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/drivers/usb/core/inode.c b/drivers/usb/core/inode.c index 0a4613df6c30..783fde7f44c8 100644 --- a/drivers/usb/core/inode.c +++ b/drivers/usb/core/inode.c | |||
@@ -264,7 +264,7 @@ static int remount(struct super_block *sb, int *flags, char *data) | |||
264 | return -EINVAL; | 264 | return -EINVAL; |
265 | } | 265 | } |
266 | 266 | ||
267 | if (usbfs_mount && usbfs_mount->mnt_sb) | 267 | if (usbfs_mount) |
268 | update_sb(usbfs_mount->mnt_sb); | 268 | update_sb(usbfs_mount->mnt_sb); |
269 | 269 | ||
270 | return 0; | 270 | return 0; |
@@ -500,9 +500,8 @@ static int fs_create_by_name (const char *name, mode_t mode, | |||
500 | * have around. | 500 | * have around. |
501 | */ | 501 | */ |
502 | if (!parent ) { | 502 | if (!parent ) { |
503 | if (usbfs_mount && usbfs_mount->mnt_sb) { | 503 | if (usbfs_mount) |
504 | parent = usbfs_mount->mnt_root; | 504 | parent = usbfs_mount->mnt_root; |
505 | } | ||
506 | } | 505 | } |
507 | 506 | ||
508 | if (!parent) { | 507 | if (!parent) { |
diff --git a/fs/configfs/dir.c b/fs/configfs/dir.c index 36b1d7aadba1..1c5296911104 100644 --- a/fs/configfs/dir.c +++ b/fs/configfs/dir.c | |||
@@ -311,7 +311,7 @@ static int configfs_create_dir(struct config_item * item, struct dentry *dentry) | |||
311 | 311 | ||
312 | if (item->ci_parent) | 312 | if (item->ci_parent) |
313 | parent = item->ci_parent->ci_dentry; | 313 | parent = item->ci_parent->ci_dentry; |
314 | else if (configfs_mount && configfs_mount->mnt_sb) | 314 | else if (configfs_mount) |
315 | parent = configfs_mount->mnt_root; | 315 | parent = configfs_mount->mnt_root; |
316 | else | 316 | else |
317 | return -EFAULT; | 317 | return -EFAULT; |