Re: [PATCH 2/4] lightnvm: assign block address before slba

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 08/31/2018 03:34 PM, Javier González wrote:
In 1.2, the chunk slba is set to the physical representation of the
block. Thus, assigning the block to the ppa must occur before the slba
is assign.

Signed-off-by: Javier González <javier@xxxxxxxxxxxx>
---
  drivers/lightnvm/core.c | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/lightnvm/core.c b/drivers/lightnvm/core.c
index e9f14c67f4f3..efb976a863d2 100644
--- a/drivers/lightnvm/core.c
+++ b/drivers/lightnvm/core.c
@@ -945,6 +945,8 @@ static int nvm_bb_to_chunk(struct nvm_dev *dev, struct ppa_addr ppa,
  			}
  		}
+ ppa.g.blk = blk;
+
  		meta->wp = 0;
  		meta->type = NVM_CHK_TP_W_SEQ;
  		meta->wi = 0;
@@ -952,7 +954,6 @@ static int nvm_bb_to_chunk(struct nvm_dev *dev, struct ppa_addr ppa,
  		meta->cnlb = dev->geo.clba;
if (blktype == NVM_BLK_T_FREE) {
-			ppa.a.blk = blk;
  			ret = nvm_bb_chunk_scan(dev, ppa, meta);
  			if (ret)
  				return ret;


Thanks. I've folded 1 & 2 into the bb patch.



[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux