newblocks is the count of new blocks written to the filesystem in this
checkpoint (roughly the amount of work that roll-forward would have to
do). We use it to trigger new checkpoints.
So we need to reset it after each checkpoint.
Signed-off-by: NeilBrown <neilb@suse.de>
/* FIXME might I now be racing with unmount and module unload??? */
fs->checkpoint_youth = youth;
+ fs->newblocks = 0;
lafs_wake_cleaner(fs);
}
} cleaner;
struct task_struct *cleaner_thread;
- unsigned long newblocks; /* number of blocks written since checkpoint */
+ unsigned long newblocks; /* number of blocks written since checkpoint
+ * FIXME this should probably be a count
+ * of segments (?)
+ */
unsigned long max_newblocks; /* max blocks in a checkpoint (roughly) */
/* counters for (pre)allocating space. */