summaryrefslogtreecommitdiffstats
path: root/fs/nfs/nfs4xdr.c
diff options
context:
space:
mode:
authorAnna Schumaker <Anna.Schumaker@netapp.com>2014-05-06 09:12:25 -0400
committerTrond Myklebust <trond.myklebust@primarydata.com>2014-05-28 18:12:43 -0400
commit9137bdf3d241fc2cbeb2a8ced51d1546150aa6a1 (patch)
treebcce3aa0d097ec8eadd4ed61236dc452903f486c /fs/nfs/nfs4xdr.c
parent3c6b899c49e5e9c2803b59ee553eddaf69cea7f6 (diff)
NFS: Create a common results structure for reads and writes
Reads and writes have very similar results. This patch combines the two structs together with comments to show where the differing fields are used. Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Diffstat (limited to 'fs/nfs/nfs4xdr.c')
-rw-r--r--fs/nfs/nfs4xdr.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/fs/nfs/nfs4xdr.c b/fs/nfs/nfs4xdr.c
index 032159c36a57..939ae606cfa4 100644
--- a/fs/nfs/nfs4xdr.c
+++ b/fs/nfs/nfs4xdr.c
@@ -5087,7 +5087,8 @@ static int decode_putrootfh(struct xdr_stream *xdr)
5087 return decode_op_hdr(xdr, OP_PUTROOTFH); 5087 return decode_op_hdr(xdr, OP_PUTROOTFH);
5088} 5088}
5089 5089
5090static int decode_read(struct xdr_stream *xdr, struct rpc_rqst *req, struct nfs_readres *res) 5090static int decode_read(struct xdr_stream *xdr, struct rpc_rqst *req,
5091 struct nfs_pgio_res *res)
5091{ 5092{
5092 __be32 *p; 5093 __be32 *p;
5093 uint32_t count, eof, recvd; 5094 uint32_t count, eof, recvd;
@@ -5341,7 +5342,7 @@ static int decode_setclientid_confirm(struct xdr_stream *xdr)
5341 return decode_op_hdr(xdr, OP_SETCLIENTID_CONFIRM); 5342 return decode_op_hdr(xdr, OP_SETCLIENTID_CONFIRM);
5342} 5343}
5343 5344
5344static int decode_write(struct xdr_stream *xdr, struct nfs_writeres *res) 5345static int decode_write(struct xdr_stream *xdr, struct nfs_pgio_res *res)
5345{ 5346{
5346 __be32 *p; 5347 __be32 *p;
5347 int status; 5348 int status;
@@ -6638,7 +6639,7 @@ out:
6638 * Decode Read response 6639 * Decode Read response
6639 */ 6640 */
6640static int nfs4_xdr_dec_read(struct rpc_rqst *rqstp, struct xdr_stream *xdr, 6641static int nfs4_xdr_dec_read(struct rpc_rqst *rqstp, struct xdr_stream *xdr,
6641 struct nfs_readres *res) 6642 struct nfs_pgio_res *res)
6642{ 6643{
6643 struct compound_hdr hdr; 6644 struct compound_hdr hdr;
6644 int status; 6645 int status;
@@ -6663,7 +6664,7 @@ out:
6663 * Decode WRITE response 6664 * Decode WRITE response
6664 */ 6665 */
6665static int nfs4_xdr_dec_write(struct rpc_rqst *rqstp, struct xdr_stream *xdr, 6666static int nfs4_xdr_dec_write(struct rpc_rqst *rqstp, struct xdr_stream *xdr,
6666 struct nfs_writeres *res) 6667 struct nfs_pgio_res *res)
6667{ 6668{
6668 struct compound_hdr hdr; 6669 struct compound_hdr hdr;
6669 int status; 6670 int status;