summaryrefslogtreecommitdiffstats
path: root/fs/jfs
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2016-04-07 08:51:58 -0700
committerAl Viro <viro@zeniv.linux.org.uk>2016-05-01 19:58:39 -0400
commitc8b8e32d700fe943a935e435ae251364d016c497 (patch)
tree956e582a123c6b2761e80901bdaaedc5ba4137e3 /fs/jfs
parent13712713caba0c1b8c2c0070a4c1f4487def8dee (diff)
downloadop-kernel-dev-c8b8e32d700fe943a935e435ae251364d016c497.zip
op-kernel-dev-c8b8e32d700fe943a935e435ae251364d016c497.tar.gz
direct-io: eliminate the offset argument to ->direct_IO
Including blkdev_direct_IO and dax_do_io. It has to be ki_pos to actually work, so eliminate the superflous argument. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/jfs')
-rw-r--r--fs/jfs/inode.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/fs/jfs/inode.c b/fs/jfs/inode.c
index 9d9bae6..f6a2a78 100644
--- a/fs/jfs/inode.c
+++ b/fs/jfs/inode.c
@@ -332,8 +332,7 @@ static sector_t jfs_bmap(struct address_space *mapping, sector_t block)
return generic_block_bmap(mapping, block, jfs_get_block);
}
-static ssize_t jfs_direct_IO(struct kiocb *iocb, struct iov_iter *iter,
- loff_t offset)
+static ssize_t jfs_direct_IO(struct kiocb *iocb, struct iov_iter *iter)
{
struct file *file = iocb->ki_filp;
struct address_space *mapping = file->f_mapping;
@@ -341,7 +340,7 @@ static ssize_t jfs_direct_IO(struct kiocb *iocb, struct iov_iter *iter,
size_t count = iov_iter_count(iter);
ssize_t ret;
- ret = blockdev_direct_IO(iocb, inode, iter, offset, jfs_get_block);
+ ret = blockdev_direct_IO(iocb, inode, iter, jfs_get_block);
/*
* In case of error extending write may have instantiated a few
@@ -349,7 +348,7 @@ static ssize_t jfs_direct_IO(struct kiocb *iocb, struct iov_iter *iter,
*/
if (unlikely(iov_iter_rw(iter) == WRITE && ret < 0)) {
loff_t isize = i_size_read(inode);
- loff_t end = offset + count;
+ loff_t end = iocb->ki_pos + count;
if (end > isize)
jfs_write_failed(mapping, end);
OpenPOWER on IntegriCloud