提交 ef658fc2 编写于 作者: J Jens Axboe

NVMe: initialize error to '0'

Reported-by: NKeith Busch <keith.busch@intel.com>
Fixes: 1951feae ("nvme: use an integer value to Linux errno values")
Signed-off-by: NJens Axboe <axboe@fb.com>
上级 1951feae
......@@ -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))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册