md/bitmap: separate out loading a bitmap from initialising the structures.

dm makes this distinction between ->ctr and ->resume, so we need to
too.

Also get the new bitmap_load to clear out the bitmap first, as this is
most consistent with the dm suspend/resume approach

Signed-off-by: NeilBrown <neilb@suse.de>
This commit is contained in:
NeilBrown
2010-06-01 19:37:35 +10:00
parent e384e58549
commit 69e51b449d
3 changed files with 60 additions and 23 deletions

View File

@@ -254,6 +254,7 @@ struct bitmap {
/* these are used only by md/bitmap */
int bitmap_create(mddev_t *mddev);
int bitmap_load(mddev_t *mddev);
void bitmap_flush(mddev_t *mddev);
void bitmap_destroy(mddev_t *mddev);