From: Xueshi Hu <xueshi.hu@smartx.com>
To: song@kernel.org
Cc: linux-raid@vger.kernel.org, Xueshi Hu <xueshi.hu@smartx.com>
Subject: [PATCH v2 0/3] md/raid1: don't change mempool if in-flight r1bio exists
Date: Sun, 9 Jul 2023 18:29:53 +0800 [thread overview]
Message-ID: <20230709102956.1716708-1-hubachelar@gmail.com> (raw)
From: Xueshi Hu <xueshi.hu@smartx.com>
All the r1bio should be freed before raid1_reshape() changes the
mempool. However, freeze_array() doesn't guarantee there's no r1bio,
as some r1bio maybe queued. Also, in raid1_write_request() and
handle_read_error(), kernel shall not allow_barrier() before the r1bio is
properly handled.
Changes in v2:
- fix the problem one by one instead of calling
blk_mq_freeze_queue() as suggested by Yu Kuai
Xueshi Hu (3):
md/raid1: gave up reshape in case there's queued io
md/raid1: free old r1bio before retry write
md/raid1: keep holding the barrier in handle_read_error()
drivers/md/raid1.c | 36 +++++++++++++++++++++---------------
1 file changed, 21 insertions(+), 15 deletions(-)
--
2.40.1
next reply other threads:[~2023-07-09 10:30 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-09 10:29 Xueshi Hu [this message]
2023-07-09 10:29 ` [PATCH v2 1/3] md/raid1: gave up reshape in case there's queued io Xueshi Hu
2023-07-11 12:35 ` Yu Kuai
2023-07-09 10:29 ` [PATCH v2 2/3] md/raid1: free old r1bio before retry write Xueshi Hu
2023-07-11 12:36 ` Yu Kuai
2023-07-09 10:29 ` [PATCH v2 3/3] md/raid1: keep holding the barrier in handle_read_error() Xueshi Hu
2023-07-11 12:37 ` Yu Kuai
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=20230709102956.1716708-1-hubachelar@gmail.com \
--to=xueshi.hu@smartx.com \
--cc=linux-raid@vger.kernel.org \
--cc=song@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).