diff options
author | Matias Bjørling <mb@lightnvm.io> | 2018-03-30 00:05:04 +0200 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2018-03-29 17:29:09 -0600 |
commit | 89a09c5643e01f5e5d3c5f2e720053473a60a90b (patch) | |
tree | 4e3c80694912bc336479de619de61a0d3f5d8837 /drivers/nvme | |
parent | af569398c390810fca773c903a85b71dfd870bb0 (diff) | |
download | blackbird-obmc-linux-89a09c5643e01f5e5d3c5f2e720053473a60a90b.tar.gz blackbird-obmc-linux-89a09c5643e01f5e5d3c5f2e720053473a60a90b.zip |
lightnvm: remove nvm_dev_ops->max_phys_sect
The value of max_phys_sect is always static. Instead of
defining it in the nvm_dev_ops structure, declare it as a global
value.
Signed-off-by: Matias Bjørling <mb@lightnvm.io>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/nvme')
-rw-r--r-- | drivers/nvme/host/lightnvm.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/nvme/host/lightnvm.c b/drivers/nvme/host/lightnvm.c index 8b243af8a949..e38d835b15b5 100644 --- a/drivers/nvme/host/lightnvm.c +++ b/drivers/nvme/host/lightnvm.c @@ -612,8 +612,6 @@ static struct nvm_dev_ops nvme_nvm_dev_ops = { .destroy_dma_pool = nvme_nvm_destroy_dma_pool, .dev_dma_alloc = nvme_nvm_dev_dma_alloc, .dev_dma_free = nvme_nvm_dev_dma_free, - - .max_phys_sect = 64, }; static int nvme_nvm_submit_user_cmd(struct request_queue *q, @@ -932,8 +930,7 @@ static ssize_t nvm_dev_attr_show_12(struct device *dev, } else if (strcmp(attr->name, "media_capabilities") == 0) { return scnprintf(page, PAGE_SIZE, "0x%08x\n", id->mccap); } else if (strcmp(attr->name, "max_phys_secs") == 0) { - return scnprintf(page, PAGE_SIZE, "%u\n", - ndev->ops->max_phys_sect); + return scnprintf(page, PAGE_SIZE, "%u\n", NVM_MAX_VLBA); } else { return scnprintf(page, PAGE_SIZE, |