lightnvm: pblk: improve line helpers
authorJavier González <javier@javigon.com>
Tue, 9 Oct 2018 11:11:42 +0000 (13:11 +0200)
committerJens Axboe <axboe@kernel.dk>
Tue, 9 Oct 2018 14:25:06 +0000 (08:25 -0600)
commitcb21665c8d13bb7e1f6e211442c53f4675f1569d
tree66f4205ee194150f918fb4588719a6b2bf7bac74
parent2cf99bbd106f89fc72f778e8ad9d5538f1ef939b
lightnvm: pblk: improve line helpers

The current helper to obtain a line from a ppa returns the line id,
which requires its users to explicitly retrieve the pointer to the line
with the id.

Make 2 different helpers: one returning the line id and one returning
the line directly.

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