diff options
author | Daeho Jeong <daehojeong@google.com> | 2024-04-11 11:37:53 -0700 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2024-04-14 15:18:23 +0000 |
commit | b2cf5a1ff236fcd0eb9dcbb188df30b50bb1af0f (patch) | |
tree | 0b0adab772d887597f1935dd965dc0bc7d97cf38 /fs/f2fs | |
parent | 3fdd89b452c2ea5e2195d6e315bef122769584c9 (diff) | |
download | linux-b2cf5a1ff236fcd0eb9dcbb188df30b50bb1af0f.tar.gz linux-b2cf5a1ff236fcd0eb9dcbb188df30b50bb1af0f.tar.bz2 linux-b2cf5a1ff236fcd0eb9dcbb188df30b50bb1af0f.zip |
f2fs: allow direct io of pinned files for zoned storage
Since the allocation happens in conventional LU for zoned storage, we
can allow direct io for that.
Signed-off-by: Daeho Jeong <daehojeong@google.com>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs')
-rw-r--r-- | fs/f2fs/file.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/f2fs/file.c b/fs/f2fs/file.c index 7fbdb7863778..ac1ae85f3cc3 100644 --- a/fs/f2fs/file.c +++ b/fs/f2fs/file.c @@ -833,7 +833,8 @@ static bool f2fs_force_buffered_io(struct inode *inode, int rw) * for blkzoned device, fallback direct IO to buffered IO, so * all IOs can be serialized by log-structured write. */ - if (f2fs_sb_has_blkzoned(sbi) && (rw == WRITE)) + if (f2fs_sb_has_blkzoned(sbi) && (rw == WRITE) && + !f2fs_is_pinned_file(inode)) return true; if (is_sbi_flag_set(sbi, SBI_CP_DISABLED)) return true; |