Merge branch 'for-3.4' of git://linux-nfs.org/~bfields/linux
[linux-2.6-block.git] / net / sunrpc / rpc_pipe.c
index e651e1b68514c7862d17a712a4cbac171b4ba369..0af37fc468181e9a6917c695d8f60dd381734e78 100644 (file)
@@ -1119,13 +1119,9 @@ rpc_fill_super(struct super_block *sb, void *data, int silent)
        sb->s_time_gran = 1;
 
        inode = rpc_get_inode(sb, S_IFDIR | 0755);
-       if (!inode)
-               return -ENOMEM;
-       sb->s_root = root = d_alloc_root(inode);
-       if (!root) {
-               iput(inode);
+       sb->s_root = root = d_make_root(inode);
+       if (!root)
                return -ENOMEM;
-       }
        if (rpc_populate(root, files, RPCAUTH_lockd, RPCAUTH_RootEOF, NULL))
                return -ENOMEM;
        dprintk("RPC:   sending pipefs MOUNT notification for net %p%s\n", net,