summaryrefslogtreecommitdiff
path: root/fs/nfsd/nfs3acl.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2017-05-08 19:01:48 +0200
committerAnna Schumaker <Anna.Schumaker@Netapp.com>2017-07-13 15:58:00 -0400
commitcc6acc20a606f9ca65a6338af8204b7ae9e67b1a (patch)
treeffaf4738edc082371a54162e032bbef0155a64eb /fs/nfsd/nfs3acl.c
parent1150ded804c2be6d02efef3e39e39e570c9cea21 (diff)
sunrpc: properly type pc_decode callbacks
Drop the argp argument as it can trivially be derived from the rqstp argument. With that all functions now have the same prototype, and we can remove the unsafe casting to kxdrproc_t. Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'fs/nfsd/nfs3acl.c')
-rw-r--r--fs/nfsd/nfs3acl.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/fs/nfsd/nfs3acl.c b/fs/nfsd/nfs3acl.c
index 56cdff4e954c..4e68d6b5f409 100644
--- a/fs/nfsd/nfs3acl.c
+++ b/fs/nfsd/nfs3acl.c
@@ -124,9 +124,10 @@ out:
/*
* XDR decode functions
*/
-static int nfs3svc_decode_getaclargs(struct svc_rqst *rqstp, __be32 *p,
- struct nfsd3_getaclargs *args)
+static int nfs3svc_decode_getaclargs(struct svc_rqst *rqstp, __be32 *p)
{
+ struct nfsd3_getaclargs *args = rqstp->rq_argp;
+
p = nfs3svc_decode_fh(p, &args->fh);
if (!p)
return 0;
@@ -136,9 +137,9 @@ static int nfs3svc_decode_getaclargs(struct svc_rqst *rqstp, __be32 *p,
}
-static int nfs3svc_decode_setaclargs(struct svc_rqst *rqstp, __be32 *p,
- struct nfsd3_setaclargs *args)
+static int nfs3svc_decode_setaclargs(struct svc_rqst *rqstp, __be32 *p)
{
+ struct nfsd3_setaclargs *args = rqstp->rq_argp;
struct kvec *head = rqstp->rq_arg.head;
unsigned int base;
int n;
@@ -241,7 +242,7 @@ struct nfsd3_voidargs { int dummy; };
#define PROC(name, argt, rest, relt, cache, respsize) \
{ \
.pc_func = nfsd3_proc_##name, \
- .pc_decode = (kxdrproc_t) nfs3svc_decode_##argt##args, \
+ .pc_decode = nfs3svc_decode_##argt##args, \
.pc_encode = (kxdrproc_t) nfs3svc_encode_##rest##res, \
.pc_release = nfs3svc_release_##relt, \
.pc_argsize = sizeof(struct nfsd3_##argt##args), \