tidy up after d_make_root() conversion

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
Al Viro
2012-02-12 22:08:01 -05:00
parent ca85c07809
commit 318ceed088
6 changed files with 26 additions and 53 deletions

View File

@@ -2175,7 +2175,6 @@ static void shmem_put_super(struct super_block *sb)
int shmem_fill_super(struct super_block *sb, void *data, int silent)
{
struct inode *inode;
struct dentry *root;
struct shmem_sb_info *sbinfo;
int err = -ENOMEM;
@@ -2232,10 +2231,9 @@ int shmem_fill_super(struct super_block *sb, void *data, int silent)
goto failed;
inode->i_uid = sbinfo->uid;
inode->i_gid = sbinfo->gid;
root = d_make_root(inode);
if (!root)
sb->s_root = d_make_root(inode);
if (!sb->s_root)
goto failed;
sb->s_root = root;
return 0;
failed: