From ae1ede303b454d8d243ffe275a62472e9700c5dd Mon Sep 17 00:00:00 2001 From: Venkat Gopalakrishnan Date: Tue, 16 Aug 2016 12:33:20 -0700 Subject: scsi: ufs-qcom: disable hibern8 during clk gating There is no need to send hibern8 enter/exit during clk gate/ungate when auto hibern8 is supported as that would be handled by the controller, thus remove UFSHCD_CAP_HIBERN8_WITH_CLK_GATING cap. Change-Id: Ica50975082b5071fafaa6a318c38e97afb7ba700 Signed-off-by: Venkat Gopalakrishnan --- drivers/scsi/ufs/ufshcd.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'drivers/scsi/ufs') diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c index 4d406c51d884..8aa886d7a4e1 100644 --- a/drivers/scsi/ufs/ufshcd.c +++ b/drivers/scsi/ufs/ufshcd.c @@ -1503,6 +1503,13 @@ static void ufshcd_init_clk_gating(struct ufs_hba *hba) if (!ufshcd_is_clkgating_allowed(hba)) return; + /* + * Disable hibern8 during clk gating if + * auto hibern8 is supported + */ + if (ufshcd_is_auto_hibern8_supported(hba)) + hba->caps &= ~UFSHCD_CAP_HIBERN8_WITH_CLK_GATING; + INIT_DELAYED_WORK(&gating->gate_work, ufshcd_gate_work); INIT_WORK(&gating->ungate_work, ufshcd_ungate_work); -- cgit v1.2.3