1
0
Fork 0

NVMe: initialize error to '0'

Reported-by: Keith Busch <keith.busch@intel.com>
Fixes: 1951feae88 ("nvme: use an integer value to Linux errno values")
Signed-off-by: Jens Axboe <axboe@fb.com>
hifive-unleashed-5.1
Jens Axboe 2015-10-15 09:49:57 -06:00
parent 1951feae88
commit ef658fc2a6
1 changed files with 1 additions and 1 deletions

View File

@ -607,7 +607,7 @@ static void req_completion(struct nvme_queue *nvmeq, void *ctx,
struct request *req = iod_get_private(iod);
struct nvme_cmd_info *cmd_rq = blk_mq_rq_to_pdu(req);
u16 status = le16_to_cpup(&cqe->status) >> 1;
int error;
int error = 0;
if (unlikely(status)) {
if (!(status & NVME_SC_DNR || blk_noretry_request(req))