Commit 2929bc33 authored by Trond Myklebust's avatar Trond Myklebust

NFS: Fix up nfs_readdir_inode_mapping_valid()

The check for duplicate readdir cookies should only care if the change
attribute is invalid or the data cache is invalid.
Signed-off-by: default avatarTrond Myklebust <trond.myklebust@hammerspace.com>
Tested-by: default avatarBenjamin Coddington <bcodding@redhat.com>
Reviewed-by: default avatarBenjamin Coddington <bcodding@redhat.com>
parent a6a361c4
......@@ -411,7 +411,8 @@ static int nfs_readdir_search_for_pos(struct nfs_cache_array *array,
static bool
nfs_readdir_inode_mapping_valid(struct nfs_inode *nfsi)
{
if (nfsi->cache_validity & (NFS_INO_INVALID_ATTR|NFS_INO_INVALID_DATA))
if (nfsi->cache_validity & (NFS_INO_INVALID_CHANGE |
NFS_INO_INVALID_DATA))
return false;
smp_rmb();
return !test_bit(NFS_INO_INVALIDATING, &nfsi->flags);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment