aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/arm/mach-omap2/omap_hwmod_2430_data.c98
1 files changed, 98 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/omap_hwmod_2430_data.c b/arch/arm/mach-omap2/omap_hwmod_2430_data.c
index 8ecfbcde13ba..76bbf8a47031 100644
--- a/arch/arm/mach-omap2/omap_hwmod_2430_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_2430_data.c
@@ -89,6 +89,16 @@ static struct omap_hwmod omap2430_uart3_hwmod;
89static struct omap_hwmod omap2430_i2c1_hwmod; 89static struct omap_hwmod omap2430_i2c1_hwmod;
90static struct omap_hwmod omap2430_i2c2_hwmod; 90static struct omap_hwmod omap2430_i2c2_hwmod;
91 91
92static struct omap_hwmod omap2430_usbhsotg_hwmod;
93
94/* l3_core -> usbhsotg interface */
95static struct omap_hwmod_ocp_if omap2430_usbhsotg__l3 = {
96 .master = &omap2430_usbhsotg_hwmod,
97 .slave = &omap2430_l3_main_hwmod,
98 .clk = "core_l3_ck",
99 .user = OCP_USER_MPU,
100};
101
92/* I2C IP block address space length (in bytes) */ 102/* I2C IP block address space length (in bytes) */
93#define OMAP2_I2C_AS_LEN 128 103#define OMAP2_I2C_AS_LEN 128
94 104
@@ -189,6 +199,35 @@ static struct omap_hwmod_ocp_if omap2_l4_core__uart3 = {
189 .user = OCP_USER_MPU | OCP_USER_SDMA, 199 .user = OCP_USER_MPU | OCP_USER_SDMA,
190}; 200};
191 201
202/*
203* usbhsotg interface data
204*/
205static struct omap_hwmod_addr_space omap2430_usbhsotg_addrs[] = {
206 {
207 .pa_start = OMAP243X_HS_BASE,
208 .pa_end = OMAP243X_HS_BASE + SZ_4K - 1,
209 .flags = ADDR_TYPE_RT
210 },
211};
212
213/* l4_core ->usbhsotg interface */
214static struct omap_hwmod_ocp_if omap2430_l4_core__usbhsotg = {
215 .master = &omap2430_l4_core_hwmod,
216 .slave = &omap2430_usbhsotg_hwmod,
217 .clk = "usb_l4_ick",
218 .addr = omap2430_usbhsotg_addrs,
219 .addr_cnt = ARRAY_SIZE(omap2430_usbhsotg_addrs),
220 .user = OCP_USER_MPU,
221};
222
223static struct omap_hwmod_ocp_if *omap2430_usbhsotg_masters[] = {
224 &omap2430_usbhsotg__l3,
225};
226
227static struct omap_hwmod_ocp_if *omap2430_usbhsotg_slaves[] = {
228 &omap2430_l4_core__usbhsotg,
229};
230
192/* Slave interfaces on the L4_CORE interconnect */ 231/* Slave interfaces on the L4_CORE interconnect */
193static struct omap_hwmod_ocp_if *omap2430_l4_core_slaves[] = { 232static struct omap_hwmod_ocp_if *omap2430_l4_core_slaves[] = {
194 &omap2430_l3_main__l4_core, 233 &omap2430_l3_main__l4_core,
@@ -919,6 +958,62 @@ static struct omap_hwmod omap2430_dma_system_hwmod = {
919 .flags = HWMOD_NO_IDLEST, 958 .flags = HWMOD_NO_IDLEST,
920}; 959};
921 960
961/*
962 * usbhsotg
963 */
964static struct omap_hwmod_class_sysconfig omap2430_usbhsotg_sysc = {
965 .rev_offs = 0x0400,
966 .sysc_offs = 0x0404,
967 .syss_offs = 0x0408,
968 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE|
969 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
970 SYSC_HAS_AUTOIDLE),
971 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
972 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
973 .sysc_fields = &omap_hwmod_sysc_type1,
974};
975
976static struct omap_hwmod_class usbotg_class = {
977 .name = "usbotg",
978 .sysc = &omap2430_usbhsotg_sysc,
979};
980
981/* usb_otg_hs */
982static struct omap_hwmod_irq_info omap2430_usbhsotg_mpu_irqs[] = {
983
984 { .name = "mc", .irq = 92 },
985 { .name = "dma", .irq = 93 },
986};
987
988static struct omap_hwmod omap2430_usbhsotg_hwmod = {
989 .name = "usb_otg_hs",
990 .mpu_irqs = omap2430_usbhsotg_mpu_irqs,
991 .mpu_irqs_cnt = ARRAY_SIZE(omap2430_usbhsotg_mpu_irqs),
992 .main_clk = "usbhs_ick",
993 .prcm = {
994 .omap2 = {
995 .prcm_reg_id = 1,
996 .module_bit = OMAP2430_EN_USBHS_MASK,
997 .module_offs = CORE_MOD,
998 .idlest_reg_id = 1,
999 .idlest_idle_bit = OMAP2430_ST_USBHS_SHIFT,
1000 },
1001 },
1002 .masters = omap2430_usbhsotg_masters,
1003 .masters_cnt = ARRAY_SIZE(omap2430_usbhsotg_masters),
1004 .slaves = omap2430_usbhsotg_slaves,
1005 .slaves_cnt = ARRAY_SIZE(omap2430_usbhsotg_slaves),
1006 .class = &usbotg_class,
1007 /*
1008 * Erratum ID: i479 idle_req / idle_ack mechanism potentially
1009 * broken when autoidle is enabled
1010 * workaround is to disable the autoidle bit at module level.
1011 */
1012 .flags = HWMOD_NO_OCP_AUTOIDLE | HWMOD_SWSUP_SIDLE
1013 | HWMOD_SWSUP_MSTANDBY,
1014 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430)
1015};
1016
922static __initdata struct omap_hwmod *omap2430_hwmods[] = { 1017static __initdata struct omap_hwmod *omap2430_hwmods[] = {
923 &omap2430_l3_main_hwmod, 1018 &omap2430_l3_main_hwmod,
924 &omap2430_l4_core_hwmod, 1019 &omap2430_l4_core_hwmod,
@@ -941,6 +1036,9 @@ static __initdata struct omap_hwmod *omap2430_hwmods[] = {
941 1036
942 /* dma_system class*/ 1037 /* dma_system class*/
943 &omap2430_dma_system_hwmod, 1038 &omap2430_dma_system_hwmod,
1039
1040 /* usbotg class*/
1041 &omap2430_usbhsotg_hwmod,
944 NULL, 1042 NULL,
945}; 1043};
946 1044