From: NeilBrown Date: Thu, 10 Mar 2011 07:14:43 +0000 (+1100) Subject: ddf: Failed should suppress Online and others. X-Git-Tag: mdadm-3.1.5~22 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=18cb44962d1128ac5fc8f6922c591c0666b6de98;p=thirdparty%2Fmdadm.git ddf: Failed should suppress Online and others. so the notes say, so make it so. Signed-off-by: NeilBrown --- diff --git a/super-ddf.c b/super-ddf.c index 35515c4b..5f7a193e 100644 --- a/super-ddf.c +++ b/super-ddf.c @@ -1158,6 +1158,9 @@ static void examine_pds(struct ddf_super *sb) (type&8) ? "spare" : "", (type&16)? ", foreign" : "", (type&32)? "pass-through" : ""); + if (state & DDF_Failed) + /* This over-rides these three */ + state &= ~(DDF_Online|DDF_Rebuilding|DDF_Transition); printf("/%s%s%s%s%s%s%s", (state&1)? "Online": "Offline", (state&2)? ", Failed": "",