All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Matias Bjørling" <m@bjorling.me>
To: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, axboe@fb.com
Cc: "Javier González" <jg@lightnvm.io>,
	"Javier González" <javier@cnexlabs.com>,
	"Matias Bjørling" <m@bjorling.me>
Subject: [PATCH 4/5] lightnvm: do not reserve lun on l2p loading
Date: Thu,  3 Mar 2016 15:06:40 +0100	[thread overview]
Message-ID: <1457014001-23561-5-git-send-email-m@bjorling.me> (raw)
In-Reply-To: <1457014001-23561-1-git-send-email-m@bjorling.me>

From: Javier González <jg@lightnvm.io>

When the l2p table is loaded, addresses are checked for the lun they
belong to and luns are reserved accordingly. This assumes that metadata
is being stored in the backend device to recover the previous target
configuration. Since this is not yet implemented, this check collides
with some of the core initialization (e.g., sysblock initialization when
a page is formed by several sectors).

We take this check out and for now rely on that the right target will be
created instead. When metadata is stored to recover a target, this check
will come natural as part of the recovery strategy.

Signed-off-by: Javier González <javier@cnexlabs.com>
Signed-off-by: Matias Bjørling <m@bjorling.me>
---
 drivers/lightnvm/gennvm.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/lightnvm/gennvm.c b/drivers/lightnvm/gennvm.c
index b97801c..42c1c2a 100644
--- a/drivers/lightnvm/gennvm.c
+++ b/drivers/lightnvm/gennvm.c
@@ -192,9 +192,6 @@ static int gennvm_block_map(u64 slba, u32 nlb, __le64 *entries, void *private)
 		lun_id = div_u64(pba, dev->sec_per_lun);
 		lun = &gn->luns[lun_id];
 
-		if (!test_bit(lun_id, dev->lun_map))
-			__set_bit(lun_id, dev->lun_map);
-
 		/* Calculate block offset into lun */
 		pba = pba - (dev->sec_per_lun * lun_id);
 		blk = &lun->vlun.blocks[div_u64(pba, dev->sec_per_blk)];
-- 
2.1.4

  parent reply	other threads:[~2016-03-03 14:08 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-03 14:06 [PATCH 0/5] LightNVM fixes for 4.6 Matias Bjørling
2016-03-03 14:06 ` [PATCH 1/5] lightnvm: specify target's logical address area Matias Bjørling
2016-03-03 14:06 ` [PATCH 2/5] lightnvm: add a bitmap of luns Matias Bjørling
2016-03-03 14:06 ` [PATCH 3/5] nvme: lightnvm: return ppa completion status Matias Bjørling
2016-03-03 14:06 ` Matias Bjørling [this message]
2016-03-03 14:06 ` [PATCH 5/5] lightnvm: do not load L2P table if not supported Matias Bjørling
2016-03-03 15:04 ` [PATCH 0/5] LightNVM fixes for 4.6 Jens Axboe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1457014001-23561-5-git-send-email-m@bjorling.me \
    --to=m@bjorling.me \
    --cc=axboe@fb.com \
    --cc=javier@cnexlabs.com \
    --cc=jg@lightnvm.io \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.