Skip to content

Commit b2cf5a1

Browse files
Daeho JeongJaegeuk Kim
authored andcommitted
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>
1 parent 3fdd89b commit b2cf5a1

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

fs/f2fs/file.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -833,7 +833,8 @@ static bool f2fs_force_buffered_io(struct inode *inode, int rw)
833833
* for blkzoned device, fallback direct IO to buffered IO, so
834834
* all IOs can be serialized by log-structured write.
835835
*/
836-
if (f2fs_sb_has_blkzoned(sbi) && (rw == WRITE))
836+
if (f2fs_sb_has_blkzoned(sbi) && (rw == WRITE) &&
837+
!f2fs_is_pinned_file(inode))
837838
return true;
838839
if (is_sbi_flag_set(sbi, SBI_CP_DISABLED))
839840
return true;

0 commit comments

Comments
 (0)