diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-03-05 14:53:53 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-03-05 14:53:53 -0500 |
commit | 9467c4fdd66f6810cecef0f1173330f3c6e67d45 (patch) | |
tree | 5fea180a10127c893b288dff2c8788b72d2eaea3 /fs/xfs | |
parent | 35c2e967d067ff02dc944f2434f024419c2fe83a (diff) | |
parent | a9185b41a4f84971b930c519f0c63bd450c4810d (diff) |
Merge branch 'write_inode2' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6
* 'write_inode2' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6:
pass writeback_control to ->write_inode
make sure data is on disk before calling ->write_inode
Diffstat (limited to 'fs/xfs')
-rw-r--r-- | fs/xfs/linux-2.6/xfs_super.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/fs/xfs/linux-2.6/xfs_super.c b/fs/xfs/linux-2.6/xfs_super.c index 25ea2408118f..71345a370d9f 100644 --- a/fs/xfs/linux-2.6/xfs_super.c +++ b/fs/xfs/linux-2.6/xfs_super.c | |||
@@ -1063,7 +1063,7 @@ xfs_log_inode( | |||
1063 | STATIC int | 1063 | STATIC int |
1064 | xfs_fs_write_inode( | 1064 | xfs_fs_write_inode( |
1065 | struct inode *inode, | 1065 | struct inode *inode, |
1066 | int sync) | 1066 | struct writeback_control *wbc) |
1067 | { | 1067 | { |
1068 | struct xfs_inode *ip = XFS_I(inode); | 1068 | struct xfs_inode *ip = XFS_I(inode); |
1069 | struct xfs_mount *mp = ip->i_mount; | 1069 | struct xfs_mount *mp = ip->i_mount; |
@@ -1074,11 +1074,7 @@ xfs_fs_write_inode( | |||
1074 | if (XFS_FORCED_SHUTDOWN(mp)) | 1074 | if (XFS_FORCED_SHUTDOWN(mp)) |
1075 | return XFS_ERROR(EIO); | 1075 | return XFS_ERROR(EIO); |
1076 | 1076 | ||
1077 | if (sync) { | 1077 | if (wbc->sync_mode == WB_SYNC_ALL) { |
1078 | error = xfs_wait_on_pages(ip, 0, -1); | ||
1079 | if (error) | ||
1080 | goto out; | ||
1081 | |||
1082 | /* | 1078 | /* |
1083 | * Make sure the inode has hit stable storage. By using the | 1079 | * Make sure the inode has hit stable storage. By using the |
1084 | * log and the fsync transactions we reduce the IOs we have | 1080 | * log and the fsync transactions we reduce the IOs we have |