From: "Matias Bjørling" <m@bjorling.me>
To: hch@infradead.org, axboe@fb.com, linux-fsdevel@vger.kernel.org,
linux-kernel@vger.kernel.org
Cc: thornber@redhat.com, bvanassche@acm.org, jmad@itu.dk,
"Matias Bjørling" <m@bjorling.me>
Subject: [RPC PATCH 0/5] Support for Open-Channel SSDs
Date: Tue, 18 Nov 2014 20:41:54 +0100 [thread overview]
Message-ID: <1416339719-8488-1-git-send-email-m@bjorling.me> (raw)
Hi,
Here is an updated patchset of LightNVM. It is now integrated directly into the
block layer when using blk-mq. I'll like to get some feedback on how it is
plugged in.
The block layer integration is as follows:
block/blk-lightnvm.c holds the setup/teardown functions and calls
in to the lightnvm code.
Extendied the request queue flags with QUEUE_FLAG_LIGHTNVM when the queue is a
LightNVM queue.
The struct request structure is extended with a ->phys_sector, that holds the
physical address that a logical address is mapped to. The ->phys_sector is set
by blk_lightnvm_map, that calls into lightnvm and allocate new address on
writes, and similarly look up an address on reads.
A request has a NVM_MAP flag set when it has been mapped. This is used to know
if completion logic should be run on blk-mq completion. It might now be for
some targets.
The request cmd_size field is extended to hold any per-request information
that lightnvm requires for its bookkeeping.
A branch with the patches can be found here:
https://github.com/OpenChannelSSD/linux.git lkml_v1
It is currently based on 3.17 on top of the NVMe blk-mq conversion.
For testing, the null_blk driver can be instantiated with:
lightnvm_enable=1 gb=4 bs=4096 nr_devices=1
or by using the qemu branch at:
https://github.com/OpenChannelSSD/qemu-nvme.git master
and booting qemu with:
-drive file=filepath,if=none,id=mynvme \
-device nvme,drive=mynvme,serial=deadbeef,namespaces=1,lver=1,lchannels=1, \
nlbaf=5,lba_index=3
Todo:
Multi-page accesses. Currently limited to sector size IO accesses.
Retrieval of mapping table from device. Mapping table is forgot on module
unload.
Bad block handling. No method to handle flash blocks there are marked bad.
Thanks,
Matias
Jesper Madsen (1):
block: extend rq_flag_bits
Matias Bjørling (4):
block: expose init_request_from_bio
lightnvm: Support for Open-Channel SSDs
nvme: LightNVM integration
null_blk: LightNVM integration
Documentation/block/null_blk.txt | 8 +
block/Makefile | 1 +
block/blk-core.c | 6 +
block/blk-lightnvm.c | 81 ++++++
block/blk-mq.c | 35 ++-
block/blk-sysfs.c | 13 +
block/blk.h | 14 +
block/ioctl.c | 1 +
drivers/Kconfig | 2 +
drivers/Makefile | 1 +
drivers/block/null_blk.c | 89 +++++-
drivers/block/nvme-core.c | 187 ++++++++++++-
drivers/lightnvm/Kconfig | 20 ++
drivers/lightnvm/Makefile | 5 +
drivers/lightnvm/core.c | 208 ++++++++++++++
drivers/lightnvm/gc.c | 370 ++++++++++++++++++++++++
drivers/lightnvm/nvm.c | 460 ++++++++++++++++++++++++++++++
drivers/lightnvm/nvm.h | 588 +++++++++++++++++++++++++++++++++++++++
drivers/lightnvm/sysfs.c | 68 +++++
drivers/lightnvm/targets.c | 244 ++++++++++++++++
include/linux/blk-mq.h | 1 +
include/linux/blk_types.h | 4 +
include/linux/blkdev.h | 24 ++
include/linux/lightnvm.h | 112 ++++++++
include/linux/nvme.h | 1 +
include/trace/events/nvm.h | 70 +++++
include/uapi/linux/nvme.h | 74 +++++
27 files changed, 2677 insertions(+), 10 deletions(-)
create mode 100644 block/blk-lightnvm.c
create mode 100644 drivers/lightnvm/Kconfig
create mode 100644 drivers/lightnvm/Makefile
create mode 100644 drivers/lightnvm/core.c
create mode 100644 drivers/lightnvm/gc.c
create mode 100644 drivers/lightnvm/nvm.c
create mode 100644 drivers/lightnvm/nvm.h
create mode 100644 drivers/lightnvm/sysfs.c
create mode 100644 drivers/lightnvm/targets.c
create mode 100644 include/linux/lightnvm.h
create mode 100644 include/trace/events/nvm.h
--
1.9.1
next reply other threads:[~2014-11-18 19:42 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-18 19:41 Matias Bjørling [this message]
2014-11-18 19:41 ` [RPC PATCH 1/5] block: expose init_request_from_bio Matias Bjørling
2014-11-18 19:41 ` [RPC PATCH 2/5] block: extend rq_flag_bits Matias Bjørling
2014-11-18 19:41 ` [RFC PATCH 3/5] lightnvm: Support for Open-Channel SSDs Matias Bjørling
2014-11-18 19:41 ` [RFC PATCH 4/5] nvme: LightNVM integration Matias Bjørling
2014-11-18 19:41 ` [RFC PATCH 5/5] null_blk: " 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=1416339719-8488-1-git-send-email-m@bjorling.me \
--to=m@bjorling.me \
--cc=axboe@fb.com \
--cc=bvanassche@acm.org \
--cc=hch@infradead.org \
--cc=jmad@itu.dk \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=thornber@redhat.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
all inboxes | Powered by JetHome®