scsi: ufs: change an order of vs resume and power control
authorhgchu <hg.chu@samsung.com>
Fri, 12 Jan 2018 05:47:16 +0000 (14:47 +0900)
committerJaeHun Jung <jh0801.jung@samsung.com>
Tue, 8 May 2018 08:20:32 +0000 (17:20 +0900)
Change-Id: Ic608651530d6e3b92c0aafe4f03be95844b939c0
Signed-off-by: hgchu <hg.chu@samsung.com>
drivers/scsi/ufs/ufshcd.c

index 0f7c233d936ed8921d3f1a1b55c4cef8054608e7..9a671dbc50846527448ba8bfae8084cd3cde3cae 100644 (file)
@@ -7692,12 +7692,6 @@ static int ufshcd_resume(struct ufs_hba *hba, enum ufs_pm_op pm_op)
 
        ufshcd_hba_vreg_set_hpm(hba);
 
-
-       /* enable the host irq as host controller would be active soon */
-       ret = ufshcd_enable_irq(hba);
-       if (ret)
-               goto disable_irq_and_vops_clks;
-
        ret = ufshcd_vreg_set_hpm(hba);
        if (ret)
                goto disable_irq_and_vops_clks;
@@ -7766,13 +7760,13 @@ set_old_link_state:
        ufshcd_link_state_transition(hba, old_link_state, 0);
 vendor_suspend:
        ufshcd_vops_suspend(hba, pm_op);
-disable_vreg:
-       ufshcd_vreg_set_lpm(hba);
 disable_irq_and_vops_clks:
        ufshcd_disable_irq(hba);
        if (hba->clk_scaling.is_allowed)
                ufshcd_suspend_clkscaling(hba);
        ufshcd_setup_clocks(hba, false);
+disable_vreg:
+       ufshcd_vreg_set_lpm(hba);
 out:
        hba->pm_op_in_progress = 0;
        return ret;