summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatias Bjørling <mb@lightnvm.io>2018-10-09 13:11:39 +0200
committerJens Axboe <axboe@kernel.dk>2018-10-09 16:25:06 +0200
commitd20be90ae0bb938ee0dfc8277d531191341d8e39 (patch)
tree5647ae80bbc78974ccb4be9e25f2dc7b3b15af4d
parentlightnvm: pblk: fix incorrect min_write_pgs (diff)
downloadlinux-d20be90ae0bb938ee0dfc8277d531191341d8e39.tar.xz
linux-d20be90ae0bb938ee0dfc8277d531191341d8e39.zip
lightnvm: pblk: remove size and out of bounds read check
The I/O size and capacity checks are already done by the block layer. Signed-off-by: Matias Bjørling <mb@lightnvm.io> Reviewed-by: Javier González <javier@cnexlabs.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
-rw-r--r--drivers/lightnvm/pblk-read.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/drivers/lightnvm/pblk-read.c b/drivers/lightnvm/pblk-read.c
index 9c61c19be5dc..ba3dcb6be4c3 100644
--- a/drivers/lightnvm/pblk-read.c
+++ b/drivers/lightnvm/pblk-read.c
@@ -449,13 +449,6 @@ int pblk_submit_read(struct pblk *pblk, struct bio *bio)
DECLARE_BITMAP(read_bitmap, NVM_MAX_VLBA);
int ret = NVM_IO_ERR;
- /* logic error: lba out-of-bounds. Ignore read request */
- if (blba >= pblk->rl.nr_secs || nr_secs > NVM_MAX_VLBA) {
- WARN(1, "pblk: read lba out of bounds (lba:%llu, nr:%d)\n",
- (unsigned long long)blba, nr_secs);
- return NVM_IO_ERR;
- }
-
generic_start_io_acct(q, REQ_OP_READ, bio_sectors(bio),
&pblk->disk->part0);