OSDN Git Service

lightnvm: pblk: set proper read status in bio
authorIgor Konopko <igor.j.konopko@intel.com>
Sat, 4 May 2019 18:37:54 +0000 (20:37 +0200)
committerJens Axboe <axboe@kernel.dk>
Mon, 6 May 2019 16:19:17 +0000 (10:19 -0600)
commitd38954ed1b76a2814057cd4af92c6966bceb3d3c
tree1d3ea312afe100f2feb4d3e91759a37bb335dfe7
parent6e46b8b24ffbc4ecb5b606094dbc8ed5d6281f59
lightnvm: pblk: set proper read status in bio

Currently in case of read errors, bi_status is not set properly which
leads to returning inproper data to layers above. This patch fix that
by setting proper status in case of read errors.

Also remove unnecessary warn_once(), which does not make sense
in that place, since user bio is not used for interation with drive
and thus bi_status will not be set here.

Signed-off-by: Igor Konopko <igor.j.konopko@intel.com>
Reviewed-by: Javier González <javier@javigon.com>
Reviewed-by: Hans Holmberg <hans.holmberg@cnexlabs.com>
Signed-off-by: Matias Bjørling <mb@lightnvm.io>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/lightnvm/pblk-read.c