
From: NeilBrown <neilb@cse.unsw.edu.au>

The return value of nfsd4_cb_recall isn't really used (and the errors we were
returning were incorrect anyway).

Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
Signed-off-by: Andrew Morton <akpm@osdl.org>
---

 25-akpm/fs/nfsd/nfs4callback.c     |   21 +++++++--------------
 25-akpm/include/linux/nfsd/state.h |    2 +-
 2 files changed, 8 insertions(+), 15 deletions(-)

diff -puN fs/nfsd/nfs4callback.c~nfsd4-make-nfsd4_cb_recall-return-void fs/nfsd/nfs4callback.c
--- 25/fs/nfsd/nfs4callback.c~nfsd4-make-nfsd4_cb_recall-return-void	2005-03-07 23:55:42.000000000 -0800
+++ 25-akpm/fs/nfsd/nfs4callback.c	2005-03-07 23:55:42.000000000 -0800
@@ -498,7 +498,6 @@ nfs4_cb_recall_done(struct rpc_task *tas
 {
 	struct nfs4_cb_recall *cbr = (struct nfs4_cb_recall *)task->tk_calldata;
 	struct nfs4_delegation *dp = cbr->cbr_dp;
-	int status;
 
 	/* all is well... */
 	if (task->tk_status == 0)
@@ -536,15 +535,14 @@ retry:
 	/* sleep 2 seconds before retrying recall */
 	set_current_state(TASK_UNINTERRUPTIBLE);
 	schedule_timeout(2*HZ);
-	status = nfsd4_cb_recall(dp);
-	dprintk("NFSD: nfs4_cb_recall_done: retry status: %d  dp %p dl_flock %p\n",status,dp, dp->dl_flock);
+	nfsd4_cb_recall(dp);
 }
 
 /*
  * called with dp->dl_count inc'ed.
  * nfs4_lock_state() may or may not have been called.
  */
-int
+void
 nfsd4_cb_recall(struct nfs4_delegation *dp)
 {
 	struct nfs4_client *clp;
@@ -559,26 +557,21 @@ nfsd4_cb_recall(struct nfs4_delegation *
 
 	clp = dp->dl_client;
 	clnt = clp->cl_callback.cb_client;
-	status = EIO;
 	if ((!atomic_read(&clp->cl_callback.cb_set)) || !clnt)
-		goto out_fail;
+		return;
 
 	msg.rpc_argp = cbr;
 	msg.rpc_resp = cbr;
 	msg.rpc_cred = nfsd4_lookupcred(clp,0);
+	if (IS_ERR(msg.rpc_cred))
+		return;
 
 	cbr->cbr_trunc = 0; /* XXX need to implement truncate optimization */
 	cbr->cbr_dp = dp;
 
 	if ((status = rpc_call_async(clnt, &msg, RPC_TASK_SOFT,
-		nfs4_cb_recall_done, cbr ))) {
+		nfs4_cb_recall_done, cbr )))
 		dprintk("NFSD: recall_delegation: rpc_call_async failed %d\n",
 			status);
-		goto out_fail;
-	}
-out:
-	return status;
-out_fail:
-	status = nfserrno(status);
-	goto out;
+	return;
 }
diff -puN include/linux/nfsd/state.h~nfsd4-make-nfsd4_cb_recall-return-void include/linux/nfsd/state.h
--- 25/include/linux/nfsd/state.h~nfsd4-make-nfsd4_cb_recall-return-void	2005-03-07 23:55:42.000000000 -0800
+++ 25-akpm/include/linux/nfsd/state.h	2005-03-07 23:55:42.000000000 -0800
@@ -289,7 +289,7 @@ extern int nfs4_check_open_reclaim(clien
 extern void put_nfs4_client(struct nfs4_client *clp);
 extern void nfs4_free_stateowner(struct kref *kref);
 extern void nfsd4_probe_callback(struct nfs4_client *clp);
-extern int nfsd4_cb_recall(struct nfs4_delegation *dp);
+extern void nfsd4_cb_recall(struct nfs4_delegation *dp);
 
 static inline void
 nfs4_put_stateowner(struct nfs4_stateowner *so)
_
