aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/lightnvm/pblk-write.c
diff options
context:
space:
mode:
authorJavier González <jg@lightnvm.io>2017-06-26 05:57:28 -0400
committerJens Axboe <axboe@kernel.dk>2017-06-26 18:27:39 -0400
commitef5764946b1314e0aa1ab261493de6b9aa482ff9 (patch)
tree20994287473b382deffea5f0877f1da8277d772f /drivers/lightnvm/pblk-write.c
parentb20ba1bc749ce0cd7a74d24f23826a6462c3de53 (diff)
lightnvm: pblk: set mempool and workqueue params.
Make constants to define sizes for internal mempools and workqueues. In this process, adjust the values to be more meaningful given the internal constrains of the FTL. In order to do this for workqueues, separate the current auxiliary workqueue into two dedicated workqueues to manage lines being closed and bad blocks. Signed-off-by: Javier González <javier@cnexlabs.com> Signed-off-by: Matias Bjørling <matias@cnexlabs.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/lightnvm/pblk-write.c')
-rw-r--r--drivers/lightnvm/pblk-write.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/lightnvm/pblk-write.c b/drivers/lightnvm/pblk-write.c
index a50bfbd12c32..f071fb79e199 100644
--- a/drivers/lightnvm/pblk-write.c
+++ b/drivers/lightnvm/pblk-write.c
@@ -150,7 +150,7 @@ static void pblk_end_w_fail(struct pblk *pblk, struct nvm_rq *rqd)
150 } 150 }
151 151
152 INIT_WORK(&recovery->ws_rec, pblk_submit_rec); 152 INIT_WORK(&recovery->ws_rec, pblk_submit_rec);
153 queue_work(pblk->kw_wq, &recovery->ws_rec); 153 queue_work(pblk->close_wq, &recovery->ws_rec);
154 154
155out: 155out:
156 pblk_complete_write(pblk, rqd, c_ctx); 156 pblk_complete_write(pblk, rqd, c_ctx);
@@ -198,7 +198,8 @@ static void pblk_end_io_write_meta(struct nvm_rq *rqd)
198 198
199 sync = atomic_add_return(rqd->nr_ppas, &emeta->sync); 199 sync = atomic_add_return(rqd->nr_ppas, &emeta->sync);
200 if (sync == emeta->nr_entries) 200 if (sync == emeta->nr_entries)
201 pblk_line_run_ws(pblk, line, NULL, pblk_line_close_ws); 201 pblk_line_run_ws(pblk, line, NULL, pblk_line_close_ws,
202 pblk->close_wq);
202 203
203 bio_put(rqd->bio); 204 bio_put(rqd->bio);
204 pblk_free_rqd(pblk, rqd, READ); 205 pblk_free_rqd(pblk, rqd, READ);