diff options
author | rmacklem <rmacklem@FreeBSD.org> | 2015-12-05 21:38:53 +0000 |
---|---|---|
committer | rmacklem <rmacklem@FreeBSD.org> | 2015-12-05 21:38:53 +0000 |
commit | 11ddbfbc5cbb55d74dd49e7d13251e56cb1dff91 (patch) | |
tree | d8031cefd74dad50d37ce43a720029b712d391f1 /sys/fs/nfs | |
parent | 8e2b2c5eb5f3434f37c9d01effd9dcdb733a8a26 (diff) | |
download | FreeBSD-src-11ddbfbc5cbb55d74dd49e7d13251e56cb1dff91.zip FreeBSD-src-11ddbfbc5cbb55d74dd49e7d13251e56cb1dff91.tar.gz |
MFC: r291150
When the nfsd threads are terminated, the NFSv4 server state
(opens, locks, etc) is retained, which I believe is correct behaviour.
However, for NFSv4.1, the server also retained a reference to the xprt
(RPC transport socket structure) for the backchannel. This caused
svcpool_destroy() to not call SVC_DESTROY() for the xprt and allowed
a socket upcall to occur after the mutexes in the svcpool were destroyed,
causing a crash.
This patch fixes the code so that the backchannel xprt structure is
dereferenced just before svcpool_destroy() is called, so the code
does do an SVC_DESTROY() on the xprt, which shuts down the socket upcall.
Diffstat (limited to 'sys/fs/nfs')
-rw-r--r-- | sys/fs/nfs/nfs_var.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/fs/nfs/nfs_var.h b/sys/fs/nfs/nfs_var.h index 2abd7e4..d540dc9 100644 --- a/sys/fs/nfs/nfs_var.h +++ b/sys/fs/nfs/nfs_var.h @@ -135,6 +135,7 @@ int nfsrv_checksequence(struct nfsrv_descript *, uint32_t, uint32_t *, uint32_t *, int, uint32_t *, NFSPROC_T *); int nfsrv_checkreclaimcomplete(struct nfsrv_descript *); void nfsrv_cache_session(uint8_t *, uint32_t, int, struct mbuf **); +void nfsrv_freeallbackchannel_xprts(void); /* nfs_nfsdserv.c */ int nfsrvd_access(struct nfsrv_descript *, int, |