Lines Matching refs:ppa
43 u64 ppa; member
369 l.ppa = ((u64)r.g.blk) << dev->ppaf.blk_offset; in generic_to_dev_addr()
370 l.ppa |= ((u64)r.g.pg) << dev->ppaf.pg_offset; in generic_to_dev_addr()
371 l.ppa |= ((u64)r.g.sec) << dev->ppaf.sect_offset; in generic_to_dev_addr()
372 l.ppa |= ((u64)r.g.pl) << dev->ppaf.pln_offset; in generic_to_dev_addr()
373 l.ppa |= ((u64)r.g.lun) << dev->ppaf.lun_offset; in generic_to_dev_addr()
374 l.ppa |= ((u64)r.g.ch) << dev->ppaf.ch_offset; in generic_to_dev_addr()
384 l.ppa = 0; in dev_to_generic_addr()
388 l.g.blk = (r.ppa >> dev->ppaf.blk_offset) & in dev_to_generic_addr()
390 l.g.pg |= (r.ppa >> dev->ppaf.pg_offset) & in dev_to_generic_addr()
392 l.g.sec |= (r.ppa >> dev->ppaf.sect_offset) & in dev_to_generic_addr()
394 l.g.pl |= (r.ppa >> dev->ppaf.pln_offset) & in dev_to_generic_addr()
396 l.g.lun |= (r.ppa >> dev->ppaf.lun_offset) & in dev_to_generic_addr()
398 l.g.ch |= (r.ppa >> dev->ppaf.ch_offset) & in dev_to_generic_addr()
406 return (ppa_addr.ppa == ADDR_EMPTY); in ppa_empty()
411 ppa_addr->ppa = ADDR_EMPTY; in ppa_set_empty()
417 struct ppa_addr ppa; in block_to_ppa() local
420 ppa.ppa = 0; in block_to_ppa()
421 ppa.g.blk = blk->id % dev->blks_per_lun; in block_to_ppa()
422 ppa.g.lun = lun->lun_id; in block_to_ppa()
423 ppa.g.ch = lun->chnl_id; in block_to_ppa()
425 return ppa; in block_to_ppa()
534 void nvm_mark_blk(struct nvm_dev *dev, struct ppa_addr ppa, int type);
572 #define nvm_for_each_lun_ppa(dev, ppa, chid, lunid) \ argument
573 for ((chid) = 0, (ppa).ppa = 0; (chid) < (dev)->nr_chnls; \
574 (chid)++, (ppa).g.ch = (chid)) \
576 (lunid)++, (ppa).g.lun = (lunid))