From: Keith Busch <keith.busch@intel.com>
To: Linux Block <linux-block@vger.kernel.org>,
Linux NVMe <linux-nvme@lists.infradead.org>,
Christoph Hellwig <hch@lst.de>, Jens Axboe <axboe@kernel.dk>
Cc: Keith Busch <keith.busch@intel.com>
Subject: [PATCHv2 0/2] block: Discard merging fixes
Date: Thu, 1 Feb 2018 13:31:56 -0700 [thread overview]
Message-ID: <20180201203158.24761-1-keith.busch@intel.com> (raw)
This series fixes some incorrect accounting from merging discard requests.
The first patch fixes merging two discard requests by having a special
case for merging these using the unique constraints discards have.
The second fixes merging a new discard bio into an existing
request. Previously all the schedulers defaulted to a front merge,
so the patch just checks merge type and adds a 'case' for handling
discard in each of the callers.
I've only been able to test with mq-deadline on NVMe as that is the only
driver currently supporting multiple discard ranges in a single command.
v1 -> v2:
Fixed patch 1 based on feedback from Jens, tested with recreate
sequence.
Added 2nd patch for merging discard bios into existing requests.
Keith Busch (2):
block: Merge discard requests as a special case
block: Handle merging discards in IO schedulers
block/bfq-iosched.c | 2 +-
block/blk-core.c | 4 ++++
block/blk-merge.c | 29 ++++++++++++++++++++++++++++-
block/blk-mq-sched.c | 2 ++
block/cfq-iosched.c | 2 +-
block/deadline-iosched.c | 4 +++-
block/elevator.c | 2 +-
block/mq-deadline.c | 2 +-
8 files changed, 41 insertions(+), 6 deletions(-)
--
2.14.3
next reply other threads:[~2018-02-01 20:31 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-01 20:31 Keith Busch [this message]
2018-02-01 20:31 ` [PATCHv2 1/2] block: Merge discard requests as a special case Keith Busch
2018-02-01 21:00 ` Jens Axboe
2018-02-01 20:31 ` [PATCHv2 2/2] block: Handle merging discards in IO schedulers Keith Busch
2018-02-01 21:02 ` Jens Axboe
2018-02-01 21:28 ` Keith Busch
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=20180201203158.24761-1-keith.busch@intel.com \
--to=keith.busch@intel.com \
--cc=axboe@kernel.dk \
--cc=hch@lst.de \
--cc=linux-block@vger.kernel.org \
--cc=linux-nvme@lists.infradead.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).