linux-sg2042/drivers/lightnvm
Matias Bjørling 5136061ce7 lightnvm: introduce nvm_for_each_lun_ppa() macro
Users that wish to iterate all luns on a device. Must create a
struct ppa_addr and separate iterators for channels and luns. To set the
iterators, two loops are required, one to iterate channels, and another
to iterate luns. This leads to decrease in readability.

Introduce nvm_for_each_lun_ppa, which implements the nested loop and
sets ppa, channel, and lun variable for each loop body, eliminating
the boilerplate code.

Signed-off-by: Matias Bjørling <m@bjorling.me>
Signed-off-by: Jens Axboe <axboe@fb.com>
2016-05-06 12:51:10 -06:00
..
Kconfig lightnvm: do not compile in debugging by default 2015-12-07 09:14:20 -07:00
Makefile lightnvm: core on-disk initialization 2016-01-12 08:21:18 -07:00
core.c lightnvm: refactor dev->online_target to global nvm_targets 2016-05-06 12:51:10 -06:00
gennvm.c lightnvm: move block fold outside of get_bb_tbl() 2016-05-06 12:51:10 -06:00
gennvm.h lightnvm: specify target's logical address area 2016-03-18 18:10:37 -07:00
rrpc.c lightnvm: rename nvm_targets to nvm_tgt_type 2016-05-06 12:51:10 -06:00
rrpc.h lightnvm: specify target's logical address area 2016-03-18 18:10:37 -07:00
sysblk.c lightnvm: introduce nvm_for_each_lun_ppa() macro 2016-05-06 12:51:10 -06:00