Re: [f2fs-dev v2] [PATCH 1/2] f2fs: stop checkpoint only from fault injection
From: Jaegeuk Kim
Date: Sun Dec 31 2017 - 20:35:03 EST
We can give another chance to write user data, which can resolve
generic/441.
Signed-off-by: Jaegeuk Kim <jaegeuk@xxxxxxxxxx>
---
Change log from v1:
- skip stop_checkpoint for user data writes
fs/f2fs/data.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/fs/f2fs/data.c b/fs/f2fs/data.c
index b9fab6186f28..45f65a5b9871 100644
--- a/fs/f2fs/data.c
+++ b/fs/f2fs/data.c
@@ -111,7 +111,8 @@ static void f2fs_write_end_io(struct bio *bio)
if (unlikely(bio->bi_status)) {
mapping_set_error(page->mapping, -EIO);
- f2fs_stop_checkpoint(sbi, true);
+ if (type == F2FS_WB_CP_DATA)
+ f2fs_stop_checkpoint(sbi, true);
}
dec_page_count(sbi, type);
clear_cold_data(page);
--
2.15.0.531.g2ccb3012c9-goog