mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-26 18:43:33 -05:00
xfs: kill VN_CACHED
Only has 2 users, has outlived it's usefulness. Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dave Chinner <david@fromorbit.com>
This commit is contained in:
parent
eac152b474
commit
2667c6f935
2 changed files with 2 additions and 3 deletions
|
@ -862,7 +862,7 @@ xfs_can_free_eofblocks(struct xfs_inode *ip, bool force)
|
||||||
* have speculative prealloc/delalloc blocks to remove.
|
* have speculative prealloc/delalloc blocks to remove.
|
||||||
*/
|
*/
|
||||||
if (VFS_I(ip)->i_size == 0 &&
|
if (VFS_I(ip)->i_size == 0 &&
|
||||||
VN_CACHED(VFS_I(ip)) == 0 &&
|
VFS_I(ip)->i_mapping->nrpages == 0 &&
|
||||||
ip->i_delayed_blks == 0)
|
ip->i_delayed_blks == 0)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
@ -1720,7 +1720,7 @@ xfs_swap_extents(
|
||||||
truncate_pagecache_range(VFS_I(tip), 0, -1);
|
truncate_pagecache_range(VFS_I(tip), 0, -1);
|
||||||
|
|
||||||
/* Verify O_DIRECT for ftmp */
|
/* Verify O_DIRECT for ftmp */
|
||||||
if (VN_CACHED(VFS_I(tip)) != 0) {
|
if (VFS_I(tip)->i_mapping->nrpages) {
|
||||||
error = -EINVAL;
|
error = -EINVAL;
|
||||||
goto out_unlock;
|
goto out_unlock;
|
||||||
}
|
}
|
||||||
|
|
|
@ -38,7 +38,6 @@ struct attrlist_cursor_kern;
|
||||||
* Some useful predicates.
|
* Some useful predicates.
|
||||||
*/
|
*/
|
||||||
#define VN_MAPPED(vp) mapping_mapped(vp->i_mapping)
|
#define VN_MAPPED(vp) mapping_mapped(vp->i_mapping)
|
||||||
#define VN_CACHED(vp) (vp->i_mapping->nrpages)
|
|
||||||
|
|
||||||
|
|
||||||
#endif /* __XFS_VNODE_H__ */
|
#endif /* __XFS_VNODE_H__ */
|
||||||
|
|
Loading…
Add table
Reference in a new issue