blob: 0852d954da406590e954e018b5287819b000608b [file] [log] [blame]
Paul Walmsley02bfc032009-09-03 20:14:05 +03001/*
Paul Walmsley73591542010-02-22 22:09:32 -07002 * omap_hwmod_2430_data.c - hardware modules present on the OMAP2430 chips
Paul Walmsley02bfc032009-09-03 20:14:05 +03003 *
Paul Walmsley73591542010-02-22 22:09:32 -07004 * Copyright (C) 2009-2010 Nokia Corporation
Paul Walmsley02bfc032009-09-03 20:14:05 +03005 * Paul Walmsley
6 *
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License version 2 as
9 * published by the Free Software Foundation.
10 *
11 * XXX handle crossbar/shared link difference for L3?
Paul Walmsley73591542010-02-22 22:09:32 -070012 * XXX these should be marked initdata for multi-OMAP kernels
Paul Walmsley02bfc032009-09-03 20:14:05 +030013 */
Tony Lindgrence491cf2009-10-20 09:40:47 -070014#include <plat/omap_hwmod.h>
Paul Walmsley02bfc032009-09-03 20:14:05 +030015#include <mach/irqs.h>
Tony Lindgrence491cf2009-10-20 09:40:47 -070016#include <plat/cpu.h>
17#include <plat/dma.h>
Paul Walmsley02bfc032009-09-03 20:14:05 +030018
Paul Walmsley43b40992010-02-22 22:09:34 -070019#include "omap_hwmod_common_data.h"
20
Paul Walmsley02bfc032009-09-03 20:14:05 +030021#include "prm-regbits-24xx.h"
22
Paul Walmsley73591542010-02-22 22:09:32 -070023/*
24 * OMAP2430 hardware module integration data
25 *
26 * ALl of the data in this section should be autogeneratable from the
27 * TI hardware database or other technical documentation. Data that
28 * is driver-specific or driver-kernel integration-specific belongs
29 * elsewhere.
30 */
31
Paul Walmsley02bfc032009-09-03 20:14:05 +030032static struct omap_hwmod omap2430_mpu_hwmod;
33static struct omap_hwmod omap2430_l3_hwmod;
34static struct omap_hwmod omap2430_l4_core_hwmod;
35
36/* L3 -> L4_CORE interface */
37static struct omap_hwmod_ocp_if omap2430_l3__l4_core = {
38 .master = &omap2430_l3_hwmod,
39 .slave = &omap2430_l4_core_hwmod,
40 .user = OCP_USER_MPU | OCP_USER_SDMA,
41};
42
43/* MPU -> L3 interface */
44static struct omap_hwmod_ocp_if omap2430_mpu__l3 = {
45 .master = &omap2430_mpu_hwmod,
46 .slave = &omap2430_l3_hwmod,
47 .user = OCP_USER_MPU,
48};
49
50/* Slave interfaces on the L3 interconnect */
51static struct omap_hwmod_ocp_if *omap2430_l3_slaves[] = {
52 &omap2430_mpu__l3,
53};
54
55/* Master interfaces on the L3 interconnect */
56static struct omap_hwmod_ocp_if *omap2430_l3_masters[] = {
57 &omap2430_l3__l4_core,
58};
59
60/* L3 */
61static struct omap_hwmod omap2430_l3_hwmod = {
62 .name = "l3_hwmod",
Paul Walmsley43b40992010-02-22 22:09:34 -070063 .class = &l3_hwmod_class,
Paul Walmsley02bfc032009-09-03 20:14:05 +030064 .masters = omap2430_l3_masters,
65 .masters_cnt = ARRAY_SIZE(omap2430_l3_masters),
66 .slaves = omap2430_l3_slaves,
67 .slaves_cnt = ARRAY_SIZE(omap2430_l3_slaves),
68 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430)
69};
70
71static struct omap_hwmod omap2430_l4_wkup_hwmod;
72static struct omap_hwmod omap2430_mmc1_hwmod;
73static struct omap_hwmod omap2430_mmc2_hwmod;
74
75/* L4_CORE -> L4_WKUP interface */
76static struct omap_hwmod_ocp_if omap2430_l4_core__l4_wkup = {
77 .master = &omap2430_l4_core_hwmod,
78 .slave = &omap2430_l4_wkup_hwmod,
79 .user = OCP_USER_MPU | OCP_USER_SDMA,
80};
81
82/* Slave interfaces on the L4_CORE interconnect */
83static struct omap_hwmod_ocp_if *omap2430_l4_core_slaves[] = {
84 &omap2430_l3__l4_core,
85};
86
87/* Master interfaces on the L4_CORE interconnect */
88static struct omap_hwmod_ocp_if *omap2430_l4_core_masters[] = {
89 &omap2430_l4_core__l4_wkup,
90};
91
92/* L4 CORE */
93static struct omap_hwmod omap2430_l4_core_hwmod = {
94 .name = "l4_core_hwmod",
Paul Walmsley43b40992010-02-22 22:09:34 -070095 .class = &l4_hwmod_class,
Paul Walmsley02bfc032009-09-03 20:14:05 +030096 .masters = omap2430_l4_core_masters,
97 .masters_cnt = ARRAY_SIZE(omap2430_l4_core_masters),
98 .slaves = omap2430_l4_core_slaves,
99 .slaves_cnt = ARRAY_SIZE(omap2430_l4_core_slaves),
100 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430)
101};
102
103/* Slave interfaces on the L4_WKUP interconnect */
104static struct omap_hwmod_ocp_if *omap2430_l4_wkup_slaves[] = {
105 &omap2430_l4_core__l4_wkup,
106};
107
108/* Master interfaces on the L4_WKUP interconnect */
109static struct omap_hwmod_ocp_if *omap2430_l4_wkup_masters[] = {
110};
111
112/* L4 WKUP */
113static struct omap_hwmod omap2430_l4_wkup_hwmod = {
114 .name = "l4_wkup_hwmod",
Paul Walmsley43b40992010-02-22 22:09:34 -0700115 .class = &l4_hwmod_class,
Paul Walmsley02bfc032009-09-03 20:14:05 +0300116 .masters = omap2430_l4_wkup_masters,
117 .masters_cnt = ARRAY_SIZE(omap2430_l4_wkup_masters),
118 .slaves = omap2430_l4_wkup_slaves,
119 .slaves_cnt = ARRAY_SIZE(omap2430_l4_wkup_slaves),
120 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430)
121};
122
123/* Master interfaces on the MPU device */
124static struct omap_hwmod_ocp_if *omap2430_mpu_masters[] = {
125 &omap2430_mpu__l3,
126};
127
128/* MPU */
129static struct omap_hwmod omap2430_mpu_hwmod = {
Benoit Cousson5c2c0292010-05-20 12:31:10 -0600130 .name = "mpu",
Paul Walmsley43b40992010-02-22 22:09:34 -0700131 .class = &mpu_hwmod_class,
Paul Walmsley50ebdac2010-02-22 22:09:31 -0700132 .main_clk = "mpu_ck",
Paul Walmsley02bfc032009-09-03 20:14:05 +0300133 .masters = omap2430_mpu_masters,
134 .masters_cnt = ARRAY_SIZE(omap2430_mpu_masters),
135 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430),
136};
137
138static __initdata struct omap_hwmod *omap2430_hwmods[] = {
139 &omap2430_l3_hwmod,
140 &omap2430_l4_core_hwmod,
141 &omap2430_l4_wkup_hwmod,
142 &omap2430_mpu_hwmod,
143 NULL,
144};
145
Paul Walmsley73591542010-02-22 22:09:32 -0700146int __init omap2430_hwmod_init(void)
147{
148 return omap_hwmod_init(omap2430_hwmods);
149}
Paul Walmsley02bfc032009-09-03 20:14:05 +0300150
151