aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHema HK <hemahk@ti.com>2011-02-17 01:37:19 -0500
committerFelipe Balbi <balbi@ti.com>2011-02-17 10:36:47 -0500
commit273ff8c3bc04cf358c131f49ee7a11efa7ec73d7 (patch)
tree6761cdbee96c5a04abe724770c6024dec2903a79
parent870ea2b8e750f40fe5681b902ce0d5445297e610 (diff)
AM35xx: hwmod data: Add USBOTG
AM35xx hwmod data structures are populated for USBOTG with base address, L3 and L4 interface clocks and IRQ. Signed-off-by: Hema HK <hemahk@ti.com> Cc: Tony Lindgren <tony@atomide.com> Cc: Kevin Hilman <khilman@deeprootsystems.com> Cc: Cousson, Benoit <b-cousson@ti.com> Cc: Paul Walmsley <paul@pwsan.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
-rw-r--r--arch/arm/mach-omap2/omap_hwmod_3xxx_data.c65
1 files changed, 65 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c b/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c
index cce09fdb9041..b4cd8ddf963e 100644
--- a/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c
@@ -28,6 +28,7 @@
28#include "prm-regbits-34xx.h" 28#include "prm-regbits-34xx.h"
29#include "cm-regbits-34xx.h" 29#include "cm-regbits-34xx.h"
30#include "wd_timer.h" 30#include "wd_timer.h"
31#include <mach/am35xx.h>
31 32
32/* 33/*
33 * OMAP3xxx hardware module integration data 34 * OMAP3xxx hardware module integration data
@@ -55,6 +56,8 @@ static struct omap_hwmod omap3xxx_gpio5_hwmod;
55static struct omap_hwmod omap3xxx_gpio6_hwmod; 56static struct omap_hwmod omap3xxx_gpio6_hwmod;
56static struct omap_hwmod omap34xx_sr1_hwmod; 57static struct omap_hwmod omap34xx_sr1_hwmod;
57static struct omap_hwmod omap34xx_sr2_hwmod; 58static struct omap_hwmod omap34xx_sr2_hwmod;
59static struct omap_hwmod am35xx_usbhsotg_hwmod;
60
58 61
59static struct omap_hwmod omap3xxx_dma_system_hwmod; 62static struct omap_hwmod omap3xxx_dma_system_hwmod;
60 63
@@ -117,6 +120,13 @@ static struct omap_hwmod_ocp_if omap3xxx_usbhsotg__l3 = {
117 .user = OCP_USER_MPU, 120 .user = OCP_USER_MPU,
118}; 121};
119 122
123/* l3_core -> am35xx_usbhsotg interface */
124static struct omap_hwmod_ocp_if am35xx_usbhsotg__l3 = {
125 .master = &am35xx_usbhsotg_hwmod,
126 .slave = &omap3xxx_l3_main_hwmod,
127 .clk = "core_l3_ick",
128 .user = OCP_USER_MPU,
129};
120/* L4_CORE -> L4_WKUP interface */ 130/* L4_CORE -> L4_WKUP interface */
121static struct omap_hwmod_ocp_if omap3xxx_l4_core__l4_wkup = { 131static struct omap_hwmod_ocp_if omap3xxx_l4_core__l4_wkup = {
122 .master = &omap3xxx_l4_core_hwmod, 132 .master = &omap3xxx_l4_core_hwmod,
@@ -340,6 +350,31 @@ static struct omap_hwmod_ocp_if *omap3xxx_usbhsotg_slaves[] = {
340 &omap3xxx_l4_core__usbhsotg, 350 &omap3xxx_l4_core__usbhsotg,
341}; 351};
342 352
353static struct omap_hwmod_addr_space am35xx_usbhsotg_addrs[] = {
354 {
355 .pa_start = AM35XX_IPSS_USBOTGSS_BASE,
356 .pa_end = AM35XX_IPSS_USBOTGSS_BASE + SZ_4K - 1,
357 .flags = ADDR_TYPE_RT
358 },
359};
360
361/* l4_core -> usbhsotg */
362static struct omap_hwmod_ocp_if am35xx_l4_core__usbhsotg = {
363 .master = &omap3xxx_l4_core_hwmod,
364 .slave = &am35xx_usbhsotg_hwmod,
365 .clk = "l4_ick",
366 .addr = am35xx_usbhsotg_addrs,
367 .addr_cnt = ARRAY_SIZE(am35xx_usbhsotg_addrs),
368 .user = OCP_USER_MPU,
369};
370
371static struct omap_hwmod_ocp_if *am35xx_usbhsotg_masters[] = {
372 &am35xx_usbhsotg__l3,
373};
374
375static struct omap_hwmod_ocp_if *am35xx_usbhsotg_slaves[] = {
376 &am35xx_l4_core__usbhsotg,
377};
343/* Slave interfaces on the L4_CORE interconnect */ 378/* Slave interfaces on the L4_CORE interconnect */
344static struct omap_hwmod_ocp_if *omap3xxx_l4_core_slaves[] = { 379static struct omap_hwmod_ocp_if *omap3xxx_l4_core_slaves[] = {
345 &omap3xxx_l3_main__l4_core, 380 &omap3xxx_l3_main__l4_core,
@@ -1452,6 +1487,33 @@ static struct omap_hwmod omap3xxx_usbhsotg_hwmod = {
1452 | HWMOD_SWSUP_MSTANDBY, 1487 | HWMOD_SWSUP_MSTANDBY,
1453 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) 1488 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
1454}; 1489};
1490/* usb_otg_hs */
1491static struct omap_hwmod_irq_info am35xx_usbhsotg_mpu_irqs[] = {
1492
1493 { .name = "mc", .irq = 71 },
1494};
1495
1496static struct omap_hwmod_class am35xx_usbotg_class = {
1497 .name = "am35xx_usbotg",
1498 .sysc = NULL,
1499};
1500
1501static struct omap_hwmod am35xx_usbhsotg_hwmod = {
1502 .name = "am35x_otg_hs",
1503 .mpu_irqs = am35xx_usbhsotg_mpu_irqs,
1504 .mpu_irqs_cnt = ARRAY_SIZE(am35xx_usbhsotg_mpu_irqs),
1505 .main_clk = NULL,
1506 .prcm = {
1507 .omap2 = {
1508 },
1509 },
1510 .masters = am35xx_usbhsotg_masters,
1511 .masters_cnt = ARRAY_SIZE(am35xx_usbhsotg_masters),
1512 .slaves = am35xx_usbhsotg_slaves,
1513 .slaves_cnt = ARRAY_SIZE(am35xx_usbhsotg_slaves),
1514 .class = &am35xx_usbotg_class,
1515 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES3_1)
1516};
1455 1517
1456static __initdata struct omap_hwmod *omap3xxx_hwmods[] = { 1518static __initdata struct omap_hwmod *omap3xxx_hwmods[] = {
1457 &omap3xxx_l3_main_hwmod, 1519 &omap3xxx_l3_main_hwmod,
@@ -1488,6 +1550,9 @@ static __initdata struct omap_hwmod *omap3xxx_hwmods[] = {
1488 /* usbotg class */ 1550 /* usbotg class */
1489 &omap3xxx_usbhsotg_hwmod, 1551 &omap3xxx_usbhsotg_hwmod,
1490 1552
1553 /* usbotg for am35x */
1554 &am35xx_usbhsotg_hwmod,
1555
1491 NULL, 1556 NULL,
1492}; 1557};
1493 1558