All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@kernel.dk>
To: Jan Kara <jack@suse.com>
Cc: Jeff Moyer <jmoyer@redhat.com>, LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] blk-flush: Queue through IO scheduler when flush not required
Date: Mon, 16 Nov 2015 15:28:51 -0700	[thread overview]
Message-ID: <564A58A3.6020005@kernel.dk> (raw)
In-Reply-To: <1447334752-31027-1-git-send-email-jack@suse.com>

On 11/12/2015 06:25 AM, Jan Kara wrote:
> Currently blk_insert_flush() just adds flush request to q->queue_head
> when flush is not required. That completely bypasses IO scheduler so
> e.g. CFQ can be idling waiting for new request to arrive and will idle
> through the whole window unnecessarily. Luckily this only happens in
> rare cases as usually checks in generic_make_request_checks() clear
> FLUSH and FUA flags early if they are not needed.
>
> When no flushing is actually required, we can easily fix the problem by
> properly queueing the request through the IO scheduler. Ideally IO
> scheduler should be also made aware of requests queued via
> blk_flush_queue_rq(). However inserting flush request through IO
> scheduler can have unwanted side-effects since due to flush batching
> delaying the flush request in IO scheduler will delay all flush requests
> possibly coming from other processes. So we keep adding the request
> directly to q->queue_head.

Applied, thanks Jan.

-- 
Jens Axboe


      parent reply	other threads:[~2015-11-16 22:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-12 13:25 [PATCH] blk-flush: Queue through IO scheduler when flush not required Jan Kara
2015-11-16 20:14 ` Jeff Moyer
2015-11-16 22:28 ` Jens Axboe [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=564A58A3.6020005@kernel.dk \
    --to=axboe@kernel.dk \
    --cc=jack@suse.com \
    --cc=jmoyer@redhat.com \
    --cc=linux-kernel@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.