public inbox for linux-block@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] blk-mq: remove unneeded needs_restart check
@ 2022-09-05 10:19 Miaohe Lin
  2022-09-05 17:45 ` Jens Axboe
  0 siblings, 1 reply; 2+ messages in thread
From: Miaohe Lin @ 2022-09-05 10:19 UTC (permalink / raw)
  To: axboe; +Cc: linux-block, linux-kernel, linmiaohe

If code reaches here, needs_restart must be true. Remove this unneeded
needs_restart check. No functional change intended.

Signed-off-by: Miaohe Lin <linmiaohe@huawei.com>
---
 block/blk-mq.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/block/blk-mq.c b/block/blk-mq.c
index b9f6989cb5bd..be7de99622a2 100644
--- a/block/blk-mq.c
+++ b/block/blk-mq.c
@@ -1992,7 +1992,7 @@ bool blk_mq_dispatch_rq_list(struct blk_mq_hw_ctx *hctx, struct list_head *list,
 		if (!needs_restart ||
 		    (no_tag && list_empty_careful(&hctx->dispatch_wait.entry)))
 			blk_mq_run_hw_queue(hctx, true);
-		else if (needs_restart && needs_resource)
+		else if (needs_resource)
 			blk_mq_delay_run_hw_queue(hctx, BLK_MQ_RESOURCE_DELAY);
 
 		blk_mq_update_dispatch_busy(hctx, true);
-- 
2.23.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] blk-mq: remove unneeded needs_restart check
  2022-09-05 10:19 [PATCH] blk-mq: remove unneeded needs_restart check Miaohe Lin
@ 2022-09-05 17:45 ` Jens Axboe
  0 siblings, 0 replies; 2+ messages in thread
From: Jens Axboe @ 2022-09-05 17:45 UTC (permalink / raw)
  To: Miaohe Lin; +Cc: linux-kernel, linux-block

On Mon, 5 Sep 2022 18:19:50 +0800, Miaohe Lin wrote:
> If code reaches here, needs_restart must be true. Remove this unneeded
> needs_restart check. No functional change intended.
> 
> 

Applied, thanks!

[1/1] blk-mq: remove unneeded needs_restart check
      commit: 6d5e8d21e8997b0efa409e46db22a27b5cbba6aa

Best regards,
-- 
Jens Axboe



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-09-05 17:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-09-05 10:19 [PATCH] blk-mq: remove unneeded needs_restart check Miaohe Lin
2022-09-05 17:45 ` Jens Axboe

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox