From: NeilBrown Date: Tue, 4 Nov 2008 09:51:12 +0000 (+1100) Subject: Assemble: revise detection of 'autoassemble' mode. X-Git-Tag: mdadm-3.0-devel2~17 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f05641cf7a250bda189f16d9c6b917683e5c9aad;p=thirdparty%2Fmdadm.git Assemble: revise detection of 'autoassemble' mode. We probably should pass a flag down saying 'this is auto-assembly', but for now, if there is no identity information set, it must be auto-assemble. Signed-off-by: NeilBrown --- diff --git a/Assemble.c b/Assemble.c index e421f22d..12e67b2c 100644 --- a/Assemble.c +++ b/Assemble.c @@ -138,7 +138,9 @@ int Assemble(struct supertype *st, char *mddev, */ int mdfd; int clean; - int auto_assem = (mddev == NULL); + int auto_assem = (mddev == NULL && !ident->uuid_set && + ident->super_minor == UnSet && ident->name[0] == 0 + && ident->container == NULL && ident->member == NULL); int old_linux = 0; int vers = vers; /* Keep gcc quite - it really is initialised */ struct {