[PATCH v1 2/3] nvme: Use blk-mq helper for IO termination
Keith Busch
keith.busch at intel.com
Thu Feb 4 07:44:54 PST 2016
On Thu, Feb 04, 2016 at 02:28:24PM +0000, Wenbo Wang wrote:
> Is the following execution valid?
>
> 1. request A is linked in q->request_list
q->request_list? Do you mean q->requeue_list?
> 2. device reset
> 3. all requests (including request A) are cancelled by nvme_dev_disable()->nvme_clear_queue()
If the request is on some list owned by the request_queue, it was not
started by the driver, and nvme_clear_queue doesn't do anything to it.
> 4. device restarted
> 5. flush q->request_list, and request A is again running in queue_rq. <-- since request A has been cancelled, it shall not be running again
Request A was not cancelled if it was never started. It will be submitted
when the driver restarts the queues h/w contexts.
Cancelling a command with the controller does not mean ending the request
in the block layer.
More information about the Linux-nvme
mailing list