diff options
author | Jaegeuk Kim <jaegeuk@kernel.org> | 2016-11-11 23:08:22 +0300 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2016-11-25 21:15:12 +0300 |
commit | e57e9ae5b179a6b243c42bf6d9549d1595c27089 (patch) | |
tree | ffe099b48c23d5ac511e012df5e9a9ba31d04e68 /fs/f2fs | |
parent | 6ae1be13e85f4c42c8ca371fda50ae39eebbfd96 (diff) | |
download | linux-e57e9ae5b179a6b243c42bf6d9549d1595c27089.tar.xz |
f2fs: allow dio read for LFS mode
We can allow dio reads for LFS mode, while doing buffered writes for dio writes.
Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs')
-rw-r--r-- | fs/f2fs/data.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/f2fs/data.c b/fs/f2fs/data.c index ca53da568633..996b9aef94ce 100644 --- a/fs/f2fs/data.c +++ b/fs/f2fs/data.c @@ -1732,7 +1732,7 @@ static ssize_t f2fs_direct_IO(struct kiocb *iocb, struct iov_iter *iter) if (f2fs_encrypted_inode(inode) && S_ISREG(inode->i_mode)) return 0; - if (test_opt(F2FS_I_SB(inode), LFS)) + if (rw == WRITE && test_opt(F2FS_I_SB(inode), LFS)) return 0; trace_f2fs_direct_IO_enter(inode, offset, count, rw); |