diff options
Diffstat (limited to 'fs/nfs')
-rw-r--r-- | fs/nfs/dir.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c index 121b533f1f28..ff167aa62434 100644 --- a/fs/nfs/dir.c +++ b/fs/nfs/dir.c | |||
@@ -799,6 +799,9 @@ static int nfs_lookup_revalidate(struct dentry * dentry, struct nameidata *nd) | |||
799 | goto out_bad; | 799 | goto out_bad; |
800 | } | 800 | } |
801 | 801 | ||
802 | if (nfs_have_delegation(inode, FMODE_READ)) | ||
803 | goto out_set_verifier; | ||
804 | |||
802 | /* Force a full look up iff the parent directory has changed */ | 805 | /* Force a full look up iff the parent directory has changed */ |
803 | if (!nfs_is_exclusive_create(dir, nd) && nfs_check_verifier(dir, dentry)) { | 806 | if (!nfs_is_exclusive_create(dir, nd) && nfs_check_verifier(dir, dentry)) { |
804 | if (nfs_lookup_verify_inode(inode, nd)) | 807 | if (nfs_lookup_verify_inode(inode, nd)) |
@@ -817,6 +820,7 @@ static int nfs_lookup_revalidate(struct dentry * dentry, struct nameidata *nd) | |||
817 | if ((error = nfs_refresh_inode(inode, &fattr)) != 0) | 820 | if ((error = nfs_refresh_inode(inode, &fattr)) != 0) |
818 | goto out_bad; | 821 | goto out_bad; |
819 | 822 | ||
823 | out_set_verifier: | ||
820 | nfs_set_verifier(dentry, nfs_save_change_attribute(dir)); | 824 | nfs_set_verifier(dentry, nfs_save_change_attribute(dir)); |
821 | out_valid: | 825 | out_valid: |
822 | dput(parent); | 826 | dput(parent); |
@@ -1084,8 +1088,6 @@ out: | |||
1084 | no_open_dput: | 1088 | no_open_dput: |
1085 | dput(parent); | 1089 | dput(parent); |
1086 | no_open: | 1090 | no_open: |
1087 | if (inode != NULL && nfs_have_delegation(inode, FMODE_READ)) | ||
1088 | return 1; | ||
1089 | return nfs_lookup_revalidate(dentry, nd); | 1091 | return nfs_lookup_revalidate(dentry, nd); |
1090 | } | 1092 | } |
1091 | #endif /* CONFIG_NFSV4 */ | 1093 | #endif /* CONFIG_NFSV4 */ |