]> git.baikalelectronics.ru Git - kernel.git/commit
f2fs: fix to read source block before invalidating it
authorJaegeuk Kim <jaegeuk@kernel.org>
Thu, 18 Jul 2019 01:31:53 +0000 (18:31 -0700)
committerJaegeuk Kim <jaegeuk@kernel.org>
Sat, 27 Jul 2019 00:49:04 +0000 (17:49 -0700)
commit07e8402dfc129801d77c0c5a5d0365406b4103a6
tree34ccdff9b2ee2dbde59707c0be74369afc1f0881
parenta60f625d68e1538124210cbff54f444ad30a6f7d
f2fs: fix to read source block before invalidating it

f2fs_allocate_data_block() invalidates old block address and enable new block
address. Then, if we try to read old block by f2fs_submit_page_bio(), it will
give WARN due to reading invalid blocks.

Let's make the order sanely back.

Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/gc.c