mirror of
https://github.com/FEX-Emu/linux.git
synced 2025-01-01 14:52:32 +00:00
lightnvm: initialize ppa_addr in dev_to_generic_addr()
The ->reserved bit is not initialized when allocated on stack. This may lead targets to misinterpret the PPA as cached. Signed-off-by: Javier González <javier@cnexlabs.com> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com>
This commit is contained in:
parent
529435e818
commit
5389a1dfb3
@ -385,6 +385,7 @@ static inline struct ppa_addr dev_to_generic_addr(struct nvm_dev *dev,
|
||||
{
|
||||
struct ppa_addr l;
|
||||
|
||||
l.ppa = 0;
|
||||
/*
|
||||
* (r.ppa << X offset) & X len bitmask. X eq. blk, pg, etc.
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user