diff options
author | Chuck Lever <chuck.lever@oracle.com> | 2020-11-05 14:48:29 -0500 |
---|---|---|
committer | Chuck Lever <chuck.lever@oracle.com> | 2020-11-30 14:46:35 -0500 |
commit | 788f7183fba86b46074c16e7d57ea09302badff4 (patch) | |
tree | 0c6421ae15a0ce3282b5c08a78791de902df94cc /fs/nfsd/nfs4proc.c | |
parent | 5191955d6fc65e6d4efe8f4f10a6028298f57281 (diff) | |
download | lwn-788f7183fba86b46074c16e7d57ea09302badff4.tar.gz lwn-788f7183fba86b46074c16e7d57ea09302badff4.zip |
NFSD: Add common helpers to decode void args and encode void results
Start off the conversion to xdr_stream by de-duplicating the functions
that decode void arguments and encode void results.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Diffstat (limited to 'fs/nfsd/nfs4proc.c')
-rw-r--r-- | fs/nfsd/nfs4proc.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/fs/nfsd/nfs4proc.c b/fs/nfsd/nfs4proc.c index 20772f6b0b2d..76300b0441f0 100644 --- a/fs/nfsd/nfs4proc.c +++ b/fs/nfsd/nfs4proc.c @@ -3295,16 +3295,13 @@ static const char *nfsd4_op_name(unsigned opnum) return "unknown_operation"; } -#define nfsd4_voidres nfsd4_voidargs -struct nfsd4_voidargs { int dummy; }; - static const struct svc_procedure nfsd_procedures4[2] = { [NFSPROC4_NULL] = { .pc_func = nfsd4_proc_null, - .pc_decode = nfs4svc_decode_voidarg, - .pc_encode = nfs4svc_encode_voidres, - .pc_argsize = sizeof(struct nfsd4_voidargs), - .pc_ressize = sizeof(struct nfsd4_voidres), + .pc_decode = nfssvc_decode_voidarg, + .pc_encode = nfssvc_encode_voidres, + .pc_argsize = sizeof(struct nfsd_voidargs), + .pc_ressize = sizeof(struct nfsd_voidres), .pc_cachetype = RC_NOCACHE, .pc_xdrressize = 1, }, |