diff options
author | Stanley Chu <stanley.chu@mediatek.com> | 2019-12-07 13:22:01 +0100 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2019-12-20 04:08:54 +0100 |
commit | 8b0bbf002a1eb9074ab770e21cd454137c76c106 (patch) | |
tree | 9748b654ad1954e591007fc9f7ff67d284e2a639 /drivers | |
parent | scsi: ufs: disable irq before disabling clocks (diff) | |
download | linux-8b0bbf002a1eb9074ab770e21cd454137c76c106.tar.xz linux-8b0bbf002a1eb9074ab770e21cd454137c76c106.zip |
scsi: ufs: disable interrupt during clock-gating
Similar to suspend, ufshcd interrupt can be disabled since there won't be
any host controller transaction expected till clocks ungated.
Link: https://lore.kernel.org/r/1575721321-8071-3-git-send-email-stanley.chu@mediatek.com
Reviewed-by: Asutosh Das <asutoshd@codeaurora.org>
Reviewed-by: Avri Altman <avri.altman@wdc.com>
Signed-off-by: Stanley Chu <stanley.chu@mediatek.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/scsi/ufs/ufshcd.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c index f55cf036c3fe..a6936bebb513 100644 --- a/drivers/scsi/ufs/ufshcd.c +++ b/drivers/scsi/ufs/ufshcd.c @@ -1466,6 +1466,8 @@ static void ufshcd_ungate_work(struct work_struct *work) spin_unlock_irqrestore(hba->host->host_lock, flags); ufshcd_setup_clocks(hba, true); + ufshcd_enable_irq(hba); + /* Exit from hibern8 */ if (ufshcd_can_hibern8_during_gating(hba)) { /* Prevent gating in this path */ @@ -1612,6 +1614,8 @@ static void ufshcd_gate_work(struct work_struct *work) ufshcd_set_link_hibern8(hba); } + ufshcd_disable_irq(hba); + if (!ufshcd_is_link_active(hba)) ufshcd_setup_clocks(hba, false); else |