aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorPaul Walmsley <paul@pwsan.com>2011-03-01 16:12:55 -0500
committerTony Lindgren <tony@atomide.com>2011-03-01 16:12:55 -0500
commitbce06f375644f8b28fbc1d261699fdfe459733ad (patch)
treed7fc5473f7ba3e012114bc3da708af8d735fd482 /arch
parente08016d0f4fcfe038a402071ada3073c6ca8d62d (diff)
OMAP2430: hwmod data: Add HSMMC
Update the omap2430 hwmod data with the HSMMC info. Signed-off-by: Paul Walmsley <paul@pwsan.com> Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com> Signed-off-by: Rajendra Nayak <rnayak@ti.com Signed-off-by: Kishore Kadiyala <kishore.kadiyala@ti.com> Cc: Benoit Cousson <b-cousson@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-omap2/omap_hwmod_2430_data.c148
1 files changed, 148 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/omap_hwmod_2430_data.c b/arch/arm/mach-omap2/omap_hwmod_2430_data.c
index b46a54ce1a41..0d239e3a9801 100644
--- a/arch/arm/mach-omap2/omap_hwmod_2430_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_2430_data.c
@@ -55,6 +55,8 @@ static struct omap_hwmod omap2430_dma_system_hwmod;
55static struct omap_hwmod omap2430_mcspi1_hwmod; 55static struct omap_hwmod omap2430_mcspi1_hwmod;
56static struct omap_hwmod omap2430_mcspi2_hwmod; 56static struct omap_hwmod omap2430_mcspi2_hwmod;
57static struct omap_hwmod omap2430_mcspi3_hwmod; 57static struct omap_hwmod omap2430_mcspi3_hwmod;
58static struct omap_hwmod omap2430_mmc1_hwmod;
59static struct omap_hwmod omap2430_mmc2_hwmod;
58 60
59/* L3 -> L4_CORE interface */ 61/* L3 -> L4_CORE interface */
60static struct omap_hwmod_ocp_if omap2430_l3_main__l4_core = { 62static struct omap_hwmod_ocp_if omap2430_l3_main__l4_core = {
@@ -251,6 +253,42 @@ static struct omap_hwmod_ocp_if *omap2430_usbhsotg_slaves[] = {
251 &omap2430_l4_core__usbhsotg, 253 &omap2430_l4_core__usbhsotg,
252}; 254};
253 255
256/* L4 CORE -> MMC1 interface */
257static struct omap_hwmod_addr_space omap2430_mmc1_addr_space[] = {
258 {
259 .pa_start = 0x4809c000,
260 .pa_end = 0x4809c1ff,
261 .flags = ADDR_TYPE_RT,
262 },
263};
264
265static struct omap_hwmod_ocp_if omap2430_l4_core__mmc1 = {
266 .master = &omap2430_l4_core_hwmod,
267 .slave = &omap2430_mmc1_hwmod,
268 .clk = "mmchs1_ick",
269 .addr = omap2430_mmc1_addr_space,
270 .addr_cnt = ARRAY_SIZE(omap2430_mmc1_addr_space),
271 .user = OCP_USER_MPU | OCP_USER_SDMA,
272};
273
274/* L4 CORE -> MMC2 interface */
275static struct omap_hwmod_addr_space omap2430_mmc2_addr_space[] = {
276 {
277 .pa_start = 0x480b4000,
278 .pa_end = 0x480b41ff,
279 .flags = ADDR_TYPE_RT,
280 },
281};
282
283static struct omap_hwmod_ocp_if omap2430_l4_core__mmc2 = {
284 .master = &omap2430_l4_core_hwmod,
285 .slave = &omap2430_mmc2_hwmod,
286 .addr = omap2430_mmc2_addr_space,
287 .clk = "mmchs2_ick",
288 .addr_cnt = ARRAY_SIZE(omap2430_mmc2_addr_space),
289 .user = OCP_USER_MPU | OCP_USER_SDMA,
290};
291
254/* Slave interfaces on the L4_CORE interconnect */ 292/* Slave interfaces on the L4_CORE interconnect */
255static struct omap_hwmod_ocp_if *omap2430_l4_core_slaves[] = { 293static struct omap_hwmod_ocp_if *omap2430_l4_core_slaves[] = {
256 &omap2430_l3_main__l4_core, 294 &omap2430_l3_main__l4_core,
@@ -259,6 +297,8 @@ static struct omap_hwmod_ocp_if *omap2430_l4_core_slaves[] = {
259/* Master interfaces on the L4_CORE interconnect */ 297/* Master interfaces on the L4_CORE interconnect */
260static struct omap_hwmod_ocp_if *omap2430_l4_core_masters[] = { 298static struct omap_hwmod_ocp_if *omap2430_l4_core_masters[] = {
261 &omap2430_l4_core__l4_wkup, 299 &omap2430_l4_core__l4_wkup,
300 &omap2430_l4_core__mmc1,
301 &omap2430_l4_core__mmc2,
262}; 302};
263 303
264/* L4 CORE */ 304/* L4 CORE */
@@ -2127,6 +2167,112 @@ static struct omap_hwmod omap2430_usbhsotg_hwmod = {
2127 2167
2128 2168
2129 2169
2170/* MMC/SD/SDIO common */
2171
2172static struct omap_hwmod_class_sysconfig omap2430_mmc_sysc = {
2173 .rev_offs = 0x1fc,
2174 .sysc_offs = 0x10,
2175 .syss_offs = 0x14,
2176 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
2177 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
2178 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS),
2179 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2180 .sysc_fields = &omap_hwmod_sysc_type1,
2181};
2182
2183static struct omap_hwmod_class omap2430_mmc_class = {
2184 .name = "mmc",
2185 .sysc = &omap2430_mmc_sysc,
2186};
2187
2188/* MMC/SD/SDIO1 */
2189
2190static struct omap_hwmod_irq_info omap2430_mmc1_mpu_irqs[] = {
2191 { .irq = 83 },
2192};
2193
2194static struct omap_hwmod_dma_info omap2430_mmc1_sdma_reqs[] = {
2195 { .name = "tx", .dma_req = 61 }, /* DMA_MMC1_TX */
2196 { .name = "rx", .dma_req = 62 }, /* DMA_MMC1_RX */
2197};
2198
2199static struct omap_hwmod_opt_clk omap2430_mmc1_opt_clks[] = {
2200 { .role = "dbck", .clk = "mmchsdb1_fck" },
2201};
2202
2203static struct omap_hwmod_ocp_if *omap2430_mmc1_slaves[] = {
2204 &omap2430_l4_core__mmc1,
2205};
2206
2207static struct omap_hwmod omap2430_mmc1_hwmod = {
2208 .name = "mmc1",
2209 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
2210 .mpu_irqs = omap2430_mmc1_mpu_irqs,
2211 .mpu_irqs_cnt = ARRAY_SIZE(omap2430_mmc1_mpu_irqs),
2212 .sdma_reqs = omap2430_mmc1_sdma_reqs,
2213 .sdma_reqs_cnt = ARRAY_SIZE(omap2430_mmc1_sdma_reqs),
2214 .opt_clks = omap2430_mmc1_opt_clks,
2215 .opt_clks_cnt = ARRAY_SIZE(omap2430_mmc1_opt_clks),
2216 .main_clk = "mmchs1_fck",
2217 .prcm = {
2218 .omap2 = {
2219 .module_offs = CORE_MOD,
2220 .prcm_reg_id = 2,
2221 .module_bit = OMAP2430_EN_MMCHS1_SHIFT,
2222 .idlest_reg_id = 2,
2223 .idlest_idle_bit = OMAP2430_ST_MMCHS1_SHIFT,
2224 },
2225 },
2226 .slaves = omap2430_mmc1_slaves,
2227 .slaves_cnt = ARRAY_SIZE(omap2430_mmc1_slaves),
2228 .class = &omap2430_mmc_class,
2229 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430),
2230};
2231
2232/* MMC/SD/SDIO2 */
2233
2234static struct omap_hwmod_irq_info omap2430_mmc2_mpu_irqs[] = {
2235 { .irq = 86 },
2236};
2237
2238static struct omap_hwmod_dma_info omap2430_mmc2_sdma_reqs[] = {
2239 { .name = "tx", .dma_req = 47 }, /* DMA_MMC2_TX */
2240 { .name = "rx", .dma_req = 48 }, /* DMA_MMC2_RX */
2241};
2242
2243static struct omap_hwmod_opt_clk omap2430_mmc2_opt_clks[] = {
2244 { .role = "dbck", .clk = "mmchsdb2_fck" },
2245};
2246
2247static struct omap_hwmod_ocp_if *omap2430_mmc2_slaves[] = {
2248 &omap2430_l4_core__mmc2,
2249};
2250
2251static struct omap_hwmod omap2430_mmc2_hwmod = {
2252 .name = "mmc2",
2253 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
2254 .mpu_irqs = omap2430_mmc2_mpu_irqs,
2255 .mpu_irqs_cnt = ARRAY_SIZE(omap2430_mmc2_mpu_irqs),
2256 .sdma_reqs = omap2430_mmc2_sdma_reqs,
2257 .sdma_reqs_cnt = ARRAY_SIZE(omap2430_mmc2_sdma_reqs),
2258 .opt_clks = omap2430_mmc2_opt_clks,
2259 .opt_clks_cnt = ARRAY_SIZE(omap2430_mmc2_opt_clks),
2260 .main_clk = "mmchs2_fck",
2261 .prcm = {
2262 .omap2 = {
2263 .module_offs = CORE_MOD,
2264 .prcm_reg_id = 2,
2265 .module_bit = OMAP2430_EN_MMCHS2_SHIFT,
2266 .idlest_reg_id = 2,
2267 .idlest_idle_bit = OMAP2430_ST_MMCHS2_SHIFT,
2268 },
2269 },
2270 .slaves = omap2430_mmc2_slaves,
2271 .slaves_cnt = ARRAY_SIZE(omap2430_mmc2_slaves),
2272 .class = &omap2430_mmc_class,
2273 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430),
2274};
2275
2130static __initdata struct omap_hwmod *omap2430_hwmods[] = { 2276static __initdata struct omap_hwmod *omap2430_hwmods[] = {
2131 &omap2430_l3_main_hwmod, 2277 &omap2430_l3_main_hwmod,
2132 &omap2430_l4_core_hwmod, 2278 &omap2430_l4_core_hwmod,
@@ -2159,6 +2305,8 @@ static __initdata struct omap_hwmod *omap2430_hwmods[] = {
2159 /* i2c class */ 2305 /* i2c class */
2160 &omap2430_i2c1_hwmod, 2306 &omap2430_i2c1_hwmod,
2161 &omap2430_i2c2_hwmod, 2307 &omap2430_i2c2_hwmod,
2308 &omap2430_mmc1_hwmod,
2309 &omap2430_mmc2_hwmod,
2162 2310
2163 /* gpio class */ 2311 /* gpio class */
2164 &omap2430_gpio1_hwmod, 2312 &omap2430_gpio1_hwmod,