Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 96c54d6d authored by Amir Samuelov's avatar Amir Samuelov
Browse files

usb: phy: hsusb: Fix usb suspend/resume for mdm9635



When PLLBTUNE is used, upon usb resume the FSEL (clock reference selection)
should be zero, same as on msm_hsphy_init().

Change-Id: I8ff9c999a43c20d60211292d6bae2e0ddbe64c71
Signed-off-by: default avatarAmir Samuelov <amirs@codeaurora.org>
parent 51f18552
Loading
Loading
Loading
Loading
+10 −3
Original line number Diff line number Diff line
/*
 * Copyright (c) 2012-2013, The Linux Foundation. All rights reserved.
 * Copyright (c) 2012-2014, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -376,10 +376,17 @@ static int msm_hsphy_set_suspend(struct usb_phy *uphy, int suspend)
				msm_hsusb_ldo_enable(phy, 1);
		}

		if (phy->core_ver >= MSM_CORE_VER_120)
		if (phy->core_ver >= MSM_CORE_VER_120) {
			if (phy->set_pllbtune) {
				msm_usb_write_readback(phy->base,
						HS_PHY_CTRL_COMMON_REG,
						FSEL_MASK, 0);
			} else {
				msm_usb_write_readback(phy->base,
						HS_PHY_CTRL_COMMON_REG,
						FSEL_MASK, FSEL_DEFAULT);
			}
		}

		if (!phy->ext_vbus_id)
			/* Disable HV interrupts */