summaryrefslogtreecommitdiffstats
path: root/drivers/lightnvm/pblk.h
diff options
context:
space:
mode:
authorHeiner Litz <hlitz@ucsc.edu>2018-07-13 10:48:44 +0200
committerJens Axboe <axboe@kernel.dk>2018-07-13 16:14:47 +0200
commit11f6ad699a32f3be1232741e4bfa34abf6677cb8 (patch)
tree0b9292a525ddeeee5e04c21fafd4feb75195ea00 /drivers/lightnvm/pblk.h
parentlightnvm: pblk: mark expected switch fall-through (diff)
downloadlinux-11f6ad699a32f3be1232741e4bfa34abf6677cb8.tar.xz
linux-11f6ad699a32f3be1232741e4bfa34abf6677cb8.zip
lightnvm: pblk: add asynchronous partial read
In the read path, partial reads are currently performed synchronously which affects performance for workloads that generate many partial reads. This patch adds an asynchronous partial read path as well as the required partial read ctx. Signed-off-by: Heiner Litz <hlitz@ucsc.edu> Reviewed-by: Igor Konopko <igor.j.konopko@intel.com> Signed-off-by: Matias Bjørling <mb@lightnvm.io> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/lightnvm/pblk.h')
-rw-r--r--drivers/lightnvm/pblk.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/lightnvm/pblk.h b/drivers/lightnvm/pblk.h
index 5c6904eb8557..4760af7b6499 100644
--- a/drivers/lightnvm/pblk.h
+++ b/drivers/lightnvm/pblk.h
@@ -119,6 +119,16 @@ struct pblk_g_ctx {
u64 lba;
};
+/* partial read context */
+struct pblk_pr_ctx {
+ struct bio *orig_bio;
+ DECLARE_BITMAP(bitmap, NVM_MAX_VLBA);
+ unsigned int orig_nr_secs;
+ unsigned int bio_init_idx;
+ void *ppa_ptr;
+ dma_addr_t dma_ppa_list;
+};
+
/* Pad context */
struct pblk_pad_rq {
struct pblk *pblk;