diff options
author | NeilBrown <neilb@suse.de> | 2012-10-04 16:51:22 +1000 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2012-10-18 15:39:10 +1100 |
commit | c51f288b1045f55619bee69ae540a83bcdc00bfb (patch) | |
tree | e33797eaa77c2730ce9a3b9521fad75e1dac07e8 | |
parent | 5267ba06c27178ae641b0700526405791883bdcb (diff) | |
download | mdadm-c51f288b1045f55619bee69ae540a83bcdc00bfb.tar.gz |
imsm: allow --assume-clean to work.
We must avoid setting IMSM_T_STATE_UNINITIALIZED if the
array was declared to be clean due to --assume-clean.
Signed-off-by: NeilBrown <neilb@suse.de>
-rw-r--r-- | super-intel.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/super-intel.c b/super-intel.c index 07ab9ae..544cb05 100644 --- a/super-intel.c +++ b/super-intel.c @@ -4678,7 +4678,8 @@ static int init_super_imsm_volume(struct supertype *st, mdu_array_info_t *info, map->blocks_per_strip = __cpu_to_le16(info_to_blocks_per_strip(info)); map->failed_disk_num = ~0; if (info->level > 0) - map->map_state = IMSM_T_STATE_UNINITIALIZED; + map->map_state = (info->state ? IMSM_T_STATE_NORMAL + : IMSM_T_STATE_UNINITIALIZED); else map->map_state = info->failed_disks ? IMSM_T_STATE_FAILED : IMSM_T_STATE_NORMAL; |