From 18fde300feeb9e7c054510b0655b316c025c7a94 Mon Sep 17 00:00:00 2001 From: Dan Williams Date: Tue, 24 Feb 2009 18:45:57 -0700 Subject: Create: fixup 'insert_point', dependent on 'subdevs', for auto-layout 'subdevs' is read from the container in the auto-layout case so reset subdevs dependent default values. 'insert_point' without this change is always 2 blocking creation of arrays with > 2 raid disks. Signed-off-by: Dan Williams --- Create.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'Create.c') diff --git a/Create.c b/Create.c index 191e1134..d33f8914 100644 --- a/Create.c +++ b/Create.c @@ -187,8 +187,12 @@ int Create(struct supertype *st, char *mddev, else st = NULL; } - if (have_container) + if (have_container) { subdevs = raiddisks; + first_missing = subdevs * 2; + second_missing = subdevs * 2; + insert_point = subdevs * 2; + } } if (fd >= 0) close(fd); -- cgit v1.2.3