nfsd: Fix races between nfsd4_cb_release() and nfsd4_shutdown_callback()
authorTrond Myklebust <trondmy@gmail.com>
Wed, 23 Oct 2019 21:43:18 +0000 (17:43 -0400)
committerJ. Bruce Fields <bfields@redhat.com>
Fri, 8 Nov 2019 17:32:59 +0000 (12:32 -0500)
commit2bbfed98a4d82ac4e7abfcd4eba40bddfc670b1d
tree26b916fc1bffa22169392125c49097470aa8822a
parent12357f1b2c8e0d06f34a045498d4a1e7877153ee
nfsd: Fix races between nfsd4_cb_release() and nfsd4_shutdown_callback()

When we're destroying the client lease, and we call
nfsd4_shutdown_callback(), we must ensure that we do not return
before all outstanding callbacks have terminated and have
released their payloads.

Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
fs/nfsd/nfs4callback.c
fs/nfsd/state.h