f2fs: provide f2fs_balance_fs to __write_node_page

Let node writeback also do f2fs_balance_fs to ensure there are always enough free
segments.

Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
Yunlong Song
2017-07-27 20:11:00 +08:00
committed by Jaegeuk Kim
parent ddc34e328d
commit 401db79f61
3 changed files with 13 additions and 8 deletions

View File

@@ -1017,7 +1017,7 @@ retry_flush_nodes:
if (get_pages(sbi, F2FS_DIRTY_NODES)) {
up_write(&sbi->node_write);
err = sync_node_pages(sbi, &wbc);
err = sync_node_pages(sbi, &wbc, false);
if (err) {
up_write(&sbi->node_change);
f2fs_unlock_all(sbi);