Skip to content

Commit

Permalink
fuse: register_filesystem() called too early
Browse files Browse the repository at this point in the history
same story as with ubifs

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
  • Loading branch information
Al Viro committed Dec 13, 2011
1 parent 5cc361e commit 988f032
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions fs/fuse/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -1138,28 +1138,28 @@ static int __init fuse_fs_init(void)
{
int err;

err = register_filesystem(&fuse_fs_type);
if (err)
goto out;

err = register_fuseblk();
if (err)
goto out_unreg;

fuse_inode_cachep = kmem_cache_create("fuse_inode",
sizeof(struct fuse_inode),
0, SLAB_HWCACHE_ALIGN,
fuse_inode_init_once);
err = -ENOMEM;
if (!fuse_inode_cachep)
goto out_unreg2;
goto out;

err = register_fuseblk();
if (err)
goto out2;

err = register_filesystem(&fuse_fs_type);
if (err)
goto out3;

return 0;

out_unreg2:
out3:
unregister_fuseblk();
out_unreg:
unregister_filesystem(&fuse_fs_type);
out2:
kmem_cache_destroy(fuse_inode_cachep);
out:
return err;
}
Expand Down

0 comments on commit 988f032

Please sign in to comment.