All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] Fix UFS task management command timeout
@ 2021-09-29  7:00 Po-Wen Kao
  2021-09-29  7:00 ` [PATCH 1/2] blk-mq: new busy request iterator for driver Po-Wen Kao
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Po-Wen Kao @ 2021-09-29  7:00 UTC (permalink / raw)
  To: linux-block, axboe, linux-kernel, stanley.chu, linux-scsi,
	martin.petersen, avri.altman, alim.akhtar, jejb
  Cc: peter.wang, chun-hung.wu, alice.chao, jonathan.hsu, powen.kao,
	cc.chou, chaotian.jing, jiajie.hao, wsd_upstream, ed.tsai

On UTP_TASK_REQ_COMPL interrupt, ufshcd_tmc_handler() iterates through
busy requests in tags->rqs and complete request if corresponding
doorbell flag is reset.
However, ufshcd_issue_tm_cmd() allocates requests from tags->static_rqs 
and trigger doorbell directly without dispatching request through block 
layer, thus requests can never be found in tags->rqs and completed 
properly. Any TM command issued by ufshcd_issue_tm_cmd() inevitably 
timeout and further leads to recovery flow failure when LU Reset or 
Abort Task is issued.

In this patch, blk_mq_tagset_busy_iter() call in ufshcd_tmc_handler() 
is replaced with new interface, blk_mq_drv_tagset_busy_iter(), to 
allow completion of request allocted by driver. The new interface is 
introduced for driver to iterate through requests in static_rqs. 

Po-Wen Kao (2):
  blk-mq: new busy request iterator for driver
  scsi: ufs: fix TM request timeout

 block/blk-mq-tag.c        | 36 ++++++++++++++++++++++++++++++------
 drivers/scsi/ufs/ufshcd.c |  2 +-
 include/linux/blk-mq.h    |  4 ++++
 3 files changed, 35 insertions(+), 7 deletions(-)

-- 
2.18.0


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

end of thread, other threads:[~2021-09-30  8:50 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-29  7:00 [PATCH 0/2] Fix UFS task management command timeout Po-Wen Kao
2021-09-29  7:00 ` [PATCH 1/2] blk-mq: new busy request iterator for driver Po-Wen Kao
2021-09-29  7:08   ` Christoph Hellwig
2021-09-29  7:00 ` [PATCH 2/2] scsi: ufs: fix TM request timeout Po-Wen Kao
2021-09-29  7:39 ` [PATCH 0/2] Fix UFS task management command timeout Avri Altman
2021-09-30  8:50   ` Po-Wen Kao

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.