From: Ming Lei <tom.leiming@gmail.com>
To: Jens Axboe <axboe@fb.com>, linux-kernel@vger.kernel.org
Cc: linux-block@vger.kernel.org,
Christoph Hellwig <hch@infradead.org>,
Ming Lei <tom.leiming@gmail.com>, Shaohua Li <shli@kernel.org>,
"open list:SOFTWARE RAID Multiple Disks SUPPORT"
<linux-raid@vger.kernel.org>
Subject: [PATCH v1 11/54] md: set NO_MP for request queue of md
Date: Tue, 27 Dec 2016 23:56:00 +0800 [thread overview]
Message-ID: <1482854250-13481-12-git-send-email-tom.leiming@gmail.com> (raw)
In-Reply-To: <1482854250-13481-1-git-send-email-tom.leiming@gmail.com>
MD isn't ready for multipage bvecs, so mark it as
NO_MP.
Signed-off-by: Ming Lei <tom.leiming@gmail.com>
---
drivers/md/md.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/drivers/md/md.c b/drivers/md/md.c
index 82821ee0d57f..63c6326bafde 100644
--- a/drivers/md/md.c
+++ b/drivers/md/md.c
@@ -5162,6 +5162,16 @@ static void md_safemode_timeout(unsigned long data)
static int start_dirty_degraded;
+/*
+ * MD isn't ready for multipage bvecs yet, and set the flag
+ * so that MD still can see singlepage bvecs bio
+ */
+static inline void md_set_no_mp(struct mddev *mddev)
+{
+ if (mddev->queue)
+ set_bit(QUEUE_FLAG_NO_MP, &mddev->queue->queue_flags);
+}
+
int md_run(struct mddev *mddev)
{
int err;
@@ -5381,6 +5391,8 @@ int md_run(struct mddev *mddev)
if (mddev->sb_flags)
md_update_sb(mddev, 0);
+ md_set_no_mp(mddev);
+
md_new_event(mddev);
sysfs_notify_dirent_safe(mddev->sysfs_state);
sysfs_notify_dirent_safe(mddev->sysfs_action);
--
2.7.4
next prev parent reply other threads:[~2016-12-27 15:56 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-27 15:55 [PATCH v1 00/54] block: support multipage bvec Ming Lei
2016-12-27 15:55 ` [PATCH v1 07/54] bcache: comment on direct access to bvec table Ming Lei
2016-12-30 16:56 ` Coly Li
2016-12-27 15:55 ` [PATCH v1 08/54] block: comment on bio_alloc_pages() Ming Lei
2016-12-30 10:40 ` Coly Li
2016-12-30 11:06 ` Coly Li
2016-12-27 15:56 ` Ming Lei [this message]
2016-12-27 15:56 ` [PATCH v1 12/54] dm: limit the max bio size as BIO_MAX_PAGES * PAGE_SIZE Ming Lei
2016-12-27 15:56 ` [PATCH v1 23/54] bcache: handle bio_clone() & bvec updating for multipage bvecs Ming Lei
2016-12-30 11:01 ` Coly Li
2016-12-31 10:29 ` Ming Lei
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=1482854250-13481-12-git-send-email-tom.leiming@gmail.com \
--to=tom.leiming@gmail.com \
--cc=axboe@fb.com \
--cc=hch@infradead.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-raid@vger.kernel.org \
--cc=shli@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).