linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] scsi: ufs: Remove an unpaired ufshcd_scsi_unblock_requests() in err_handler()
@ 2020-08-19  1:02 Can Guo
  2020-08-24  8:41 ` Bean Huo
  2020-09-09  2:17 ` Martin K. Petersen
  0 siblings, 2 replies; 3+ messages in thread
From: Can Guo @ 2020-08-19  1:02 UTC (permalink / raw)
  To: asutoshd, nguyenb, hongwus, rnayak, linux-scsi, kernel-team,
	saravanak, salyzyn, cang
  Cc: Alim Akhtar, Avri Altman, James E.J. Bottomley,
	Martin K. Petersen, Stanley Chu, Bean Huo, Bart Van Assche,
	open list

Commit 5586dd8ea250 ("scsi: ufs: Fix a race condition between error handler
and runtime PM ops") moves the ufshcd_scsi_block_requests() inside
err_handler(), but forgets to remove the ufshcd_scsi_unblock_requests() in
the early return path. Correct the coding mistake.

Fixes: 5586dd8ea250 ("scsi: ufs: Fix a race condition between error handler and runtime PM ops")
Signed-off-by: Can Guo <cang@codeaurora.org>
Reviewed-by: Asutosh Das <asutoshd@codeaurora.org>
Reviewed-by: Hongwu Su<hongwus@codeaurora.org>
---

Change since v1:
- Added Fixes tag.

 drivers/scsi/ufs/ufshcd.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index 2b55c2e..b8441ad 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs/ufshcd.c
@@ -5670,7 +5670,6 @@ static void ufshcd_err_handler(struct work_struct *work)
 		if (hba->ufshcd_state != UFSHCD_STATE_ERROR)
 			hba->ufshcd_state = UFSHCD_STATE_OPERATIONAL;
 		spin_unlock_irqrestore(hba->host->host_lock, flags);
-		ufshcd_scsi_unblock_requests(hba);
 		return;
 	}
 	ufshcd_set_eh_in_progress(hba);
-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project.


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

* Re: [PATCH v2] scsi: ufs: Remove an unpaired ufshcd_scsi_unblock_requests() in err_handler()
  2020-08-19  1:02 [PATCH v2] scsi: ufs: Remove an unpaired ufshcd_scsi_unblock_requests() in err_handler() Can Guo
@ 2020-08-24  8:41 ` Bean Huo
  2020-09-09  2:17 ` Martin K. Petersen
  1 sibling, 0 replies; 3+ messages in thread
From: Bean Huo @ 2020-08-24  8:41 UTC (permalink / raw)
  To: Can Guo, asutoshd, nguyenb, hongwus, rnayak, linux-scsi,
	kernel-team, saravanak, salyzyn
  Cc: Alim Akhtar, Avri Altman, James E.J. Bottomley,
	Martin K. Petersen, Stanley Chu, Bean Huo, Bart Van Assche,
	open list

On Tue, 2020-08-18 at 18:02 -0700, Can Guo wrote:
> Commit 5586dd8ea250 ("scsi: ufs: Fix a race condition between error
> handler
> and runtime PM ops") moves the ufshcd_scsi_block_requests() inside
> err_handler(), but forgets to remove the
> ufshcd_scsi_unblock_requests() in
> the early return path. Correct the coding mistake.
> 
> Fixes: 5586dd8ea250 ("scsi: ufs: Fix a race condition between error
> handler and runtime PM ops")
> Signed-off-by: Can Guo <cang@codeaurora.org>
> Reviewed-by: Asutosh Das <asutoshd@codeaurora.org>
> Reviewed-by: Hongwu Su<hongwus@codeaurora.org>

Reviewed-by: Bean Huo <beanhuo@micron.com>




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

* Re: [PATCH v2] scsi: ufs: Remove an unpaired ufshcd_scsi_unblock_requests() in err_handler()
  2020-08-19  1:02 [PATCH v2] scsi: ufs: Remove an unpaired ufshcd_scsi_unblock_requests() in err_handler() Can Guo
  2020-08-24  8:41 ` Bean Huo
@ 2020-09-09  2:17 ` Martin K. Petersen
  1 sibling, 0 replies; 3+ messages in thread
From: Martin K. Petersen @ 2020-09-09  2:17 UTC (permalink / raw)
  To: rnayak, asutoshd, nguyenb, linux-scsi, saravanak, kernel-team,
	salyzyn, hongwus, Can Guo
  Cc: Martin K . Petersen, Bart Van Assche, Stanley Chu, Bean Huo,
	James E.J. Bottomley, open list, Alim Akhtar, Avri Altman

On Tue, 18 Aug 2020 18:02:29 -0700, Can Guo wrote:

> Commit 5586dd8ea250 ("scsi: ufs: Fix a race condition between error handler
> and runtime PM ops") moves the ufshcd_scsi_block_requests() inside
> err_handler(), but forgets to remove the ufshcd_scsi_unblock_requests() in
> the early return path. Correct the coding mistake.

Applied to 5.10/scsi-queue, thanks!

[1/1] scsi: ufs: Remove an unpaired ufshcd_scsi_unblock_requests() in err_handler()
      https://git.kernel.org/mkp/scsi/c/50807f22c89f

-- 
Martin K. Petersen	Oracle Linux Engineering

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

end of thread, other threads:[~2020-09-09  2:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-19  1:02 [PATCH v2] scsi: ufs: Remove an unpaired ufshcd_scsi_unblock_requests() in err_handler() Can Guo
2020-08-24  8:41 ` Bean Huo
2020-09-09  2:17 ` Martin K. Petersen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).