From: NeilBrown <neilb@suse.de>
To: Namhyung Kim <namhyung@gmail.com>
Cc: linux-raid@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] md: use REQ_NOIDLE flag in md_super_write()
Date: Thu, 4 Aug 2011 14:26:39 +1000 [thread overview]
Message-ID: <20110804142639.6484de94@notabene.brown> (raw)
In-Reply-To: <1312387077-26617-1-git-send-email-namhyung@gmail.com>
On Thu, 4 Aug 2011 00:57:57 +0900 Namhyung Kim <namhyung@gmail.com> wrote:
> Queue idling is used for the anticipation of immediate
> sequencial I/O's but md_super_write() is a kind of one-
> shot operation, coupled with md_super_wait(), so the
> idling in this case will be just a waste of time.
>
> Specifying REQ_NOIDLE prevents it. Instead of adding
> the flag to submit_bio() directly, use pre-defined
> macro WRITE_FLUSH_FUA.
>
> Signed-off-by: Namhyung Kim <namhyung@gmail.com>
> ---
> drivers/md/md.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/md/md.c b/drivers/md/md.c
> index d97a62534798..8650e9a0ce7c 100644
> --- a/drivers/md/md.c
> +++ b/drivers/md/md.c
> @@ -848,7 +848,7 @@ void md_super_write(mddev_t *mddev, mdk_rdev_t *rdev,
> bio->bi_end_io = super_written;
>
> atomic_inc(&mddev->pending_writes);
> - submit_bio(REQ_WRITE | REQ_SYNC | REQ_FLUSH | REQ_FUA, bio);
> + submit_bio(WRITE_FLUSH_FUA, bio);
> }
>
> void md_super_wait(mddev_t *mddev)
Applied, thanks.
NeilBrown
prev parent reply other threads:[~2011-08-04 4:26 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-03 15:57 [PATCH] md: use REQ_NOIDLE flag in md_super_write() Namhyung Kim
2011-08-04 4:26 ` NeilBrown [this message]
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=20110804142639.6484de94@notabene.brown \
--to=neilb@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-raid@vger.kernel.org \
--cc=namhyung@gmail.com \
/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