NFS: Replace last uses of NFS_INO_REVAL_PAGECACHE
Now that we have more fine grained attribute revalidation, let's just get rid of NFS_INO_REVAL_PAGECACHE. Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
This commit is contained in:
Родитель
50c790a0b6
Коммит
88a6099fc3
|
@ -236,19 +236,17 @@ static void nfs_zap_caches_locked(struct inode *inode)
|
|||
nfsi->attrtimeo = NFS_MINATTRTIMEO(inode);
|
||||
nfsi->attrtimeo_timestamp = jiffies;
|
||||
|
||||
if (S_ISREG(mode) || S_ISDIR(mode) || S_ISLNK(mode)) {
|
||||
nfs_set_cache_invalid(inode, NFS_INO_INVALID_ATTR
|
||||
| NFS_INO_INVALID_DATA
|
||||
| NFS_INO_INVALID_ACCESS
|
||||
| NFS_INO_INVALID_ACL
|
||||
| NFS_INO_INVALID_XATTR
|
||||
| NFS_INO_REVAL_PAGECACHE);
|
||||
} else
|
||||
nfs_set_cache_invalid(inode, NFS_INO_INVALID_ATTR
|
||||
| NFS_INO_INVALID_ACCESS
|
||||
| NFS_INO_INVALID_ACL
|
||||
| NFS_INO_INVALID_XATTR
|
||||
| NFS_INO_REVAL_PAGECACHE);
|
||||
if (S_ISREG(mode) || S_ISDIR(mode) || S_ISLNK(mode))
|
||||
nfs_set_cache_invalid(inode, NFS_INO_INVALID_ATTR |
|
||||
NFS_INO_INVALID_DATA |
|
||||
NFS_INO_INVALID_ACCESS |
|
||||
NFS_INO_INVALID_ACL |
|
||||
NFS_INO_INVALID_XATTR);
|
||||
else
|
||||
nfs_set_cache_invalid(inode, NFS_INO_INVALID_ATTR |
|
||||
NFS_INO_INVALID_ACCESS |
|
||||
NFS_INO_INVALID_ACL |
|
||||
NFS_INO_INVALID_XATTR);
|
||||
nfs_zap_label_cache_locked(nfsi);
|
||||
}
|
||||
|
||||
|
|
|
@ -306,7 +306,7 @@ static void nfs_set_pageerror(struct address_space *mapping)
|
|||
/* Force file size revalidation */
|
||||
spin_lock(&inode->i_lock);
|
||||
nfs_set_cache_invalid(inode, NFS_INO_REVAL_FORCED |
|
||||
NFS_INO_REVAL_PAGECACHE |
|
||||
NFS_INO_INVALID_CHANGE |
|
||||
NFS_INO_INVALID_SIZE);
|
||||
spin_unlock(&inode->i_lock);
|
||||
}
|
||||
|
|
|
@ -356,11 +356,9 @@ static inline void nfs_mark_for_revalidate(struct inode *inode)
|
|||
struct nfs_inode *nfsi = NFS_I(inode);
|
||||
|
||||
spin_lock(&inode->i_lock);
|
||||
nfsi->cache_validity |= NFS_INO_REVAL_PAGECACHE
|
||||
| NFS_INO_INVALID_ACCESS
|
||||
| NFS_INO_INVALID_ACL
|
||||
| NFS_INO_INVALID_CHANGE
|
||||
| NFS_INO_INVALID_CTIME;
|
||||
nfsi->cache_validity |= NFS_INO_INVALID_ACCESS | NFS_INO_INVALID_ACL |
|
||||
NFS_INO_INVALID_CHANGE | NFS_INO_INVALID_CTIME |
|
||||
NFS_INO_INVALID_SIZE;
|
||||
if (S_ISDIR(inode->i_mode))
|
||||
nfsi->cache_validity |= NFS_INO_INVALID_DATA;
|
||||
spin_unlock(&inode->i_lock);
|
||||
|
|
Загрузка…
Ссылка в новой задаче