public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/2] Fixes for UFS clock gating initialization
@ 2025-01-26  6:45 Avri Altman
  2025-01-26  6:45 ` [PATCH v3 1/2] scsi: ufs: core: Ensure clk_gating.lock is used only after initialization Avri Altman
  2025-01-26  6:45 ` [PATCH v3 2/2] scsi: ufs: Fix toggling of clk_gating.state when clock gating is not allowed Avri Altman
  0 siblings, 2 replies; 9+ messages in thread
From: Avri Altman @ 2025-01-26  6:45 UTC (permalink / raw)
  To: Martin K . Petersen
  Cc: linux-scsi, linux-kernel, Manivannan Sadhasivam, Bart Van Assche,
	Geert Uytterhoeven, Avri Altman

Martin hi,

This patch series addresses two issues related to the UFS clock gating
mechanism. The first patch ensures that the `clk_gating.lock` is used
only after it has been properly initialized.

The second patch fixes an issue where `clk_gating.state` is toggled even
if clock gating is not allowed, which can lead to crashes.

Changes since v2:
 - Add patch #2 (Geert)
 - Initialize clk_gating.lock unconditionally (Bart)

Changes since v1:
 - move the spin_lock_init(&hba->clk_gating.lock) call from
   ufshcd_init_clk_gating() just before the ufshcd_hba_init() call in
   ufshcd_init() (Bart)

Avri Altman (2):
  scsi: ufs: core: Ensure clk_gating.lock is used only after
    initialization
  scsi: ufs: Fix toggling of clk_gating.state when clock gating is not
    allowed

 drivers/ufs/core/ufshcd.c | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

-- 
2.25.1


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

end of thread, other threads:[~2025-01-27 12:00 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-01-26  6:45 [PATCH v3 0/2] Fixes for UFS clock gating initialization Avri Altman
2025-01-26  6:45 ` [PATCH v3 1/2] scsi: ufs: core: Ensure clk_gating.lock is used only after initialization Avri Altman
2025-01-26 19:55   ` Bean Huo
2025-01-27  9:54   ` Geert Uytterhoeven
2025-01-26  6:45 ` [PATCH v3 2/2] scsi: ufs: Fix toggling of clk_gating.state when clock gating is not allowed Avri Altman
2025-01-26 21:55   ` Bean Huo
2025-01-27  7:07     ` Avri Altman
2025-01-27 10:10   ` Geert Uytterhoeven
2025-01-27 12:00     ` Avri Altman

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