diff options
author | Christoph Hellwig <hch@lst.de> | 2017-05-08 17:35:49 +0200 |
---|---|---|
committer | Anna Schumaker <Anna.Schumaker@Netapp.com> | 2017-07-13 15:57:59 -0400 |
commit | 1c8a5409f3c4748ff42c1721d9578dd03091f378 (patch) | |
tree | 70ff6480826a2120ee50aef20a9cdf0a2935ee2b /fs/nfs | |
parent | 36ba89c2a40fe138898b394106205a3853ef2a4d (diff) | |
download | linux-stable-1c8a5409f3c4748ff42c1721d9578dd03091f378.tar.gz linux-stable-1c8a5409f3c4748ff42c1721d9578dd03091f378.tar.bz2 linux-stable-1c8a5409f3c4748ff42c1721d9578dd03091f378.zip |
sunrpc: properly type pc_func callbacks
Drop the argp and resp arguments as they 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 svc_procfunc as well as the
svc_procfunc typedef itself.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'fs/nfs')
-rw-r--r-- | fs/nfs/callback_xdr.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/fs/nfs/callback_xdr.c b/fs/nfs/callback_xdr.c index 287c02202b25..5a14bdaa5986 100644 --- a/fs/nfs/callback_xdr.c +++ b/fs/nfs/callback_xdr.c @@ -53,7 +53,7 @@ struct callback_op { static struct callback_op callback_ops[]; -static __be32 nfs4_callback_null(struct svc_rqst *rqstp, void *argp, void *resp) +static __be32 nfs4_callback_null(struct svc_rqst *rqstp) { return htonl(NFS4_OK); } @@ -880,7 +880,7 @@ encode_hdr: /* * Decode, process and encode a COMPOUND */ -static __be32 nfs4_callback_compound(struct svc_rqst *rqstp, void *argp, void *resp) +static __be32 nfs4_callback_compound(struct svc_rqst *rqstp) { struct cb_compound_hdr_arg hdr_arg = { 0 }; struct cb_compound_hdr_res hdr_res = { NULL }; @@ -916,7 +916,8 @@ static __be32 nfs4_callback_compound(struct svc_rqst *rqstp, void *argp, void *r while (status == 0 && nops != hdr_arg.nops) { status = process_op(nops, rqstp, &xdr_in, - argp, &xdr_out, resp, &cps); + rqstp->rq_argp, &xdr_out, rqstp->rq_resp, + &cps); nops++; } |