diff options
author | Subramaniam C.A <subramaniam.ca@ti.com> | 2011-02-14 19:23:08 -0500 |
---|---|---|
committer | Paolo Pisati <paolo.pisati@canonical.com> | 2012-08-17 04:19:16 -0400 |
commit | 277d1ec9cedc625e954549734b8ad3584602277c (patch) | |
tree | fe0b8be2bdb68a5da3f7e4efa33a00abde2d4db3 /arch/arm | |
parent | 4c1549fe859f1fc5acc80880d3d9658696a07634 (diff) |
omap-hwmod: Add hwmod definitions for SysLink related devices
This patch adds hwmod definitions for all devices that are used/
requested by Syslink/ipu-pm.
The devices are:
--sl2if iss ipu mailbox hwspinlock fdif
Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Miguel Vadillo <vadillo@ti.com>
Signed-off-by: Simon Que <sque@ti.com>
Signed-off-by: Hari Kanigeri <h-kanigeri2@ti.com>
Cc: Paul Walmsley <paul@pwsan.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-omap2/omap_hwmod_44xx_data.c | 149 | ||||
-rw-r--r-- | arch/arm/plat-omap/include/plat/omap44xx.h | 4 | ||||
-rw-r--r-- | arch/arm/plat-omap/include/plat/omap_hwmod.h | 4 |
3 files changed, 154 insertions, 3 deletions
diff --git a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c index c07e0db479a..37d4effbb12 100644 --- a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c +++ b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c | |||
@@ -49,6 +49,7 @@ static struct omap_hwmod omap44xx_dmm_hwmod; | |||
49 | static struct omap_hwmod omap44xx_dsp_hwmod; | 49 | static struct omap_hwmod omap44xx_dsp_hwmod; |
50 | static struct omap_hwmod omap44xx_dss_hwmod; | 50 | static struct omap_hwmod omap44xx_dss_hwmod; |
51 | static struct omap_hwmod omap44xx_emif_fw_hwmod; | 51 | static struct omap_hwmod omap44xx_emif_fw_hwmod; |
52 | static struct omap_hwmod omap44xx_fdif_hwmod; | ||
52 | static struct omap_hwmod omap44xx_hsi_hwmod; | 53 | static struct omap_hwmod omap44xx_hsi_hwmod; |
53 | static struct omap_hwmod omap44xx_ipu_hwmod; | 54 | static struct omap_hwmod omap44xx_ipu_hwmod; |
54 | static struct omap_hwmod omap44xx_iss_hwmod; | 55 | static struct omap_hwmod omap44xx_iss_hwmod; |
@@ -65,6 +66,7 @@ static struct omap_hwmod omap44xx_l4_wkup_hwmod; | |||
65 | static struct omap_hwmod omap44xx_mmc1_hwmod; | 66 | static struct omap_hwmod omap44xx_mmc1_hwmod; |
66 | static struct omap_hwmod omap44xx_mmc2_hwmod; | 67 | static struct omap_hwmod omap44xx_mmc2_hwmod; |
67 | static struct omap_hwmod omap44xx_mpu_hwmod; | 68 | static struct omap_hwmod omap44xx_mpu_hwmod; |
69 | static struct omap_hwmod omap44xx_sl2if_hwmod; | ||
68 | static struct omap_hwmod omap44xx_mpu_private_hwmod; | 70 | static struct omap_hwmod omap44xx_mpu_private_hwmod; |
69 | static struct omap_hwmod omap44xx_usb_otg_hs_hwmod; | 71 | static struct omap_hwmod omap44xx_usb_otg_hs_hwmod; |
70 | 72 | ||
@@ -319,6 +321,14 @@ static struct omap_hwmod_ocp_if omap44xx_dma_system__l3_main_2 = { | |||
319 | .user = OCP_USER_MPU | OCP_USER_SDMA, | 321 | .user = OCP_USER_MPU | OCP_USER_SDMA, |
320 | }; | 322 | }; |
321 | 323 | ||
324 | /* fdif -> l3_main_2 */ | ||
325 | static struct omap_hwmod_ocp_if omap44xx_fdif__l3_main_2 = { | ||
326 | .master = &omap44xx_fdif_hwmod, | ||
327 | .slave = &omap44xx_l3_main_2_hwmod, | ||
328 | .clk = "l3_div_ck", | ||
329 | .user = OCP_USER_MPU | OCP_USER_SDMA, | ||
330 | }; | ||
331 | |||
322 | /* hsi -> l3_main_2 */ | 332 | /* hsi -> l3_main_2 */ |
323 | static struct omap_hwmod_ocp_if omap44xx_hsi__l3_main_2 = { | 333 | static struct omap_hwmod_ocp_if omap44xx_hsi__l3_main_2 = { |
324 | .master = &omap44xx_hsi_hwmod, | 334 | .master = &omap44xx_hsi_hwmod, |
@@ -396,6 +406,7 @@ static struct omap_hwmod_ocp_if omap44xx_usb_otg_hs__l3_main_2 = { | |||
396 | /* l3_main_2 slave ports */ | 406 | /* l3_main_2 slave ports */ |
397 | static struct omap_hwmod_ocp_if *omap44xx_l3_main_2_slaves[] = { | 407 | static struct omap_hwmod_ocp_if *omap44xx_l3_main_2_slaves[] = { |
398 | &omap44xx_dma_system__l3_main_2, | 408 | &omap44xx_dma_system__l3_main_2, |
409 | &omap44xx_fdif__l3_main_2, | ||
399 | &omap44xx_hsi__l3_main_2, | 410 | &omap44xx_hsi__l3_main_2, |
400 | &omap44xx_ipu__l3_main_2, | 411 | &omap44xx_ipu__l3_main_2, |
401 | &omap44xx_iss__l3_main_2, | 412 | &omap44xx_iss__l3_main_2, |
@@ -639,7 +650,6 @@ static struct omap_hwmod omap44xx_mpu_private_hwmod = { | |||
639 | * elm | 650 | * elm |
640 | * emif1 | 651 | * emif1 |
641 | * emif2 | 652 | * emif2 |
642 | * fdif | ||
643 | * gpmc | 653 | * gpmc |
644 | * gpu | 654 | * gpu |
645 | * hdq1w | 655 | * hdq1w |
@@ -650,7 +660,6 @@ static struct omap_hwmod omap44xx_mpu_private_hwmod = { | |||
650 | * prcm_mpu | 660 | * prcm_mpu |
651 | * prm | 661 | * prm |
652 | * scrm | 662 | * scrm |
653 | * sl2if | ||
654 | * slimbus1 | 663 | * slimbus1 |
655 | * slimbus2 | 664 | * slimbus2 |
656 | * usb_host_fs | 665 | * usb_host_fs |
@@ -1113,10 +1122,25 @@ static struct omap_hwmod_ocp_if omap44xx_dsp__iva = { | |||
1113 | }; | 1122 | }; |
1114 | 1123 | ||
1115 | /* dsp master ports */ | 1124 | /* dsp master ports */ |
1125 | /* dsp -> sl2if */ | ||
1126 | static struct omap_hwmod_ocp_if omap44xx_dsp__sl2if = { | ||
1127 | .master = &omap44xx_dsp_hwmod, | ||
1128 | .slave = &omap44xx_sl2if_hwmod, | ||
1129 | .clk = "dpll_iva_m5x2_ck", | ||
1130 | }; | ||
1131 | |||
1116 | static struct omap_hwmod_ocp_if *omap44xx_dsp_masters[] = { | 1132 | static struct omap_hwmod_ocp_if *omap44xx_dsp_masters[] = { |
1117 | &omap44xx_dsp__l3_main_1, | 1133 | &omap44xx_dsp__l3_main_1, |
1118 | &omap44xx_dsp__l4_abe, | 1134 | &omap44xx_dsp__l4_abe, |
1119 | &omap44xx_dsp__iva, | 1135 | &omap44xx_dsp__iva, |
1136 | &omap44xx_dsp__sl2if, | ||
1137 | }; | ||
1138 | |||
1139 | /* iva -> sl2if */ | ||
1140 | static struct omap_hwmod_ocp_if omap44xx_iva__sl2if = { | ||
1141 | .master = &omap44xx_iva_hwmod, | ||
1142 | .slave = &omap44xx_sl2if_hwmod, | ||
1143 | .clk = "dpll_iva_m5x2_ck", | ||
1120 | }; | 1144 | }; |
1121 | 1145 | ||
1122 | /* l4_cfg -> dsp */ | 1146 | /* l4_cfg -> dsp */ |
@@ -1686,6 +1710,45 @@ static struct omap_hwmod omap44xx_dss_rfbi_hwmod = { | |||
1686 | }; | 1710 | }; |
1687 | 1711 | ||
1688 | /* | 1712 | /* |
1713 | * 'sl2if' class | ||
1714 | * shared level 2 memory interface | ||
1715 | */ | ||
1716 | |||
1717 | static struct omap_hwmod_class omap44xx_sl2if_hwmod_class = { | ||
1718 | .name = "sl2if", | ||
1719 | }; | ||
1720 | |||
1721 | /* sl2if */ | ||
1722 | /* l3_main_2 -> sl2if */ | ||
1723 | static struct omap_hwmod_ocp_if omap44xx_l3_main_2__sl2if = { | ||
1724 | .master = &omap44xx_l3_main_2_hwmod, | ||
1725 | .slave = &omap44xx_sl2if_hwmod, | ||
1726 | .clk = "l3_div_ck", | ||
1727 | .user = OCP_USER_MPU | OCP_USER_SDMA, | ||
1728 | }; | ||
1729 | |||
1730 | /* sl2if slave ports */ | ||
1731 | static struct omap_hwmod_ocp_if *omap44xx_sl2if_slaves[] = { | ||
1732 | &omap44xx_l3_main_2__sl2if, | ||
1733 | &omap44xx_iva__sl2if, | ||
1734 | &omap44xx_dsp__sl2if, | ||
1735 | }; | ||
1736 | |||
1737 | static struct omap_hwmod omap44xx_sl2if_hwmod = { | ||
1738 | .name = "sl2if", | ||
1739 | .class = &omap44xx_sl2if_hwmod_class, | ||
1740 | .main_clk = "sl2if_ick", | ||
1741 | .prcm = { | ||
1742 | .omap4 = { | ||
1743 | .clkctrl_reg = OMAP4430_CM_IVAHD_SL2_CLKCTRL, | ||
1744 | }, | ||
1745 | }, | ||
1746 | .slaves = omap44xx_sl2if_slaves, | ||
1747 | .slaves_cnt = ARRAY_SIZE(omap44xx_sl2if_slaves), | ||
1748 | .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP4430), | ||
1749 | }; | ||
1750 | |||
1751 | /* | ||
1689 | * 'venc' class | 1752 | * 'venc' class |
1690 | * video encoder | 1753 | * video encoder |
1691 | */ | 1754 | */ |
@@ -2298,6 +2361,82 @@ static struct omap_hwmod_dma_info omap44xx_i2c1_sdma_reqs[] = { | |||
2298 | { .name = "rx", .dma_req = 27 + OMAP44XX_DMA_REQ_START }, | 2361 | { .name = "rx", .dma_req = 27 + OMAP44XX_DMA_REQ_START }, |
2299 | }; | 2362 | }; |
2300 | 2363 | ||
2364 | /* | ||
2365 | * 'fdif' class | ||
2366 | * face detection hw accelerator module | ||
2367 | */ | ||
2368 | |||
2369 | /* static struct omap_hwmod_class_sysconfig omap44xx_fdif_sysc = { | ||
2370 | * .rev_offs = 0x0000, | ||
2371 | * .sysc_offs = 0x0010, | ||
2372 | * .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS | | ||
2373 | * SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET), | ||
2374 | * .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | | ||
2375 | * MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART), | ||
2376 | * .sysc_fields = &omap_hwmod_sysc_type2, | ||
2377 | *}; | ||
2378 | */ | ||
2379 | |||
2380 | static struct omap_hwmod_class omap44xx_fdif_hwmod_class = { | ||
2381 | .name = "fdif", | ||
2382 | /* .sysc = &omap44xx_fdif_sysc, */ | ||
2383 | }; | ||
2384 | |||
2385 | /* fdif */ | ||
2386 | static struct omap_hwmod_irq_info omap44xx_fdif_irqs[] = { | ||
2387 | { .irq = 69 + OMAP44XX_IRQ_GIC_START }, | ||
2388 | }; | ||
2389 | |||
2390 | /* fdif master ports */ | ||
2391 | static struct omap_hwmod_ocp_if *omap44xx_fdif_masters[] = { | ||
2392 | &omap44xx_fdif__l3_main_2, | ||
2393 | }; | ||
2394 | |||
2395 | static struct omap_hwmod_addr_space omap44xx_fdif_addrs[] = { | ||
2396 | { | ||
2397 | .pa_start = 0x4a10a000, | ||
2398 | .pa_end = 0x4a10a1ff, | ||
2399 | .flags = ADDR_TYPE_RT | ||
2400 | }, | ||
2401 | }; | ||
2402 | |||
2403 | /* l4_cfg -> fdif */ | ||
2404 | static struct omap_hwmod_ocp_if omap44xx_l4_cfg__fdif = { | ||
2405 | .master = &omap44xx_l4_cfg_hwmod, | ||
2406 | .slave = &omap44xx_fdif_hwmod, | ||
2407 | .clk = "l4_div_ck", | ||
2408 | .addr = omap44xx_fdif_addrs, | ||
2409 | .addr_cnt = ARRAY_SIZE(omap44xx_fdif_addrs), | ||
2410 | .user = OCP_USER_MPU | OCP_USER_SDMA, | ||
2411 | }; | ||
2412 | |||
2413 | /* fdif slave ports */ | ||
2414 | static struct omap_hwmod_ocp_if *omap44xx_fdif_slaves[] = { | ||
2415 | &omap44xx_l4_cfg__fdif, | ||
2416 | }; | ||
2417 | |||
2418 | static struct omap_hwmod omap44xx_fdif_hwmod = { | ||
2419 | .name = "fdif", | ||
2420 | .class = &omap44xx_fdif_hwmod_class, | ||
2421 | .flags = HWMOD_INIT_NO_RESET, | ||
2422 | .mpu_irqs = omap44xx_fdif_irqs, | ||
2423 | .mpu_irqs_cnt = ARRAY_SIZE(omap44xx_fdif_irqs), | ||
2424 | .main_clk = "fdif_fck", | ||
2425 | .vdd_name = "core", | ||
2426 | .prcm = { | ||
2427 | .omap4 = { | ||
2428 | .clkctrl_reg = OMAP4430_CM_CAM_FDIF_CLKCTRL, | ||
2429 | }, | ||
2430 | }, | ||
2431 | .slaves = omap44xx_fdif_slaves, | ||
2432 | .slaves_cnt = ARRAY_SIZE(omap44xx_fdif_slaves), | ||
2433 | .masters = omap44xx_fdif_masters, | ||
2434 | .masters_cnt = ARRAY_SIZE(omap44xx_fdif_masters), | ||
2435 | .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP4430), | ||
2436 | }; | ||
2437 | |||
2438 | |||
2439 | |||
2301 | static struct omap_hwmod_addr_space omap44xx_i2c1_addrs[] = { | 2440 | static struct omap_hwmod_addr_space omap44xx_i2c1_addrs[] = { |
2302 | { | 2441 | { |
2303 | .pa_start = 0x48070000, | 2442 | .pa_start = 0x48070000, |
@@ -2711,6 +2850,7 @@ static struct omap_hwmod_rst_info omap44xx_iva_seq1_resets[] = { | |||
2711 | 2850 | ||
2712 | /* iva master ports */ | 2851 | /* iva master ports */ |
2713 | static struct omap_hwmod_ocp_if *omap44xx_iva_masters[] = { | 2852 | static struct omap_hwmod_ocp_if *omap44xx_iva_masters[] = { |
2853 | &omap44xx_iva__sl2if, | ||
2714 | &omap44xx_iva__l3_main_2, | 2854 | &omap44xx_iva__l3_main_2, |
2715 | &omap44xx_iva__l3_instr, | 2855 | &omap44xx_iva__l3_instr, |
2716 | }; | 2856 | }; |
@@ -5239,6 +5379,9 @@ static __initdata struct omap_hwmod *omap44xx_hwmods[] = { | |||
5239 | &omap44xx_dss_rfbi_hwmod, | 5379 | &omap44xx_dss_rfbi_hwmod, |
5240 | &omap44xx_dss_venc_hwmod, | 5380 | &omap44xx_dss_venc_hwmod, |
5241 | 5381 | ||
5382 | /* fdif class */ | ||
5383 | &omap44xx_fdif_hwmod, | ||
5384 | |||
5242 | /* gpio class */ | 5385 | /* gpio class */ |
5243 | &omap443x_gpio1_hwmod, | 5386 | &omap443x_gpio1_hwmod, |
5244 | &omap446x_gpio1_hwmod, | 5387 | &omap446x_gpio1_hwmod, |
@@ -5303,6 +5446,8 @@ static __initdata struct omap_hwmod *omap44xx_hwmods[] = { | |||
5303 | 5446 | ||
5304 | /* mpu class */ | 5447 | /* mpu class */ |
5305 | &omap44xx_mpu_hwmod, | 5448 | &omap44xx_mpu_hwmod, |
5449 | /* sl2if class */ | ||
5450 | &omap44xx_sl2if_hwmod, | ||
5306 | 5451 | ||
5307 | /* smartreflex class */ | 5452 | /* smartreflex class */ |
5308 | &omap44xx_smartreflex_core_hwmod, | 5453 | &omap44xx_smartreflex_core_hwmod, |
diff --git a/arch/arm/plat-omap/include/plat/omap44xx.h b/arch/arm/plat-omap/include/plat/omap44xx.h index 722c5b54a26..92cec5083b8 100644 --- a/arch/arm/plat-omap/include/plat/omap44xx.h +++ b/arch/arm/plat-omap/include/plat/omap44xx.h | |||
@@ -22,6 +22,9 @@ | |||
22 | #define L4_PER_44XX_BASE 0x48000000 | 22 | #define L4_PER_44XX_BASE 0x48000000 |
23 | #define L4_EMU_44XX_BASE 0x54000000 | 23 | #define L4_EMU_44XX_BASE 0x54000000 |
24 | #define L3_44XX_BASE 0x44000000 | 24 | #define L3_44XX_BASE 0x44000000 |
25 | #define L3_44XX_BASE_CLK1 L3_44XX_BASE | ||
26 | #define L3_44XX_BASE_CLK2 0x44800000 | ||
27 | #define L3_44XX_BASE_CLK3 0x45000000 | ||
25 | #define OMAP44XX_EMIF1_BASE 0x4c000000 | 28 | #define OMAP44XX_EMIF1_BASE 0x4c000000 |
26 | #define OMAP44XX_EMIF2_BASE 0x4d000000 | 29 | #define OMAP44XX_EMIF2_BASE 0x4d000000 |
27 | #define OMAP44XX_DMM_BASE 0x4e000000 | 30 | #define OMAP44XX_DMM_BASE 0x4e000000 |
@@ -54,6 +57,7 @@ | |||
54 | #define OMAP4_MMU1_BASE 0x55082000 | 57 | #define OMAP4_MMU1_BASE 0x55082000 |
55 | #define OMAP4_MMU2_BASE 0x4A066000 | 58 | #define OMAP4_MMU2_BASE 0x4A066000 |
56 | 59 | ||
60 | #define OMAP44XX_SPINLOCK_BASE (L4_44XX_BASE + 0xF6000) | ||
57 | #define OMAP44XX_USBTLL_BASE (L4_44XX_BASE + 0x62000) | 61 | #define OMAP44XX_USBTLL_BASE (L4_44XX_BASE + 0x62000) |
58 | #define OMAP44XX_UHH_CONFIG_BASE (L4_44XX_BASE + 0x64000) | 62 | #define OMAP44XX_UHH_CONFIG_BASE (L4_44XX_BASE + 0x64000) |
59 | #define OMAP44XX_HSUSB_OHCI_BASE (L4_44XX_BASE + 0x64800) | 63 | #define OMAP44XX_HSUSB_OHCI_BASE (L4_44XX_BASE + 0x64800) |
diff --git a/arch/arm/plat-omap/include/plat/omap_hwmod.h b/arch/arm/plat-omap/include/plat/omap_hwmod.h index 1adea9c6298..5fa9b43e3e1 100644 --- a/arch/arm/plat-omap/include/plat/omap_hwmod.h +++ b/arch/arm/plat-omap/include/plat/omap_hwmod.h | |||
@@ -430,6 +430,7 @@ struct omap_hwmod_omap4_prcm { | |||
430 | #define _HWMOD_STATE_ENABLED 4 | 430 | #define _HWMOD_STATE_ENABLED 4 |
431 | #define _HWMOD_STATE_IDLE 5 | 431 | #define _HWMOD_STATE_IDLE 5 |
432 | #define _HWMOD_STATE_DISABLED 6 | 432 | #define _HWMOD_STATE_DISABLED 6 |
433 | #define _HWMOD_STATE_LAST _HWMOD_STATE_DISABLED | ||
433 | 434 | ||
434 | /** | 435 | /** |
435 | * struct omap_hwmod_class - the type of an IP block | 436 | * struct omap_hwmod_class - the type of an IP block |
@@ -459,7 +460,8 @@ struct omap_hwmod_class { | |||
459 | const char *name; | 460 | const char *name; |
460 | struct omap_hwmod_class_sysconfig *sysc; | 461 | struct omap_hwmod_class_sysconfig *sysc; |
461 | u32 rev; | 462 | u32 rev; |
462 | int (*pre_shutdown)(struct omap_hwmod *oh); | 463 | int (*pre_shutdown) |
464 | (struct omap_hwmod *oh); | ||
463 | int (*reset)(struct omap_hwmod *oh); | 465 | int (*reset)(struct omap_hwmod *oh); |
464 | }; | 466 | }; |
465 | 467 | ||