[HACK][COMMON] scsi: ufs: Disable power in suspend
authorhgchu <hg.chu@samsung.com>
Thu, 25 Jan 2018 11:15:58 +0000 (20:15 +0900)
committerJaeHun Jung <jh0801.jung@samsung.com>
Tue, 8 May 2018 08:21:02 +0000 (17:21 +0900)
Change-Id: I8e9170de02617e9f778ebb7f6beb1a5d1ef57be0
Signed-off-by: hgchu <hg.chu@samsung.com>
drivers/scsi/ufs/ufshcd.c

index b12059e80c52e4e5b33b5356821aae1382f930a1..9cfb410f88b4047e5f4b7d2d7e8f964ae1f9f80f 100644 (file)
@@ -7993,15 +7993,15 @@ static int ufshcd_suspend(struct ufs_hba *hba, enum ufs_pm_op pm_op)
        if (ufshcd_is_shutdown_pm(pm_op))
                ufs_shutdown_state = 1;
 
-       if ((req_dev_pwr_mode != hba->curr_dev_pwr_mode) &&
-            ((ufshcd_is_runtime_pm(pm_op) && !hba->auto_bkops_enabled) ||
-              !ufshcd_is_runtime_pm(pm_op))) {
+//     if ((req_dev_pwr_mode != hba->curr_dev_pwr_mode) &&
+//          ((ufshcd_is_runtime_pm(pm_op) && !hba->auto_bkops_enabled) ||
+//            !ufshcd_is_runtime_pm(pm_op))) {
                /* ensure that bkops is disabled */
-               ufshcd_disable_auto_bkops(hba);
-               ret = ufshcd_set_dev_pwr_mode(hba, req_dev_pwr_mode);
-               if (ret)
-                       goto enable_gating;
-       }
+//             ufshcd_disable_auto_bkops(hba);
+//             ret = ufshcd_set_dev_pwr_mode(hba, req_dev_pwr_mode);
+//             if (ret)
+//                     goto enable_gating;
+//     }
 
        ret = ufshcd_link_state_transition(hba, req_link_state, 1);
        if (ret)
@@ -8026,11 +8026,11 @@ disable_clks:
        udelay(50);
 
        if (gating_allowed) {
-               if (!ufshcd_is_link_active(hba))
-                       ufshcd_setup_clocks(hba, false);
-               else
-                       /* If link is active, device ref_clk can't be switched off */
-                       __ufshcd_setup_clocks(hba, false, true);
+//             if (!ufshcd_is_link_active(hba))
+//                     ufshcd_setup_clocks(hba, false);
+///            else
+//                     /* If link is active, device ref_clk can't be switched off */
+///                    __ufshcd_setup_clocks(hba, false, true);
        }
 
        hba->clk_gating.state = CLKS_OFF;