From: Kinga Tanska <kinga.tanska@intel.com>
To: linux-raid@vger.kernel.org
Cc: jes@trained-monkey.org, colyli@suse.de
Subject: [PATCH v3 1/2] Assemble: check if device is container before scheduling force-clean update
Date: Thu, 18 Aug 2022 09:20:40 +0200 [thread overview]
Message-ID: <20220818072041.13586-2-kinga.tanska@intel.com> (raw)
In-Reply-To: <20220818072041.13586-1-kinga.tanska@intel.com>
Up to now using assemble with force flag making each array as clean.
Force-clean should not be done for the container. This commit add
check if device is different than container before cleaning.
Signed-off-by: Kinga Tanska <kinga.tanska@intel.com>
---
Assemble.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/Assemble.c b/Assemble.c
index 704b8293..f31372db 100644
--- a/Assemble.c
+++ b/Assemble.c
@@ -1813,10 +1813,9 @@ try_again:
}
#endif
}
- if (c->force && !clean &&
+ if (c->force && !clean && content->array.level != LEVEL_CONTAINER &&
!enough(content->array.level, content->array.raid_disks,
- content->array.layout, clean,
- avail)) {
+ content->array.layout, clean, avail)) {
change += st->ss->update_super(st, content, "force-array",
devices[chosen_drive].devname, c->verbose,
0, NULL);
--
2.26.2
next prev parent reply other threads:[~2022-08-18 14:20 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-18 7:20 [PATCH v3 0/2] Fix force addemblation Kinga Tanska
2022-08-18 7:20 ` Kinga Tanska [this message]
2022-08-18 7:20 ` [PATCH v3 2/2] mdadm: replace container level checking with inline Kinga Tanska
-- strict thread matches above, loose matches on Subject: below --
2022-08-19 0:55 [PATCH v3 0/2] Fix force assemblation Kinga Tanska
2022-08-19 0:55 ` [PATCH v3 1/2] Assemble: check if device is container before scheduling force-clean update Kinga Tanska
2022-08-24 16:01 ` Jes Sorensen
2022-07-05 11:58 [PATCH v3 0/2] Fix force assemblation Kinga Tanska
2022-07-05 11:58 ` [PATCH v3 1/2] Assemble: check if device is container before scheduling force-clean update Kinga Tanska
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220818072041.13586-2-kinga.tanska@intel.com \
--to=kinga.tanska@intel.com \
--cc=colyli@suse.de \
--cc=jes@trained-monkey.org \
--cc=linux-raid@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.