]> git.ipfire.org Git - thirdparty/mdadm.git/commitdiff
monitor: call get_resync_start on array shutdown.
authorNeilBrown <neilb@suse.de>
Fri, 18 Jul 2008 06:37:26 +0000 (16:37 +1000)
committerNeilBrown <neilb@suse.de>
Fri, 18 Jul 2008 06:37:26 +0000 (16:37 +1000)
If the array is shutdown as soon as resync finishes, we might not
notice the resync finish.  So on array shutdown, check for current
resync pos.

Signed-off-by: Neil Brown <neilb@suse.de>
monitor.c

index e29d023a4c756c9ad1599b5c283988ad1c479f00..347cde79f78c96699729e126928d1298d81b7a10 100644 (file)
--- a/monitor.c
+++ b/monitor.c
@@ -220,6 +220,7 @@ static int read_and_act(struct active_array *a)
        if (a->curr_state <= inactive &&
            a->prev_state > inactive) {
                /* array has been stopped */
+               get_resync_start(a);
                a->container->ss->set_array_state(a, 1);
                a->next_state = clear;
                deactivate = 1;