Commit 94b97e39 authored by David Chinner's avatar David Chinner Committed by Lachlan McIlroy

[XFS] Never call mark_inode_dirty_sync() directly

Once the Linux inode and the XFS inode are combined, we cannot rely on
just check if the linux inode exists as a method of determining if it is
valid or not. Hence we should always call xfs_mark_inode_dirty_sync()
instead as it does the correct checks to determine if the liinux inode is
in a valid state or not.

SGI-PV: 988141

SGI-Modid: xfs-linux-melb:xfs-kern:32318a
Signed-off-by: default avatarDavid Chinner <david@fromorbit.com>
Signed-off-by: default avatarLachlan McIlroy <lachlan@sgi.com>
Signed-off-by: default avatarChristoph Hellwig <hch@infradead.org>
parent 6441e549
...@@ -191,7 +191,7 @@ xfs_setfilesize( ...@@ -191,7 +191,7 @@ xfs_setfilesize(
ip->i_d.di_size = isize; ip->i_d.di_size = isize;
ip->i_update_core = 1; ip->i_update_core = 1;
ip->i_update_size = 1; ip->i_update_size = 1;
mark_inode_dirty_sync(ioend->io_inode); xfs_mark_inode_dirty_sync(ip);
} }
xfs_iunlock(ip, XFS_ILOCK_EXCL); xfs_iunlock(ip, XFS_ILOCK_EXCL);
......
...@@ -128,7 +128,7 @@ xfs_ichgtime( ...@@ -128,7 +128,7 @@ xfs_ichgtime(
if (sync_it) { if (sync_it) {
SYNCHRONIZE(); SYNCHRONIZE();
ip->i_update_core = 1; ip->i_update_core = 1;
mark_inode_dirty_sync(inode); xfs_mark_inode_dirty_sync(ip);
} }
} }
......
...@@ -948,7 +948,7 @@ xfs_fs_write_inode( ...@@ -948,7 +948,7 @@ xfs_fs_write_inode(
* it dirty again so we'll try again later. * it dirty again so we'll try again later.
*/ */
if (error) if (error)
mark_inode_dirty_sync(inode); xfs_mark_inode_dirty_sync(XFS_I(inode));
return -error; return -error;
} }
......
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