aboutsummaryrefslogtreecommitdiffstats
path: root/net/sunrpc/sched.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/sunrpc/sched.c')
-rw-r--r--net/sunrpc/sched.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/net/sunrpc/sched.c b/net/sunrpc/sched.c
index 0e9fbbd4f987..bb12983580a0 100644
--- a/net/sunrpc/sched.c
+++ b/net/sunrpc/sched.c
@@ -846,7 +846,7 @@ void rpc_init_task(struct rpc_task *task, struct rpc_clnt *clnt, int flags, cons
846 task->tk_workqueue = rpciod_workqueue; 846 task->tk_workqueue = rpciod_workqueue;
847 847
848 if (clnt) { 848 if (clnt) {
849 atomic_inc(&clnt->cl_users); 849 kref_get(&clnt->cl_kref);
850 if (clnt->cl_softrtry) 850 if (clnt->cl_softrtry)
851 task->tk_flags |= RPC_TASK_SOFT; 851 task->tk_flags |= RPC_TASK_SOFT;
852 if (!clnt->cl_intr) 852 if (!clnt->cl_intr)
@@ -898,9 +898,7 @@ out:
898cleanup: 898cleanup:
899 /* Check whether to release the client */ 899 /* Check whether to release the client */
900 if (clnt) { 900 if (clnt) {
901 printk("rpc_new_task: failed, users=%d, oneshot=%d\n", 901 kref_get(&clnt->cl_kref); /* pretend we were used ... */
902 atomic_read(&clnt->cl_users), clnt->cl_oneshot);
903 atomic_inc(&clnt->cl_users); /* pretend we were used ... */
904 rpc_release_client(clnt); 902 rpc_release_client(clnt);
905 } 903 }
906 goto out; 904 goto out;