lightnvm: pblk: remove debug from pblk_[down/up]_page
authorMatias Bjørling <mb@lightnvm.io>
Tue, 9 Oct 2018 11:11:51 +0000 (13:11 +0200)
committerJens Axboe <axboe@kernel.dk>
Tue, 9 Oct 2018 14:25:07 +0000 (08:25 -0600)
commit43241cfe470850a590913a86e590fd4ad9939d59
tree2de5e0eeed63f296fd2457a8acf3f72e718c4ddd
parent765462fa4c4d0fd3eb718f2ba14cb04c35219854
lightnvm: pblk: remove debug from pblk_[down/up]_page

Remove the debug only iteration within __pblk_down_page, which
then allows us to reduce the number of arguments down to pblk and
the parallel unit from the functions that calls it. Simplifying the
callers logic considerably.

Also, rename the functions pblk_[down/up]_page to
pblk_[down/up]_chunk, to communicate that it manages the write
pointer of the chunk. Note that it also protects the parallel unit
such that at most one chunk is active per parallel unit.

Signed-off-by: Matias Bjørling <mb@lightnvm.io>
Reviewed-by: Javier González <javier@cnexlabs.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/lightnvm/pblk-core.c
drivers/lightnvm/pblk-map.c
drivers/lightnvm/pblk-recovery.c
drivers/lightnvm/pblk-write.c
drivers/lightnvm/pblk.h