aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_aops.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/xfs_aops.c')
-rw-r--r--fs/xfs/xfs_aops.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/fs/xfs/xfs_aops.c b/fs/xfs/xfs_aops.c
index 4f8cdc59bc38..1d8eef9cf0f5 100644
--- a/fs/xfs/xfs_aops.c
+++ b/fs/xfs/xfs_aops.c
@@ -1495,7 +1495,6 @@ xfs_end_io_direct_write(
1495 1495
1496STATIC ssize_t 1496STATIC ssize_t
1497xfs_vm_direct_IO( 1497xfs_vm_direct_IO(
1498 int rw,
1499 struct kiocb *iocb, 1498 struct kiocb *iocb,
1500 struct iov_iter *iter, 1499 struct iov_iter *iter,
1501 loff_t offset) 1500 loff_t offset)
@@ -1503,15 +1502,14 @@ xfs_vm_direct_IO(
1503 struct inode *inode = iocb->ki_filp->f_mapping->host; 1502 struct inode *inode = iocb->ki_filp->f_mapping->host;
1504 struct block_device *bdev = xfs_find_bdev_for_inode(inode); 1503 struct block_device *bdev = xfs_find_bdev_for_inode(inode);
1505 1504
1506 if (rw & WRITE) { 1505 if (iov_iter_rw(iter) == WRITE) {
1507 return __blockdev_direct_IO(rw, iocb, inode, bdev, iter, 1506 return __blockdev_direct_IO(iocb, inode, bdev, iter, offset,
1508 offset, xfs_get_blocks_direct, 1507 xfs_get_blocks_direct,
1509 xfs_end_io_direct_write, NULL, 1508 xfs_end_io_direct_write, NULL,
1510 DIO_ASYNC_EXTEND); 1509 DIO_ASYNC_EXTEND);
1511 } 1510 }
1512 return __blockdev_direct_IO(rw, iocb, inode, bdev, iter, 1511 return __blockdev_direct_IO(iocb, inode, bdev, iter, offset,
1513 offset, xfs_get_blocks_direct, 1512 xfs_get_blocks_direct, NULL, NULL, 0);
1514 NULL, NULL, 0);
1515} 1513}
1516 1514
1517/* 1515/*