2 * omap_hwmod_3xxx_data.c - hardware modules present on the OMAP3xxx chips
4 * Copyright (C) 2009-2011 Nokia Corporation
5 * Copyright (C) 2012 Texas Instruments, Inc.
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License version 2 as
10 * published by the Free Software Foundation.
12 * The data in this file should be completely autogeneratable from
13 * the TI hardware database or other technical documentation.
15 * XXX these should be marked initdata for multi-OMAP kernels
18 #include <linux/i2c-omap.h>
19 #include <linux/power/smartreflex.h>
20 #include <linux/platform_data/gpio-omap.h>
22 #include <plat-omap/dma-omap.h>
25 #include <linux/platform_data/asoc-ti-mcbsp.h>
26 #include <linux/platform_data/spi-omap2-mcspi.h>
27 #include <plat/dmtimer.h>
28 #include <plat/iommu.h>
33 #include "omap_hwmod.h"
34 #include "omap_hwmod_common_data.h"
35 #include "prm-regbits-34xx.h"
36 #include "cm-regbits-34xx.h"
45 * OMAP3xxx hardware module integration data
47 * All of the data in this section should be autogeneratable from the
48 * TI hardware database or other technical documentation. Data that
49 * is driver-specific or driver-kernel integration-specific belongs
58 static struct omap_hwmod_irq_info omap3xxx_l3_main_irqs[] = {
59 { .irq = 9 + OMAP_INTC_START, },
60 { .irq = 10 + OMAP_INTC_START, },
64 static struct omap_hwmod omap3xxx_l3_main_hwmod = {
66 .class = &l3_hwmod_class,
67 .mpu_irqs = omap3xxx_l3_main_irqs,
68 .flags = HWMOD_NO_IDLEST,
72 static struct omap_hwmod omap3xxx_l4_core_hwmod = {
74 .class = &l4_hwmod_class,
75 .flags = HWMOD_NO_IDLEST,
79 static struct omap_hwmod omap3xxx_l4_per_hwmod = {
81 .class = &l4_hwmod_class,
82 .flags = HWMOD_NO_IDLEST,
86 static struct omap_hwmod omap3xxx_l4_wkup_hwmod = {
88 .class = &l4_hwmod_class,
89 .flags = HWMOD_NO_IDLEST,
93 static struct omap_hwmod omap3xxx_l4_sec_hwmod = {
95 .class = &l4_hwmod_class,
96 .flags = HWMOD_NO_IDLEST,
100 static struct omap_hwmod_irq_info omap3xxx_mpu_irqs[] = {
101 { .name = "pmu", .irq = 3 + OMAP_INTC_START },
105 static struct omap_hwmod omap3xxx_mpu_hwmod = {
107 .mpu_irqs = omap3xxx_mpu_irqs,
108 .class = &mpu_hwmod_class,
109 .main_clk = "arm_fck",
113 static struct omap_hwmod_rst_info omap3xxx_iva_resets[] = {
114 { .name = "logic", .rst_shift = 0, .st_shift = 8 },
115 { .name = "seq0", .rst_shift = 1, .st_shift = 9 },
116 { .name = "seq1", .rst_shift = 2, .st_shift = 10 },
119 static struct omap_hwmod omap3xxx_iva_hwmod = {
121 .class = &iva_hwmod_class,
122 .clkdm_name = "iva2_clkdm",
123 .rst_lines = omap3xxx_iva_resets,
124 .rst_lines_cnt = ARRAY_SIZE(omap3xxx_iva_resets),
125 .main_clk = "iva2_ck",
128 .module_offs = OMAP3430_IVA2_MOD,
130 .module_bit = OMAP3430_CM_FCLKEN_IVA2_EN_IVA2_SHIFT,
132 .idlest_idle_bit = OMAP3430_ST_IVA2_SHIFT,
139 * debug and emulation sub system
142 static struct omap_hwmod_class omap3xxx_debugss_hwmod_class = {
147 static struct omap_hwmod omap3xxx_debugss_hwmod = {
149 .class = &omap3xxx_debugss_hwmod_class,
150 .clkdm_name = "emu_clkdm",
151 .main_clk = "emu_src_ck",
152 .flags = HWMOD_NO_IDLEST,
156 static struct omap_hwmod_class_sysconfig omap3xxx_timer_1ms_sysc = {
160 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_CLOCKACTIVITY |
161 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
162 SYSC_HAS_EMUFREE | SYSC_HAS_AUTOIDLE),
163 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
164 .sysc_fields = &omap_hwmod_sysc_type1,
167 static struct omap_hwmod_class omap3xxx_timer_1ms_hwmod_class = {
169 .sysc = &omap3xxx_timer_1ms_sysc,
172 static struct omap_hwmod_class_sysconfig omap3xxx_timer_sysc = {
176 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP |
177 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
178 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
179 .sysc_fields = &omap_hwmod_sysc_type1,
182 static struct omap_hwmod_class omap3xxx_timer_hwmod_class = {
184 .sysc = &omap3xxx_timer_sysc,
187 /* secure timers dev attribute */
188 static struct omap_timer_capability_dev_attr capability_secure_dev_attr = {
189 .timer_capability = OMAP_TIMER_ALWON | OMAP_TIMER_SECURE,
192 /* always-on timers dev attribute */
193 static struct omap_timer_capability_dev_attr capability_alwon_dev_attr = {
194 .timer_capability = OMAP_TIMER_ALWON,
197 /* pwm timers dev attribute */
198 static struct omap_timer_capability_dev_attr capability_pwm_dev_attr = {
199 .timer_capability = OMAP_TIMER_HAS_PWM,
202 /* timers with DSP interrupt dev attribute */
203 static struct omap_timer_capability_dev_attr capability_dsp_dev_attr = {
204 .timer_capability = OMAP_TIMER_HAS_DSP_IRQ,
207 /* pwm timers with DSP interrupt dev attribute */
208 static struct omap_timer_capability_dev_attr capability_dsp_pwm_dev_attr = {
209 .timer_capability = OMAP_TIMER_HAS_DSP_IRQ | OMAP_TIMER_HAS_PWM,
213 static struct omap_hwmod omap3xxx_timer1_hwmod = {
215 .mpu_irqs = omap2_timer1_mpu_irqs,
216 .main_clk = "gpt1_fck",
220 .module_bit = OMAP3430_EN_GPT1_SHIFT,
221 .module_offs = WKUP_MOD,
223 .idlest_idle_bit = OMAP3430_ST_GPT1_SHIFT,
226 .dev_attr = &capability_alwon_dev_attr,
227 .class = &omap3xxx_timer_1ms_hwmod_class,
231 static struct omap_hwmod omap3xxx_timer2_hwmod = {
233 .mpu_irqs = omap2_timer2_mpu_irqs,
234 .main_clk = "gpt2_fck",
238 .module_bit = OMAP3430_EN_GPT2_SHIFT,
239 .module_offs = OMAP3430_PER_MOD,
241 .idlest_idle_bit = OMAP3430_ST_GPT2_SHIFT,
244 .class = &omap3xxx_timer_1ms_hwmod_class,
248 static struct omap_hwmod omap3xxx_timer3_hwmod = {
250 .mpu_irqs = omap2_timer3_mpu_irqs,
251 .main_clk = "gpt3_fck",
255 .module_bit = OMAP3430_EN_GPT3_SHIFT,
256 .module_offs = OMAP3430_PER_MOD,
258 .idlest_idle_bit = OMAP3430_ST_GPT3_SHIFT,
261 .class = &omap3xxx_timer_hwmod_class,
265 static struct omap_hwmod omap3xxx_timer4_hwmod = {
267 .mpu_irqs = omap2_timer4_mpu_irqs,
268 .main_clk = "gpt4_fck",
272 .module_bit = OMAP3430_EN_GPT4_SHIFT,
273 .module_offs = OMAP3430_PER_MOD,
275 .idlest_idle_bit = OMAP3430_ST_GPT4_SHIFT,
278 .class = &omap3xxx_timer_hwmod_class,
282 static struct omap_hwmod omap3xxx_timer5_hwmod = {
284 .mpu_irqs = omap2_timer5_mpu_irqs,
285 .main_clk = "gpt5_fck",
289 .module_bit = OMAP3430_EN_GPT5_SHIFT,
290 .module_offs = OMAP3430_PER_MOD,
292 .idlest_idle_bit = OMAP3430_ST_GPT5_SHIFT,
295 .dev_attr = &capability_dsp_dev_attr,
296 .class = &omap3xxx_timer_hwmod_class,
300 static struct omap_hwmod omap3xxx_timer6_hwmod = {
302 .mpu_irqs = omap2_timer6_mpu_irqs,
303 .main_clk = "gpt6_fck",
307 .module_bit = OMAP3430_EN_GPT6_SHIFT,
308 .module_offs = OMAP3430_PER_MOD,
310 .idlest_idle_bit = OMAP3430_ST_GPT6_SHIFT,
313 .dev_attr = &capability_dsp_dev_attr,
314 .class = &omap3xxx_timer_hwmod_class,
318 static struct omap_hwmod omap3xxx_timer7_hwmod = {
320 .mpu_irqs = omap2_timer7_mpu_irqs,
321 .main_clk = "gpt7_fck",
325 .module_bit = OMAP3430_EN_GPT7_SHIFT,
326 .module_offs = OMAP3430_PER_MOD,
328 .idlest_idle_bit = OMAP3430_ST_GPT7_SHIFT,
331 .dev_attr = &capability_dsp_dev_attr,
332 .class = &omap3xxx_timer_hwmod_class,
336 static struct omap_hwmod omap3xxx_timer8_hwmod = {
338 .mpu_irqs = omap2_timer8_mpu_irqs,
339 .main_clk = "gpt8_fck",
343 .module_bit = OMAP3430_EN_GPT8_SHIFT,
344 .module_offs = OMAP3430_PER_MOD,
346 .idlest_idle_bit = OMAP3430_ST_GPT8_SHIFT,
349 .dev_attr = &capability_dsp_pwm_dev_attr,
350 .class = &omap3xxx_timer_hwmod_class,
354 static struct omap_hwmod omap3xxx_timer9_hwmod = {
356 .mpu_irqs = omap2_timer9_mpu_irqs,
357 .main_clk = "gpt9_fck",
361 .module_bit = OMAP3430_EN_GPT9_SHIFT,
362 .module_offs = OMAP3430_PER_MOD,
364 .idlest_idle_bit = OMAP3430_ST_GPT9_SHIFT,
367 .dev_attr = &capability_pwm_dev_attr,
368 .class = &omap3xxx_timer_hwmod_class,
372 static struct omap_hwmod omap3xxx_timer10_hwmod = {
374 .mpu_irqs = omap2_timer10_mpu_irqs,
375 .main_clk = "gpt10_fck",
379 .module_bit = OMAP3430_EN_GPT10_SHIFT,
380 .module_offs = CORE_MOD,
382 .idlest_idle_bit = OMAP3430_ST_GPT10_SHIFT,
385 .dev_attr = &capability_pwm_dev_attr,
386 .class = &omap3xxx_timer_1ms_hwmod_class,
390 static struct omap_hwmod omap3xxx_timer11_hwmod = {
392 .mpu_irqs = omap2_timer11_mpu_irqs,
393 .main_clk = "gpt11_fck",
397 .module_bit = OMAP3430_EN_GPT11_SHIFT,
398 .module_offs = CORE_MOD,
400 .idlest_idle_bit = OMAP3430_ST_GPT11_SHIFT,
403 .dev_attr = &capability_pwm_dev_attr,
404 .class = &omap3xxx_timer_hwmod_class,
408 static struct omap_hwmod_irq_info omap3xxx_timer12_mpu_irqs[] = {
409 { .irq = 95 + OMAP_INTC_START, },
413 static struct omap_hwmod omap3xxx_timer12_hwmod = {
415 .mpu_irqs = omap3xxx_timer12_mpu_irqs,
416 .main_clk = "gpt12_fck",
420 .module_bit = OMAP3430_EN_GPT12_SHIFT,
421 .module_offs = WKUP_MOD,
423 .idlest_idle_bit = OMAP3430_ST_GPT12_SHIFT,
426 .dev_attr = &capability_secure_dev_attr,
427 .class = &omap3xxx_timer_hwmod_class,
432 * 32-bit watchdog upward counter that generates a pulse on the reset pin on
436 static struct omap_hwmod_class_sysconfig omap3xxx_wd_timer_sysc = {
440 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_EMUFREE |
441 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
442 SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
443 SYSS_HAS_RESET_STATUS),
444 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
445 .sysc_fields = &omap_hwmod_sysc_type1,
449 static struct omap_hwmod_class_sysconfig i2c_sysc = {
453 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
454 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
455 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS),
456 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
457 .clockact = CLOCKACT_TEST_ICLK,
458 .sysc_fields = &omap_hwmod_sysc_type1,
461 static struct omap_hwmod_class omap3xxx_wd_timer_hwmod_class = {
463 .sysc = &omap3xxx_wd_timer_sysc,
464 .pre_shutdown = &omap2_wd_timer_disable,
465 .reset = &omap2_wd_timer_reset,
468 static struct omap_hwmod omap3xxx_wd_timer2_hwmod = {
470 .class = &omap3xxx_wd_timer_hwmod_class,
471 .main_clk = "wdt2_fck",
475 .module_bit = OMAP3430_EN_WDT2_SHIFT,
476 .module_offs = WKUP_MOD,
478 .idlest_idle_bit = OMAP3430_ST_WDT2_SHIFT,
482 * XXX: Use software supervised mode, HW supervised smartidle seems to
483 * block CORE power domain idle transitions. Maybe a HW bug in wdt2?
485 .flags = HWMOD_SWSUP_SIDLE,
489 static struct omap_hwmod omap3xxx_uart1_hwmod = {
491 .mpu_irqs = omap2_uart1_mpu_irqs,
492 .sdma_reqs = omap2_uart1_sdma_reqs,
493 .main_clk = "uart1_fck",
496 .module_offs = CORE_MOD,
498 .module_bit = OMAP3430_EN_UART1_SHIFT,
500 .idlest_idle_bit = OMAP3430_EN_UART1_SHIFT,
503 .class = &omap2_uart_class,
507 static struct omap_hwmod omap3xxx_uart2_hwmod = {
509 .mpu_irqs = omap2_uart2_mpu_irqs,
510 .sdma_reqs = omap2_uart2_sdma_reqs,
511 .main_clk = "uart2_fck",
514 .module_offs = CORE_MOD,
516 .module_bit = OMAP3430_EN_UART2_SHIFT,
518 .idlest_idle_bit = OMAP3430_EN_UART2_SHIFT,
521 .class = &omap2_uart_class,
525 static struct omap_hwmod omap3xxx_uart3_hwmod = {
527 .mpu_irqs = omap2_uart3_mpu_irqs,
528 .sdma_reqs = omap2_uart3_sdma_reqs,
529 .main_clk = "uart3_fck",
532 .module_offs = OMAP3430_PER_MOD,
534 .module_bit = OMAP3430_EN_UART3_SHIFT,
536 .idlest_idle_bit = OMAP3430_EN_UART3_SHIFT,
539 .class = &omap2_uart_class,
543 static struct omap_hwmod_irq_info uart4_mpu_irqs[] = {
544 { .irq = 80 + OMAP_INTC_START, },
548 static struct omap_hwmod_dma_info uart4_sdma_reqs[] = {
549 { .name = "rx", .dma_req = OMAP36XX_DMA_UART4_RX, },
550 { .name = "tx", .dma_req = OMAP36XX_DMA_UART4_TX, },
554 static struct omap_hwmod omap36xx_uart4_hwmod = {
556 .mpu_irqs = uart4_mpu_irqs,
557 .sdma_reqs = uart4_sdma_reqs,
558 .main_clk = "uart4_fck",
561 .module_offs = OMAP3430_PER_MOD,
563 .module_bit = OMAP3630_EN_UART4_SHIFT,
565 .idlest_idle_bit = OMAP3630_EN_UART4_SHIFT,
568 .class = &omap2_uart_class,
571 static struct omap_hwmod_irq_info am35xx_uart4_mpu_irqs[] = {
572 { .irq = 84 + OMAP_INTC_START, },
576 static struct omap_hwmod_dma_info am35xx_uart4_sdma_reqs[] = {
577 { .name = "rx", .dma_req = AM35XX_DMA_UART4_RX, },
578 { .name = "tx", .dma_req = AM35XX_DMA_UART4_TX, },
583 * XXX AM35xx UART4 cannot complete its softreset without uart1_fck or
584 * uart2_fck being enabled. So we add uart1_fck as an optional clock,
585 * below, and set the HWMOD_CONTROL_OPT_CLKS_IN_RESET. This really
586 * should not be needed. The functional clock structure of the AM35xx
587 * UART4 is extremely unclear and opaque; it is unclear what the role
588 * of uart1/2_fck is for the UART4. Any clarification from either
589 * empirical testing or the AM3505/3517 hardware designers would be
592 static struct omap_hwmod_opt_clk am35xx_uart4_opt_clks[] = {
593 { .role = "softreset_uart1_fck", .clk = "uart1_fck" },
596 static struct omap_hwmod am35xx_uart4_hwmod = {
598 .mpu_irqs = am35xx_uart4_mpu_irqs,
599 .sdma_reqs = am35xx_uart4_sdma_reqs,
600 .main_clk = "uart4_fck",
603 .module_offs = CORE_MOD,
605 .module_bit = AM35XX_EN_UART4_SHIFT,
607 .idlest_idle_bit = AM35XX_ST_UART4_SHIFT,
610 .opt_clks = am35xx_uart4_opt_clks,
611 .opt_clks_cnt = ARRAY_SIZE(am35xx_uart4_opt_clks),
612 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
613 .class = &omap2_uart_class,
616 static struct omap_hwmod_class i2c_class = {
619 .rev = OMAP_I2C_IP_VERSION_1,
620 .reset = &omap_i2c_reset,
623 static struct omap_hwmod_dma_info omap3xxx_dss_sdma_chs[] = {
624 { .name = "dispc", .dma_req = 5 },
625 { .name = "dsi1", .dma_req = 74 },
630 static struct omap_hwmod_opt_clk dss_opt_clks[] = {
632 * The DSS HW needs all DSS clocks enabled during reset. The dss_core
633 * driver does not use these clocks.
635 { .role = "sys_clk", .clk = "dss2_alwon_fck" },
636 { .role = "tv_clk", .clk = "dss_tv_fck" },
637 /* required only on OMAP3430 */
638 { .role = "tv_dac_clk", .clk = "dss_96m_fck" },
641 static struct omap_hwmod omap3430es1_dss_core_hwmod = {
643 .class = &omap2_dss_hwmod_class,
644 .main_clk = "dss1_alwon_fck", /* instead of dss_fck */
645 .sdma_reqs = omap3xxx_dss_sdma_chs,
649 .module_bit = OMAP3430_EN_DSS1_SHIFT,
650 .module_offs = OMAP3430_DSS_MOD,
652 .idlest_stdby_bit = OMAP3430ES1_ST_DSS_SHIFT,
655 .opt_clks = dss_opt_clks,
656 .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks),
657 .flags = HWMOD_NO_IDLEST | HWMOD_CONTROL_OPT_CLKS_IN_RESET,
660 static struct omap_hwmod omap3xxx_dss_core_hwmod = {
662 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
663 .class = &omap2_dss_hwmod_class,
664 .main_clk = "dss1_alwon_fck", /* instead of dss_fck */
665 .sdma_reqs = omap3xxx_dss_sdma_chs,
669 .module_bit = OMAP3430_EN_DSS1_SHIFT,
670 .module_offs = OMAP3430_DSS_MOD,
672 .idlest_idle_bit = OMAP3430ES2_ST_DSS_IDLE_SHIFT,
673 .idlest_stdby_bit = OMAP3430ES2_ST_DSS_STDBY_SHIFT,
676 .opt_clks = dss_opt_clks,
677 .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks),
685 static struct omap_hwmod_class_sysconfig omap3_dispc_sysc = {
689 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE |
690 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE |
692 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
693 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
694 .sysc_fields = &omap_hwmod_sysc_type1,
697 static struct omap_hwmod_class omap3_dispc_hwmod_class = {
699 .sysc = &omap3_dispc_sysc,
702 static struct omap_hwmod omap3xxx_dss_dispc_hwmod = {
704 .class = &omap3_dispc_hwmod_class,
705 .mpu_irqs = omap2_dispc_irqs,
706 .main_clk = "dss1_alwon_fck",
710 .module_bit = OMAP3430_EN_DSS1_SHIFT,
711 .module_offs = OMAP3430_DSS_MOD,
714 .flags = HWMOD_NO_IDLEST,
715 .dev_attr = &omap2_3_dss_dispc_dev_attr
720 * display serial interface controller
723 static struct omap_hwmod_class omap3xxx_dsi_hwmod_class = {
727 static struct omap_hwmod_irq_info omap3xxx_dsi1_irqs[] = {
728 { .irq = 25 + OMAP_INTC_START, },
733 static struct omap_hwmod_opt_clk dss_dsi1_opt_clks[] = {
734 { .role = "sys_clk", .clk = "dss2_alwon_fck" },
737 static struct omap_hwmod omap3xxx_dss_dsi1_hwmod = {
739 .class = &omap3xxx_dsi_hwmod_class,
740 .mpu_irqs = omap3xxx_dsi1_irqs,
741 .main_clk = "dss1_alwon_fck",
745 .module_bit = OMAP3430_EN_DSS1_SHIFT,
746 .module_offs = OMAP3430_DSS_MOD,
749 .opt_clks = dss_dsi1_opt_clks,
750 .opt_clks_cnt = ARRAY_SIZE(dss_dsi1_opt_clks),
751 .flags = HWMOD_NO_IDLEST,
754 static struct omap_hwmod_opt_clk dss_rfbi_opt_clks[] = {
755 { .role = "ick", .clk = "dss_ick" },
758 static struct omap_hwmod omap3xxx_dss_rfbi_hwmod = {
760 .class = &omap2_rfbi_hwmod_class,
761 .main_clk = "dss1_alwon_fck",
765 .module_bit = OMAP3430_EN_DSS1_SHIFT,
766 .module_offs = OMAP3430_DSS_MOD,
769 .opt_clks = dss_rfbi_opt_clks,
770 .opt_clks_cnt = ARRAY_SIZE(dss_rfbi_opt_clks),
771 .flags = HWMOD_NO_IDLEST,
774 static struct omap_hwmod_opt_clk dss_venc_opt_clks[] = {
775 /* required only on OMAP3430 */
776 { .role = "tv_dac_clk", .clk = "dss_96m_fck" },
779 static struct omap_hwmod omap3xxx_dss_venc_hwmod = {
781 .class = &omap2_venc_hwmod_class,
782 .main_clk = "dss_tv_fck",
786 .module_bit = OMAP3430_EN_DSS1_SHIFT,
787 .module_offs = OMAP3430_DSS_MOD,
790 .opt_clks = dss_venc_opt_clks,
791 .opt_clks_cnt = ARRAY_SIZE(dss_venc_opt_clks),
792 .flags = HWMOD_NO_IDLEST,
796 static struct omap_i2c_dev_attr i2c1_dev_attr = {
797 .fifo_depth = 8, /* bytes */
798 .flags = OMAP_I2C_FLAG_APPLY_ERRATA_I207 |
799 OMAP_I2C_FLAG_RESET_REGS_POSTIDLE |
800 OMAP_I2C_FLAG_BUS_SHIFT_2,
803 static struct omap_hwmod omap3xxx_i2c1_hwmod = {
805 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
806 .mpu_irqs = omap2_i2c1_mpu_irqs,
807 .sdma_reqs = omap2_i2c1_sdma_reqs,
808 .main_clk = "i2c1_fck",
811 .module_offs = CORE_MOD,
813 .module_bit = OMAP3430_EN_I2C1_SHIFT,
815 .idlest_idle_bit = OMAP3430_ST_I2C1_SHIFT,
819 .dev_attr = &i2c1_dev_attr,
823 static struct omap_i2c_dev_attr i2c2_dev_attr = {
824 .fifo_depth = 8, /* bytes */
825 .flags = OMAP_I2C_FLAG_APPLY_ERRATA_I207 |
826 OMAP_I2C_FLAG_RESET_REGS_POSTIDLE |
827 OMAP_I2C_FLAG_BUS_SHIFT_2,
830 static struct omap_hwmod omap3xxx_i2c2_hwmod = {
832 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
833 .mpu_irqs = omap2_i2c2_mpu_irqs,
834 .sdma_reqs = omap2_i2c2_sdma_reqs,
835 .main_clk = "i2c2_fck",
838 .module_offs = CORE_MOD,
840 .module_bit = OMAP3430_EN_I2C2_SHIFT,
842 .idlest_idle_bit = OMAP3430_ST_I2C2_SHIFT,
846 .dev_attr = &i2c2_dev_attr,
850 static struct omap_i2c_dev_attr i2c3_dev_attr = {
851 .fifo_depth = 64, /* bytes */
852 .flags = OMAP_I2C_FLAG_APPLY_ERRATA_I207 |
853 OMAP_I2C_FLAG_RESET_REGS_POSTIDLE |
854 OMAP_I2C_FLAG_BUS_SHIFT_2,
857 static struct omap_hwmod_irq_info i2c3_mpu_irqs[] = {
858 { .irq = 61 + OMAP_INTC_START, },
862 static struct omap_hwmod_dma_info i2c3_sdma_reqs[] = {
863 { .name = "tx", .dma_req = OMAP34XX_DMA_I2C3_TX },
864 { .name = "rx", .dma_req = OMAP34XX_DMA_I2C3_RX },
868 static struct omap_hwmod omap3xxx_i2c3_hwmod = {
870 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
871 .mpu_irqs = i2c3_mpu_irqs,
872 .sdma_reqs = i2c3_sdma_reqs,
873 .main_clk = "i2c3_fck",
876 .module_offs = CORE_MOD,
878 .module_bit = OMAP3430_EN_I2C3_SHIFT,
880 .idlest_idle_bit = OMAP3430_ST_I2C3_SHIFT,
884 .dev_attr = &i2c3_dev_attr,
889 * general purpose io module
892 static struct omap_hwmod_class_sysconfig omap3xxx_gpio_sysc = {
896 .sysc_flags = (SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
897 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE |
898 SYSS_HAS_RESET_STATUS),
899 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
900 .sysc_fields = &omap_hwmod_sysc_type1,
903 static struct omap_hwmod_class omap3xxx_gpio_hwmod_class = {
905 .sysc = &omap3xxx_gpio_sysc,
910 static struct omap_gpio_dev_attr gpio_dev_attr = {
916 static struct omap_hwmod_opt_clk gpio1_opt_clks[] = {
917 { .role = "dbclk", .clk = "gpio1_dbck", },
920 static struct omap_hwmod omap3xxx_gpio1_hwmod = {
922 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
923 .mpu_irqs = omap2_gpio1_irqs,
924 .main_clk = "gpio1_ick",
925 .opt_clks = gpio1_opt_clks,
926 .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks),
930 .module_bit = OMAP3430_EN_GPIO1_SHIFT,
931 .module_offs = WKUP_MOD,
933 .idlest_idle_bit = OMAP3430_ST_GPIO1_SHIFT,
936 .class = &omap3xxx_gpio_hwmod_class,
937 .dev_attr = &gpio_dev_attr,
941 static struct omap_hwmod_opt_clk gpio2_opt_clks[] = {
942 { .role = "dbclk", .clk = "gpio2_dbck", },
945 static struct omap_hwmod omap3xxx_gpio2_hwmod = {
947 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
948 .mpu_irqs = omap2_gpio2_irqs,
949 .main_clk = "gpio2_ick",
950 .opt_clks = gpio2_opt_clks,
951 .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks),
955 .module_bit = OMAP3430_EN_GPIO2_SHIFT,
956 .module_offs = OMAP3430_PER_MOD,
958 .idlest_idle_bit = OMAP3430_ST_GPIO2_SHIFT,
961 .class = &omap3xxx_gpio_hwmod_class,
962 .dev_attr = &gpio_dev_attr,
966 static struct omap_hwmod_opt_clk gpio3_opt_clks[] = {
967 { .role = "dbclk", .clk = "gpio3_dbck", },
970 static struct omap_hwmod omap3xxx_gpio3_hwmod = {
972 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
973 .mpu_irqs = omap2_gpio3_irqs,
974 .main_clk = "gpio3_ick",
975 .opt_clks = gpio3_opt_clks,
976 .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks),
980 .module_bit = OMAP3430_EN_GPIO3_SHIFT,
981 .module_offs = OMAP3430_PER_MOD,
983 .idlest_idle_bit = OMAP3430_ST_GPIO3_SHIFT,
986 .class = &omap3xxx_gpio_hwmod_class,
987 .dev_attr = &gpio_dev_attr,
991 static struct omap_hwmod_opt_clk gpio4_opt_clks[] = {
992 { .role = "dbclk", .clk = "gpio4_dbck", },
995 static struct omap_hwmod omap3xxx_gpio4_hwmod = {
997 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
998 .mpu_irqs = omap2_gpio4_irqs,
999 .main_clk = "gpio4_ick",
1000 .opt_clks = gpio4_opt_clks,
1001 .opt_clks_cnt = ARRAY_SIZE(gpio4_opt_clks),
1005 .module_bit = OMAP3430_EN_GPIO4_SHIFT,
1006 .module_offs = OMAP3430_PER_MOD,
1008 .idlest_idle_bit = OMAP3430_ST_GPIO4_SHIFT,
1011 .class = &omap3xxx_gpio_hwmod_class,
1012 .dev_attr = &gpio_dev_attr,
1016 static struct omap_hwmod_irq_info omap3xxx_gpio5_irqs[] = {
1017 { .irq = 33 + OMAP_INTC_START, }, /* INT_34XX_GPIO_BANK5 */
1021 static struct omap_hwmod_opt_clk gpio5_opt_clks[] = {
1022 { .role = "dbclk", .clk = "gpio5_dbck", },
1025 static struct omap_hwmod omap3xxx_gpio5_hwmod = {
1027 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
1028 .mpu_irqs = omap3xxx_gpio5_irqs,
1029 .main_clk = "gpio5_ick",
1030 .opt_clks = gpio5_opt_clks,
1031 .opt_clks_cnt = ARRAY_SIZE(gpio5_opt_clks),
1035 .module_bit = OMAP3430_EN_GPIO5_SHIFT,
1036 .module_offs = OMAP3430_PER_MOD,
1038 .idlest_idle_bit = OMAP3430_ST_GPIO5_SHIFT,
1041 .class = &omap3xxx_gpio_hwmod_class,
1042 .dev_attr = &gpio_dev_attr,
1046 static struct omap_hwmod_irq_info omap3xxx_gpio6_irqs[] = {
1047 { .irq = 34 + OMAP_INTC_START, }, /* INT_34XX_GPIO_BANK6 */
1051 static struct omap_hwmod_opt_clk gpio6_opt_clks[] = {
1052 { .role = "dbclk", .clk = "gpio6_dbck", },
1055 static struct omap_hwmod omap3xxx_gpio6_hwmod = {
1057 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
1058 .mpu_irqs = omap3xxx_gpio6_irqs,
1059 .main_clk = "gpio6_ick",
1060 .opt_clks = gpio6_opt_clks,
1061 .opt_clks_cnt = ARRAY_SIZE(gpio6_opt_clks),
1065 .module_bit = OMAP3430_EN_GPIO6_SHIFT,
1066 .module_offs = OMAP3430_PER_MOD,
1068 .idlest_idle_bit = OMAP3430_ST_GPIO6_SHIFT,
1071 .class = &omap3xxx_gpio_hwmod_class,
1072 .dev_attr = &gpio_dev_attr,
1075 /* dma attributes */
1076 static struct omap_dma_dev_attr dma_dev_attr = {
1077 .dev_caps = RESERVE_CHANNEL | DMA_LINKED_LCH | GLOBAL_PRIORITY |
1078 IS_CSSA_32 | IS_CDSA_32 | IS_RW_PRIORITY,
1082 static struct omap_hwmod_class_sysconfig omap3xxx_dma_sysc = {
1084 .sysc_offs = 0x002c,
1085 .syss_offs = 0x0028,
1086 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
1087 SYSC_HAS_MIDLEMODE | SYSC_HAS_CLOCKACTIVITY |
1088 SYSC_HAS_EMUFREE | SYSC_HAS_AUTOIDLE |
1089 SYSS_HAS_RESET_STATUS),
1090 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1091 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
1092 .sysc_fields = &omap_hwmod_sysc_type1,
1095 static struct omap_hwmod_class omap3xxx_dma_hwmod_class = {
1097 .sysc = &omap3xxx_dma_sysc,
1101 static struct omap_hwmod omap3xxx_dma_system_hwmod = {
1103 .class = &omap3xxx_dma_hwmod_class,
1104 .mpu_irqs = omap2_dma_system_irqs,
1105 .main_clk = "core_l3_ick",
1108 .module_offs = CORE_MOD,
1110 .module_bit = OMAP3430_ST_SDMA_SHIFT,
1112 .idlest_idle_bit = OMAP3430_ST_SDMA_SHIFT,
1115 .dev_attr = &dma_dev_attr,
1116 .flags = HWMOD_NO_IDLEST,
1121 * multi channel buffered serial port controller
1124 static struct omap_hwmod_class_sysconfig omap3xxx_mcbsp_sysc = {
1125 .sysc_offs = 0x008c,
1126 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_ENAWAKEUP |
1127 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
1128 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1129 .sysc_fields = &omap_hwmod_sysc_type1,
1133 static struct omap_hwmod_class omap3xxx_mcbsp_hwmod_class = {
1135 .sysc = &omap3xxx_mcbsp_sysc,
1136 .rev = MCBSP_CONFIG_TYPE3,
1139 /* McBSP functional clock mapping */
1140 static struct omap_hwmod_opt_clk mcbsp15_opt_clks[] = {
1141 { .role = "pad_fck", .clk = "mcbsp_clks" },
1142 { .role = "prcm_fck", .clk = "core_96m_fck" },
1145 static struct omap_hwmod_opt_clk mcbsp234_opt_clks[] = {
1146 { .role = "pad_fck", .clk = "mcbsp_clks" },
1147 { .role = "prcm_fck", .clk = "per_96m_fck" },
1151 static struct omap_hwmod_irq_info omap3xxx_mcbsp1_irqs[] = {
1152 { .name = "common", .irq = 16 + OMAP_INTC_START, },
1153 { .name = "tx", .irq = 59 + OMAP_INTC_START, },
1154 { .name = "rx", .irq = 60 + OMAP_INTC_START, },
1158 static struct omap_hwmod omap3xxx_mcbsp1_hwmod = {
1160 .class = &omap3xxx_mcbsp_hwmod_class,
1161 .mpu_irqs = omap3xxx_mcbsp1_irqs,
1162 .sdma_reqs = omap2_mcbsp1_sdma_reqs,
1163 .main_clk = "mcbsp1_fck",
1167 .module_bit = OMAP3430_EN_MCBSP1_SHIFT,
1168 .module_offs = CORE_MOD,
1170 .idlest_idle_bit = OMAP3430_ST_MCBSP1_SHIFT,
1173 .opt_clks = mcbsp15_opt_clks,
1174 .opt_clks_cnt = ARRAY_SIZE(mcbsp15_opt_clks),
1178 static struct omap_hwmod_irq_info omap3xxx_mcbsp2_irqs[] = {
1179 { .name = "common", .irq = 17 + OMAP_INTC_START, },
1180 { .name = "tx", .irq = 62 + OMAP_INTC_START, },
1181 { .name = "rx", .irq = 63 + OMAP_INTC_START, },
1185 static struct omap_mcbsp_dev_attr omap34xx_mcbsp2_dev_attr = {
1186 .sidetone = "mcbsp2_sidetone",
1189 static struct omap_hwmod omap3xxx_mcbsp2_hwmod = {
1191 .class = &omap3xxx_mcbsp_hwmod_class,
1192 .mpu_irqs = omap3xxx_mcbsp2_irqs,
1193 .sdma_reqs = omap2_mcbsp2_sdma_reqs,
1194 .main_clk = "mcbsp2_fck",
1198 .module_bit = OMAP3430_EN_MCBSP2_SHIFT,
1199 .module_offs = OMAP3430_PER_MOD,
1201 .idlest_idle_bit = OMAP3430_ST_MCBSP2_SHIFT,
1204 .opt_clks = mcbsp234_opt_clks,
1205 .opt_clks_cnt = ARRAY_SIZE(mcbsp234_opt_clks),
1206 .dev_attr = &omap34xx_mcbsp2_dev_attr,
1210 static struct omap_hwmod_irq_info omap3xxx_mcbsp3_irqs[] = {
1211 { .name = "common", .irq = 22 + OMAP_INTC_START, },
1212 { .name = "tx", .irq = 89 + OMAP_INTC_START, },
1213 { .name = "rx", .irq = 90 + OMAP_INTC_START, },
1217 static struct omap_mcbsp_dev_attr omap34xx_mcbsp3_dev_attr = {
1218 .sidetone = "mcbsp3_sidetone",
1221 static struct omap_hwmod omap3xxx_mcbsp3_hwmod = {
1223 .class = &omap3xxx_mcbsp_hwmod_class,
1224 .mpu_irqs = omap3xxx_mcbsp3_irqs,
1225 .sdma_reqs = omap2_mcbsp3_sdma_reqs,
1226 .main_clk = "mcbsp3_fck",
1230 .module_bit = OMAP3430_EN_MCBSP3_SHIFT,
1231 .module_offs = OMAP3430_PER_MOD,
1233 .idlest_idle_bit = OMAP3430_ST_MCBSP3_SHIFT,
1236 .opt_clks = mcbsp234_opt_clks,
1237 .opt_clks_cnt = ARRAY_SIZE(mcbsp234_opt_clks),
1238 .dev_attr = &omap34xx_mcbsp3_dev_attr,
1242 static struct omap_hwmod_irq_info omap3xxx_mcbsp4_irqs[] = {
1243 { .name = "common", .irq = 23 + OMAP_INTC_START, },
1244 { .name = "tx", .irq = 54 + OMAP_INTC_START, },
1245 { .name = "rx", .irq = 55 + OMAP_INTC_START, },
1249 static struct omap_hwmod_dma_info omap3xxx_mcbsp4_sdma_chs[] = {
1250 { .name = "rx", .dma_req = 20 },
1251 { .name = "tx", .dma_req = 19 },
1255 static struct omap_hwmod omap3xxx_mcbsp4_hwmod = {
1257 .class = &omap3xxx_mcbsp_hwmod_class,
1258 .mpu_irqs = omap3xxx_mcbsp4_irqs,
1259 .sdma_reqs = omap3xxx_mcbsp4_sdma_chs,
1260 .main_clk = "mcbsp4_fck",
1264 .module_bit = OMAP3430_EN_MCBSP4_SHIFT,
1265 .module_offs = OMAP3430_PER_MOD,
1267 .idlest_idle_bit = OMAP3430_ST_MCBSP4_SHIFT,
1270 .opt_clks = mcbsp234_opt_clks,
1271 .opt_clks_cnt = ARRAY_SIZE(mcbsp234_opt_clks),
1275 static struct omap_hwmod_irq_info omap3xxx_mcbsp5_irqs[] = {
1276 { .name = "common", .irq = 27 + OMAP_INTC_START, },
1277 { .name = "tx", .irq = 81 + OMAP_INTC_START, },
1278 { .name = "rx", .irq = 82 + OMAP_INTC_START, },
1282 static struct omap_hwmod_dma_info omap3xxx_mcbsp5_sdma_chs[] = {
1283 { .name = "rx", .dma_req = 22 },
1284 { .name = "tx", .dma_req = 21 },
1288 static struct omap_hwmod omap3xxx_mcbsp5_hwmod = {
1290 .class = &omap3xxx_mcbsp_hwmod_class,
1291 .mpu_irqs = omap3xxx_mcbsp5_irqs,
1292 .sdma_reqs = omap3xxx_mcbsp5_sdma_chs,
1293 .main_clk = "mcbsp5_fck",
1297 .module_bit = OMAP3430_EN_MCBSP5_SHIFT,
1298 .module_offs = CORE_MOD,
1300 .idlest_idle_bit = OMAP3430_ST_MCBSP5_SHIFT,
1303 .opt_clks = mcbsp15_opt_clks,
1304 .opt_clks_cnt = ARRAY_SIZE(mcbsp15_opt_clks),
1307 /* 'mcbsp sidetone' class */
1308 static struct omap_hwmod_class_sysconfig omap3xxx_mcbsp_sidetone_sysc = {
1309 .sysc_offs = 0x0010,
1310 .sysc_flags = SYSC_HAS_AUTOIDLE,
1311 .sysc_fields = &omap_hwmod_sysc_type1,
1314 static struct omap_hwmod_class omap3xxx_mcbsp_sidetone_hwmod_class = {
1315 .name = "mcbsp_sidetone",
1316 .sysc = &omap3xxx_mcbsp_sidetone_sysc,
1319 /* mcbsp2_sidetone */
1320 static struct omap_hwmod_irq_info omap3xxx_mcbsp2_sidetone_irqs[] = {
1321 { .name = "irq", .irq = 4 + OMAP_INTC_START, },
1325 static struct omap_hwmod omap3xxx_mcbsp2_sidetone_hwmod = {
1326 .name = "mcbsp2_sidetone",
1327 .class = &omap3xxx_mcbsp_sidetone_hwmod_class,
1328 .mpu_irqs = omap3xxx_mcbsp2_sidetone_irqs,
1329 .main_clk = "mcbsp2_fck",
1333 .module_bit = OMAP3430_EN_MCBSP2_SHIFT,
1334 .module_offs = OMAP3430_PER_MOD,
1336 .idlest_idle_bit = OMAP3430_ST_MCBSP2_SHIFT,
1341 /* mcbsp3_sidetone */
1342 static struct omap_hwmod_irq_info omap3xxx_mcbsp3_sidetone_irqs[] = {
1343 { .name = "irq", .irq = 5 + OMAP_INTC_START, },
1347 static struct omap_hwmod omap3xxx_mcbsp3_sidetone_hwmod = {
1348 .name = "mcbsp3_sidetone",
1349 .class = &omap3xxx_mcbsp_sidetone_hwmod_class,
1350 .mpu_irqs = omap3xxx_mcbsp3_sidetone_irqs,
1351 .main_clk = "mcbsp3_fck",
1355 .module_bit = OMAP3430_EN_MCBSP3_SHIFT,
1356 .module_offs = OMAP3430_PER_MOD,
1358 .idlest_idle_bit = OMAP3430_ST_MCBSP3_SHIFT,
1364 static struct omap_hwmod_sysc_fields omap34xx_sr_sysc_fields = {
1368 static struct omap_hwmod_class_sysconfig omap34xx_sr_sysc = {
1370 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_NO_CACHE),
1371 .clockact = CLOCKACT_TEST_ICLK,
1372 .sysc_fields = &omap34xx_sr_sysc_fields,
1375 static struct omap_hwmod_class omap34xx_smartreflex_hwmod_class = {
1376 .name = "smartreflex",
1377 .sysc = &omap34xx_sr_sysc,
1381 static struct omap_hwmod_sysc_fields omap36xx_sr_sysc_fields = {
1386 static struct omap_hwmod_class_sysconfig omap36xx_sr_sysc = {
1388 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1389 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP |
1391 .sysc_fields = &omap36xx_sr_sysc_fields,
1394 static struct omap_hwmod_class omap36xx_smartreflex_hwmod_class = {
1395 .name = "smartreflex",
1396 .sysc = &omap36xx_sr_sysc,
1401 static struct omap_smartreflex_dev_attr sr1_dev_attr = {
1402 .sensor_voltdm_name = "mpu_iva",
1405 static struct omap_hwmod_irq_info omap3_smartreflex_mpu_irqs[] = {
1406 { .irq = 18 + OMAP_INTC_START, },
1410 static struct omap_hwmod omap34xx_sr1_hwmod = {
1411 .name = "smartreflex_mpu_iva",
1412 .class = &omap34xx_smartreflex_hwmod_class,
1413 .main_clk = "sr1_fck",
1417 .module_bit = OMAP3430_EN_SR1_SHIFT,
1418 .module_offs = WKUP_MOD,
1420 .idlest_idle_bit = OMAP3430_EN_SR1_SHIFT,
1423 .dev_attr = &sr1_dev_attr,
1424 .mpu_irqs = omap3_smartreflex_mpu_irqs,
1425 .flags = HWMOD_SET_DEFAULT_CLOCKACT,
1428 static struct omap_hwmod omap36xx_sr1_hwmod = {
1429 .name = "smartreflex_mpu_iva",
1430 .class = &omap36xx_smartreflex_hwmod_class,
1431 .main_clk = "sr1_fck",
1435 .module_bit = OMAP3430_EN_SR1_SHIFT,
1436 .module_offs = WKUP_MOD,
1438 .idlest_idle_bit = OMAP3430_EN_SR1_SHIFT,
1441 .dev_attr = &sr1_dev_attr,
1442 .mpu_irqs = omap3_smartreflex_mpu_irqs,
1446 static struct omap_smartreflex_dev_attr sr2_dev_attr = {
1447 .sensor_voltdm_name = "core",
1450 static struct omap_hwmod_irq_info omap3_smartreflex_core_irqs[] = {
1451 { .irq = 19 + OMAP_INTC_START, },
1455 static struct omap_hwmod omap34xx_sr2_hwmod = {
1456 .name = "smartreflex_core",
1457 .class = &omap34xx_smartreflex_hwmod_class,
1458 .main_clk = "sr2_fck",
1462 .module_bit = OMAP3430_EN_SR2_SHIFT,
1463 .module_offs = WKUP_MOD,
1465 .idlest_idle_bit = OMAP3430_EN_SR2_SHIFT,
1468 .dev_attr = &sr2_dev_attr,
1469 .mpu_irqs = omap3_smartreflex_core_irqs,
1470 .flags = HWMOD_SET_DEFAULT_CLOCKACT,
1473 static struct omap_hwmod omap36xx_sr2_hwmod = {
1474 .name = "smartreflex_core",
1475 .class = &omap36xx_smartreflex_hwmod_class,
1476 .main_clk = "sr2_fck",
1480 .module_bit = OMAP3430_EN_SR2_SHIFT,
1481 .module_offs = WKUP_MOD,
1483 .idlest_idle_bit = OMAP3430_EN_SR2_SHIFT,
1486 .dev_attr = &sr2_dev_attr,
1487 .mpu_irqs = omap3_smartreflex_core_irqs,
1492 * mailbox module allowing communication between the on-chip processors
1493 * using a queued mailbox-interrupt mechanism.
1496 static struct omap_hwmod_class_sysconfig omap3xxx_mailbox_sysc = {
1500 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
1501 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
1502 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1503 .sysc_fields = &omap_hwmod_sysc_type1,
1506 static struct omap_hwmod_class omap3xxx_mailbox_hwmod_class = {
1508 .sysc = &omap3xxx_mailbox_sysc,
1511 static struct omap_hwmod_irq_info omap3xxx_mailbox_irqs[] = {
1512 { .irq = 26 + OMAP_INTC_START, },
1516 static struct omap_hwmod omap3xxx_mailbox_hwmod = {
1518 .class = &omap3xxx_mailbox_hwmod_class,
1519 .mpu_irqs = omap3xxx_mailbox_irqs,
1520 .main_clk = "mailboxes_ick",
1524 .module_bit = OMAP3430_EN_MAILBOXES_SHIFT,
1525 .module_offs = CORE_MOD,
1527 .idlest_idle_bit = OMAP3430_ST_MAILBOXES_SHIFT,
1534 * multichannel serial port interface (mcspi) / master/slave synchronous serial
1538 static struct omap_hwmod_class_sysconfig omap34xx_mcspi_sysc = {
1540 .sysc_offs = 0x0010,
1541 .syss_offs = 0x0014,
1542 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
1543 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
1544 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS),
1545 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1546 .sysc_fields = &omap_hwmod_sysc_type1,
1549 static struct omap_hwmod_class omap34xx_mcspi_class = {
1551 .sysc = &omap34xx_mcspi_sysc,
1552 .rev = OMAP3_MCSPI_REV,
1556 static struct omap2_mcspi_dev_attr omap_mcspi1_dev_attr = {
1557 .num_chipselect = 4,
1560 static struct omap_hwmod omap34xx_mcspi1 = {
1562 .mpu_irqs = omap2_mcspi1_mpu_irqs,
1563 .sdma_reqs = omap2_mcspi1_sdma_reqs,
1564 .main_clk = "mcspi1_fck",
1567 .module_offs = CORE_MOD,
1569 .module_bit = OMAP3430_EN_MCSPI1_SHIFT,
1571 .idlest_idle_bit = OMAP3430_ST_MCSPI1_SHIFT,
1574 .class = &omap34xx_mcspi_class,
1575 .dev_attr = &omap_mcspi1_dev_attr,
1579 static struct omap2_mcspi_dev_attr omap_mcspi2_dev_attr = {
1580 .num_chipselect = 2,
1583 static struct omap_hwmod omap34xx_mcspi2 = {
1585 .mpu_irqs = omap2_mcspi2_mpu_irqs,
1586 .sdma_reqs = omap2_mcspi2_sdma_reqs,
1587 .main_clk = "mcspi2_fck",
1590 .module_offs = CORE_MOD,
1592 .module_bit = OMAP3430_EN_MCSPI2_SHIFT,
1594 .idlest_idle_bit = OMAP3430_ST_MCSPI2_SHIFT,
1597 .class = &omap34xx_mcspi_class,
1598 .dev_attr = &omap_mcspi2_dev_attr,
1602 static struct omap_hwmod_irq_info omap34xx_mcspi3_mpu_irqs[] = {
1603 { .name = "irq", .irq = 91 + OMAP_INTC_START, }, /* 91 */
1607 static struct omap_hwmod_dma_info omap34xx_mcspi3_sdma_reqs[] = {
1608 { .name = "tx0", .dma_req = 15 },
1609 { .name = "rx0", .dma_req = 16 },
1610 { .name = "tx1", .dma_req = 23 },
1611 { .name = "rx1", .dma_req = 24 },
1615 static struct omap2_mcspi_dev_attr omap_mcspi3_dev_attr = {
1616 .num_chipselect = 2,
1619 static struct omap_hwmod omap34xx_mcspi3 = {
1621 .mpu_irqs = omap34xx_mcspi3_mpu_irqs,
1622 .sdma_reqs = omap34xx_mcspi3_sdma_reqs,
1623 .main_clk = "mcspi3_fck",
1626 .module_offs = CORE_MOD,
1628 .module_bit = OMAP3430_EN_MCSPI3_SHIFT,
1630 .idlest_idle_bit = OMAP3430_ST_MCSPI3_SHIFT,
1633 .class = &omap34xx_mcspi_class,
1634 .dev_attr = &omap_mcspi3_dev_attr,
1638 static struct omap_hwmod_irq_info omap34xx_mcspi4_mpu_irqs[] = {
1639 { .name = "irq", .irq = 48 + OMAP_INTC_START, },
1643 static struct omap_hwmod_dma_info omap34xx_mcspi4_sdma_reqs[] = {
1644 { .name = "tx0", .dma_req = 70 }, /* DMA_SPI4_TX0 */
1645 { .name = "rx0", .dma_req = 71 }, /* DMA_SPI4_RX0 */
1649 static struct omap2_mcspi_dev_attr omap_mcspi4_dev_attr = {
1650 .num_chipselect = 1,
1653 static struct omap_hwmod omap34xx_mcspi4 = {
1655 .mpu_irqs = omap34xx_mcspi4_mpu_irqs,
1656 .sdma_reqs = omap34xx_mcspi4_sdma_reqs,
1657 .main_clk = "mcspi4_fck",
1660 .module_offs = CORE_MOD,
1662 .module_bit = OMAP3430_EN_MCSPI4_SHIFT,
1664 .idlest_idle_bit = OMAP3430_ST_MCSPI4_SHIFT,
1667 .class = &omap34xx_mcspi_class,
1668 .dev_attr = &omap_mcspi4_dev_attr,
1672 static struct omap_hwmod_class_sysconfig omap3xxx_usbhsotg_sysc = {
1674 .sysc_offs = 0x0404,
1675 .syss_offs = 0x0408,
1676 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE|
1677 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
1679 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1680 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
1681 .sysc_fields = &omap_hwmod_sysc_type1,
1684 static struct omap_hwmod_class usbotg_class = {
1686 .sysc = &omap3xxx_usbhsotg_sysc,
1690 static struct omap_hwmod_irq_info omap3xxx_usbhsotg_mpu_irqs[] = {
1692 { .name = "mc", .irq = 92 + OMAP_INTC_START, },
1693 { .name = "dma", .irq = 93 + OMAP_INTC_START, },
1697 static struct omap_hwmod omap3xxx_usbhsotg_hwmod = {
1698 .name = "usb_otg_hs",
1699 .mpu_irqs = omap3xxx_usbhsotg_mpu_irqs,
1700 .main_clk = "hsotgusb_ick",
1704 .module_bit = OMAP3430_EN_HSOTGUSB_SHIFT,
1705 .module_offs = CORE_MOD,
1707 .idlest_idle_bit = OMAP3430ES2_ST_HSOTGUSB_IDLE_SHIFT,
1708 .idlest_stdby_bit = OMAP3430ES2_ST_HSOTGUSB_STDBY_SHIFT
1711 .class = &usbotg_class,
1714 * Erratum ID: i479 idle_req / idle_ack mechanism potentially
1715 * broken when autoidle is enabled
1716 * workaround is to disable the autoidle bit at module level.
1718 .flags = HWMOD_NO_OCP_AUTOIDLE | HWMOD_SWSUP_SIDLE
1719 | HWMOD_SWSUP_MSTANDBY,
1723 static struct omap_hwmod_irq_info am35xx_usbhsotg_mpu_irqs[] = {
1724 { .name = "mc", .irq = 71 + OMAP_INTC_START, },
1728 static struct omap_hwmod_class am35xx_usbotg_class = {
1729 .name = "am35xx_usbotg",
1732 static struct omap_hwmod am35xx_usbhsotg_hwmod = {
1733 .name = "am35x_otg_hs",
1734 .mpu_irqs = am35xx_usbhsotg_mpu_irqs,
1735 .main_clk = "hsotgusb_fck",
1736 .class = &am35xx_usbotg_class,
1737 .flags = HWMOD_NO_IDLEST,
1740 /* MMC/SD/SDIO common */
1741 static struct omap_hwmod_class_sysconfig omap34xx_mmc_sysc = {
1745 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
1746 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
1747 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS),
1748 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1749 .sysc_fields = &omap_hwmod_sysc_type1,
1752 static struct omap_hwmod_class omap34xx_mmc_class = {
1754 .sysc = &omap34xx_mmc_sysc,
1759 static struct omap_hwmod_irq_info omap34xx_mmc1_mpu_irqs[] = {
1760 { .irq = 83 + OMAP_INTC_START, },
1764 static struct omap_hwmod_dma_info omap34xx_mmc1_sdma_reqs[] = {
1765 { .name = "tx", .dma_req = 61, },
1766 { .name = "rx", .dma_req = 62, },
1770 static struct omap_hwmod_opt_clk omap34xx_mmc1_opt_clks[] = {
1771 { .role = "dbck", .clk = "omap_32k_fck", },
1774 static struct omap_mmc_dev_attr mmc1_dev_attr = {
1775 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
1778 /* See 35xx errata 2.1.1.128 in SPRZ278F */
1779 static struct omap_mmc_dev_attr mmc1_pre_es3_dev_attr = {
1780 .flags = (OMAP_HSMMC_SUPPORTS_DUAL_VOLT |
1781 OMAP_HSMMC_BROKEN_MULTIBLOCK_READ),
1784 static struct omap_hwmod omap3xxx_pre_es3_mmc1_hwmod = {
1786 .mpu_irqs = omap34xx_mmc1_mpu_irqs,
1787 .sdma_reqs = omap34xx_mmc1_sdma_reqs,
1788 .opt_clks = omap34xx_mmc1_opt_clks,
1789 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc1_opt_clks),
1790 .main_clk = "mmchs1_fck",
1793 .module_offs = CORE_MOD,
1795 .module_bit = OMAP3430_EN_MMC1_SHIFT,
1797 .idlest_idle_bit = OMAP3430_ST_MMC1_SHIFT,
1800 .dev_attr = &mmc1_pre_es3_dev_attr,
1801 .class = &omap34xx_mmc_class,
1804 static struct omap_hwmod omap3xxx_es3plus_mmc1_hwmod = {
1806 .mpu_irqs = omap34xx_mmc1_mpu_irqs,
1807 .sdma_reqs = omap34xx_mmc1_sdma_reqs,
1808 .opt_clks = omap34xx_mmc1_opt_clks,
1809 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc1_opt_clks),
1810 .main_clk = "mmchs1_fck",
1813 .module_offs = CORE_MOD,
1815 .module_bit = OMAP3430_EN_MMC1_SHIFT,
1817 .idlest_idle_bit = OMAP3430_ST_MMC1_SHIFT,
1820 .dev_attr = &mmc1_dev_attr,
1821 .class = &omap34xx_mmc_class,
1826 static struct omap_hwmod_irq_info omap34xx_mmc2_mpu_irqs[] = {
1827 { .irq = 86 + OMAP_INTC_START, },
1831 static struct omap_hwmod_dma_info omap34xx_mmc2_sdma_reqs[] = {
1832 { .name = "tx", .dma_req = 47, },
1833 { .name = "rx", .dma_req = 48, },
1837 static struct omap_hwmod_opt_clk omap34xx_mmc2_opt_clks[] = {
1838 { .role = "dbck", .clk = "omap_32k_fck", },
1841 /* See 35xx errata 2.1.1.128 in SPRZ278F */
1842 static struct omap_mmc_dev_attr mmc2_pre_es3_dev_attr = {
1843 .flags = OMAP_HSMMC_BROKEN_MULTIBLOCK_READ,
1846 static struct omap_hwmod omap3xxx_pre_es3_mmc2_hwmod = {
1848 .mpu_irqs = omap34xx_mmc2_mpu_irqs,
1849 .sdma_reqs = omap34xx_mmc2_sdma_reqs,
1850 .opt_clks = omap34xx_mmc2_opt_clks,
1851 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc2_opt_clks),
1852 .main_clk = "mmchs2_fck",
1855 .module_offs = CORE_MOD,
1857 .module_bit = OMAP3430_EN_MMC2_SHIFT,
1859 .idlest_idle_bit = OMAP3430_ST_MMC2_SHIFT,
1862 .dev_attr = &mmc2_pre_es3_dev_attr,
1863 .class = &omap34xx_mmc_class,
1866 static struct omap_hwmod omap3xxx_es3plus_mmc2_hwmod = {
1868 .mpu_irqs = omap34xx_mmc2_mpu_irqs,
1869 .sdma_reqs = omap34xx_mmc2_sdma_reqs,
1870 .opt_clks = omap34xx_mmc2_opt_clks,
1871 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc2_opt_clks),
1872 .main_clk = "mmchs2_fck",
1875 .module_offs = CORE_MOD,
1877 .module_bit = OMAP3430_EN_MMC2_SHIFT,
1879 .idlest_idle_bit = OMAP3430_ST_MMC2_SHIFT,
1882 .class = &omap34xx_mmc_class,
1887 static struct omap_hwmod_irq_info omap34xx_mmc3_mpu_irqs[] = {
1888 { .irq = 94 + OMAP_INTC_START, },
1892 static struct omap_hwmod_dma_info omap34xx_mmc3_sdma_reqs[] = {
1893 { .name = "tx", .dma_req = 77, },
1894 { .name = "rx", .dma_req = 78, },
1898 static struct omap_hwmod_opt_clk omap34xx_mmc3_opt_clks[] = {
1899 { .role = "dbck", .clk = "omap_32k_fck", },
1902 static struct omap_hwmod omap3xxx_mmc3_hwmod = {
1904 .mpu_irqs = omap34xx_mmc3_mpu_irqs,
1905 .sdma_reqs = omap34xx_mmc3_sdma_reqs,
1906 .opt_clks = omap34xx_mmc3_opt_clks,
1907 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc3_opt_clks),
1908 .main_clk = "mmchs3_fck",
1912 .module_bit = OMAP3430_EN_MMC3_SHIFT,
1914 .idlest_idle_bit = OMAP3430_ST_MMC3_SHIFT,
1917 .class = &omap34xx_mmc_class,
1921 * 'usb_host_hs' class
1922 * high-speed multi-port usb host controller
1925 static struct omap_hwmod_class_sysconfig omap3xxx_usb_host_hs_sysc = {
1927 .sysc_offs = 0x0010,
1928 .syss_offs = 0x0014,
1929 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_CLOCKACTIVITY |
1930 SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP |
1931 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
1932 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1933 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
1934 .sysc_fields = &omap_hwmod_sysc_type1,
1937 static struct omap_hwmod_class omap3xxx_usb_host_hs_hwmod_class = {
1938 .name = "usb_host_hs",
1939 .sysc = &omap3xxx_usb_host_hs_sysc,
1942 static struct omap_hwmod_opt_clk omap3xxx_usb_host_hs_opt_clks[] = {
1943 { .role = "ehci_logic_fck", .clk = "usbhost_120m_fck", },
1946 static struct omap_hwmod_irq_info omap3xxx_usb_host_hs_irqs[] = {
1947 { .name = "ohci-irq", .irq = 76 + OMAP_INTC_START, },
1948 { .name = "ehci-irq", .irq = 77 + OMAP_INTC_START, },
1952 static struct omap_hwmod omap3xxx_usb_host_hs_hwmod = {
1953 .name = "usb_host_hs",
1954 .class = &omap3xxx_usb_host_hs_hwmod_class,
1955 .clkdm_name = "l3_init_clkdm",
1956 .mpu_irqs = omap3xxx_usb_host_hs_irqs,
1957 .main_clk = "usbhost_48m_fck",
1960 .module_offs = OMAP3430ES2_USBHOST_MOD,
1962 .module_bit = OMAP3430ES2_EN_USBHOST1_SHIFT,
1964 .idlest_idle_bit = OMAP3430ES2_ST_USBHOST_IDLE_SHIFT,
1965 .idlest_stdby_bit = OMAP3430ES2_ST_USBHOST_STDBY_SHIFT,
1968 .opt_clks = omap3xxx_usb_host_hs_opt_clks,
1969 .opt_clks_cnt = ARRAY_SIZE(omap3xxx_usb_host_hs_opt_clks),
1972 * Errata: USBHOST Configured In Smart-Idle Can Lead To a Deadlock
1976 * In the following configuration :
1977 * - USBHOST module is set to smart-idle mode
1978 * - PRCM asserts idle_req to the USBHOST module ( This typically
1979 * happens when the system is going to a low power mode : all ports
1980 * have been suspended, the master part of the USBHOST module has
1981 * entered the standby state, and SW has cut the functional clocks)
1982 * - an USBHOST interrupt occurs before the module is able to answer
1983 * idle_ack, typically a remote wakeup IRQ.
1984 * Then the USB HOST module will enter a deadlock situation where it
1985 * is no more accessible nor functional.
1988 * Don't use smart idle; use only force idle, hence HWMOD_SWSUP_SIDLE
1992 * Errata: USB host EHCI may stall when entering smart-standby mode
1996 * When the USBHOST module is set to smart-standby mode, and when it is
1997 * ready to enter the standby state (i.e. all ports are suspended and
1998 * all attached devices are in suspend mode), then it can wrongly assert
1999 * the Mstandby signal too early while there are still some residual OCP
2000 * transactions ongoing. If this condition occurs, the internal state
2001 * machine may go to an undefined state and the USB link may be stuck
2002 * upon the next resume.
2005 * Don't use smart standby; use only force standby,
2006 * hence HWMOD_SWSUP_MSTANDBY
2010 * During system boot; If the hwmod framework resets the module
2011 * the module will have smart idle settings; which can lead to deadlock
2012 * (above Errata Id:i660); so, dont reset the module during boot;
2013 * Use HWMOD_INIT_NO_RESET.
2016 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
2017 HWMOD_INIT_NO_RESET,
2021 * 'usb_tll_hs' class
2022 * usb_tll_hs module is the adapter on the usb_host_hs ports
2024 static struct omap_hwmod_class_sysconfig omap3xxx_usb_tll_hs_sysc = {
2026 .sysc_offs = 0x0010,
2027 .syss_offs = 0x0014,
2028 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
2029 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
2031 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2032 .sysc_fields = &omap_hwmod_sysc_type1,
2035 static struct omap_hwmod_class omap3xxx_usb_tll_hs_hwmod_class = {
2036 .name = "usb_tll_hs",
2037 .sysc = &omap3xxx_usb_tll_hs_sysc,
2040 static struct omap_hwmod_irq_info omap3xxx_usb_tll_hs_irqs[] = {
2041 { .name = "tll-irq", .irq = 78 + OMAP_INTC_START, },
2045 static struct omap_hwmod omap3xxx_usb_tll_hs_hwmod = {
2046 .name = "usb_tll_hs",
2047 .class = &omap3xxx_usb_tll_hs_hwmod_class,
2048 .clkdm_name = "l3_init_clkdm",
2049 .mpu_irqs = omap3xxx_usb_tll_hs_irqs,
2050 .main_clk = "usbtll_fck",
2053 .module_offs = CORE_MOD,
2055 .module_bit = OMAP3430ES2_EN_USBTLL_SHIFT,
2057 .idlest_idle_bit = OMAP3430ES2_ST_USBTLL_SHIFT,
2062 static struct omap_hwmod omap3xxx_hdq1w_hwmod = {
2064 .mpu_irqs = omap2_hdq1w_mpu_irqs,
2065 .main_clk = "hdq_fck",
2068 .module_offs = CORE_MOD,
2070 .module_bit = OMAP3430_EN_HDQ_SHIFT,
2072 .idlest_idle_bit = OMAP3430_ST_HDQ_SHIFT,
2075 .class = &omap2_hdq1w_class,
2079 static struct omap_hwmod_rst_info omap3xxx_sad2d_resets[] = {
2080 { .name = "rst_modem_pwron_sw", .rst_shift = 0 },
2081 { .name = "rst_modem_sw", .rst_shift = 1 },
2084 static struct omap_hwmod_class omap3xxx_sad2d_class = {
2088 static struct omap_hwmod omap3xxx_sad2d_hwmod = {
2090 .rst_lines = omap3xxx_sad2d_resets,
2091 .rst_lines_cnt = ARRAY_SIZE(omap3xxx_sad2d_resets),
2092 .main_clk = "sad2d_ick",
2095 .module_offs = CORE_MOD,
2097 .module_bit = OMAP3430_EN_SAD2D_SHIFT,
2099 .idlest_idle_bit = OMAP3430_ST_SAD2D_SHIFT,
2102 .class = &omap3xxx_sad2d_class,
2106 * '32K sync counter' class
2107 * 32-bit ordinary counter, clocked by the falling edge of the 32 khz clock
2109 static struct omap_hwmod_class_sysconfig omap3xxx_counter_sysc = {
2111 .sysc_offs = 0x0004,
2112 .sysc_flags = SYSC_HAS_SIDLEMODE,
2113 .idlemodes = (SIDLE_FORCE | SIDLE_NO),
2114 .sysc_fields = &omap_hwmod_sysc_type1,
2117 static struct omap_hwmod_class omap3xxx_counter_hwmod_class = {
2119 .sysc = &omap3xxx_counter_sysc,
2122 static struct omap_hwmod omap3xxx_counter_32k_hwmod = {
2123 .name = "counter_32k",
2124 .class = &omap3xxx_counter_hwmod_class,
2125 .clkdm_name = "wkup_clkdm",
2126 .flags = HWMOD_SWSUP_SIDLE,
2127 .main_clk = "wkup_32k_fck",
2130 .module_offs = WKUP_MOD,
2132 .module_bit = OMAP3430_ST_32KSYNC_SHIFT,
2134 .idlest_idle_bit = OMAP3430_ST_32KSYNC_SHIFT,
2141 * general purpose memory controller
2144 static struct omap_hwmod_class_sysconfig omap3xxx_gpmc_sysc = {
2146 .sysc_offs = 0x0010,
2147 .syss_offs = 0x0014,
2148 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
2149 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
2150 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2151 .sysc_fields = &omap_hwmod_sysc_type1,
2154 static struct omap_hwmod_class omap3xxx_gpmc_hwmod_class = {
2156 .sysc = &omap3xxx_gpmc_sysc,
2159 static struct omap_hwmod_irq_info omap3xxx_gpmc_irqs[] = {
2164 static struct omap_hwmod omap3xxx_gpmc_hwmod = {
2166 .class = &omap3xxx_gpmc_hwmod_class,
2167 .clkdm_name = "core_l3_clkdm",
2168 .mpu_irqs = omap3xxx_gpmc_irqs,
2169 .main_clk = "gpmc_fck",
2171 * XXX HWMOD_INIT_NO_RESET should not be needed for this IP
2172 * block. It is not being added due to any known bugs with
2173 * resetting the GPMC IP block, but rather because any timings
2174 * set by the bootloader are not being correctly programmed by
2175 * the kernel from the board file or DT data.
2176 * HWMOD_INIT_NO_RESET should be removed ASAP.
2178 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET |
2186 /* L3 -> L4_CORE interface */
2187 static struct omap_hwmod_ocp_if omap3xxx_l3_main__l4_core = {
2188 .master = &omap3xxx_l3_main_hwmod,
2189 .slave = &omap3xxx_l4_core_hwmod,
2190 .user = OCP_USER_MPU | OCP_USER_SDMA,
2193 /* L3 -> L4_PER interface */
2194 static struct omap_hwmod_ocp_if omap3xxx_l3_main__l4_per = {
2195 .master = &omap3xxx_l3_main_hwmod,
2196 .slave = &omap3xxx_l4_per_hwmod,
2197 .user = OCP_USER_MPU | OCP_USER_SDMA,
2200 static struct omap_hwmod_addr_space omap3xxx_l3_main_addrs[] = {
2202 .pa_start = 0x68000000,
2203 .pa_end = 0x6800ffff,
2204 .flags = ADDR_TYPE_RT,
2209 /* MPU -> L3 interface */
2210 static struct omap_hwmod_ocp_if omap3xxx_mpu__l3_main = {
2211 .master = &omap3xxx_mpu_hwmod,
2212 .slave = &omap3xxx_l3_main_hwmod,
2213 .addr = omap3xxx_l3_main_addrs,
2214 .user = OCP_USER_MPU,
2217 static struct omap_hwmod_addr_space omap3xxx_l4_emu_addrs[] = {
2219 .pa_start = 0x54000000,
2220 .pa_end = 0x547fffff,
2221 .flags = ADDR_TYPE_RT,
2227 static struct omap_hwmod_ocp_if omap3xxx_l3_main__l4_debugss = {
2228 .master = &omap3xxx_l3_main_hwmod,
2229 .slave = &omap3xxx_debugss_hwmod,
2230 .addr = omap3xxx_l4_emu_addrs,
2231 .user = OCP_USER_MPU,
2235 static struct omap_hwmod_ocp_if omap3430es1_dss__l3 = {
2236 .master = &omap3430es1_dss_core_hwmod,
2237 .slave = &omap3xxx_l3_main_hwmod,
2238 .user = OCP_USER_MPU | OCP_USER_SDMA,
2241 static struct omap_hwmod_ocp_if omap3xxx_dss__l3 = {
2242 .master = &omap3xxx_dss_core_hwmod,
2243 .slave = &omap3xxx_l3_main_hwmod,
2246 .l3_perm_bit = OMAP3_L3_CORE_FW_INIT_ID_DSS,
2247 .flags = OMAP_FIREWALL_L3,
2250 .user = OCP_USER_MPU | OCP_USER_SDMA,
2253 /* l3_core -> usbhsotg interface */
2254 static struct omap_hwmod_ocp_if omap3xxx_usbhsotg__l3 = {
2255 .master = &omap3xxx_usbhsotg_hwmod,
2256 .slave = &omap3xxx_l3_main_hwmod,
2257 .clk = "core_l3_ick",
2258 .user = OCP_USER_MPU,
2261 /* l3_core -> am35xx_usbhsotg interface */
2262 static struct omap_hwmod_ocp_if am35xx_usbhsotg__l3 = {
2263 .master = &am35xx_usbhsotg_hwmod,
2264 .slave = &omap3xxx_l3_main_hwmod,
2265 .clk = "hsotgusb_ick",
2266 .user = OCP_USER_MPU,
2269 /* l3_core -> sad2d interface */
2270 static struct omap_hwmod_ocp_if omap3xxx_sad2d__l3 = {
2271 .master = &omap3xxx_sad2d_hwmod,
2272 .slave = &omap3xxx_l3_main_hwmod,
2273 .clk = "core_l3_ick",
2274 .user = OCP_USER_MPU,
2277 /* L4_CORE -> L4_WKUP interface */
2278 static struct omap_hwmod_ocp_if omap3xxx_l4_core__l4_wkup = {
2279 .master = &omap3xxx_l4_core_hwmod,
2280 .slave = &omap3xxx_l4_wkup_hwmod,
2281 .user = OCP_USER_MPU | OCP_USER_SDMA,
2284 /* L4 CORE -> MMC1 interface */
2285 static struct omap_hwmod_ocp_if omap3xxx_l4_core__pre_es3_mmc1 = {
2286 .master = &omap3xxx_l4_core_hwmod,
2287 .slave = &omap3xxx_pre_es3_mmc1_hwmod,
2288 .clk = "mmchs1_ick",
2289 .addr = omap2430_mmc1_addr_space,
2290 .user = OCP_USER_MPU | OCP_USER_SDMA,
2291 .flags = OMAP_FIREWALL_L4
2294 static struct omap_hwmod_ocp_if omap3xxx_l4_core__es3plus_mmc1 = {
2295 .master = &omap3xxx_l4_core_hwmod,
2296 .slave = &omap3xxx_es3plus_mmc1_hwmod,
2297 .clk = "mmchs1_ick",
2298 .addr = omap2430_mmc1_addr_space,
2299 .user = OCP_USER_MPU | OCP_USER_SDMA,
2300 .flags = OMAP_FIREWALL_L4
2303 /* L4 CORE -> MMC2 interface */
2304 static struct omap_hwmod_ocp_if omap3xxx_l4_core__pre_es3_mmc2 = {
2305 .master = &omap3xxx_l4_core_hwmod,
2306 .slave = &omap3xxx_pre_es3_mmc2_hwmod,
2307 .clk = "mmchs2_ick",
2308 .addr = omap2430_mmc2_addr_space,
2309 .user = OCP_USER_MPU | OCP_USER_SDMA,
2310 .flags = OMAP_FIREWALL_L4
2313 static struct omap_hwmod_ocp_if omap3xxx_l4_core__es3plus_mmc2 = {
2314 .master = &omap3xxx_l4_core_hwmod,
2315 .slave = &omap3xxx_es3plus_mmc2_hwmod,
2316 .clk = "mmchs2_ick",
2317 .addr = omap2430_mmc2_addr_space,
2318 .user = OCP_USER_MPU | OCP_USER_SDMA,
2319 .flags = OMAP_FIREWALL_L4
2322 /* L4 CORE -> MMC3 interface */
2323 static struct omap_hwmod_addr_space omap3xxx_mmc3_addr_space[] = {
2325 .pa_start = 0x480ad000,
2326 .pa_end = 0x480ad1ff,
2327 .flags = ADDR_TYPE_RT,
2332 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mmc3 = {
2333 .master = &omap3xxx_l4_core_hwmod,
2334 .slave = &omap3xxx_mmc3_hwmod,
2335 .clk = "mmchs3_ick",
2336 .addr = omap3xxx_mmc3_addr_space,
2337 .user = OCP_USER_MPU | OCP_USER_SDMA,
2338 .flags = OMAP_FIREWALL_L4
2341 /* L4 CORE -> UART1 interface */
2342 static struct omap_hwmod_addr_space omap3xxx_uart1_addr_space[] = {
2344 .pa_start = OMAP3_UART1_BASE,
2345 .pa_end = OMAP3_UART1_BASE + SZ_8K - 1,
2346 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
2351 static struct omap_hwmod_ocp_if omap3_l4_core__uart1 = {
2352 .master = &omap3xxx_l4_core_hwmod,
2353 .slave = &omap3xxx_uart1_hwmod,
2355 .addr = omap3xxx_uart1_addr_space,
2356 .user = OCP_USER_MPU | OCP_USER_SDMA,
2359 /* L4 CORE -> UART2 interface */
2360 static struct omap_hwmod_addr_space omap3xxx_uart2_addr_space[] = {
2362 .pa_start = OMAP3_UART2_BASE,
2363 .pa_end = OMAP3_UART2_BASE + SZ_1K - 1,
2364 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
2369 static struct omap_hwmod_ocp_if omap3_l4_core__uart2 = {
2370 .master = &omap3xxx_l4_core_hwmod,
2371 .slave = &omap3xxx_uart2_hwmod,
2373 .addr = omap3xxx_uart2_addr_space,
2374 .user = OCP_USER_MPU | OCP_USER_SDMA,
2377 /* L4 PER -> UART3 interface */
2378 static struct omap_hwmod_addr_space omap3xxx_uart3_addr_space[] = {
2380 .pa_start = OMAP3_UART3_BASE,
2381 .pa_end = OMAP3_UART3_BASE + SZ_1K - 1,
2382 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
2387 static struct omap_hwmod_ocp_if omap3_l4_per__uart3 = {
2388 .master = &omap3xxx_l4_per_hwmod,
2389 .slave = &omap3xxx_uart3_hwmod,
2391 .addr = omap3xxx_uart3_addr_space,
2392 .user = OCP_USER_MPU | OCP_USER_SDMA,
2395 /* L4 PER -> UART4 interface */
2396 static struct omap_hwmod_addr_space omap36xx_uart4_addr_space[] = {
2398 .pa_start = OMAP3_UART4_BASE,
2399 .pa_end = OMAP3_UART4_BASE + SZ_1K - 1,
2400 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
2405 static struct omap_hwmod_ocp_if omap36xx_l4_per__uart4 = {
2406 .master = &omap3xxx_l4_per_hwmod,
2407 .slave = &omap36xx_uart4_hwmod,
2409 .addr = omap36xx_uart4_addr_space,
2410 .user = OCP_USER_MPU | OCP_USER_SDMA,
2413 /* AM35xx: L4 CORE -> UART4 interface */
2414 static struct omap_hwmod_addr_space am35xx_uart4_addr_space[] = {
2416 .pa_start = OMAP3_UART4_AM35XX_BASE,
2417 .pa_end = OMAP3_UART4_AM35XX_BASE + SZ_1K - 1,
2418 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
2423 static struct omap_hwmod_ocp_if am35xx_l4_core__uart4 = {
2424 .master = &omap3xxx_l4_core_hwmod,
2425 .slave = &am35xx_uart4_hwmod,
2427 .addr = am35xx_uart4_addr_space,
2428 .user = OCP_USER_MPU | OCP_USER_SDMA,
2431 /* L4 CORE -> I2C1 interface */
2432 static struct omap_hwmod_ocp_if omap3_l4_core__i2c1 = {
2433 .master = &omap3xxx_l4_core_hwmod,
2434 .slave = &omap3xxx_i2c1_hwmod,
2436 .addr = omap2_i2c1_addr_space,
2439 .l4_fw_region = OMAP3_L4_CORE_FW_I2C1_REGION,
2441 .flags = OMAP_FIREWALL_L4,
2444 .user = OCP_USER_MPU | OCP_USER_SDMA,
2447 /* L4 CORE -> I2C2 interface */
2448 static struct omap_hwmod_ocp_if omap3_l4_core__i2c2 = {
2449 .master = &omap3xxx_l4_core_hwmod,
2450 .slave = &omap3xxx_i2c2_hwmod,
2452 .addr = omap2_i2c2_addr_space,
2455 .l4_fw_region = OMAP3_L4_CORE_FW_I2C2_REGION,
2457 .flags = OMAP_FIREWALL_L4,
2460 .user = OCP_USER_MPU | OCP_USER_SDMA,
2463 /* L4 CORE -> I2C3 interface */
2464 static struct omap_hwmod_addr_space omap3xxx_i2c3_addr_space[] = {
2466 .pa_start = 0x48060000,
2467 .pa_end = 0x48060000 + SZ_128 - 1,
2468 .flags = ADDR_TYPE_RT,
2473 static struct omap_hwmod_ocp_if omap3_l4_core__i2c3 = {
2474 .master = &omap3xxx_l4_core_hwmod,
2475 .slave = &omap3xxx_i2c3_hwmod,
2477 .addr = omap3xxx_i2c3_addr_space,
2480 .l4_fw_region = OMAP3_L4_CORE_FW_I2C3_REGION,
2482 .flags = OMAP_FIREWALL_L4,
2485 .user = OCP_USER_MPU | OCP_USER_SDMA,
2488 /* L4 CORE -> SR1 interface */
2489 static struct omap_hwmod_addr_space omap3_sr1_addr_space[] = {
2491 .pa_start = OMAP34XX_SR1_BASE,
2492 .pa_end = OMAP34XX_SR1_BASE + SZ_1K - 1,
2493 .flags = ADDR_TYPE_RT,
2498 static struct omap_hwmod_ocp_if omap34xx_l4_core__sr1 = {
2499 .master = &omap3xxx_l4_core_hwmod,
2500 .slave = &omap34xx_sr1_hwmod,
2502 .addr = omap3_sr1_addr_space,
2503 .user = OCP_USER_MPU,
2506 static struct omap_hwmod_ocp_if omap36xx_l4_core__sr1 = {
2507 .master = &omap3xxx_l4_core_hwmod,
2508 .slave = &omap36xx_sr1_hwmod,
2510 .addr = omap3_sr1_addr_space,
2511 .user = OCP_USER_MPU,
2514 /* L4 CORE -> SR1 interface */
2515 static struct omap_hwmod_addr_space omap3_sr2_addr_space[] = {
2517 .pa_start = OMAP34XX_SR2_BASE,
2518 .pa_end = OMAP34XX_SR2_BASE + SZ_1K - 1,
2519 .flags = ADDR_TYPE_RT,
2524 static struct omap_hwmod_ocp_if omap34xx_l4_core__sr2 = {
2525 .master = &omap3xxx_l4_core_hwmod,
2526 .slave = &omap34xx_sr2_hwmod,
2528 .addr = omap3_sr2_addr_space,
2529 .user = OCP_USER_MPU,
2532 static struct omap_hwmod_ocp_if omap36xx_l4_core__sr2 = {
2533 .master = &omap3xxx_l4_core_hwmod,
2534 .slave = &omap36xx_sr2_hwmod,
2536 .addr = omap3_sr2_addr_space,
2537 .user = OCP_USER_MPU,
2540 static struct omap_hwmod_addr_space omap3xxx_usbhsotg_addrs[] = {
2542 .pa_start = OMAP34XX_HSUSB_OTG_BASE,
2543 .pa_end = OMAP34XX_HSUSB_OTG_BASE + SZ_4K - 1,
2544 .flags = ADDR_TYPE_RT
2549 /* l4_core -> usbhsotg */
2550 static struct omap_hwmod_ocp_if omap3xxx_l4_core__usbhsotg = {
2551 .master = &omap3xxx_l4_core_hwmod,
2552 .slave = &omap3xxx_usbhsotg_hwmod,
2554 .addr = omap3xxx_usbhsotg_addrs,
2555 .user = OCP_USER_MPU,
2558 static struct omap_hwmod_addr_space am35xx_usbhsotg_addrs[] = {
2560 .pa_start = AM35XX_IPSS_USBOTGSS_BASE,
2561 .pa_end = AM35XX_IPSS_USBOTGSS_BASE + SZ_4K - 1,
2562 .flags = ADDR_TYPE_RT
2567 /* l4_core -> usbhsotg */
2568 static struct omap_hwmod_ocp_if am35xx_l4_core__usbhsotg = {
2569 .master = &omap3xxx_l4_core_hwmod,
2570 .slave = &am35xx_usbhsotg_hwmod,
2571 .clk = "hsotgusb_ick",
2572 .addr = am35xx_usbhsotg_addrs,
2573 .user = OCP_USER_MPU,
2576 /* L4_WKUP -> L4_SEC interface */
2577 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__l4_sec = {
2578 .master = &omap3xxx_l4_wkup_hwmod,
2579 .slave = &omap3xxx_l4_sec_hwmod,
2580 .user = OCP_USER_MPU | OCP_USER_SDMA,
2583 /* IVA2 <- L3 interface */
2584 static struct omap_hwmod_ocp_if omap3xxx_l3__iva = {
2585 .master = &omap3xxx_l3_main_hwmod,
2586 .slave = &omap3xxx_iva_hwmod,
2587 .clk = "core_l3_ick",
2588 .user = OCP_USER_MPU | OCP_USER_SDMA,
2591 static struct omap_hwmod_addr_space omap3xxx_timer1_addrs[] = {
2593 .pa_start = 0x48318000,
2594 .pa_end = 0x48318000 + SZ_1K - 1,
2595 .flags = ADDR_TYPE_RT
2600 /* l4_wkup -> timer1 */
2601 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__timer1 = {
2602 .master = &omap3xxx_l4_wkup_hwmod,
2603 .slave = &omap3xxx_timer1_hwmod,
2605 .addr = omap3xxx_timer1_addrs,
2606 .user = OCP_USER_MPU | OCP_USER_SDMA,
2609 static struct omap_hwmod_addr_space omap3xxx_timer2_addrs[] = {
2611 .pa_start = 0x49032000,
2612 .pa_end = 0x49032000 + SZ_1K - 1,
2613 .flags = ADDR_TYPE_RT
2618 /* l4_per -> timer2 */
2619 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer2 = {
2620 .master = &omap3xxx_l4_per_hwmod,
2621 .slave = &omap3xxx_timer2_hwmod,
2623 .addr = omap3xxx_timer2_addrs,
2624 .user = OCP_USER_MPU | OCP_USER_SDMA,
2627 static struct omap_hwmod_addr_space omap3xxx_timer3_addrs[] = {
2629 .pa_start = 0x49034000,
2630 .pa_end = 0x49034000 + SZ_1K - 1,
2631 .flags = ADDR_TYPE_RT
2636 /* l4_per -> timer3 */
2637 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer3 = {
2638 .master = &omap3xxx_l4_per_hwmod,
2639 .slave = &omap3xxx_timer3_hwmod,
2641 .addr = omap3xxx_timer3_addrs,
2642 .user = OCP_USER_MPU | OCP_USER_SDMA,
2645 static struct omap_hwmod_addr_space omap3xxx_timer4_addrs[] = {
2647 .pa_start = 0x49036000,
2648 .pa_end = 0x49036000 + SZ_1K - 1,
2649 .flags = ADDR_TYPE_RT
2654 /* l4_per -> timer4 */
2655 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer4 = {
2656 .master = &omap3xxx_l4_per_hwmod,
2657 .slave = &omap3xxx_timer4_hwmod,
2659 .addr = omap3xxx_timer4_addrs,
2660 .user = OCP_USER_MPU | OCP_USER_SDMA,
2663 static struct omap_hwmod_addr_space omap3xxx_timer5_addrs[] = {
2665 .pa_start = 0x49038000,
2666 .pa_end = 0x49038000 + SZ_1K - 1,
2667 .flags = ADDR_TYPE_RT
2672 /* l4_per -> timer5 */
2673 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer5 = {
2674 .master = &omap3xxx_l4_per_hwmod,
2675 .slave = &omap3xxx_timer5_hwmod,
2677 .addr = omap3xxx_timer5_addrs,
2678 .user = OCP_USER_MPU | OCP_USER_SDMA,
2681 static struct omap_hwmod_addr_space omap3xxx_timer6_addrs[] = {
2683 .pa_start = 0x4903A000,
2684 .pa_end = 0x4903A000 + SZ_1K - 1,
2685 .flags = ADDR_TYPE_RT
2690 /* l4_per -> timer6 */
2691 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer6 = {
2692 .master = &omap3xxx_l4_per_hwmod,
2693 .slave = &omap3xxx_timer6_hwmod,
2695 .addr = omap3xxx_timer6_addrs,
2696 .user = OCP_USER_MPU | OCP_USER_SDMA,
2699 static struct omap_hwmod_addr_space omap3xxx_timer7_addrs[] = {
2701 .pa_start = 0x4903C000,
2702 .pa_end = 0x4903C000 + SZ_1K - 1,
2703 .flags = ADDR_TYPE_RT
2708 /* l4_per -> timer7 */
2709 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer7 = {
2710 .master = &omap3xxx_l4_per_hwmod,
2711 .slave = &omap3xxx_timer7_hwmod,
2713 .addr = omap3xxx_timer7_addrs,
2714 .user = OCP_USER_MPU | OCP_USER_SDMA,
2717 static struct omap_hwmod_addr_space omap3xxx_timer8_addrs[] = {
2719 .pa_start = 0x4903E000,
2720 .pa_end = 0x4903E000 + SZ_1K - 1,
2721 .flags = ADDR_TYPE_RT
2726 /* l4_per -> timer8 */
2727 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer8 = {
2728 .master = &omap3xxx_l4_per_hwmod,
2729 .slave = &omap3xxx_timer8_hwmod,
2731 .addr = omap3xxx_timer8_addrs,
2732 .user = OCP_USER_MPU | OCP_USER_SDMA,
2735 static struct omap_hwmod_addr_space omap3xxx_timer9_addrs[] = {
2737 .pa_start = 0x49040000,
2738 .pa_end = 0x49040000 + SZ_1K - 1,
2739 .flags = ADDR_TYPE_RT
2744 /* l4_per -> timer9 */
2745 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer9 = {
2746 .master = &omap3xxx_l4_per_hwmod,
2747 .slave = &omap3xxx_timer9_hwmod,
2749 .addr = omap3xxx_timer9_addrs,
2750 .user = OCP_USER_MPU | OCP_USER_SDMA,
2753 /* l4_core -> timer10 */
2754 static struct omap_hwmod_ocp_if omap3xxx_l4_core__timer10 = {
2755 .master = &omap3xxx_l4_core_hwmod,
2756 .slave = &omap3xxx_timer10_hwmod,
2758 .addr = omap2_timer10_addrs,
2759 .user = OCP_USER_MPU | OCP_USER_SDMA,
2762 /* l4_core -> timer11 */
2763 static struct omap_hwmod_ocp_if omap3xxx_l4_core__timer11 = {
2764 .master = &omap3xxx_l4_core_hwmod,
2765 .slave = &omap3xxx_timer11_hwmod,
2767 .addr = omap2_timer11_addrs,
2768 .user = OCP_USER_MPU | OCP_USER_SDMA,
2771 static struct omap_hwmod_addr_space omap3xxx_timer12_addrs[] = {
2773 .pa_start = 0x48304000,
2774 .pa_end = 0x48304000 + SZ_1K - 1,
2775 .flags = ADDR_TYPE_RT
2780 /* l4_core -> timer12 */
2781 static struct omap_hwmod_ocp_if omap3xxx_l4_sec__timer12 = {
2782 .master = &omap3xxx_l4_sec_hwmod,
2783 .slave = &omap3xxx_timer12_hwmod,
2785 .addr = omap3xxx_timer12_addrs,
2786 .user = OCP_USER_MPU | OCP_USER_SDMA,
2789 /* l4_wkup -> wd_timer2 */
2790 static struct omap_hwmod_addr_space omap3xxx_wd_timer2_addrs[] = {
2792 .pa_start = 0x48314000,
2793 .pa_end = 0x4831407f,
2794 .flags = ADDR_TYPE_RT
2799 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__wd_timer2 = {
2800 .master = &omap3xxx_l4_wkup_hwmod,
2801 .slave = &omap3xxx_wd_timer2_hwmod,
2803 .addr = omap3xxx_wd_timer2_addrs,
2804 .user = OCP_USER_MPU | OCP_USER_SDMA,
2807 /* l4_core -> dss */
2808 static struct omap_hwmod_ocp_if omap3430es1_l4_core__dss = {
2809 .master = &omap3xxx_l4_core_hwmod,
2810 .slave = &omap3430es1_dss_core_hwmod,
2812 .addr = omap2_dss_addrs,
2815 .l4_fw_region = OMAP3ES1_L4_CORE_FW_DSS_CORE_REGION,
2816 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
2817 .flags = OMAP_FIREWALL_L4,
2820 .user = OCP_USER_MPU | OCP_USER_SDMA,
2823 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss = {
2824 .master = &omap3xxx_l4_core_hwmod,
2825 .slave = &omap3xxx_dss_core_hwmod,
2827 .addr = omap2_dss_addrs,
2830 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_CORE_REGION,
2831 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
2832 .flags = OMAP_FIREWALL_L4,
2835 .user = OCP_USER_MPU | OCP_USER_SDMA,
2838 /* l4_core -> dss_dispc */
2839 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_dispc = {
2840 .master = &omap3xxx_l4_core_hwmod,
2841 .slave = &omap3xxx_dss_dispc_hwmod,
2843 .addr = omap2_dss_dispc_addrs,
2846 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_DISPC_REGION,
2847 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
2848 .flags = OMAP_FIREWALL_L4,
2851 .user = OCP_USER_MPU | OCP_USER_SDMA,
2854 static struct omap_hwmod_addr_space omap3xxx_dss_dsi1_addrs[] = {
2856 .pa_start = 0x4804FC00,
2857 .pa_end = 0x4804FFFF,
2858 .flags = ADDR_TYPE_RT
2863 /* l4_core -> dss_dsi1 */
2864 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_dsi1 = {
2865 .master = &omap3xxx_l4_core_hwmod,
2866 .slave = &omap3xxx_dss_dsi1_hwmod,
2868 .addr = omap3xxx_dss_dsi1_addrs,
2871 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_DSI_REGION,
2872 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
2873 .flags = OMAP_FIREWALL_L4,
2876 .user = OCP_USER_MPU | OCP_USER_SDMA,
2879 /* l4_core -> dss_rfbi */
2880 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_rfbi = {
2881 .master = &omap3xxx_l4_core_hwmod,
2882 .slave = &omap3xxx_dss_rfbi_hwmod,
2884 .addr = omap2_dss_rfbi_addrs,
2887 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_RFBI_REGION,
2888 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP ,
2889 .flags = OMAP_FIREWALL_L4,
2892 .user = OCP_USER_MPU | OCP_USER_SDMA,
2895 /* l4_core -> dss_venc */
2896 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_venc = {
2897 .master = &omap3xxx_l4_core_hwmod,
2898 .slave = &omap3xxx_dss_venc_hwmod,
2900 .addr = omap2_dss_venc_addrs,
2903 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_VENC_REGION,
2904 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
2905 .flags = OMAP_FIREWALL_L4,
2908 .flags = OCPIF_SWSUP_IDLE,
2909 .user = OCP_USER_MPU | OCP_USER_SDMA,
2912 /* l4_wkup -> gpio1 */
2913 static struct omap_hwmod_addr_space omap3xxx_gpio1_addrs[] = {
2915 .pa_start = 0x48310000,
2916 .pa_end = 0x483101ff,
2917 .flags = ADDR_TYPE_RT
2922 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__gpio1 = {
2923 .master = &omap3xxx_l4_wkup_hwmod,
2924 .slave = &omap3xxx_gpio1_hwmod,
2925 .addr = omap3xxx_gpio1_addrs,
2926 .user = OCP_USER_MPU | OCP_USER_SDMA,
2929 /* l4_per -> gpio2 */
2930 static struct omap_hwmod_addr_space omap3xxx_gpio2_addrs[] = {
2932 .pa_start = 0x49050000,
2933 .pa_end = 0x490501ff,
2934 .flags = ADDR_TYPE_RT
2939 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio2 = {
2940 .master = &omap3xxx_l4_per_hwmod,
2941 .slave = &omap3xxx_gpio2_hwmod,
2942 .addr = omap3xxx_gpio2_addrs,
2943 .user = OCP_USER_MPU | OCP_USER_SDMA,
2946 /* l4_per -> gpio3 */
2947 static struct omap_hwmod_addr_space omap3xxx_gpio3_addrs[] = {
2949 .pa_start = 0x49052000,
2950 .pa_end = 0x490521ff,
2951 .flags = ADDR_TYPE_RT
2956 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio3 = {
2957 .master = &omap3xxx_l4_per_hwmod,
2958 .slave = &omap3xxx_gpio3_hwmod,
2959 .addr = omap3xxx_gpio3_addrs,
2960 .user = OCP_USER_MPU | OCP_USER_SDMA,
2965 * The memory management unit performs virtual to physical address translation
2966 * for its requestors.
2969 static struct omap_hwmod_class_sysconfig mmu_sysc = {
2973 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
2974 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
2975 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2976 .sysc_fields = &omap_hwmod_sysc_type1,
2979 static struct omap_hwmod_class omap3xxx_mmu_hwmod_class = {
2986 static struct omap_mmu_dev_attr mmu_isp_dev_attr = {
2988 .da_end = 0xfffff000,
2989 .nr_tlb_entries = 8,
2992 static struct omap_hwmod omap3xxx_mmu_isp_hwmod;
2993 static struct omap_hwmod_irq_info omap3xxx_mmu_isp_irqs[] = {
2998 static struct omap_hwmod_addr_space omap3xxx_mmu_isp_addrs[] = {
3000 .pa_start = 0x480bd400,
3001 .pa_end = 0x480bd47f,
3002 .flags = ADDR_TYPE_RT,
3007 /* l4_core -> mmu isp */
3008 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mmu_isp = {
3009 .master = &omap3xxx_l4_core_hwmod,
3010 .slave = &omap3xxx_mmu_isp_hwmod,
3011 .addr = omap3xxx_mmu_isp_addrs,
3012 .user = OCP_USER_MPU | OCP_USER_SDMA,
3015 static struct omap_hwmod omap3xxx_mmu_isp_hwmod = {
3017 .class = &omap3xxx_mmu_hwmod_class,
3018 .mpu_irqs = omap3xxx_mmu_isp_irqs,
3019 .main_clk = "cam_ick",
3020 .dev_attr = &mmu_isp_dev_attr,
3021 .flags = HWMOD_NO_IDLEST,
3024 #ifdef CONFIG_OMAP_IOMMU_IVA2
3028 static struct omap_mmu_dev_attr mmu_iva_dev_attr = {
3029 .da_start = 0x11000000,
3030 .da_end = 0xfffff000,
3031 .nr_tlb_entries = 32,
3034 static struct omap_hwmod omap3xxx_mmu_iva_hwmod;
3035 static struct omap_hwmod_irq_info omap3xxx_mmu_iva_irqs[] = {
3040 static struct omap_hwmod_rst_info omap3xxx_mmu_iva_resets[] = {
3041 { .name = "mmu", .rst_shift = 1, .st_shift = 9 },
3044 static struct omap_hwmod_addr_space omap3xxx_mmu_iva_addrs[] = {
3046 .pa_start = 0x5d000000,
3047 .pa_end = 0x5d00007f,
3048 .flags = ADDR_TYPE_RT,
3053 /* l3_main -> iva mmu */
3054 static struct omap_hwmod_ocp_if omap3xxx_l3_main__mmu_iva = {
3055 .master = &omap3xxx_l3_main_hwmod,
3056 .slave = &omap3xxx_mmu_iva_hwmod,
3057 .addr = omap3xxx_mmu_iva_addrs,
3058 .user = OCP_USER_MPU | OCP_USER_SDMA,
3061 static struct omap_hwmod omap3xxx_mmu_iva_hwmod = {
3063 .class = &omap3xxx_mmu_hwmod_class,
3064 .mpu_irqs = omap3xxx_mmu_iva_irqs,
3065 .rst_lines = omap3xxx_mmu_iva_resets,
3066 .rst_lines_cnt = ARRAY_SIZE(omap3xxx_mmu_iva_resets),
3067 .main_clk = "iva2_ck",
3070 .module_offs = OMAP3430_IVA2_MOD,
3073 .dev_attr = &mmu_iva_dev_attr,
3074 .flags = HWMOD_NO_IDLEST,
3079 /* l4_per -> gpio4 */
3080 static struct omap_hwmod_addr_space omap3xxx_gpio4_addrs[] = {
3082 .pa_start = 0x49054000,
3083 .pa_end = 0x490541ff,
3084 .flags = ADDR_TYPE_RT
3089 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio4 = {
3090 .master = &omap3xxx_l4_per_hwmod,
3091 .slave = &omap3xxx_gpio4_hwmod,
3092 .addr = omap3xxx_gpio4_addrs,
3093 .user = OCP_USER_MPU | OCP_USER_SDMA,
3096 /* l4_per -> gpio5 */
3097 static struct omap_hwmod_addr_space omap3xxx_gpio5_addrs[] = {
3099 .pa_start = 0x49056000,
3100 .pa_end = 0x490561ff,
3101 .flags = ADDR_TYPE_RT
3106 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio5 = {
3107 .master = &omap3xxx_l4_per_hwmod,
3108 .slave = &omap3xxx_gpio5_hwmod,
3109 .addr = omap3xxx_gpio5_addrs,
3110 .user = OCP_USER_MPU | OCP_USER_SDMA,
3113 /* l4_per -> gpio6 */
3114 static struct omap_hwmod_addr_space omap3xxx_gpio6_addrs[] = {
3116 .pa_start = 0x49058000,
3117 .pa_end = 0x490581ff,
3118 .flags = ADDR_TYPE_RT
3123 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio6 = {
3124 .master = &omap3xxx_l4_per_hwmod,
3125 .slave = &omap3xxx_gpio6_hwmod,
3126 .addr = omap3xxx_gpio6_addrs,
3127 .user = OCP_USER_MPU | OCP_USER_SDMA,
3130 /* dma_system -> L3 */
3131 static struct omap_hwmod_ocp_if omap3xxx_dma_system__l3 = {
3132 .master = &omap3xxx_dma_system_hwmod,
3133 .slave = &omap3xxx_l3_main_hwmod,
3134 .clk = "core_l3_ick",
3135 .user = OCP_USER_MPU | OCP_USER_SDMA,
3138 static struct omap_hwmod_addr_space omap3xxx_dma_system_addrs[] = {
3140 .pa_start = 0x48056000,
3141 .pa_end = 0x48056fff,
3142 .flags = ADDR_TYPE_RT
3147 /* l4_cfg -> dma_system */
3148 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dma_system = {
3149 .master = &omap3xxx_l4_core_hwmod,
3150 .slave = &omap3xxx_dma_system_hwmod,
3151 .clk = "core_l4_ick",
3152 .addr = omap3xxx_dma_system_addrs,
3153 .user = OCP_USER_MPU | OCP_USER_SDMA,
3156 static struct omap_hwmod_addr_space omap3xxx_mcbsp1_addrs[] = {
3159 .pa_start = 0x48074000,
3160 .pa_end = 0x480740ff,
3161 .flags = ADDR_TYPE_RT
3166 /* l4_core -> mcbsp1 */
3167 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mcbsp1 = {
3168 .master = &omap3xxx_l4_core_hwmod,
3169 .slave = &omap3xxx_mcbsp1_hwmod,
3170 .clk = "mcbsp1_ick",
3171 .addr = omap3xxx_mcbsp1_addrs,
3172 .user = OCP_USER_MPU | OCP_USER_SDMA,
3175 static struct omap_hwmod_addr_space omap3xxx_mcbsp2_addrs[] = {
3178 .pa_start = 0x49022000,
3179 .pa_end = 0x490220ff,
3180 .flags = ADDR_TYPE_RT
3185 /* l4_per -> mcbsp2 */
3186 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp2 = {
3187 .master = &omap3xxx_l4_per_hwmod,
3188 .slave = &omap3xxx_mcbsp2_hwmod,
3189 .clk = "mcbsp2_ick",
3190 .addr = omap3xxx_mcbsp2_addrs,
3191 .user = OCP_USER_MPU | OCP_USER_SDMA,
3194 static struct omap_hwmod_addr_space omap3xxx_mcbsp3_addrs[] = {
3197 .pa_start = 0x49024000,
3198 .pa_end = 0x490240ff,
3199 .flags = ADDR_TYPE_RT
3204 /* l4_per -> mcbsp3 */
3205 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp3 = {
3206 .master = &omap3xxx_l4_per_hwmod,
3207 .slave = &omap3xxx_mcbsp3_hwmod,
3208 .clk = "mcbsp3_ick",
3209 .addr = omap3xxx_mcbsp3_addrs,
3210 .user = OCP_USER_MPU | OCP_USER_SDMA,
3213 static struct omap_hwmod_addr_space omap3xxx_mcbsp4_addrs[] = {
3216 .pa_start = 0x49026000,
3217 .pa_end = 0x490260ff,
3218 .flags = ADDR_TYPE_RT
3223 /* l4_per -> mcbsp4 */
3224 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp4 = {
3225 .master = &omap3xxx_l4_per_hwmod,
3226 .slave = &omap3xxx_mcbsp4_hwmod,
3227 .clk = "mcbsp4_ick",
3228 .addr = omap3xxx_mcbsp4_addrs,
3229 .user = OCP_USER_MPU | OCP_USER_SDMA,
3232 static struct omap_hwmod_addr_space omap3xxx_mcbsp5_addrs[] = {
3235 .pa_start = 0x48096000,
3236 .pa_end = 0x480960ff,
3237 .flags = ADDR_TYPE_RT
3242 /* l4_core -> mcbsp5 */
3243 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mcbsp5 = {
3244 .master = &omap3xxx_l4_core_hwmod,
3245 .slave = &omap3xxx_mcbsp5_hwmod,
3246 .clk = "mcbsp5_ick",
3247 .addr = omap3xxx_mcbsp5_addrs,
3248 .user = OCP_USER_MPU | OCP_USER_SDMA,
3251 static struct omap_hwmod_addr_space omap3xxx_mcbsp2_sidetone_addrs[] = {
3254 .pa_start = 0x49028000,
3255 .pa_end = 0x490280ff,
3256 .flags = ADDR_TYPE_RT
3261 /* l4_per -> mcbsp2_sidetone */
3262 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp2_sidetone = {
3263 .master = &omap3xxx_l4_per_hwmod,
3264 .slave = &omap3xxx_mcbsp2_sidetone_hwmod,
3265 .clk = "mcbsp2_ick",
3266 .addr = omap3xxx_mcbsp2_sidetone_addrs,
3267 .user = OCP_USER_MPU,
3270 static struct omap_hwmod_addr_space omap3xxx_mcbsp3_sidetone_addrs[] = {
3273 .pa_start = 0x4902A000,
3274 .pa_end = 0x4902A0ff,
3275 .flags = ADDR_TYPE_RT
3280 /* l4_per -> mcbsp3_sidetone */
3281 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp3_sidetone = {
3282 .master = &omap3xxx_l4_per_hwmod,
3283 .slave = &omap3xxx_mcbsp3_sidetone_hwmod,
3284 .clk = "mcbsp3_ick",
3285 .addr = omap3xxx_mcbsp3_sidetone_addrs,
3286 .user = OCP_USER_MPU,
3289 static struct omap_hwmod_addr_space omap3xxx_mailbox_addrs[] = {
3291 .pa_start = 0x48094000,
3292 .pa_end = 0x480941ff,
3293 .flags = ADDR_TYPE_RT,
3298 /* l4_core -> mailbox */
3299 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mailbox = {
3300 .master = &omap3xxx_l4_core_hwmod,
3301 .slave = &omap3xxx_mailbox_hwmod,
3302 .addr = omap3xxx_mailbox_addrs,
3303 .user = OCP_USER_MPU | OCP_USER_SDMA,
3306 /* l4 core -> mcspi1 interface */
3307 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi1 = {
3308 .master = &omap3xxx_l4_core_hwmod,
3309 .slave = &omap34xx_mcspi1,
3310 .clk = "mcspi1_ick",
3311 .addr = omap2_mcspi1_addr_space,
3312 .user = OCP_USER_MPU | OCP_USER_SDMA,
3315 /* l4 core -> mcspi2 interface */
3316 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi2 = {
3317 .master = &omap3xxx_l4_core_hwmod,
3318 .slave = &omap34xx_mcspi2,
3319 .clk = "mcspi2_ick",
3320 .addr = omap2_mcspi2_addr_space,
3321 .user = OCP_USER_MPU | OCP_USER_SDMA,
3324 /* l4 core -> mcspi3 interface */
3325 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi3 = {
3326 .master = &omap3xxx_l4_core_hwmod,
3327 .slave = &omap34xx_mcspi3,
3328 .clk = "mcspi3_ick",
3329 .addr = omap2430_mcspi3_addr_space,
3330 .user = OCP_USER_MPU | OCP_USER_SDMA,
3333 /* l4 core -> mcspi4 interface */
3334 static struct omap_hwmod_addr_space omap34xx_mcspi4_addr_space[] = {
3336 .pa_start = 0x480ba000,
3337 .pa_end = 0x480ba0ff,
3338 .flags = ADDR_TYPE_RT,
3343 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi4 = {
3344 .master = &omap3xxx_l4_core_hwmod,
3345 .slave = &omap34xx_mcspi4,
3346 .clk = "mcspi4_ick",
3347 .addr = omap34xx_mcspi4_addr_space,
3348 .user = OCP_USER_MPU | OCP_USER_SDMA,
3351 static struct omap_hwmod_ocp_if omap3xxx_usb_host_hs__l3_main_2 = {
3352 .master = &omap3xxx_usb_host_hs_hwmod,
3353 .slave = &omap3xxx_l3_main_hwmod,
3354 .clk = "core_l3_ick",
3355 .user = OCP_USER_MPU,
3358 static struct omap_hwmod_addr_space omap3xxx_usb_host_hs_addrs[] = {
3361 .pa_start = 0x48064000,
3362 .pa_end = 0x480643ff,
3363 .flags = ADDR_TYPE_RT
3367 .pa_start = 0x48064400,
3368 .pa_end = 0x480647ff,
3372 .pa_start = 0x48064800,
3373 .pa_end = 0x48064cff,
3378 static struct omap_hwmod_ocp_if omap3xxx_l4_core__usb_host_hs = {
3379 .master = &omap3xxx_l4_core_hwmod,
3380 .slave = &omap3xxx_usb_host_hs_hwmod,
3381 .clk = "usbhost_ick",
3382 .addr = omap3xxx_usb_host_hs_addrs,
3383 .user = OCP_USER_MPU | OCP_USER_SDMA,
3386 static struct omap_hwmod_addr_space omap3xxx_usb_tll_hs_addrs[] = {
3389 .pa_start = 0x48062000,
3390 .pa_end = 0x48062fff,
3391 .flags = ADDR_TYPE_RT
3396 static struct omap_hwmod_ocp_if omap3xxx_l4_core__usb_tll_hs = {
3397 .master = &omap3xxx_l4_core_hwmod,
3398 .slave = &omap3xxx_usb_tll_hs_hwmod,
3399 .clk = "usbtll_ick",
3400 .addr = omap3xxx_usb_tll_hs_addrs,
3401 .user = OCP_USER_MPU | OCP_USER_SDMA,
3404 /* l4_core -> hdq1w interface */
3405 static struct omap_hwmod_ocp_if omap3xxx_l4_core__hdq1w = {
3406 .master = &omap3xxx_l4_core_hwmod,
3407 .slave = &omap3xxx_hdq1w_hwmod,
3409 .addr = omap2_hdq1w_addr_space,
3410 .user = OCP_USER_MPU | OCP_USER_SDMA,
3411 .flags = OMAP_FIREWALL_L4 | OCPIF_SWSUP_IDLE,
3414 /* l4_wkup -> 32ksync_counter */
3415 static struct omap_hwmod_addr_space omap3xxx_counter_32k_addrs[] = {
3417 .pa_start = 0x48320000,
3418 .pa_end = 0x4832001f,
3419 .flags = ADDR_TYPE_RT
3424 static struct omap_hwmod_addr_space omap3xxx_gpmc_addrs[] = {
3426 .pa_start = 0x6e000000,
3427 .pa_end = 0x6e000fff,
3428 .flags = ADDR_TYPE_RT
3433 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__counter_32k = {
3434 .master = &omap3xxx_l4_wkup_hwmod,
3435 .slave = &omap3xxx_counter_32k_hwmod,
3436 .clk = "omap_32ksync_ick",
3437 .addr = omap3xxx_counter_32k_addrs,
3438 .user = OCP_USER_MPU | OCP_USER_SDMA,
3441 /* am35xx has Davinci MDIO & EMAC */
3442 static struct omap_hwmod_class am35xx_mdio_class = {
3443 .name = "davinci_mdio",
3446 static struct omap_hwmod am35xx_mdio_hwmod = {
3447 .name = "davinci_mdio",
3448 .class = &am35xx_mdio_class,
3449 .flags = HWMOD_NO_IDLEST,
3453 * XXX Should be connected to an IPSS hwmod, not the L3 directly;
3454 * but this will probably require some additional hwmod core support,
3455 * so is left as a future to-do item.
3457 static struct omap_hwmod_ocp_if am35xx_mdio__l3 = {
3458 .master = &am35xx_mdio_hwmod,
3459 .slave = &omap3xxx_l3_main_hwmod,
3461 .user = OCP_USER_MPU,
3464 static struct omap_hwmod_addr_space am35xx_mdio_addrs[] = {
3466 .pa_start = AM35XX_IPSS_MDIO_BASE,
3467 .pa_end = AM35XX_IPSS_MDIO_BASE + SZ_4K - 1,
3468 .flags = ADDR_TYPE_RT,
3473 /* l4_core -> davinci mdio */
3475 * XXX Should be connected to an IPSS hwmod, not the L4_CORE directly;
3476 * but this will probably require some additional hwmod core support,
3477 * so is left as a future to-do item.
3479 static struct omap_hwmod_ocp_if am35xx_l4_core__mdio = {
3480 .master = &omap3xxx_l4_core_hwmod,
3481 .slave = &am35xx_mdio_hwmod,
3483 .addr = am35xx_mdio_addrs,
3484 .user = OCP_USER_MPU,
3487 static struct omap_hwmod_irq_info am35xx_emac_mpu_irqs[] = {
3488 { .name = "rxthresh", .irq = 67 + OMAP_INTC_START, },
3489 { .name = "rx_pulse", .irq = 68 + OMAP_INTC_START, },
3490 { .name = "tx_pulse", .irq = 69 + OMAP_INTC_START },
3491 { .name = "misc_pulse", .irq = 70 + OMAP_INTC_START },
3495 static struct omap_hwmod_class am35xx_emac_class = {
3496 .name = "davinci_emac",
3499 static struct omap_hwmod am35xx_emac_hwmod = {
3500 .name = "davinci_emac",
3501 .mpu_irqs = am35xx_emac_mpu_irqs,
3502 .class = &am35xx_emac_class,
3503 .flags = HWMOD_NO_IDLEST,
3506 /* l3_core -> davinci emac interface */
3508 * XXX Should be connected to an IPSS hwmod, not the L3 directly;
3509 * but this will probably require some additional hwmod core support,
3510 * so is left as a future to-do item.
3512 static struct omap_hwmod_ocp_if am35xx_emac__l3 = {
3513 .master = &am35xx_emac_hwmod,
3514 .slave = &omap3xxx_l3_main_hwmod,
3516 .user = OCP_USER_MPU,
3519 static struct omap_hwmod_addr_space am35xx_emac_addrs[] = {
3521 .pa_start = AM35XX_IPSS_EMAC_BASE,
3522 .pa_end = AM35XX_IPSS_EMAC_BASE + 0x30000 - 1,
3523 .flags = ADDR_TYPE_RT,
3528 /* l4_core -> davinci emac */
3530 * XXX Should be connected to an IPSS hwmod, not the L4_CORE directly;
3531 * but this will probably require some additional hwmod core support,
3532 * so is left as a future to-do item.
3534 static struct omap_hwmod_ocp_if am35xx_l4_core__emac = {
3535 .master = &omap3xxx_l4_core_hwmod,
3536 .slave = &am35xx_emac_hwmod,
3538 .addr = am35xx_emac_addrs,
3539 .user = OCP_USER_MPU,
3542 static struct omap_hwmod_ocp_if omap3xxx_l3_main__gpmc = {
3543 .master = &omap3xxx_l3_main_hwmod,
3544 .slave = &omap3xxx_gpmc_hwmod,
3545 .clk = "core_l3_ick",
3546 .addr = omap3xxx_gpmc_addrs,
3547 .user = OCP_USER_MPU | OCP_USER_SDMA,
3550 static struct omap_hwmod_ocp_if *omap3xxx_hwmod_ocp_ifs[] __initdata = {
3551 &omap3xxx_l3_main__l4_core,
3552 &omap3xxx_l3_main__l4_per,
3553 &omap3xxx_mpu__l3_main,
3554 &omap3xxx_l3_main__l4_debugss,
3555 &omap3xxx_l4_core__l4_wkup,
3556 &omap3xxx_l4_core__mmc3,
3557 &omap3_l4_core__uart1,
3558 &omap3_l4_core__uart2,
3559 &omap3_l4_per__uart3,
3560 &omap3_l4_core__i2c1,
3561 &omap3_l4_core__i2c2,
3562 &omap3_l4_core__i2c3,
3563 &omap3xxx_l4_wkup__l4_sec,
3564 &omap3xxx_l4_wkup__timer1,
3565 &omap3xxx_l4_per__timer2,
3566 &omap3xxx_l4_per__timer3,
3567 &omap3xxx_l4_per__timer4,
3568 &omap3xxx_l4_per__timer5,
3569 &omap3xxx_l4_per__timer6,
3570 &omap3xxx_l4_per__timer7,
3571 &omap3xxx_l4_per__timer8,
3572 &omap3xxx_l4_per__timer9,
3573 &omap3xxx_l4_core__timer10,
3574 &omap3xxx_l4_core__timer11,
3575 &omap3xxx_l4_wkup__wd_timer2,
3576 &omap3xxx_l4_wkup__gpio1,
3577 &omap3xxx_l4_per__gpio2,
3578 &omap3xxx_l4_per__gpio3,
3579 &omap3xxx_l4_per__gpio4,
3580 &omap3xxx_l4_per__gpio5,
3581 &omap3xxx_l4_per__gpio6,
3582 &omap3xxx_dma_system__l3,
3583 &omap3xxx_l4_core__dma_system,
3584 &omap3xxx_l4_core__mcbsp1,
3585 &omap3xxx_l4_per__mcbsp2,
3586 &omap3xxx_l4_per__mcbsp3,
3587 &omap3xxx_l4_per__mcbsp4,
3588 &omap3xxx_l4_core__mcbsp5,
3589 &omap3xxx_l4_per__mcbsp2_sidetone,
3590 &omap3xxx_l4_per__mcbsp3_sidetone,
3591 &omap34xx_l4_core__mcspi1,
3592 &omap34xx_l4_core__mcspi2,
3593 &omap34xx_l4_core__mcspi3,
3594 &omap34xx_l4_core__mcspi4,
3595 &omap3xxx_l4_wkup__counter_32k,
3596 &omap3xxx_l3_main__gpmc,
3600 /* GP-only hwmod links */
3601 static struct omap_hwmod_ocp_if *omap3xxx_gp_hwmod_ocp_ifs[] __initdata = {
3602 &omap3xxx_l4_sec__timer12,
3606 /* 3430ES1-only hwmod links */
3607 static struct omap_hwmod_ocp_if *omap3430es1_hwmod_ocp_ifs[] __initdata = {
3608 &omap3430es1_dss__l3,
3609 &omap3430es1_l4_core__dss,
3613 /* 3430ES2+-only hwmod links */
3614 static struct omap_hwmod_ocp_if *omap3430es2plus_hwmod_ocp_ifs[] __initdata = {
3616 &omap3xxx_l4_core__dss,
3617 &omap3xxx_usbhsotg__l3,
3618 &omap3xxx_l4_core__usbhsotg,
3619 &omap3xxx_usb_host_hs__l3_main_2,
3620 &omap3xxx_l4_core__usb_host_hs,
3621 &omap3xxx_l4_core__usb_tll_hs,
3625 /* <= 3430ES3-only hwmod links */
3626 static struct omap_hwmod_ocp_if *omap3430_pre_es3_hwmod_ocp_ifs[] __initdata = {
3627 &omap3xxx_l4_core__pre_es3_mmc1,
3628 &omap3xxx_l4_core__pre_es3_mmc2,
3632 /* 3430ES3+-only hwmod links */
3633 static struct omap_hwmod_ocp_if *omap3430_es3plus_hwmod_ocp_ifs[] __initdata = {
3634 &omap3xxx_l4_core__es3plus_mmc1,
3635 &omap3xxx_l4_core__es3plus_mmc2,
3639 /* 34xx-only hwmod links (all ES revisions) */
3640 static struct omap_hwmod_ocp_if *omap34xx_hwmod_ocp_ifs[] __initdata = {
3642 &omap34xx_l4_core__sr1,
3643 &omap34xx_l4_core__sr2,
3644 &omap3xxx_l4_core__mailbox,
3645 &omap3xxx_l4_core__hdq1w,
3646 &omap3xxx_sad2d__l3,
3647 &omap3xxx_l4_core__mmu_isp,
3648 #ifdef CONFIG_OMAP_IOMMU_IVA2
3649 &omap3xxx_l3_main__mmu_iva,
3654 /* 36xx-only hwmod links (all ES revisions) */
3655 static struct omap_hwmod_ocp_if *omap36xx_hwmod_ocp_ifs[] __initdata = {
3657 &omap36xx_l4_per__uart4,
3659 &omap3xxx_l4_core__dss,
3660 &omap36xx_l4_core__sr1,
3661 &omap36xx_l4_core__sr2,
3662 &omap3xxx_usbhsotg__l3,
3663 &omap3xxx_l4_core__usbhsotg,
3664 &omap3xxx_l4_core__mailbox,
3665 &omap3xxx_usb_host_hs__l3_main_2,
3666 &omap3xxx_l4_core__usb_host_hs,
3667 &omap3xxx_l4_core__usb_tll_hs,
3668 &omap3xxx_l4_core__es3plus_mmc1,
3669 &omap3xxx_l4_core__es3plus_mmc2,
3670 &omap3xxx_l4_core__hdq1w,
3671 &omap3xxx_sad2d__l3,
3672 &omap3xxx_l4_core__mmu_isp,
3673 #ifdef CONFIG_OMAP_IOMMU_IVA2
3674 &omap3xxx_l3_main__mmu_iva,
3679 static struct omap_hwmod_ocp_if *am35xx_hwmod_ocp_ifs[] __initdata = {
3681 &omap3xxx_l4_core__dss,
3682 &am35xx_usbhsotg__l3,
3683 &am35xx_l4_core__usbhsotg,
3684 &am35xx_l4_core__uart4,
3685 &omap3xxx_usb_host_hs__l3_main_2,
3686 &omap3xxx_l4_core__usb_host_hs,
3687 &omap3xxx_l4_core__usb_tll_hs,
3688 &omap3xxx_l4_core__es3plus_mmc1,
3689 &omap3xxx_l4_core__es3plus_mmc2,
3690 &omap3xxx_l4_core__hdq1w,
3692 &am35xx_l4_core__mdio,
3694 &am35xx_l4_core__emac,
3698 static struct omap_hwmod_ocp_if *omap3xxx_dss_hwmod_ocp_ifs[] __initdata = {
3699 &omap3xxx_l4_core__dss_dispc,
3700 &omap3xxx_l4_core__dss_dsi1,
3701 &omap3xxx_l4_core__dss_rfbi,
3702 &omap3xxx_l4_core__dss_venc,
3706 int __init omap3xxx_hwmod_init(void)
3709 struct omap_hwmod_ocp_if **h = NULL;
3714 /* Register hwmod links common to all OMAP3 */
3715 r = omap_hwmod_register_links(omap3xxx_hwmod_ocp_ifs);
3719 /* Register GP-only hwmod links. */
3720 if (omap_type() == OMAP2_DEVICE_TYPE_GP) {
3721 r = omap_hwmod_register_links(omap3xxx_gp_hwmod_ocp_ifs);
3729 * Register hwmod links common to individual OMAP3 families, all
3730 * silicon revisions (e.g., 34xx, or AM3505/3517, or 36xx)
3731 * All possible revisions should be included in this conditional.
3733 if (rev == OMAP3430_REV_ES1_0 || rev == OMAP3430_REV_ES2_0 ||
3734 rev == OMAP3430_REV_ES2_1 || rev == OMAP3430_REV_ES3_0 ||
3735 rev == OMAP3430_REV_ES3_1 || rev == OMAP3430_REV_ES3_1_2) {
3736 h = omap34xx_hwmod_ocp_ifs;
3737 } else if (rev == AM35XX_REV_ES1_0 || rev == AM35XX_REV_ES1_1) {
3738 h = am35xx_hwmod_ocp_ifs;
3739 } else if (rev == OMAP3630_REV_ES1_0 || rev == OMAP3630_REV_ES1_1 ||
3740 rev == OMAP3630_REV_ES1_2) {
3741 h = omap36xx_hwmod_ocp_ifs;
3743 WARN(1, "OMAP3 hwmod family init: unknown chip type\n");
3747 r = omap_hwmod_register_links(h);
3752 * Register hwmod links specific to certain ES levels of a
3753 * particular family of silicon (e.g., 34xx ES1.0)
3756 if (rev == OMAP3430_REV_ES1_0) {
3757 h = omap3430es1_hwmod_ocp_ifs;
3758 } else if (rev == OMAP3430_REV_ES2_0 || rev == OMAP3430_REV_ES2_1 ||
3759 rev == OMAP3430_REV_ES3_0 || rev == OMAP3430_REV_ES3_1 ||
3760 rev == OMAP3430_REV_ES3_1_2) {
3761 h = omap3430es2plus_hwmod_ocp_ifs;
3765 r = omap_hwmod_register_links(h);
3771 if (rev == OMAP3430_REV_ES1_0 || rev == OMAP3430_REV_ES2_0 ||
3772 rev == OMAP3430_REV_ES2_1) {
3773 h = omap3430_pre_es3_hwmod_ocp_ifs;
3774 } else if (rev == OMAP3430_REV_ES3_0 || rev == OMAP3430_REV_ES3_1 ||
3775 rev == OMAP3430_REV_ES3_1_2) {
3776 h = omap3430_es3plus_hwmod_ocp_ifs;
3780 r = omap_hwmod_register_links(h);
3785 * DSS code presumes that dss_core hwmod is handled first,
3786 * _before_ any other DSS related hwmods so register common
3787 * DSS hwmod links last to ensure that dss_core is already
3788 * registered. Otherwise some change things may happen, for
3789 * ex. if dispc is handled before dss_core and DSS is enabled
3790 * in bootloader DISPC will be reset with outputs enabled
3791 * which sometimes leads to unrecoverable L3 error. XXX The
3792 * long-term fix to this is to ensure hwmods are set up in
3793 * dependency order in the hwmod core code.
3795 r = omap_hwmod_register_links(omap3xxx_dss_hwmod_ocp_ifs);