diff options
author | Benoît Cousson <b-cousson@ti.com> | 2012-04-19 15:33:54 -0400 |
---|---|---|
committer | Paul Walmsley <paul@pwsan.com> | 2012-04-19 15:33:54 -0400 |
commit | 896d4e98c0b5e3a9894b62a88fe4798eef14ba02 (patch) | |
tree | ae62acd60dae3e0738efc8d91f5cb6772759b005 | |
parent | 1e3b5e59532c6f1f57e38b8f8ad7e74bc7cb6f4e (diff) |
ARM: OMAP4: hwmod data: add McASP
Add the McASP hwmod and associated interconnect data. The McASP is a
general-purpose audio serial port.
Signed-off-by: Benoît Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
-rw-r--r-- | arch/arm/mach-omap2/omap_hwmod_44xx_data.c | 91 |
1 files changed, 90 insertions, 1 deletions
diff --git a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c index 4c5add709d7..330cafe5656 100644 --- a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c +++ b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c | |||
@@ -261,7 +261,6 @@ static struct omap_hwmod omap44xx_mpu_private_hwmod = { | |||
261 | * efuse_ctrl_cust | 261 | * efuse_ctrl_cust |
262 | * efuse_ctrl_std | 262 | * efuse_ctrl_std |
263 | * elm | 263 | * elm |
264 | * mcasp | ||
265 | * mpu_c0 | 264 | * mpu_c0 |
266 | * mpu_c1 | 265 | * mpu_c1 |
267 | * ocmc_ram | 266 | * ocmc_ram |
@@ -1670,6 +1669,58 @@ static struct omap_hwmod omap44xx_mailbox_hwmod = { | |||
1670 | }; | 1669 | }; |
1671 | 1670 | ||
1672 | /* | 1671 | /* |
1672 | * 'mcasp' class | ||
1673 | * multi-channel audio serial port controller | ||
1674 | */ | ||
1675 | |||
1676 | /* The IP is not compliant to type1 / type2 scheme */ | ||
1677 | static struct omap_hwmod_sysc_fields omap_hwmod_sysc_type_mcasp = { | ||
1678 | .sidle_shift = 0, | ||
1679 | }; | ||
1680 | |||
1681 | static struct omap_hwmod_class_sysconfig omap44xx_mcasp_sysc = { | ||
1682 | .sysc_offs = 0x0004, | ||
1683 | .sysc_flags = SYSC_HAS_SIDLEMODE, | ||
1684 | .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | | ||
1685 | SIDLE_SMART_WKUP), | ||
1686 | .sysc_fields = &omap_hwmod_sysc_type_mcasp, | ||
1687 | }; | ||
1688 | |||
1689 | static struct omap_hwmod_class omap44xx_mcasp_hwmod_class = { | ||
1690 | .name = "mcasp", | ||
1691 | .sysc = &omap44xx_mcasp_sysc, | ||
1692 | }; | ||
1693 | |||
1694 | /* mcasp */ | ||
1695 | static struct omap_hwmod_irq_info omap44xx_mcasp_irqs[] = { | ||
1696 | { .name = "arevt", .irq = 108 + OMAP44XX_IRQ_GIC_START }, | ||
1697 | { .name = "axevt", .irq = 109 + OMAP44XX_IRQ_GIC_START }, | ||
1698 | { .irq = -1 } | ||
1699 | }; | ||
1700 | |||
1701 | static struct omap_hwmod_dma_info omap44xx_mcasp_sdma_reqs[] = { | ||
1702 | { .name = "axevt", .dma_req = 7 + OMAP44XX_DMA_REQ_START }, | ||
1703 | { .name = "arevt", .dma_req = 10 + OMAP44XX_DMA_REQ_START }, | ||
1704 | { .dma_req = -1 } | ||
1705 | }; | ||
1706 | |||
1707 | static struct omap_hwmod omap44xx_mcasp_hwmod = { | ||
1708 | .name = "mcasp", | ||
1709 | .class = &omap44xx_mcasp_hwmod_class, | ||
1710 | .clkdm_name = "abe_clkdm", | ||
1711 | .mpu_irqs = omap44xx_mcasp_irqs, | ||
1712 | .sdma_reqs = omap44xx_mcasp_sdma_reqs, | ||
1713 | .main_clk = "mcasp_fck", | ||
1714 | .prcm = { | ||
1715 | .omap4 = { | ||
1716 | .clkctrl_offs = OMAP4_CM1_ABE_MCASP_CLKCTRL_OFFSET, | ||
1717 | .context_offs = OMAP4_RM_ABE_MCASP_CONTEXT_OFFSET, | ||
1718 | .modulemode = MODULEMODE_SWCTRL, | ||
1719 | }, | ||
1720 | }, | ||
1721 | }; | ||
1722 | |||
1723 | /* | ||
1673 | * 'mcbsp' class | 1724 | * 'mcbsp' class |
1674 | * multi channel buffered serial port controller | 1725 | * multi channel buffered serial port controller |
1675 | */ | 1726 | */ |
@@ -4265,6 +4316,42 @@ static struct omap_hwmod_ocp_if omap44xx_l4_cfg__mailbox = { | |||
4265 | .user = OCP_USER_MPU | OCP_USER_SDMA, | 4316 | .user = OCP_USER_MPU | OCP_USER_SDMA, |
4266 | }; | 4317 | }; |
4267 | 4318 | ||
4319 | static struct omap_hwmod_addr_space omap44xx_mcasp_addrs[] = { | ||
4320 | { | ||
4321 | .pa_start = 0x40128000, | ||
4322 | .pa_end = 0x401283ff, | ||
4323 | .flags = ADDR_TYPE_RT | ||
4324 | }, | ||
4325 | { } | ||
4326 | }; | ||
4327 | |||
4328 | /* l4_abe -> mcasp */ | ||
4329 | static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcasp = { | ||
4330 | .master = &omap44xx_l4_abe_hwmod, | ||
4331 | .slave = &omap44xx_mcasp_hwmod, | ||
4332 | .clk = "ocp_abe_iclk", | ||
4333 | .addr = omap44xx_mcasp_addrs, | ||
4334 | .user = OCP_USER_MPU, | ||
4335 | }; | ||
4336 | |||
4337 | static struct omap_hwmod_addr_space omap44xx_mcasp_dma_addrs[] = { | ||
4338 | { | ||
4339 | .pa_start = 0x49028000, | ||
4340 | .pa_end = 0x490283ff, | ||
4341 | .flags = ADDR_TYPE_RT | ||
4342 | }, | ||
4343 | { } | ||
4344 | }; | ||
4345 | |||
4346 | /* l4_abe -> mcasp (dma) */ | ||
4347 | static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcasp_dma = { | ||
4348 | .master = &omap44xx_l4_abe_hwmod, | ||
4349 | .slave = &omap44xx_mcasp_hwmod, | ||
4350 | .clk = "ocp_abe_iclk", | ||
4351 | .addr = omap44xx_mcasp_dma_addrs, | ||
4352 | .user = OCP_USER_SDMA, | ||
4353 | }; | ||
4354 | |||
4268 | static struct omap_hwmod_addr_space omap44xx_mcbsp1_addrs[] = { | 4355 | static struct omap_hwmod_addr_space omap44xx_mcbsp1_addrs[] = { |
4269 | { | 4356 | { |
4270 | .name = "mpu", | 4357 | .name = "mpu", |
@@ -5263,6 +5350,8 @@ static struct omap_hwmod_ocp_if *omap44xx_hwmod_ocp_ifs[] __initdata = { | |||
5263 | &omap44xx_l3_main_2__iva, | 5350 | &omap44xx_l3_main_2__iva, |
5264 | &omap44xx_l4_wkup__kbd, | 5351 | &omap44xx_l4_wkup__kbd, |
5265 | &omap44xx_l4_cfg__mailbox, | 5352 | &omap44xx_l4_cfg__mailbox, |
5353 | &omap44xx_l4_abe__mcasp, | ||
5354 | &omap44xx_l4_abe__mcasp_dma, | ||
5266 | &omap44xx_l4_abe__mcbsp1, | 5355 | &omap44xx_l4_abe__mcbsp1, |
5267 | &omap44xx_l4_abe__mcbsp1_dma, | 5356 | &omap44xx_l4_abe__mcbsp1_dma, |
5268 | &omap44xx_l4_abe__mcbsp2, | 5357 | &omap44xx_l4_abe__mcbsp2, |