lockd: set other missing fields when unlocking files
authorTrond Myklebust <trond.myklebust@hammerspace.com>
Sun, 6 Nov 2022 19:02:39 +0000 (14:02 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 31 Dec 2022 12:32:00 +0000 (13:32 +0100)
commitd7aa9f7778316beb690f6e2763b6d672ad8b256f
treeda9bb5328a951468a2c9ed6b7b239718ae138966
parent5c8e13a2b66abc290da39767bfb5ba3fba2b053e
lockd: set other missing fields when unlocking files

[ Upstream commit 18ebd35b61b4693a0ddc270b6d4f18def232e770 ]

vfs_lock_file() expects the struct file_lock to be fully initialised by
the caller. Re-exported NFSv3 has been seen to Oops if the fl_file field
is NULL.

Fixes: aec158242b87 ("lockd: set fl_owner when unlocking files")
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Link: https://bugzilla.kernel.org/show_bug.cgi?id=216582
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
fs/lockd/svcsubs.c