linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Matias Bjorling <m@bjorling.me>
Cc: Christoph Hellwig <hch@infradead.org>,
	Stephen.Bates@pmcs.com, keith.busch@intel.com,
	javier@lightnvm.io, linux-kernel@vger.kernel.org,
	linux-nvme@lists.infradead.org, axboe@fb.com,
	linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH v4 0/8] Support for Open-Channel SSDs
Date: Wed, 17 Jun 2015 06:59:05 -0700	[thread overview]
Message-ID: <20150617135905.GA17119@infradead.org> (raw)
In-Reply-To: <557C5787.3000608@bjorling.me>

On Sat, Jun 13, 2015 at 06:17:11PM +0200, Matias Bjorling wrote:
> > Note that for NVMe it might still make sense to implement this using
> > blk-mq and a struct request, but those should be internal similar to
> > how NVMe implements admin commands.
> 
> How about handling I/O merges? In the case where a block API is exposed
> with a global FTL, filesystems relies on I/O merges for improving
> performance. If using internal commands, merging has to implemented in
> the lightnvm stack itself, I rather want to use blk-mq and not duplicate
> the effort. I've kept the stacking model, so that I/Os go through the
> queue I/O path and then picked up in the device driver.

I don't think the current abuses of the block API are acceptable though.
The crazy deep merging shouldn't be too relevant for SSD-type devices
so I think you'd do better than trying to reuse the TYPE_FS level
blk-mq merging code.  If you want to reuse the request
allocation/submission code that's still doable.

As a start add a new submit_io method to the nvm_dev_ops, and add
an implementation similar to pscsi_execute_cmd in
drivers/target/target_core_pscsi.c for nvme, and a trivial no op
for a null-nvm driver replacing the null-blk additions.  This
will give you very similar behavior to your current code, while
allowing to drop all the hacks in the block code.  Note that simple
plugging will work just fine which should be all you'll need.

  reply	other threads:[~2015-06-17 13:59 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-05 12:54 [PATCH v4 0/8] Support for Open-Channel SSDs Matias Bjørling
2015-06-05 12:54 ` [PATCH v4 1/8] nvme: add special param for nvme_submit_sync_cmd Matias Bjørling
2015-06-05 12:54 ` [PATCH v4 2/8] nvme: don't overwrite req->cmd_flags on sync cmd Matias Bjørling
2015-06-09  7:31   ` Christoph Hellwig
2015-06-05 12:54 ` [PATCH v4 3/8] null_blk: wrong capacity when bs is not 512 bytes Matias Bjørling
2015-06-05 12:54 ` [PATCH v4 4/8] bio: Introduce LightNVM payload Matias Bjørling
2015-06-05 18:17   ` Matias Bjorling
2015-07-06 13:16     ` Pavel Machek
2015-06-05 12:54 ` [PATCH v4 5/8] lightnvm: Support for Open-Channel SSDs Matias Bjørling
2015-06-05 12:54 ` [PATCH v4 6/8] lightnvm: RRPC target Matias Bjørling
2015-06-05 12:54 ` [PATCH v4 7/8] null_blk: LightNVM support Matias Bjørling
2015-06-05 12:54 ` [PATCH v4 8/8] nvme: " Matias Bjørling
2015-06-08 14:48 ` [PATCH v4 0/8] Support for Open-Channel SSDs Stephen Bates
2015-06-09  7:46 ` Christoph Hellwig
2015-06-10 18:11   ` Matias Bjorling
2015-06-11 10:29     ` Christoph Hellwig
2015-06-13 16:17       ` Matias Bjorling
2015-06-17 13:59         ` Christoph Hellwig [this message]
2015-06-17 18:04           ` Matias Bjorling
2015-07-16 12:23           ` Matias Bjørling
2015-07-16 12:46             ` Christoph Hellwig
2015-07-16 13:06               ` Matias Bjørling

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=20150617135905.GA17119@infradead.org \
    --to=hch@infradead.org \
    --cc=Stephen.Bates@pmcs.com \
    --cc=axboe@fb.com \
    --cc=javier@lightnvm.io \
    --cc=keith.busch@intel.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nvme@lists.infradead.org \
    --cc=m@bjorling.me \
    /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).