From 8fb870df5a1f261294b833dd807bcba3bacface6 Mon Sep 17 00:00:00 2001 From: David Woodhouse Date: Sat, 6 Oct 2007 15:12:58 -0400 Subject: [JFFS2] Trigger garbage collection when very_dirty_list size becomes excessive With huge amounts of free space, we weren't bothering to GC for while a while, and pathological numbers of obsolete nodes were accumulating, seriously affecting performance on NAND flash (OLPC trac #3978) Signed-off-by: David Woodhouse --- fs/jffs2/jffs2_fs_sb.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'fs/jffs2/jffs2_fs_sb.h') diff --git a/fs/jffs2/jffs2_fs_sb.h b/fs/jffs2/jffs2_fs_sb.h index ae99cd7fd43..3a2197f3c81 100644 --- a/fs/jffs2/jffs2_fs_sb.h +++ b/fs/jffs2/jffs2_fs_sb.h @@ -69,6 +69,8 @@ struct jffs2_sb_info { uint8_t resv_blocks_gctrigger; /* ... wake up the GC thread */ uint8_t resv_blocks_gcbad; /* ... pick a block from the bad_list to GC */ uint8_t resv_blocks_gcmerge; /* ... merge pages when garbage collecting */ + /* Number of 'very dirty' blocks before we trigger immediate GC */ + uint8_t vdirty_blocks_gctrigger; uint32_t nospc_dirty_size; -- cgit v1.2.3-70-g09d2