Re: [PATCH 16/20] blk-mq: don't kick the requeue_list in blk_mq_add_to_requeue_list

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 4/13/23 15:40, Christoph Hellwig wrote:
> blk_mq_add_to_requeue_list takes a bool parameter to control how to kick
> the requeue list at the end of the function.  Move the call to
> blk_mq_kick_requeue_list to the callers that want it instead.
> 
> Signed-off-by: Christoph Hellwig <hch@xxxxxx>

One nit below. Looks good otherwise.

Reviewed-by: Damien Le Moal <dlemoal@xxxxxxxxxx>

> diff --git a/block/blk-mq.c b/block/blk-mq.c
> index cde7ba9c39bf6b..db806c1a194c7b 100644
> --- a/block/blk-mq.c
> +++ b/block/blk-mq.c
> @@ -1412,12 +1412,17 @@ static void __blk_mq_requeue_request(struct request *rq)
>  
>  void blk_mq_requeue_request(struct request *rq, bool kick_requeue_list)
>  {
> +	struct request_queue *q = rq->q;

Nit: not really needed given that it is used in one place only.
You could just call "blk_mq_kick_requeue_list(rq->q)" below.

> +
>  	__blk_mq_requeue_request(rq);
>  
>  	/* this request will be re-inserted to io scheduler queue */
>  	blk_mq_sched_requeue_request(rq);
>  
> -	blk_mq_add_to_requeue_list(rq, true, kick_requeue_list);
> +	blk_mq_add_to_requeue_list(rq, true);
> +
> +	if (kick_requeue_list)
> +		blk_mq_kick_requeue_list(q);
>  }
>  EXPORT_SYMBOL(blk_mq_requeue_request);





[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux