From: Keith Busch kbusch@kernel.org
mainline inclusion from mainline-5.8-rc1 commit 3382a567efd4015697f087f2e91ac08b90577876 category: bugfix bugzilla: 175150 CVE: NA
---------------------------
Use blk_mq_foce_complete_rq() to bypass fake timeout error injection so that request reclaim may proceed.
Signed-off-by: Keith Busch kbusch@kernel.org Reviewed-by: Johannes Thumshirn johannes.thumshirn@wdc.com Reviewed-by: Ming Lei ming.lei@redhat.com Reviewed-by: Daniel Wagner dwagner@suse.de Signed-off-by: Jens Axboe axboe@kernel.dk
Conflicts: drivers/nvme/host/core.c [ 7baa85727d04("blk-mq-tag: change busy_iter_fn to return whether to continue or not") is not applied. ]
Signed-off-by: Zhihao Cheng chengzhihao1@huawei.com Reviewed-by: Hou Tao houtao1@huawei.com Signed-off-by: Yang Yingliang yangyingliang@huawei.com --- drivers/nvme/host/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c index aab3d9a950a5e..c1e6c513c7956 100644 --- a/drivers/nvme/host/core.c +++ b/drivers/nvme/host/core.c @@ -330,7 +330,7 @@ void nvme_cancel_request(struct request *req, void *data, bool reserved) return;
nvme_req(req)->status = NVME_SC_HOST_ABORTED_CMD; - blk_mq_complete_request(req); + blk_mq_force_complete_rq(req);
} EXPORT_SYMBOL_GPL(nvme_cancel_request);