summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.de>2014-05-06 11:29:49 +1000
committerNeilBrown <neilb@suse.de>2014-05-21 11:54:48 +1000
commit4fe903aa8b65f9a66d00a54d114c9a10ccdf21b0 (patch)
tree6a39d9125ab76a02cfa552abb1a43cf1e4da238d
parent25532b88a0ee9fa051c9ebace59cd79f9adae328 (diff)
DDF: DDF_Missing devices should not be reported as 'working' by getinfo_super_ddf
Signed-off-by: NeilBrown <neilb@suse.de>
-rw-r--r--super-ddf.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/super-ddf.c b/super-ddf.c
index da45be9c..5a07c46e 100644
--- a/super-ddf.c
+++ b/super-ddf.c
@@ -2014,7 +2014,8 @@ static void getinfo_super_ddf(struct supertype *st, struct mdinfo *info, char *m
if (info->disk.raid_disk >= 0)
pde = ddf->phys->entries + info->disk.raid_disk;
if (pde &&
- !(be16_to_cpu(pde->state) & DDF_Failed))
+ !(be16_to_cpu(pde->state) & DDF_Failed) &&
+ !(be16_to_cpu(pde->state) & DDF_Missing))
info->disk.state = (1 << MD_DISK_SYNC) | (1 << MD_DISK_ACTIVE);
else
info->disk.state = 1 << MD_DISK_FAULTY;