Skip to content

Commit

Permalink
SUNRPC: Don't create an rpc_pipefs directory before rpc_clone is init…
Browse files Browse the repository at this point in the history
…ialised

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
  • Loading branch information
Trond Myklebust authored and Trond Myklebust committed Jul 11, 2007
1 parent 4c402b4 commit d431a55
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions net/sunrpc/clnt.c
Original file line number Diff line number Diff line change
Expand Up @@ -269,23 +269,23 @@ rpc_clone_client(struct rpc_clnt *clnt)
new = kmemdup(clnt, sizeof(*new), GFP_KERNEL);
if (!new)
goto out_no_clnt;
new->cl_parent = clnt;
/* Turn off autobind on clones */
new->cl_autobind = 0;
INIT_LIST_HEAD(&new->cl_tasks);
spin_lock_init(&new->cl_lock);
rpc_init_rtt(&new->cl_rtt_default, clnt->cl_xprt->timeout.to_initval);
new->cl_metrics = rpc_alloc_iostats(clnt);
if (new->cl_metrics == NULL)
goto out_no_stats;
kref_init(&new->cl_kref);
err = rpc_setup_pipedir(new, clnt->cl_program->pipe_dir_name);
if (err != 0)
goto out_no_path;
new->cl_parent = clnt;
kref_get(&clnt->cl_kref);
new->cl_xprt = xprt_get(clnt->cl_xprt);
/* Turn off autobind on clones */
new->cl_autobind = 0;
INIT_LIST_HEAD(&new->cl_tasks);
spin_lock_init(&new->cl_lock);
rpc_init_rtt(&new->cl_rtt_default, clnt->cl_xprt->timeout.to_initval);
if (new->cl_auth)
atomic_inc(&new->cl_auth->au_count);
xprt_get(clnt->cl_xprt);
kref_get(&clnt->cl_kref);
rpc_register_client(new);
return new;
out_no_path:
Expand Down

0 comments on commit d431a55

Please sign in to comment.