Linux block layer
 help / color / mirror / Atom feed
From: Bart Van Assche <bvanassche@acm.org>
To: Xianting Tian <tian.xianting@h3c.com>, axboe@kernel.dk
Cc: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] [v3] blk-mq: add cond_resched() in __blk_mq_alloc_rq_maps()
Date: Fri, 25 Sep 2020 21:07:22 -0700	[thread overview]
Message-ID: <b884d4af-ef49-f294-4099-e35778f2a783@acm.org> (raw)
In-Reply-To: <20200926023947.1891-1-tian.xianting@h3c.com>

On 2020-09-25 19:39, Xianting Tian wrote:
> diff --git a/block/blk-mq.c b/block/blk-mq.c
> index b3d2785ee..62d152d03 100644
> --- a/block/blk-mq.c
> +++ b/block/blk-mq.c
> @@ -3256,9 +3256,11 @@ static int __blk_mq_alloc_rq_maps(struct blk_mq_tag_set *set)
>  {
>  	int i;
>  
> -	for (i = 0; i < set->nr_hw_queues; i++)
> +	for (i = 0; i < set->nr_hw_queues; i++) {
>  		if (!__blk_mq_alloc_map_and_request(set, i))
>  			goto out_unwind;
> +		cond_resched();
> +	}
>  
>  	return 0;

Reviewed-by: Bart Van Assche <bvanassche@acm.org>

  reply	other threads:[~2020-09-26  4:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-26  2:39 [PATCH] [v3] blk-mq: add cond_resched() in __blk_mq_alloc_rq_maps() Xianting Tian
2020-09-26  4:07 ` Bart Van Assche [this message]
2020-09-28 14:56   ` Tianxianting
2020-09-28 15:02 ` Jens Axboe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b884d4af-ef49-f294-4099-e35778f2a783@acm.org \
    --to=bvanassche@acm.org \
    --cc=axboe@kernel.dk \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tian.xianting@h3c.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox