diff options
author | 2015-06-08 12:03:32 -0700 | |
---|---|---|
committer | 2015-08-10 16:05:40 -0400 | |
commit | ea126e74353453d15fc0a181910ae1e25162f2a1 (patch) | |
tree | 649da943b8d6c391f0936971897165c0003a76d7 /fs/nfsd/nfssvc.c | |
parent | svcrdma: Change maximum server payload back to RPCSVC_MAXPAYLOAD (diff) | |
download | linux-ea126e74353453d15fc0a181910ae1e25162f2a1.tar.gz linux-ea126e74353453d15fc0a181910ae1e25162f2a1.tar.bz2 linux-ea126e74353453d15fc0a181910ae1e25162f2a1.zip |
nfsd/sunrpc: add a new svc_serv_ops struct and move sv_shutdown into it
In later patches we'll need to abstract out more operations on a
per-service level, besides sv_shutdown and sv_function.
Declare a new svc_serv_ops struct to hold these operations, and move
sv_shutdown into this struct.
Signed-off-by: Shirley Ma <shirley.ma@oracle.com>
Acked-by: Jeff Layton <jlayton@primarydata.com>
Tested-by: Shirley Ma <shirley.ma@oracle.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs/nfsd/nfssvc.c')
-rw-r--r-- | fs/nfsd/nfssvc.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/fs/nfsd/nfssvc.c b/fs/nfsd/nfssvc.c index 9277cc91c21b..7311677330b2 100644 --- a/fs/nfsd/nfssvc.c +++ b/fs/nfsd/nfssvc.c @@ -391,6 +391,10 @@ static int nfsd_get_default_max_blksize(void) return ret; } +static struct svc_serv_ops nfsd_sv_ops = { + .svo_shutdown = nfsd_last_thread, +}; + int nfsd_create_serv(struct net *net) { int error; @@ -405,7 +409,7 @@ int nfsd_create_serv(struct net *net) nfsd_max_blksize = nfsd_get_default_max_blksize(); nfsd_reset_versions(); nn->nfsd_serv = svc_create_pooled(&nfsd_program, nfsd_max_blksize, - nfsd_last_thread, nfsd, THIS_MODULE); + &nfsd_sv_ops, nfsd, THIS_MODULE); if (nn->nfsd_serv == NULL) return -ENOMEM; |