summaryrefslogtreecommitdiffstats
path: root/drivers/lightnvm/core.c
diff options
context:
space:
mode:
authorMatias Bjørling <matias@cnexlabs.com>2017-01-31 13:17:15 +0100
committerJens Axboe <axboe@fb.com>2017-01-31 08:32:13 -0700
commit19bd6fe73ca812964963aa30827cff9aae64a715 (patch)
treef01107a5aaa6c09fea5d0ad2454fc9954d8e376c /drivers/lightnvm/core.c
parentdab8ee9e8a30620a5b5f22d6c0b3749217093803 (diff)
downloadop-kernel-dev-19bd6fe73ca812964963aa30827cff9aae64a715.zip
op-kernel-dev-19bd6fe73ca812964963aa30827cff9aae64a715.tar.gz
lightnvm: reduce number of nvm_id groups to one
The number of configuration groups has been limited to one in current code, even if there is support for up to four. With the introduction of the open-channel SSD 1.3 specification, only a single group is exposed onwards. Reflect this in the nvm_id structure. Signed-off-by: Matias Bjørling <matias@cnexlabs.com> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'drivers/lightnvm/core.c')
-rw-r--r--drivers/lightnvm/core.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/drivers/lightnvm/core.c b/drivers/lightnvm/core.c
index 0842c85..80cd767 100644
--- a/drivers/lightnvm/core.c
+++ b/drivers/lightnvm/core.c
@@ -884,7 +884,7 @@ static int nvm_init_mlc_tbl(struct nvm_dev *dev, struct nvm_id_group *grp)
static int nvm_core_init(struct nvm_dev *dev)
{
struct nvm_id *id = &dev->identity;
- struct nvm_id_group *grp = &id->groups[0];
+ struct nvm_id_group *grp = &id->grp;
struct nvm_geo *geo = &dev->geo;
int ret;
@@ -988,20 +988,14 @@ static int nvm_init(struct nvm_dev *dev)
goto err;
}
- pr_debug("nvm: ver:%x nvm_vendor:%x groups:%u\n",
- dev->identity.ver_id, dev->identity.vmnt,
- dev->identity.cgrps);
+ pr_debug("nvm: ver:%x nvm_vendor:%x\n",
+ dev->identity.ver_id, dev->identity.vmnt);
if (dev->identity.ver_id != 1) {
pr_err("nvm: device not supported by kernel.");
goto err;
}
- if (dev->identity.cgrps != 1) {
- pr_err("nvm: only one group configuration supported.");
- goto err;
- }
-
ret = nvm_core_init(dev);
if (ret) {
pr_err("nvm: could not initialize core structures.\n");
OpenPOWER on IntegriCloud