summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorTrond Myklebust <trond.myklebust@hammerspace.com>2020-12-04 15:16:46 -0500
committerTrond Myklebust <trond.myklebust@hammerspace.com>2020-12-14 06:51:07 -0500
commit9a20f6f4e6ba9713605fbf7e7426ca22f1181545 (patch)
treedaeff278962badcaca252fa9546bc6177fba964f /include
parentc54e959b36cbdb0cb2f2805e3e945dd83476a5c7 (diff)
downloadlinux-stable-9a20f6f4e6ba9713605fbf7e7426ca22f1181545.tar.gz
linux-stable-9a20f6f4e6ba9713605fbf7e7426ca22f1181545.tar.bz2
linux-stable-9a20f6f4e6ba9713605fbf7e7426ca22f1181545.zip
SUNRPC: Fixes for xdr_align_data()
The main use case right now for xdr_align_data() is to shift the page data to the left, and in practice shrink the total XDR data buffer. This patch ensures that we fix up the accounting for the buffer length as we shift that data around. Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/sunrpc/xdr.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/sunrpc/xdr.h b/include/linux/sunrpc/xdr.h
index 9548d075e06d..2b4e44bb0654 100644
--- a/include/linux/sunrpc/xdr.h
+++ b/include/linux/sunrpc/xdr.h
@@ -252,7 +252,7 @@ extern __be32 *xdr_inline_decode(struct xdr_stream *xdr, size_t nbytes);
extern unsigned int xdr_read_pages(struct xdr_stream *xdr, unsigned int len);
extern void xdr_enter_page(struct xdr_stream *xdr, unsigned int len);
extern int xdr_process_buf(struct xdr_buf *buf, unsigned int offset, unsigned int len, int (*actor)(struct scatterlist *, void *), void *data);
-extern uint64_t xdr_align_data(struct xdr_stream *, uint64_t, uint32_t);
+extern unsigned int xdr_align_data(struct xdr_stream *, unsigned int offset, unsigned int length);
extern uint64_t xdr_expand_hole(struct xdr_stream *, uint64_t, uint64_t);
/**