diff options
author | Matias Bjørling <m@bjorling.me> | 2016-01-12 07:49:20 +0100 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2016-01-12 08:21:16 -0700 |
commit | abd805ec9f51f37db9da63dda44c3f4b4ae8ad57 (patch) | |
tree | 5298213b1795db79ebd1769e0d2c66b865d71e5a /include/linux/lightnvm.h | |
parent | 069368e91879a3a640cfae4bdc1f9f8cc99c93a0 (diff) |
lightnvm: refactor rqd ppa list into set/free
A device may be driven in single, double or quad plane mode. In that
case, the rqd must have either one, two, or four PPAs set for a single
PPA sent to the device. Refactor this logic into their own
functions to be shared by program/erase/read in the core.
Signed-off-by: Matias Bjørling <m@bjorling.me>
Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'include/linux/lightnvm.h')
-rw-r--r-- | include/linux/lightnvm.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/lightnvm.h b/include/linux/lightnvm.h index c228dbc803bf..2fd6871ac7f5 100644 --- a/include/linux/lightnvm.h +++ b/include/linux/lightnvm.h @@ -429,6 +429,9 @@ extern void nvm_unregister(char *); extern int nvm_submit_io(struct nvm_dev *, struct nvm_rq *); extern void nvm_generic_to_addr_mode(struct nvm_dev *, struct nvm_rq *); extern void nvm_addr_to_generic_mode(struct nvm_dev *, struct nvm_rq *); +extern int nvm_set_rqd_ppalist(struct nvm_dev *, struct nvm_rq *, + struct ppa_addr *, int); +extern void nvm_free_rqd_ppalist(struct nvm_dev *, struct nvm_rq *); extern int nvm_erase_ppa(struct nvm_dev *, struct ppa_addr); extern int nvm_erase_blk(struct nvm_dev *, struct nvm_block *); #else /* CONFIG_NVM */ |