From: Anna Czarnowska Date: Wed, 5 Jan 2011 02:42:59 +0000 (+1100) Subject: Assemble: we need to read policy to know array domains X-Git-Tag: mdadm-3.2~148 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=26b05aeaede6fbdf92807324ab94f9c15c1cc2c5;p=thirdparty%2Fmdadm.git Assemble: we need to read policy to know array domains Policy must be read on all disks identified as array members to get array's domains list. Currently it is only read on first array member in auto assembly mode. Signed-off-by: Anna Czarnowska Signed-off-by: NeilBrown --- diff --git a/Assemble.c b/Assemble.c index 5725b232..7ef9dc3e 100644 --- a/Assemble.c +++ b/Assemble.c @@ -546,8 +546,11 @@ int Assemble(struct supertype *st, char *mddev, } loop: /* Collect domain information from members only */ - if (tmpdev && tmpdev->used == 1) + if (tmpdev && tmpdev->used == 1) { + if (!pol) + pol = devnum_policy(stb.st_rdev); domain_merge(&domains, pol, tst?tst->ss->name:NULL); + } dev_policy_free(pol); pol = NULL; if (tst)