X-Git-Url: http://git.rot13.org/?p=powerpc.git;a=blobdiff_plain;f=fs%2Fnfs%2Fdir.c;h=469cf66e1dc06918d860dd58b03f3bbc2729e232;hp=fced7d1d48de7ad6e4248e48935f8ad7f6ebbd37;hb=e70c490810dc683fad39e57cf00e69d5f120c542;hpb=e62c2bba1fb7cf068eb78d731da46e4447a9efb1 diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c index fced7d1d48..469cf66e1d 100644 --- a/fs/nfs/dir.c +++ b/fs/nfs/dir.c @@ -655,9 +655,7 @@ static int nfs_check_verifier(struct inode *dir, struct dentry *dentry) if (IS_ROOT(dentry)) return 1; verf = (unsigned long)dentry->d_fsdata; - if ((NFS_I(dir)->cache_validity & NFS_INO_INVALID_ATTR) != 0 - || nfs_attribute_timeout(dir) - || nfs_caches_unstable(dir) + if (nfs_caches_unstable(dir) || verf != NFS_I(dir)->cache_change_attribute) return 0; return 1; @@ -769,6 +767,10 @@ static int nfs_lookup_revalidate(struct dentry * dentry, struct nameidata *nd) nfs_inc_stats(dir, NFSIOS_DENTRYREVALIDATE); inode = dentry->d_inode; + /* Revalidate parent directory attribute cache */ + if (nfs_revalidate_inode(NFS_SERVER(dir), dir) < 0) + goto out_zap_parent; + if (!inode) { if (nfs_neg_need_reval(dir, dentry, nd)) goto out_bad; @@ -782,10 +784,6 @@ static int nfs_lookup_revalidate(struct dentry * dentry, struct nameidata *nd) goto out_bad; } - /* Revalidate parent directory attribute cache */ - if (nfs_revalidate_inode(NFS_SERVER(dir), dir) < 0) - goto out_zap_parent; - /* Force a full look up iff the parent directory has changed */ if (nfs_check_verifier(dir, dentry)) { if (nfs_lookup_verify_inode(inode, nd))