summaryrefslogtreecommitdiff
path: root/Incremental.c
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.de>2010-12-09 13:06:29 +1100
committerNeilBrown <neilb@suse.de>2010-12-09 13:06:29 +1100
commit833bb0f8f61c576895a2ec90c344c148c08dadba (patch)
treea94afa659cd2d01366009d3b0df2c77d473f92f9 /Incremental.c
parent691a36b76f871a63a327641589f41e968b05afa9 (diff)
Allow --update=devicesize with --re-add
This is useful with 1.1 and 1.2 metadata to update the metadata if the device size has changed. The same functionality can be achieved by writing to the device size in sysfs after re-adding normally, but in some cases this might be easier. Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'Incremental.c')
-rw-r--r--Incremental.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/Incremental.c b/Incremental.c
index 9399f5be..bc4531a5 100644
--- a/Incremental.c
+++ b/Incremental.c
@@ -980,7 +980,7 @@ static int array_try_spare(char *devname, int *dfdp, struct dev_policy *pol,
close(dfd);
*dfdp = -1;
rv = Manage_subdevs(chosen->sys_name, mdfd, &devlist,
- -1, 0);
+ -1, 0, NULL);
close(mdfd);
}
if (verbose > 0) {
@@ -1549,15 +1549,16 @@ int IncrementalRemove(char *devname, char *id_path, int verbose)
int subfd = open_dev(memb->devnum);
if (subfd >= 0) {
Manage_subdevs(memb->dev, subfd,
- &devlist, verbose, 0);
+ &devlist, verbose, 0,
+ NULL);
close(subfd);
}
}
free_mdstat(mdstat);
} else
- Manage_subdevs(ent->dev, mdfd, &devlist, verbose, 0);
+ Manage_subdevs(ent->dev, mdfd, &devlist, verbose, 0, NULL);
devlist.disposition = 'r';
- rv = Manage_subdevs(ent->dev, mdfd, &devlist, verbose, 0);
+ rv = Manage_subdevs(ent->dev, mdfd, &devlist, verbose, 0, NULL);
close(mdfd);
free_mdstat(ent);
return rv;