handle resync completion
From: Dan Williams <dan.j.williams@intel.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
This commit is contained in:
parent
845dea950c
commit
fd7cde1bf0
1
mdadm.h
1
mdadm.h
|
@ -407,6 +407,7 @@ extern struct superswitch {
|
|||
int (*open_new)(struct supertype *c, struct active_array *a, int inst);
|
||||
void (*mark_clean)(struct active_array *a, unsigned long long sync_pos);
|
||||
void (*mark_dirty)(struct active_array *a);
|
||||
void (*mark_sync)(struct active_array *a, unsigned long long resync);
|
||||
void (*set_disk)(struct active_array *a, int n);
|
||||
void (*sync_metadata)(struct active_array *a);
|
||||
|
||||
|
|
|
@ -274,10 +274,9 @@ static int read_and_act(struct active_array *a)
|
|||
|
||||
if (a->curr_action == idle &&
|
||||
a->prev_action == resync) {
|
||||
/* check resync_start to see if it is 'max'.
|
||||
* Do I open here, or have it open the whole time?
|
||||
*/
|
||||
get_sync_pos(a);
|
||||
/* check resync_start to see if it is 'max' */
|
||||
get_resync_start(a);
|
||||
a->container->ss->mark_sync(a, a->resync_start);
|
||||
check_degraded = 1;
|
||||
}
|
||||
|
||||
|
|
|
@ -2459,6 +2459,11 @@ static void ddf_mark_dirty(struct active_array *a)
|
|||
fprintf(stderr, "ddf: mark dirty\n");
|
||||
}
|
||||
|
||||
static void ddf_mark_sync(struct active_array *a, unsigned long long resync)
|
||||
{
|
||||
fprintf(stderr, "ddf: mark sync\n");
|
||||
}
|
||||
|
||||
static void ddf_set_disk(struct active_array *a, int n)
|
||||
{
|
||||
fprintf(stderr, "ddf: set_disk %d\n", n);
|
||||
|
@ -2504,6 +2509,7 @@ struct superswitch super_ddf = {
|
|||
.load_super = load_super_ddf,
|
||||
.mark_clean = ddf_mark_clean,
|
||||
.mark_dirty = ddf_mark_dirty,
|
||||
.mark_sync = ddf_mark_sync,
|
||||
.set_disk = ddf_set_disk,
|
||||
.sync_metadata = ddf_sync_metadata,
|
||||
|
||||
|
|
|
@ -1132,6 +1132,11 @@ static void imsm_mark_dirty(struct active_array *a)
|
|||
fprintf(stderr, "imsm: mark dirty\n");
|
||||
}
|
||||
|
||||
static void imsm_mark_sync(struct active_array *a, unsigned long long resync)
|
||||
{
|
||||
fprintf(stderr, "imsm: mark sync\n");
|
||||
}
|
||||
|
||||
static void imsm_set_disk(struct active_array *a, int n)
|
||||
{
|
||||
fprintf(stderr, "imsm: set_disk %d\n", n);
|
||||
|
@ -1176,6 +1181,7 @@ struct superswitch super_imsm = {
|
|||
.load_super = load_super_imsm,
|
||||
.mark_clean = imsm_mark_clean,
|
||||
.mark_dirty = imsm_mark_dirty,
|
||||
.mark_sync = imsm_mark_sync,
|
||||
.set_disk = imsm_set_disk,
|
||||
.sync_metadata = imsm_sync_metadata,
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue