summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--super-ddf.c6
-rw-r--r--super-intel.c6
2 files changed, 10 insertions, 2 deletions
diff --git a/super-ddf.c b/super-ddf.c
index b1cb2689..3feea577 100644
--- a/super-ddf.c
+++ b/super-ddf.c
@@ -2413,8 +2413,12 @@ static int write_init_super_ddf(struct supertype *st)
/* FIXME I need to close the fds! */
return 0;
- } else
+ } else {
+ struct dl *d;
+ for (d = ddf->dlist; d; d=d->next)
+ while (Kill(d->devname, NULL, 0, 1, 1) == 0);
return __write_init_super_ddf(st, 1);
+ }
}
#endif
diff --git a/super-intel.c b/super-intel.c
index b413435d..a196ca3d 100644
--- a/super-intel.c
+++ b/super-intel.c
@@ -3441,8 +3441,12 @@ static int write_init_super_imsm(struct supertype *st)
}
return rv;
- } else
+ } else {
+ struct dl *d;
+ for (d = super->disks; d; d = d->next)
+ Kill(d->devname, NULL, 0, 1, 1);
return write_super_imsm(st->sb, 1);
+ }
}
#endif