xfs
[Top] [All Lists]

[PATCH 3/6] xfs: kill VN_DIRTY()

To: xfs@xxxxxxxxxxx
Subject: [PATCH 3/6] xfs: kill VN_DIRTY()
From: Dave Chinner <david@xxxxxxxxxxxxx>
Date: Thu, 31 Jul 2014 17:33:12 +1000
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <1406791995-14723-1-git-send-email-david@xxxxxxxxxxxxx>
References: <1406791995-14723-1-git-send-email-david@xxxxxxxxxxxxx>
From: Dave Chinner <dchinner@xxxxxxxxxx>

Only one user, so get rid of it.

Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
Signed-off-by: Dave Chinner <david@xxxxxxxxxxxxx>
---
 fs/xfs/xfs_inode.c | 4 +++-
 fs/xfs/xfs_vnode.h | 2 --
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/fs/xfs/xfs_inode.c b/fs/xfs/xfs_inode.c
index 1a5e068..c929217 100644
--- a/fs/xfs/xfs_inode.c
+++ b/fs/xfs/xfs_inode.c
@@ -1635,7 +1635,9 @@ xfs_release(
                truncated = xfs_iflags_test_and_clear(ip, XFS_ITRUNCATED);
                if (truncated) {
                        xfs_iflags_clear(ip, XFS_IDIRTY_RELEASE);
-                       if (VN_DIRTY(VFS_I(ip)) && ip->i_delayed_blks > 0) {
+                       if (mapping_tagged(VFS_I(ip)->i_mapping,
+                                          PAGECACHE_TAG_DIRTY) &&
+                           ip->i_delayed_blks > 0) {
                                error = filemap_flush(VFS_I(ip)->i_mapping);
                                if (error)
                                        return error;
diff --git a/fs/xfs/xfs_vnode.h b/fs/xfs/xfs_vnode.h
index e8a7738..07b475a 100644
--- a/fs/xfs/xfs_vnode.h
+++ b/fs/xfs/xfs_vnode.h
@@ -39,8 +39,6 @@ struct attrlist_cursor_kern;
  */
 #define VN_MAPPED(vp)  mapping_mapped(vp->i_mapping)
 #define VN_CACHED(vp)  (vp->i_mapping->nrpages)
-#define VN_DIRTY(vp)   mapping_tagged(vp->i_mapping, \
-                                       PAGECACHE_TAG_DIRTY)
 
 
 #endif /* __XFS_VNODE_H__ */
-- 
2.0.0

<Prev in Thread] Current Thread [Next in Thread>