summaryrefslogtreecommitdiff
path: root/fs/f2fs/node.c
diff options
context:
space:
mode:
authorJaegeuk Kim <jaegeuk.kim@samsung.com>2014-03-18 13:43:05 +0900
committerJaegeuk Kim <jaegeuk.kim@samsung.com>2014-03-18 16:37:16 +0900
commitd3baf95da5b0bce9fe980eeff6140817d63fabdf (patch)
treebdfe9bf428f9c21959b05136b61bd440df2b86a5 /fs/f2fs/node.c
parent87d6f890944d092c4ef5b84053f0d0d5d8137b0b (diff)
f2fs: increase pages_skipped when skipping writepages
This patch increases pages_skipped when skipping writepages. Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
Diffstat (limited to 'fs/f2fs/node.c')
-rw-r--r--fs/f2fs/node.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/fs/f2fs/node.c b/fs/f2fs/node.c
index cb514f1896ab..7cc146bcbfed 100644
--- a/fs/f2fs/node.c
+++ b/fs/f2fs/node.c
@@ -1209,7 +1209,7 @@ static int f2fs_write_node_pages(struct address_space *mapping,
/* collect a number of dirty node pages and write together */
if (get_pages(sbi, F2FS_DIRTY_NODES) < nr_pages_to_skip(sbi, NODE))
- return 0;
+ goto skip_write;
/* if mounting is failed, skip writing node pages */
wbc->nr_to_write = 3 * max_hw_blocks(sbi);
@@ -1218,6 +1218,10 @@ static int f2fs_write_node_pages(struct address_space *mapping,
wbc->nr_to_write = nr_to_write - (3 * max_hw_blocks(sbi) -
wbc->nr_to_write);
return 0;
+
+skip_write:
+ wbc->pages_skipped += get_pages(sbi, F2FS_DIRTY_NODES);
+ return 0;
}
static int f2fs_set_node_page_dirty(struct page *page)