Thread (17 messages) 17 messages, 2 authors, 2018-07-27

Re: [PATCH 5/5] blk-mq: Rework blk-mq timeout handling again

From: Bart Van Assche <hidden>
Date: 2018-07-27 16:59:34
Subsystem: block layer, the rest · Maintainers: Jens Axboe, Linus Torvalds

On Fri, 2018-07-27 at 10:57 -0600, Keith Busch wrote:
You skip that code if the driver returns BLK_EH_DONT_RESE=
T_TIMER.

How about applying the following patch on top of this series?
diff --git a/block/blk-mq.c b/block/blk-mq.c
index a97ab5ba9d18..aa66535604fd 100644
--- a/block/blk-mq.c
+++ b/block/blk-mq.c
@@ -854,10 +854,10 @@ static void blk_mq_rq_timed�
AF8-out(struct request *req, bool reserved)
 	 * latter case, if blk_mq_complete_request() was called w=
hile
 	 * the timeout handler was in progress, ignore that call.
 	 */
-	if (ret == BLK_EH_DONT_RESET_TIMER)
-		return;
-	WARN_ON_ONCE(ret != BLK_EH_RESET_TIMER);
-	blk_mq_add_timer(req);
+	if (ret == BLK_EH_RESET_TIMER)
+		blk_mq_add_timer(req);
+	else
+		WARN_ON_ONCE(ret != BLK_EH_DONT_RESET_TIM=
ER);
 again:
 	if (blk_mq_change_rq_state(req, MQ_RQ_TIMED_O=
UT, MQ_RQ_IN_FLIGHT))
 		return;

Bart.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help