nfsd: Extend the mutex holding region around in nfsd4_process_open2()
authorOleg Drokin <green@linuxhacker.ru>
Wed, 15 Jun 2016 03:28:05 +0000 (23:28 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 27 Jul 2016 16:47:30 +0000 (09:47 -0700)
commitf78ffdc2bb3c88792636f14d732cc1fce4073685
tree5d4fe330cceade546938026b1617aa7a3a759fad
parent087f8fe0074874a6072bdabbdf6dad03e0fbba2a
nfsd: Extend the mutex holding region around in nfsd4_process_open2()

commit 5cc1fb2a093e254b656c64ff24b0b76bed1d34d9 upstream.

To avoid racing entry into nfs4_get_vfs_file().
Make init_open_stateid() return with locked stateid to be unlocked
by the caller.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/nfsd/nfs4state.c