If there is no metadata (--build was used) then we need to lookup
by devnum, not by uuid, to get the map entry.
Signed-off-by: NeilBrown <neilb@suse.de>
if (st->ss->export_detail_super)
st->ss->export_detail_super(st);
+ } else {
+ struct map_ent *mp, *map = NULL;
+ mp = map_by_devnum(&map, fd2devnum(fd));
+ if (mp && mp->path &&
+ strncmp(mp->path, "/dev/md/", 8) == 0)
+ printf("MD_DEVNAME=%s\n", mp->path+8);
}
goto out;
}