[PATCH] block: re-introduce blk_mq_complete_request_sync
Sagi Grimberg
sagi at grimberg.me
Fri Oct 9 04:11:46 EDT 2020
>> diff --git a/drivers/nvme/host/tcp.c b/drivers/nvme/host/tcp.c
>> index 8f4f29f18b8c..629b025685d1 100644
>> --- a/drivers/nvme/host/tcp.c
>> +++ b/drivers/nvme/host/tcp.c
>> @@ -2177,7 +2177,7 @@ static void nvme_tcp_complete_timed_out(struct request *rq)
>> nvme_tcp_stop_queue(ctrl, nvme_tcp_queue_id(req->queue));
>> if (!blk_mq_request_completed(rq)) {
>> nvme_req(rq)->status = NVME_SC_HOST_ABORTED_CMD;
>> - blk_mq_complete_request(rq);
>> + blk_mq_complete_request_sync(rq);
>
> Or complete the request in the following way? Then one block layer API
> can be saved:
>
> blk_mq_complete_request_remote(rq);
> nvme_complete_rq(rq);
Not sure I follow, how does this work?
Anyways, I think that blk_mq_complete_request_sync is a clean
and useful interface. We can do it in nvme but I don't think
it would be better.
More information about the Linux-nvme
mailing list