From: Trond Myklebust Date: Tue, 20 Aug 2013 16:29:27 +0000 (-0400) Subject: NFS: Remove the NFSv4 "open optimisation" from nfs_permission X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5948a401a7f06d67f8548651041e00fd1aafcaf9;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git NFS: Remove the NFSv4 "open optimisation" from nfs_permission Ever since commit 6168f62cb (Add ACCESS operation to OPEN compound) the NFSv4 atomic open has primed the access cache, and so nfs_permission will no longer do an RPC call on the wire. Signed-off-by: Trond Myklebust --- diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c index 39e69d47cd0b..5d737bd52288 100644 --- a/fs/nfs/dir.c +++ b/fs/nfs/dir.c @@ -2245,11 +2245,6 @@ int nfs_permission(struct inode *inode, int mask) case S_IFLNK: goto out; case S_IFREG: - /* NFSv4 has atomic_open... */ - if (nfs_server_capable(inode, NFS_CAP_ATOMIC_OPEN) - && (mask & MAY_OPEN) - && !(mask & MAY_EXEC)) - goto out; break; case S_IFDIR: /*