switch open-coded instances of d_make_root() to new helper
[deliverable/linux.git] / arch / s390 / hypfs / inode.c
index 8a2a887478cc770141f7f8138ee0b8cce44dda54..6a2cb560e968ec1cd430200b0fb4cb9e2d3e87b7 100644 (file)
@@ -293,11 +293,9 @@ static int hypfs_fill_super(struct super_block *sb, void *data, int silent)
                return -ENOMEM;
        root_inode->i_op = &simple_dir_inode_operations;
        root_inode->i_fop = &simple_dir_operations;
-       sb->s_root = root_dentry = d_alloc_root(root_inode);
-       if (!root_dentry) {
-               iput(root_inode);
+       sb->s_root = root_dentry = d_make_root(root_inode);
+       if (!root_dentry)
                return -ENOMEM;
-       }
        if (MACHINE_IS_VM)
                rc = hypfs_vm_create_files(sb, root_dentry);
        else
This page took 0.02487 seconds and 5 git commands to generate.