aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_iops.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@infradead.org>2011-08-23 04:28:12 -0400
committerAlex Elder <aelder@sgi.com>2011-10-11 22:15:00 -0400
commit2b3ffd7eb7b4392e3657c5046b055ca9f1f7cf5e (patch)
treefae89c3a78eca1ea273eb239d967b0eae23c7a50 /fs/xfs/xfs_iops.c
parentfc0063c4474599b7a066ba76b90902abe21bc675 (diff)
xfs: wait for I/O completion when writing out pages in xfs_setattr_size
The current code relies on the xfs_ioend_wait call later on to make sure all I/O actually has completed. The xfs_ioend_wait call will go away soon, so prepare for that by using the waiting filemap function. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Alex Elder <aelder@sgi.com>
Diffstat (limited to 'fs/xfs/xfs_iops.c')
-rw-r--r--fs/xfs/xfs_iops.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/xfs/xfs_iops.c b/fs/xfs/xfs_iops.c
index 673704fab748..32aca87bde5e 100644
--- a/fs/xfs/xfs_iops.c
+++ b/fs/xfs/xfs_iops.c
@@ -833,8 +833,8 @@ xfs_setattr_size(
833 * care about here. 833 * care about here.
834 */ 834 */
835 if (ip->i_size != ip->i_d.di_size && iattr->ia_size > ip->i_d.di_size) { 835 if (ip->i_size != ip->i_d.di_size && iattr->ia_size > ip->i_d.di_size) {
836 error = xfs_flush_pages(ip, ip->i_d.di_size, iattr->ia_size, 836 error = xfs_flush_pages(ip, ip->i_d.di_size, iattr->ia_size, 0,
837 XBF_ASYNC, FI_NONE); 837 FI_NONE);
838 if (error) 838 if (error)
839 goto out_unlock; 839 goto out_unlock;
840 } 840 }