Skip to content

Commit 89d13c3

Browse files
author
Jaegeuk Kim
committed
f2fs: fix missing up_read
This patch fixes missing up_read call. Fixes: c9b6078 ("f2fs: fix to do sanity check with block address in main area") Cc: <[email protected]> # 4.19+ Reviewed-by: Chao Yu <[email protected]> Signed-off-by: Jaegeuk Kim <[email protected]>
1 parent 61f7725 commit 89d13c3

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

fs/f2fs/node.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1541,8 +1541,10 @@ static int __write_node_page(struct page *page, bool atomic, bool *submitted,
15411541
}
15421542

15431543
if (__is_valid_data_blkaddr(ni.blk_addr) &&
1544-
!f2fs_is_valid_blkaddr(sbi, ni.blk_addr, DATA_GENERIC))
1544+
!f2fs_is_valid_blkaddr(sbi, ni.blk_addr, DATA_GENERIC)) {
1545+
up_read(&sbi->node_write);
15451546
goto redirty_out;
1547+
}
15461548

15471549
if (atomic && !test_opt(sbi, NOBARRIER))
15481550
fio.op_flags |= REQ_PREFLUSH | REQ_FUA;

0 commit comments

Comments
 (0)