commit | c040ff9d69fd1d782fe577ba9e35c1f5798158ae | [log] [tgz] |
---|---|---|
author | Jaegeuk Kim <jaegeuk@kernel.org> | Fri Nov 11 16:46:40 2016 -0800 |
committer | Jaegeuk Kim <jaegeuk@kernel.org> | Fri Nov 25 10:15:50 2016 -0800 |
tree | b833c477d306b768d88be6203a4cf0ecc55dbb61 | |
parent | a7de608691f766cd148971a71d4f13aa1692d4c8 [diff] |
f2fs: fix redundant block allocation In direct_IO path of f2fs_file_write_iter(), 1. f2fs_preallocate_blocks(F2FS_GET_BLOCK_PRE_DIO) -> allocate LBA X 2. f2fs_direct_IO() -> return 0; Then, f2fs_write_data_page() will allocate another LBA X+1. This makes EIO triggered by HM-SMR. Reviewed-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>