xfs: remove i_iocount
[GitHub/mt8127/android_kernel_alcatel_ttab.git] / fs / xfs / xfs_file.c
index cbbac5cc9c26a44a82d12019d975a2c6cd7c05c0..ee63c4fb3639f0ae59c733c7a556dfbeef370a8f 100644 (file)
@@ -149,10 +149,6 @@ xfs_file_fsync(
 
        xfs_iflags_clear(ip, XFS_ITRUNCATED);
 
-       xfs_ilock(ip, XFS_IOLOCK_SHARED);
-       xfs_ioend_wait(ip);
-       xfs_iunlock(ip, XFS_IOLOCK_SHARED);
-
        if (mp->m_flags & XFS_MOUNT_BARRIER) {
                /*
                 * If we have an RT and/or log subvolume we need to make sure
@@ -758,7 +754,7 @@ restart:
  * the dio layer.  To avoid the problem with aio, we also need to wait for
  * outstanding IOs to complete so that unwritten extent conversion is completed
  * before we try to map the overlapping block. This is currently implemented by
- * hitting it with a big hammer (i.e. xfs_ioend_wait()).
+ * hitting it with a big hammer (i.e. inode_dio_wait()).
  *
  * Returns with locks held indicated by @iolock and errors indicated by
  * negative return values.
@@ -821,7 +817,7 @@ xfs_file_dio_aio_write(
         * otherwise demote the lock if we had to flush cached pages
         */
        if (unaligned_io)
-               xfs_ioend_wait(ip);
+               inode_dio_wait(inode);
        else if (*iolock == XFS_IOLOCK_EXCL) {
                xfs_rw_ilock_demote(ip, XFS_IOLOCK_EXCL);
                *iolock = XFS_IOLOCK_SHARED;