2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2025-01-02 10:43:57 +08:00

NFSD: Replace READ* macros in nfsd4_decode_readdir()

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
This commit is contained in:
Chuck Lever 2020-11-03 14:30:59 -05:00
parent 3909c3bc60
commit 0dfaf2a371

View File

@ -1234,17 +1234,22 @@ nfsd4_decode_read(struct nfsd4_compoundargs *argp, struct nfsd4_read *read)
static __be32
nfsd4_decode_readdir(struct nfsd4_compoundargs *argp, struct nfsd4_readdir *readdir)
{
DECODE_HEAD;
__be32 status;
READ_BUF(24);
p = xdr_decode_hyper(p, &readdir->rd_cookie);
COPYMEM(readdir->rd_verf.data, sizeof(readdir->rd_verf.data));
readdir->rd_dircount = be32_to_cpup(p++);
readdir->rd_maxcount = be32_to_cpup(p++);
if ((status = nfsd4_decode_bitmap(argp, readdir->rd_bmval)))
goto out;
if (xdr_stream_decode_u64(argp->xdr, &readdir->rd_cookie) < 0)
return nfserr_bad_xdr;
status = nfsd4_decode_verifier4(argp, &readdir->rd_verf);
if (status)
return status;
if (xdr_stream_decode_u32(argp->xdr, &readdir->rd_dircount) < 0)
return nfserr_bad_xdr;
if (xdr_stream_decode_u32(argp->xdr, &readdir->rd_maxcount) < 0)
return nfserr_bad_xdr;
if (xdr_stream_decode_uint32_array(argp->xdr, readdir->rd_bmval,
ARRAY_SIZE(readdir->rd_bmval)) < 0)
return nfserr_bad_xdr;
DECODE_TAIL;
return nfs_ok;
}
static __be32