msm: mdm: Disconnect peripheral(hsic) before powering down the MDM
Powering down the MDM before disconnecting HSIC can cause PHY lock
due to bus-errors. Hence remove the hsic controller device before
resetting external modem.
CRs-Fixed: 388234
Change-Id: Ia22451cfcc4d9ef8a41348a8b0f02960c068c74b
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
diff --git a/arch/arm/mach-msm/mdm2.c b/arch/arm/mach-msm/mdm2.c
index 2073856..43c85bb 100644
--- a/arch/arm/mach-msm/mdm2.c
+++ b/arch/arm/mach-msm/mdm2.c
@@ -108,6 +108,8 @@
int soft_reset_direction =
mdm_drv->pdata->soft_reset_inverted ? 1 : 0;
+ mdm_peripheral_disconnect(mdm_drv);
+
/* Wait for the modem to complete its power down actions. */
for (i = 20; i > 0; i--) {
if (gpio_get_value(mdm_drv->mdm2ap_status_gpio) == 0)
@@ -127,7 +129,6 @@
*/
msleep(4000);
}
- mdm_peripheral_disconnect(mdm_drv);
}
static void mdm_do_first_power_on(struct mdm_modem_drv *mdm_drv)