Re: [PATCH v2 1/1] blk-mq: fill header with kernel-doc

From: Bart Van Assche
Date: Fri Oct 11 2019 - 13:00:46 EST


On 10/10/19 1:38 PM, Andrà Almeida wrote:
Seems that it's not clear for me the role of these members. Could you
please check if those definitions make sense for you?

- hctx->dispatch: This queue is used for requests that are ready to be
dispatched to the hardware but for some reason (e.g. lack of resources,
the hardware is to busy and can't get more requests) could not be sent
to the hardware. As soon as the driver can send new requests, those
queued at this list will be sent first for a more fair dispatch. Since
those requests are at the hctx, they can't be requeued or rescheduled
anymore.

- request_queue->requeue_list: This list is used when it's not possible
to send the request to the associated hctx. This can happen if the
associated CPU or hctx is not available anymore. When requeueing those
requests, it will be possible to send them to new and function queues.

Hi AndrÃ,

The hctx->dispatch description looks mostly fine. Can the following part be left out since it looks confusing to me: "Since those requests are at the hctx, they can't be requeued or rescheduled anymore."

How about changing the requeue_list description into the following: "requests requeued by a call to blk_mq_requeue_request()".

Thanks,

Bart.