nfsd4: use local variable in nfs4svc_encode_compoundres
authorBenny Halevy <bhalevy@panasas.com>
Mon, 3 May 2010 16:31:33 +0000 (19:31 +0300)
committerJ. Bruce Fields <bfields@citi.umich.edu>
Tue, 4 May 2010 14:10:36 +0000 (10:10 -0400)
'cs' is already computed, re-use it.

Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
fs/nfsd/nfs4xdr.c

index 05bc5bd63c954a86b6984dedd7889dfb505bed48..b27bcf33107c57fd87e7537e948f25e3c06d2977 100644 (file)
@@ -3310,9 +3310,9 @@ nfs4svc_encode_compoundres(struct svc_rqst *rqstp, __be32 *p, struct nfsd4_compo
                if (cs->status != nfserr_replay_cache) {
                        nfsd4_store_cache_entry(resp);
                        dprintk("%s: SET SLOT STATE TO AVAILABLE\n", __func__);
-                       resp->cstate.slot->sl_inuse = false;
+                       cs->slot->sl_inuse = false;
                }
-               nfsd4_put_session(resp->cstate.session);
+               nfsd4_put_session(cs->session);
        }
        return 1;
 }