When expansion was interrupted, assembly should include all disks in to new array. To do this delta_disks has to be added to raid disks number. When metadata reports all disks in content->array.raid_disks then delta_disks should be equal to 0 (it is included in raid_disks already). Signed-off-by: Adam Kwolek <adam.kwolek@xxxxxxxxx> --- Assemble.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/Assemble.c b/Assemble.c index 317be8b..8d89dbe 100644 --- a/Assemble.c +++ b/Assemble.c @@ -1508,6 +1508,8 @@ int assemble_container_content(struct supertype *st, int mdfd, sysfs_init(content, mdfd, 0); + if (content->reshape_active) + content->array.raid_disks += content->delta_disks; sra = sysfs_read(mdfd, 0, GET_VERSION); if (sra == NULL || strcmp(sra->text_version, content->text_version) != 0) if (sysfs_set_array(content, md_get_version(mdfd)) != 0) { -- To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html