summaryrefslogtreecommitdiffstats
path: root/fs/iomap
diff options
context:
space:
mode:
authorJoseph Qi <joseph.qi@linux.alibaba.com>2019-10-29 09:51:24 -0700
committerDarrick J. Wong <darrick.wong@oracle.com>2019-10-29 09:51:24 -0700
commita901004214994f12523b47521cddfa4426f284c1 (patch)
tree7087e5bb7467b36ed3e565b546554a56f8641894 /fs/iomap
parentc039b99792726346ad46ff17c5a5bcb77a5edac4 (diff)
downloadlinux-a901004214994f12523b47521cddfa4426f284c1.tar.bz2
fs/iomap: remove redundant check in iomap_dio_rw()
We've already check if it is READ iov_iter, no need check again. Signed-off-by: Joseph Qi <joseph.qi@linux.alibaba.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Reviewed-by: Jens Axboe <axboe@kernel.dk> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Diffstat (limited to 'fs/iomap')
-rw-r--r--fs/iomap/direct-io.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/iomap/direct-io.c b/fs/iomap/direct-io.c
index 49bf9780e3ed..2f88d64c2a4d 100644
--- a/fs/iomap/direct-io.c
+++ b/fs/iomap/direct-io.c
@@ -433,7 +433,7 @@ iomap_dio_rw(struct kiocb *iocb, struct iov_iter *iter,
if (pos >= dio->i_size)
goto out_free_dio;
- if (iter_is_iovec(iter) && iov_iter_rw(iter) == READ)
+ if (iter_is_iovec(iter))
dio->flags |= IOMAP_DIO_DIRTY;
} else {
flags |= IOMAP_WRITE;