]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
NFS: Fix NFSv4 open stateid regressions
authorTrond Myklebust <Trond.Myklebust@netapp.com>
Thu, 26 Jul 2007 21:47:34 +0000 (17:47 -0400)
committerTrond Myklebust <Trond.Myklebust@netapp.com>
Tue, 7 Aug 2007 19:13:19 +0000 (15:13 -0400)
commit45328c354e8ae16b67cb3adb72ab57459f9e5fd6
treef0c4271a0c9f6b8d9b499f22fffc1804419d49c8
parentba683031fae115d61c6b5f4c675cc27f6e9576d2
NFS: Fix NFSv4 open stateid regressions

Do not allow cached open for O_RDONLY or O_WRONLY unless the file has been
previously opened in these modes.

Also Fix the calculation of the mode in nfs4_close_prepare. We should only
issue an OPEN_DOWNGRADE if we're sure that we will still be holding the
correct open modes. This may not be the case if we've been doing delegated
opens.

Finally, there is no need to adjust the open mode bit flags in
nfs4_close_done(): that has already been done in nfs4_close_prepare().

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
fs/nfs/nfs4proc.c