[PATCH 1/3] usb-imx28: fix enable

Eric Bénard eric at eukrea.com
Tue Sep 10 13:57:54 EDT 2013


we need to power on the PLL when enabling the USB clock.

Signed-off-by: Eric Bénard <eric at eukrea.com>
---
 arch/arm/mach-mxs/usb-imx28.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/arch/arm/mach-mxs/usb-imx28.c b/arch/arm/mach-mxs/usb-imx28.c
index 61d59c3..e5b63c3 100644
--- a/arch/arm/mach-mxs/usb-imx28.c
+++ b/arch/arm/mach-mxs/usb-imx28.c
@@ -46,6 +46,7 @@
 #define CLK_PLL0CTRL0			(IMX_CCM_BASE + 0x0)
 #define CLK_PLL1CTRL0			(IMX_CCM_BASE + 0x20)
 #define PLLCTRL0_EN_USB_CLKS		(1 << 18)
+#define PLLCTRL0_POWER		(1 << 17)
 
 #define DIGCTRL_CTRL			(IMX_DIGCTL_BASE + 0x0)
 #define DIGCTL_CTRL_USB0_CLKGATE	(1 << 2)
@@ -77,7 +78,7 @@ int imx28_usb_phy0_enable(void)
 	imx28_usb_phy_reset((void *)IMX_USBPHY0_BASE);
 
 	/* Turn on the USB clocks */
-	writel(PLLCTRL0_EN_USB_CLKS, CLK_PLL0CTRL0 + SET);
+	writel(PLLCTRL0_EN_USB_CLKS | PLLCTRL0_POWER, CLK_PLL0CTRL0 + SET);
 
 	writel(DIGCTL_CTRL_USB0_CLKGATE, DIGCTRL_CTRL + CLR);
 
@@ -91,7 +92,7 @@ int imx28_usb_phy1_enable(void)
 	imx28_usb_phy_reset((void *)IMX_USBPHY1_BASE);
 
 	/* Turn on the USB clocks */
-	writel(PLLCTRL0_EN_USB_CLKS, CLK_PLL1CTRL0 + SET);
+	writel(PLLCTRL0_EN_USB_CLKS | PLLCTRL0_POWER, CLK_PLL1CTRL0 + SET);
 
 	writel(DIGCTL_CTRL_USB1_CLKGATE, DIGCTRL_CTRL + CLR);
 
-- 
1.8.3.1




More information about the barebox mailing list