提交 0f89f0ec 编写于 作者: G Guixin Liu 提交者: Jens Axboe

nvme-apple: use nvme core helper to cancel requests in tagset

Use nvme core helper nvme_cancel_tagset and nvme_cancel_admin_tagset
instead of same logic code.
Signed-off-by: NGuixin Liu <kanie@linux.alibaba.com>
Reviewed-by: NSagi Grimberg <sagi@grimberg.me>
Reviewed-by: NRuozhu Li <liruozhu@huawei.com>
Reviewed-by: NSven Peter <sven@svenpeter.dev>
Signed-off-by: NChristoph Hellwig <hch@lst.de>
Signed-off-by: NJens Axboe <axboe@kernel.dk>
上级 1fcfca78
......@@ -845,11 +845,8 @@ static void apple_nvme_disable(struct apple_nvme *anv, bool shutdown)
apple_nvme_handle_cq(&anv->adminq, true);
spin_unlock_irqrestore(&anv->lock, flags);
blk_mq_tagset_busy_iter(&anv->tagset, nvme_cancel_request, &anv->ctrl);
blk_mq_tagset_busy_iter(&anv->admin_tagset, nvme_cancel_request,
&anv->ctrl);
blk_mq_tagset_wait_completed_request(&anv->tagset);
blk_mq_tagset_wait_completed_request(&anv->admin_tagset);
nvme_cancel_tagset(&anv->ctrl);
nvme_cancel_admin_tagset(&anv->ctrl);
/*
* The driver will not be starting up queues again if shutting down so
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册