]> git.baikalelectronics.ru Git - kernel.git/commit
nilfs2: fix possible mismatch of sufile counters on recovery
authorRyusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
Sun, 5 Apr 2009 09:30:58 +0000 (18:30 +0900)
committerRyusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
Mon, 13 Apr 2009 00:53:52 +0000 (09:53 +0900)
commit3d693cc57239bbe60b851d2e01708e8601f1add0
tree0319b8ab4d8b7da4d614e46949755b8a9ba4eab0
parent32568f306bd86b86fc3e477b58d31309b0d7ba32
nilfs2: fix possible mismatch of sufile counters on recovery

On-disk counters ndirtysegs and ncleansegs of sufile, can go wrong
after roll-forward recovery because
nilfs_prepare_segment_for_recovery() function marks segments dirty
without adjusting value of these counters.

This fixes the problem by adding a function to sufile which does the
operation adjusting the counters, and by letting the recovery function
use it.

Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
fs/nilfs2/recovery.c
fs/nilfs2/sufile.c
fs/nilfs2/sufile.h