f2fs: fix error path of move_data_page
authorChao Yu <yuchao0@huawei.com>
Mon, 28 May 2018 08:59:27 +0000 (16:59 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 3 Aug 2018 05:50:25 +0000 (07:50 +0200)
commitf3f029197738730a7b74d1b2d25288586975df47
tree6d3f53aab138b7b5efd3b758a62c77bbb2212324
parent122031c292023f520befba701eb9895c3e0fc48c
f2fs: fix error path of move_data_page

[ Upstream commit 14a28559f43ac7c0b98dd1b0e73ec9ec8ab4fc45 ]

This patch fixes error path of move_data_page:
- clear cold data flag if it fails to write page.
- redirty page for non-ENOMEM case.

Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/f2fs/gc.c