mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 02:21:52 +09:00
pnfsblock: add missing rpc_put_mount and path_put
commit 760383f1ee upstream.
Reviewed-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
7ab7073b8b
commit
f135656f64
@@ -993,17 +993,20 @@ static int __init nfs4blocklayout_init(void)
|
||||
mnt,
|
||||
NFS_PIPE_DIRNAME, 0, &path);
|
||||
if (ret)
|
||||
goto out_remove;
|
||||
goto out_putrpc;
|
||||
|
||||
bl_device_pipe = rpc_mkpipe(path.dentry, "blocklayout", NULL,
|
||||
&bl_upcall_ops, 0);
|
||||
path_put(&path);
|
||||
if (IS_ERR(bl_device_pipe)) {
|
||||
ret = PTR_ERR(bl_device_pipe);
|
||||
goto out_remove;
|
||||
goto out_putrpc;
|
||||
}
|
||||
out:
|
||||
return ret;
|
||||
|
||||
out_putrpc:
|
||||
rpc_put_mount();
|
||||
out_remove:
|
||||
pnfs_unregister_layoutdriver(&blocklayout_type);
|
||||
return ret;
|
||||
@@ -1016,6 +1019,7 @@ static void __exit nfs4blocklayout_exit(void)
|
||||
|
||||
pnfs_unregister_layoutdriver(&blocklayout_type);
|
||||
rpc_unlink(bl_device_pipe);
|
||||
rpc_put_mount();
|
||||
}
|
||||
|
||||
MODULE_ALIAS("nfs-layouttype4-3");
|
||||
|
||||
Reference in New Issue
Block a user