modify rk2928 usb host&otg phy config
authoryangkai <yk@rock-chips.com>
Mon, 22 Oct 2012 07:53:47 +0000 (15:53 +0800)
committeryangkai <yk@rock-chips.com>
Mon, 22 Oct 2012 07:53:47 +0000 (15:53 +0800)
drivers/usb/dwc_otg/usbdev_rk2928.c

index 8776931a36d0973375d6a2fb23ba81725f421623..2885e166b666b7cc11b881d2bd9a6f5fba913abb 100755 (executable)
@@ -16,7 +16,9 @@
 #define GRF_REG_BASE RK2928_GRF_BASE\r
 #define USBOTG_SIZE    RK2928_USBOTG20_SIZE\r
 #define USBGRF_SOC_STATUS0     (GRF_REG_BASE+0x14c)\r
+#define USBGRF_UOC0_CON0       (GRF_REG_BASE+0x16c)\r
 #define USBGRF_UOC0_CON5       (GRF_REG_BASE+0x17c)\r
+#define USBGRF_UOC1_CON0       (GRF_REG_BASE+0x180)\r
 #define USBGRF_UOC1_CON4    (GRF_REG_BASE+0X190)\r
 #define USBGRF_UOC1_CON5       (GRF_REG_BASE+0x194)\r
 \r
@@ -93,6 +95,7 @@ void usb20otg_hw_init(void)
     *otg_phy_con1 = 0x1D5 |(0x1ff<<16);   // enter suspend.\r
 #endif\r
     // usb phy config init\r
+    *(unsigned int *)(USBGRF_UOC0_CON0) = 0x07e70350;\r
 \r
     // other hardware init\r
     rk30_mux_api_set(GPIO3C1_OTG_DRVVBUS_NAME, GPIO3C_OTG_DRVVBUS);    \r
@@ -239,7 +242,7 @@ static struct resource usb20_host_resource[] = {
 void usb20host_hw_init(void)\r
 {\r
     // usb phy config init\r
-    *(unsigned int *)(USBGRF_UOC0_CON5+4) = 0x07e70350;\r
+    *(unsigned int *)(USBGRF_UOC1_CON0) = 0x07e70350;\r
     // other haredware init\r
     \r
 }\r