diff options
author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2006-01-03 03:55:10 -0500 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2006-01-06 14:58:42 -0500 |
commit | e60859ac0e50f660d23b72e42e05f58757dcfeff (patch) | |
tree | a48b07cea18971545bd6670f66f8b8341d393cbc /net/sunrpc/clnt.c | |
parent | 89991c24e48b76f40aa3bd8c40c1e87c75d10a33 (diff) |
SUNRPC: rpc_execute should not return task->tk_status;
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'net/sunrpc/clnt.c')
-rw-r--r-- | net/sunrpc/clnt.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/net/sunrpc/clnt.c b/net/sunrpc/clnt.c index 8b2f75bc006d..f025b7e72353 100644 --- a/net/sunrpc/clnt.c +++ b/net/sunrpc/clnt.c | |||
@@ -446,14 +446,15 @@ int rpc_call_sync(struct rpc_clnt *clnt, struct rpc_message *msg, int flags) | |||
446 | rpc_call_setup(task, msg, 0); | 446 | rpc_call_setup(task, msg, 0); |
447 | 447 | ||
448 | /* Set up the call info struct and execute the task */ | 448 | /* Set up the call info struct and execute the task */ |
449 | if (task->tk_status == 0) { | 449 | status = task->tk_status; |
450 | if (status == 0) { | ||
451 | atomic_inc(&task->tk_count); | ||
450 | status = rpc_execute(task); | 452 | status = rpc_execute(task); |
451 | } else { | 453 | if (status == 0) |
452 | status = task->tk_status; | 454 | status = task->tk_status; |
453 | rpc_release_task(task); | ||
454 | } | 455 | } |
455 | |||
456 | rpc_restore_sigmask(&oldset); | 456 | rpc_restore_sigmask(&oldset); |
457 | rpc_release_task(task); | ||
457 | out: | 458 | out: |
458 | return status; | 459 | return status; |
459 | } | 460 | } |