Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 294376
b: refs/heads/master
c: 70fe25b
h: refs/heads/master
v: v3
  • Loading branch information
Stanislav Kinsbursky authored and Trond Myklebust committed Jan 31, 2012
1 parent 9ffd3c9 commit 07404fd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 17 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f5131257f771ad0e84cf0314a2a86b66318755a9
refs/heads/master: 70fe25b6e1a535f09792d1ed7012036c7bd506b2
19 changes: 3 additions & 16 deletions trunk/net/sunrpc/clnt.c
Original file line number Diff line number Diff line change
Expand Up @@ -109,17 +109,12 @@ static void __rpc_clnt_remove_pipedir(struct rpc_clnt *clnt)
static void rpc_clnt_remove_pipedir(struct rpc_clnt *clnt)
{
struct super_block *pipefs_sb;
int put_mnt = 0;

pipefs_sb = rpc_get_sb_net(clnt->cl_xprt->xprt_net);
if (pipefs_sb) {
if (clnt->cl_path.dentry)
put_mnt = 1;
__rpc_clnt_remove_pipedir(clnt);
rpc_put_sb_net(clnt->cl_xprt->xprt_net);
}
if (put_mnt)
rpc_put_mount();
}

static struct dentry *rpc_setup_pipedir_sb(struct super_block *sb,
Expand Down Expand Up @@ -165,21 +160,13 @@ rpc_setup_pipedir(struct rpc_clnt *clnt, char *dir_name)
clnt->cl_path.dentry = NULL;
if (dir_name == NULL)
return 0;

path.mnt = rpc_get_mount();
if (IS_ERR(path.mnt))
return PTR_ERR(path.mnt);
pipefs_sb = rpc_get_sb_net(clnt->cl_xprt->xprt_net);
if (!pipefs_sb) {
rpc_put_mount();
return -ENOENT;
}
if (!pipefs_sb)
return 0;
path.dentry = rpc_setup_pipedir_sb(pipefs_sb, clnt, dir_name);
rpc_put_sb_net(clnt->cl_xprt->xprt_net);
if (IS_ERR(path.dentry)) {
rpc_put_mount();
if (IS_ERR(path.dentry))
return PTR_ERR(path.dentry);
}
clnt->cl_path = path;
return 0;
}
Expand Down

0 comments on commit 07404fd

Please sign in to comment.