Commit d38e570f authored by Chuck Lever's avatar Chuck Lever

NFSD: Clean up nfsd4_encode_access()

Convert nfsd4_encode_access() to use modern XDR utility functions.
Reviewed-by: default avatarJeff Layton <jlayton@kernel.org>
Signed-off-by: default avatarChuck Lever <chuck.lever@oracle.com>
parent 25c307ac
...@@ -3908,14 +3908,14 @@ nfsd4_encode_access(struct nfsd4_compoundres *resp, __be32 nfserr, ...@@ -3908,14 +3908,14 @@ nfsd4_encode_access(struct nfsd4_compoundres *resp, __be32 nfserr,
{ {
struct nfsd4_access *access = &u->access; struct nfsd4_access *access = &u->access;
struct xdr_stream *xdr = resp->xdr; struct xdr_stream *xdr = resp->xdr;
__be32 *p; __be32 status;
p = xdr_reserve_space(xdr, 8); /* supported */
if (!p) status = nfsd4_encode_uint32_t(xdr, access->ac_supported);
return nfserr_resource; if (status != nfs_ok)
*p++ = cpu_to_be32(access->ac_supported); return status;
*p++ = cpu_to_be32(access->ac_resp_access); /* access */
return 0; return nfsd4_encode_uint32_t(xdr, access->ac_resp_access);
} }
static __be32 nfsd4_encode_bind_conn_to_session(struct nfsd4_compoundres *resp, __be32 nfserr, static __be32 nfsd4_encode_bind_conn_to_session(struct nfsd4_compoundres *resp, __be32 nfserr,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment