NFS: nfs_find_open_context() may only select open files
authorTrond Myklebust <trond.myklebust@hammerspace.com>
Wed, 12 May 2021 03:41:10 +0000 (23:41 -0400)
committerTrond Myklebust <trond.myklebust@hammerspace.com>
Tue, 29 Jun 2021 17:12:39 +0000 (13:12 -0400)
commite97bc66377bca097e1f3349ca18ca17f202ff659
tree12093332810a92c0eae0ab0717e3c4353a4ac0d6
parente93a5e9306a576011f03011b492d4fbaa274477b
NFS: nfs_find_open_context() may only select open files

If a file has already been closed, then it should not be selected to
support further I/O.

Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
[Trond: Fix an invalid pointer deref reported by Colin Ian King]
fs/nfs/inode.c
include/linux/nfs_fs.h