Assemble: Fix naming of container devices.

Container devices are meant to be named for the metadata type.
That wasn't happening properly for DDF.


Signed-off-by: NeilBrown <neilb@suse.de>
This commit is contained in:
NeilBrown 2008-11-04 20:50:39 +11:00
parent 9759037678
commit a4bc1720ff
1 changed files with 6 additions and 5 deletions

View File

@ -423,13 +423,14 @@ int Assemble(struct supertype *st, char *mddev,
name = info.name;
break;
case -1:
if (info.name[0] == 0 && info.array.level == LEVEL_CONTAINER) {
name = info.text_version;
trustworthy = METADATA;
} else
trustworthy = FOREIGN;
trustworthy = FOREIGN;
break;
}
if (info.name[0] == 0 &&
info.array.level == LEVEL_CONTAINER) {
name = info.text_version;
trustworthy = METADATA;
}
mdfd = create_mddev(mddev, name, ident->autof, trustworthy,
chosen_name);
if (mdfd < 0) {