From 89fc0a31eb36a683d331be8f59bef740141fb2af Mon Sep 17 00:00:00 2001 From: Neil Brown Date: Thu, 21 Nov 2002 19:20:01 -0800 Subject: [PATCH] kNFSd - 1 of 2 - Change NFSv4 xdr decoding to cope with separate pages. Now that nfsd uses a list of pages for requests instead of one large buffer, NFSv4 need to know about this. The most interesting part of this is that it is possible that section of a request, like a path name, could span two pages, so we need to be able to kmalloc as little bit of space to copy them into, and make sure they get freed later. --- include/linux/nfsd/xdr4.h | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'include/linux/nfsd') diff --git a/include/linux/nfsd/xdr4.h b/include/linux/nfsd/xdr4.h index 4238cb04ad90..72b7c03dfc1a 100644 --- a/include/linux/nfsd/xdr4.h +++ b/include/linux/nfsd/xdr4.h @@ -249,7 +249,9 @@ struct nfsd4_write { u64 wr_offset; /* request */ u32 wr_stable_how; /* request */ u32 wr_buflen; /* request */ - char * wr_buf; /* request */ + struct iovec wr_vec[RPCSVC_MAXPAGES]; /* request */ + int wr_vlen; + u32 wr_bytes_written; /* response */ u32 wr_how_written; /* response */ nfs4_verifier wr_verifier; /* response */ @@ -288,6 +290,14 @@ struct nfsd4_compoundargs { /* scratch variables for XDR decode */ u32 * p; u32 * end; + struct page ** pagelist; + int pagelen; + u32 tmp[8]; + u32 * tmpp; + struct tmpbuf { + struct tmpbuf *next; + void *buf; + } *to_free; u32 taglen; char * tag; -- cgit v1.2.3