From: Christoph Hellwig Date: Sat, 26 Sep 2009 19:55:04 +0000 (+0000) Subject: xfs: stop calling filemap_fdatawait inside ->fsync X-Git-Tag: 2.1b_release~10522^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d0800703febc04827b8fa91921aa4e254d01e8d1;p=platform%2Fkernel%2Fkernel-mfld-blackbay.git xfs: stop calling filemap_fdatawait inside ->fsync Now that the VFS actually waits for the data I/O to complete before calling into ->fsync we can stop doing it ourselves. Signed-off-by: Christoph Hellwig Reviewed-by: Alex Elder Signed-off-by: Alex Elder --- diff --git a/fs/xfs/linux-2.6/xfs_file.c b/fs/xfs/linux-2.6/xfs_file.c index 988d8f8..6d65baf 100644 --- a/fs/xfs/linux-2.6/xfs_file.c +++ b/fs/xfs/linux-2.6/xfs_file.c @@ -176,14 +176,7 @@ xfs_file_fsync( struct dentry *dentry, int datasync) { - struct inode *inode = dentry->d_inode; - struct xfs_inode *ip = XFS_I(inode); - int error; - - /* capture size updates in I/O completion before writing the inode. */ - error = filemap_fdatawait(inode->i_mapping); - if (error) - return error; + struct xfs_inode *ip = XFS_I(dentry->d_inode); xfs_iflags_clear(ip, XFS_ITRUNCATED); return -xfs_fsync(ip);