blob: 5fdcc1e9d4ace7435033771d476c38a669e7a247 [file] [log] [blame]
Paul Walmsley73591542010-02-22 22:09:32 -07001/*
2 * omap_hwmod_3xxx_data.c - hardware modules present on the OMAP3xxx chips
3 *
4 * Copyright (C) 2009-2010 Nokia Corporation
5 * 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 * The data in this file should be completely autogeneratable from
12 * the TI hardware database or other technical documentation.
13 *
14 * XXX these should be marked initdata for multi-OMAP kernels
15 */
16#include <plat/omap_hwmod.h>
17#include <mach/irqs.h>
18#include <plat/cpu.h>
19#include <plat/dma.h>
Kevin Hilman046465b2010-09-27 20:19:30 +053020#include <plat/serial.h>
Senthilvadivu Guruswamye04d9e12011-01-24 06:21:51 +000021#include <plat/l3_3xxx.h>
Rajendra Nayak4fe20e92010-09-21 19:37:13 +053022#include <plat/l4_3xxx.h>
23#include <plat/i2c.h>
Varadarajan, Charulatha70034d32010-12-07 16:26:57 -080024#include <plat/gpio.h>
Kishore Kadiyala6ab89462011-03-01 13:12:56 -080025#include <plat/mmc.h>
Thara Gopinathd3442722010-05-29 22:02:24 +053026#include <plat/smartreflex.h>
Charulatha V0f616a42011-02-17 09:53:10 -080027#include <plat/mcspi.h>
Thara Gopinathce722d22011-02-23 00:14:05 -070028#include <plat/dmtimer.h>
Paul Walmsley73591542010-02-22 22:09:32 -070029
Paul Walmsley43b40992010-02-22 22:09:34 -070030#include "omap_hwmod_common_data.h"
31
Paul Walmsley73591542010-02-22 22:09:32 -070032#include "prm-regbits-34xx.h"
Varadarajan, Charulatha6b667f82010-09-23 20:02:38 +053033#include "cm-regbits-34xx.h"
Paul Walmsleyff2516f2010-12-21 15:39:15 -070034#include "wd_timer.h"
Hema HK273ff8c2011-02-17 12:07:19 +053035#include <mach/am35xx.h>
Paul Walmsley73591542010-02-22 22:09:32 -070036
37/*
38 * OMAP3xxx hardware module integration data
39 *
40 * ALl of the data in this section should be autogeneratable from the
41 * TI hardware database or other technical documentation. Data that
42 * is driver-specific or driver-kernel integration-specific belongs
43 * elsewhere.
44 */
45
46static struct omap_hwmod omap3xxx_mpu_hwmod;
Kevin Hilman540064b2010-07-26 16:34:32 -060047static struct omap_hwmod omap3xxx_iva_hwmod;
Kevin Hilman4a7cf902010-07-26 16:34:32 -060048static struct omap_hwmod omap3xxx_l3_main_hwmod;
Paul Walmsley73591542010-02-22 22:09:32 -070049static struct omap_hwmod omap3xxx_l4_core_hwmod;
50static struct omap_hwmod omap3xxx_l4_per_hwmod;
Varadarajan, Charulatha6b667f82010-09-23 20:02:38 +053051static struct omap_hwmod omap3xxx_wd_timer2_hwmod;
Senthilvadivu Guruswamye04d9e12011-01-24 06:21:51 +000052static struct omap_hwmod omap3430es1_dss_core_hwmod;
53static struct omap_hwmod omap3xxx_dss_core_hwmod;
54static struct omap_hwmod omap3xxx_dss_dispc_hwmod;
55static struct omap_hwmod omap3xxx_dss_dsi1_hwmod;
56static struct omap_hwmod omap3xxx_dss_rfbi_hwmod;
57static struct omap_hwmod omap3xxx_dss_venc_hwmod;
Rajendra Nayak4fe20e92010-09-21 19:37:13 +053058static struct omap_hwmod omap3xxx_i2c1_hwmod;
59static struct omap_hwmod omap3xxx_i2c2_hwmod;
60static struct omap_hwmod omap3xxx_i2c3_hwmod;
Varadarajan, Charulatha70034d32010-12-07 16:26:57 -080061static struct omap_hwmod omap3xxx_gpio1_hwmod;
62static struct omap_hwmod omap3xxx_gpio2_hwmod;
63static struct omap_hwmod omap3xxx_gpio3_hwmod;
64static struct omap_hwmod omap3xxx_gpio4_hwmod;
65static struct omap_hwmod omap3xxx_gpio5_hwmod;
66static struct omap_hwmod omap3xxx_gpio6_hwmod;
Thara Gopinathd3442722010-05-29 22:02:24 +053067static struct omap_hwmod omap34xx_sr1_hwmod;
68static struct omap_hwmod omap34xx_sr2_hwmod;
Charulatha V0f616a42011-02-17 09:53:10 -080069static struct omap_hwmod omap34xx_mcspi1;
70static struct omap_hwmod omap34xx_mcspi2;
71static struct omap_hwmod omap34xx_mcspi3;
72static struct omap_hwmod omap34xx_mcspi4;
Paul Walmsleyb1636052011-03-01 13:12:56 -080073static struct omap_hwmod omap3xxx_mmc1_hwmod;
74static struct omap_hwmod omap3xxx_mmc2_hwmod;
75static struct omap_hwmod omap3xxx_mmc3_hwmod;
Hema HK273ff8c2011-02-17 12:07:19 +053076static struct omap_hwmod am35xx_usbhsotg_hwmod;
Paul Walmsley73591542010-02-22 22:09:32 -070077
G, Manjunath Kondaiah01438ab2010-12-20 18:27:19 -080078static struct omap_hwmod omap3xxx_dma_system_hwmod;
79
Paul Walmsley73591542010-02-22 22:09:32 -070080/* L3 -> L4_CORE interface */
Kevin Hilman4a7cf902010-07-26 16:34:32 -060081static struct omap_hwmod_ocp_if omap3xxx_l3_main__l4_core = {
82 .master = &omap3xxx_l3_main_hwmod,
Paul Walmsley73591542010-02-22 22:09:32 -070083 .slave = &omap3xxx_l4_core_hwmod,
84 .user = OCP_USER_MPU | OCP_USER_SDMA,
85};
86
87/* L3 -> L4_PER interface */
Kevin Hilman4a7cf902010-07-26 16:34:32 -060088static struct omap_hwmod_ocp_if omap3xxx_l3_main__l4_per = {
89 .master = &omap3xxx_l3_main_hwmod,
Paul Walmsley73591542010-02-22 22:09:32 -070090 .slave = &omap3xxx_l4_per_hwmod,
91 .user = OCP_USER_MPU | OCP_USER_SDMA,
92};
93
94/* MPU -> L3 interface */
Kevin Hilman4a7cf902010-07-26 16:34:32 -060095static struct omap_hwmod_ocp_if omap3xxx_mpu__l3_main = {
Paul Walmsley73591542010-02-22 22:09:32 -070096 .master = &omap3xxx_mpu_hwmod,
Kevin Hilman4a7cf902010-07-26 16:34:32 -060097 .slave = &omap3xxx_l3_main_hwmod,
Paul Walmsley73591542010-02-22 22:09:32 -070098 .user = OCP_USER_MPU,
99};
100
101/* Slave interfaces on the L3 interconnect */
Kevin Hilman4a7cf902010-07-26 16:34:32 -0600102static struct omap_hwmod_ocp_if *omap3xxx_l3_main_slaves[] = {
103 &omap3xxx_mpu__l3_main,
Paul Walmsley73591542010-02-22 22:09:32 -0700104};
105
Senthilvadivu Guruswamye04d9e12011-01-24 06:21:51 +0000106/* DSS -> l3 */
107static struct omap_hwmod_ocp_if omap3xxx_dss__l3 = {
108 .master = &omap3xxx_dss_core_hwmod,
109 .slave = &omap3xxx_l3_main_hwmod,
110 .fw = {
111 .omap2 = {
112 .l3_perm_bit = OMAP3_L3_CORE_FW_INIT_ID_DSS,
113 .flags = OMAP_FIREWALL_L3,
114 }
115 },
116 .user = OCP_USER_MPU | OCP_USER_SDMA,
117};
118
Paul Walmsley73591542010-02-22 22:09:32 -0700119/* Master interfaces on the L3 interconnect */
Kevin Hilman4a7cf902010-07-26 16:34:32 -0600120static struct omap_hwmod_ocp_if *omap3xxx_l3_main_masters[] = {
121 &omap3xxx_l3_main__l4_core,
122 &omap3xxx_l3_main__l4_per,
Paul Walmsley73591542010-02-22 22:09:32 -0700123};
124
125/* L3 */
Kevin Hilman4a7cf902010-07-26 16:34:32 -0600126static struct omap_hwmod omap3xxx_l3_main_hwmod = {
Benoit Coussonfa983472010-07-26 16:34:29 -0600127 .name = "l3_main",
Paul Walmsley43b40992010-02-22 22:09:34 -0700128 .class = &l3_hwmod_class,
Kevin Hilman4a7cf902010-07-26 16:34:32 -0600129 .masters = omap3xxx_l3_main_masters,
130 .masters_cnt = ARRAY_SIZE(omap3xxx_l3_main_masters),
131 .slaves = omap3xxx_l3_main_slaves,
132 .slaves_cnt = ARRAY_SIZE(omap3xxx_l3_main_slaves),
Kevin Hilman2eb18752010-07-26 16:34:28 -0600133 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
134 .flags = HWMOD_NO_IDLEST,
Paul Walmsley73591542010-02-22 22:09:32 -0700135};
136
137static struct omap_hwmod omap3xxx_l4_wkup_hwmod;
Kevin Hilman046465b2010-09-27 20:19:30 +0530138static struct omap_hwmod omap3xxx_uart1_hwmod;
139static struct omap_hwmod omap3xxx_uart2_hwmod;
140static struct omap_hwmod omap3xxx_uart3_hwmod;
141static struct omap_hwmod omap3xxx_uart4_hwmod;
Hema HK870ea2b2011-02-17 12:07:18 +0530142static struct omap_hwmod omap3xxx_usbhsotg_hwmod;
Paul Walmsley73591542010-02-22 22:09:32 -0700143
Hema HK870ea2b2011-02-17 12:07:18 +0530144/* l3_core -> usbhsotg interface */
145static struct omap_hwmod_ocp_if omap3xxx_usbhsotg__l3 = {
146 .master = &omap3xxx_usbhsotg_hwmod,
147 .slave = &omap3xxx_l3_main_hwmod,
148 .clk = "core_l3_ick",
149 .user = OCP_USER_MPU,
150};
Paul Walmsley73591542010-02-22 22:09:32 -0700151
Hema HK273ff8c2011-02-17 12:07:19 +0530152/* l3_core -> am35xx_usbhsotg interface */
153static struct omap_hwmod_ocp_if am35xx_usbhsotg__l3 = {
154 .master = &am35xx_usbhsotg_hwmod,
155 .slave = &omap3xxx_l3_main_hwmod,
156 .clk = "core_l3_ick",
157 .user = OCP_USER_MPU,
158};
Paul Walmsley73591542010-02-22 22:09:32 -0700159/* L4_CORE -> L4_WKUP interface */
160static struct omap_hwmod_ocp_if omap3xxx_l4_core__l4_wkup = {
161 .master = &omap3xxx_l4_core_hwmod,
162 .slave = &omap3xxx_l4_wkup_hwmod,
163 .user = OCP_USER_MPU | OCP_USER_SDMA,
164};
165
Paul Walmsleyb1636052011-03-01 13:12:56 -0800166/* L4 CORE -> MMC1 interface */
167static struct omap_hwmod_addr_space omap3xxx_mmc1_addr_space[] = {
168 {
169 .pa_start = 0x4809c000,
170 .pa_end = 0x4809c1ff,
171 .flags = ADDR_TYPE_RT,
172 },
173};
174
175static struct omap_hwmod_ocp_if omap3xxx_l4_core__mmc1 = {
176 .master = &omap3xxx_l4_core_hwmod,
177 .slave = &omap3xxx_mmc1_hwmod,
178 .clk = "mmchs1_ick",
179 .addr = omap3xxx_mmc1_addr_space,
180 .addr_cnt = ARRAY_SIZE(omap3xxx_mmc1_addr_space),
181 .user = OCP_USER_MPU | OCP_USER_SDMA,
182 .flags = OMAP_FIREWALL_L4
183};
184
185/* L4 CORE -> MMC2 interface */
186static struct omap_hwmod_addr_space omap3xxx_mmc2_addr_space[] = {
187 {
188 .pa_start = 0x480b4000,
189 .pa_end = 0x480b41ff,
190 .flags = ADDR_TYPE_RT,
191 },
192};
193
194static struct omap_hwmod_ocp_if omap3xxx_l4_core__mmc2 = {
195 .master = &omap3xxx_l4_core_hwmod,
196 .slave = &omap3xxx_mmc2_hwmod,
197 .clk = "mmchs2_ick",
198 .addr = omap3xxx_mmc2_addr_space,
199 .addr_cnt = ARRAY_SIZE(omap3xxx_mmc2_addr_space),
200 .user = OCP_USER_MPU | OCP_USER_SDMA,
201 .flags = OMAP_FIREWALL_L4
202};
203
204/* L4 CORE -> MMC3 interface */
205static struct omap_hwmod_addr_space omap3xxx_mmc3_addr_space[] = {
206 {
207 .pa_start = 0x480ad000,
208 .pa_end = 0x480ad1ff,
209 .flags = ADDR_TYPE_RT,
210 },
211};
212
213static struct omap_hwmod_ocp_if omap3xxx_l4_core__mmc3 = {
214 .master = &omap3xxx_l4_core_hwmod,
215 .slave = &omap3xxx_mmc3_hwmod,
216 .clk = "mmchs3_ick",
217 .addr = omap3xxx_mmc3_addr_space,
218 .addr_cnt = ARRAY_SIZE(omap3xxx_mmc3_addr_space),
219 .user = OCP_USER_MPU | OCP_USER_SDMA,
220 .flags = OMAP_FIREWALL_L4
221};
222
Kevin Hilman046465b2010-09-27 20:19:30 +0530223/* L4 CORE -> UART1 interface */
224static struct omap_hwmod_addr_space omap3xxx_uart1_addr_space[] = {
225 {
226 .pa_start = OMAP3_UART1_BASE,
227 .pa_end = OMAP3_UART1_BASE + SZ_8K - 1,
228 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
229 },
230};
231
232static struct omap_hwmod_ocp_if omap3_l4_core__uart1 = {
233 .master = &omap3xxx_l4_core_hwmod,
234 .slave = &omap3xxx_uart1_hwmod,
235 .clk = "uart1_ick",
236 .addr = omap3xxx_uart1_addr_space,
237 .addr_cnt = ARRAY_SIZE(omap3xxx_uart1_addr_space),
238 .user = OCP_USER_MPU | OCP_USER_SDMA,
239};
240
241/* L4 CORE -> UART2 interface */
242static struct omap_hwmod_addr_space omap3xxx_uart2_addr_space[] = {
243 {
244 .pa_start = OMAP3_UART2_BASE,
245 .pa_end = OMAP3_UART2_BASE + SZ_1K - 1,
246 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
247 },
248};
249
250static struct omap_hwmod_ocp_if omap3_l4_core__uart2 = {
251 .master = &omap3xxx_l4_core_hwmod,
252 .slave = &omap3xxx_uart2_hwmod,
253 .clk = "uart2_ick",
254 .addr = omap3xxx_uart2_addr_space,
255 .addr_cnt = ARRAY_SIZE(omap3xxx_uart2_addr_space),
256 .user = OCP_USER_MPU | OCP_USER_SDMA,
257};
258
259/* L4 PER -> UART3 interface */
260static struct omap_hwmod_addr_space omap3xxx_uart3_addr_space[] = {
261 {
262 .pa_start = OMAP3_UART3_BASE,
263 .pa_end = OMAP3_UART3_BASE + SZ_1K - 1,
264 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
265 },
266};
267
268static struct omap_hwmod_ocp_if omap3_l4_per__uart3 = {
269 .master = &omap3xxx_l4_per_hwmod,
270 .slave = &omap3xxx_uart3_hwmod,
271 .clk = "uart3_ick",
272 .addr = omap3xxx_uart3_addr_space,
273 .addr_cnt = ARRAY_SIZE(omap3xxx_uart3_addr_space),
274 .user = OCP_USER_MPU | OCP_USER_SDMA,
275};
276
277/* L4 PER -> UART4 interface */
278static struct omap_hwmod_addr_space omap3xxx_uart4_addr_space[] = {
279 {
280 .pa_start = OMAP3_UART4_BASE,
281 .pa_end = OMAP3_UART4_BASE + SZ_1K - 1,
282 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
283 },
284};
285
286static struct omap_hwmod_ocp_if omap3_l4_per__uart4 = {
287 .master = &omap3xxx_l4_per_hwmod,
288 .slave = &omap3xxx_uart4_hwmod,
289 .clk = "uart4_ick",
290 .addr = omap3xxx_uart4_addr_space,
291 .addr_cnt = ARRAY_SIZE(omap3xxx_uart4_addr_space),
292 .user = OCP_USER_MPU | OCP_USER_SDMA,
293};
294
Rajendra Nayak4fe20e92010-09-21 19:37:13 +0530295/* I2C IP block address space length (in bytes) */
296#define OMAP2_I2C_AS_LEN 128
297
298/* L4 CORE -> I2C1 interface */
299static struct omap_hwmod_addr_space omap3xxx_i2c1_addr_space[] = {
300 {
301 .pa_start = 0x48070000,
302 .pa_end = 0x48070000 + OMAP2_I2C_AS_LEN - 1,
303 .flags = ADDR_TYPE_RT,
304 },
305};
306
307static struct omap_hwmod_ocp_if omap3_l4_core__i2c1 = {
308 .master = &omap3xxx_l4_core_hwmod,
309 .slave = &omap3xxx_i2c1_hwmod,
310 .clk = "i2c1_ick",
311 .addr = omap3xxx_i2c1_addr_space,
312 .addr_cnt = ARRAY_SIZE(omap3xxx_i2c1_addr_space),
313 .fw = {
314 .omap2 = {
315 .l4_fw_region = OMAP3_L4_CORE_FW_I2C1_REGION,
316 .l4_prot_group = 7,
317 .flags = OMAP_FIREWALL_L4,
318 }
319 },
320 .user = OCP_USER_MPU | OCP_USER_SDMA,
321};
322
323/* L4 CORE -> I2C2 interface */
324static struct omap_hwmod_addr_space omap3xxx_i2c2_addr_space[] = {
325 {
326 .pa_start = 0x48072000,
327 .pa_end = 0x48072000 + OMAP2_I2C_AS_LEN - 1,
328 .flags = ADDR_TYPE_RT,
329 },
330};
331
332static struct omap_hwmod_ocp_if omap3_l4_core__i2c2 = {
333 .master = &omap3xxx_l4_core_hwmod,
334 .slave = &omap3xxx_i2c2_hwmod,
335 .clk = "i2c2_ick",
336 .addr = omap3xxx_i2c2_addr_space,
337 .addr_cnt = ARRAY_SIZE(omap3xxx_i2c2_addr_space),
338 .fw = {
339 .omap2 = {
340 .l4_fw_region = OMAP3_L4_CORE_FW_I2C2_REGION,
341 .l4_prot_group = 7,
342 .flags = OMAP_FIREWALL_L4,
343 }
344 },
345 .user = OCP_USER_MPU | OCP_USER_SDMA,
346};
347
348/* L4 CORE -> I2C3 interface */
349static struct omap_hwmod_addr_space omap3xxx_i2c3_addr_space[] = {
350 {
351 .pa_start = 0x48060000,
352 .pa_end = 0x48060000 + OMAP2_I2C_AS_LEN - 1,
353 .flags = ADDR_TYPE_RT,
354 },
355};
356
357static struct omap_hwmod_ocp_if omap3_l4_core__i2c3 = {
358 .master = &omap3xxx_l4_core_hwmod,
359 .slave = &omap3xxx_i2c3_hwmod,
360 .clk = "i2c3_ick",
361 .addr = omap3xxx_i2c3_addr_space,
362 .addr_cnt = ARRAY_SIZE(omap3xxx_i2c3_addr_space),
363 .fw = {
364 .omap2 = {
365 .l4_fw_region = OMAP3_L4_CORE_FW_I2C3_REGION,
366 .l4_prot_group = 7,
367 .flags = OMAP_FIREWALL_L4,
368 }
369 },
370 .user = OCP_USER_MPU | OCP_USER_SDMA,
371};
372
Thara Gopinathd3442722010-05-29 22:02:24 +0530373/* L4 CORE -> SR1 interface */
374static struct omap_hwmod_addr_space omap3_sr1_addr_space[] = {
375 {
376 .pa_start = OMAP34XX_SR1_BASE,
377 .pa_end = OMAP34XX_SR1_BASE + SZ_1K - 1,
378 .flags = ADDR_TYPE_RT,
379 },
380};
381
382static struct omap_hwmod_ocp_if omap3_l4_core__sr1 = {
383 .master = &omap3xxx_l4_core_hwmod,
384 .slave = &omap34xx_sr1_hwmod,
385 .clk = "sr_l4_ick",
386 .addr = omap3_sr1_addr_space,
387 .addr_cnt = ARRAY_SIZE(omap3_sr1_addr_space),
388 .user = OCP_USER_MPU,
389};
390
391/* L4 CORE -> SR1 interface */
392static struct omap_hwmod_addr_space omap3_sr2_addr_space[] = {
393 {
394 .pa_start = OMAP34XX_SR2_BASE,
395 .pa_end = OMAP34XX_SR2_BASE + SZ_1K - 1,
396 .flags = ADDR_TYPE_RT,
397 },
398};
399
400static struct omap_hwmod_ocp_if omap3_l4_core__sr2 = {
401 .master = &omap3xxx_l4_core_hwmod,
402 .slave = &omap34xx_sr2_hwmod,
403 .clk = "sr_l4_ick",
404 .addr = omap3_sr2_addr_space,
405 .addr_cnt = ARRAY_SIZE(omap3_sr2_addr_space),
406 .user = OCP_USER_MPU,
407};
408
Hema HK870ea2b2011-02-17 12:07:18 +0530409/*
410* usbhsotg interface data
411*/
412
413static struct omap_hwmod_addr_space omap3xxx_usbhsotg_addrs[] = {
414 {
415 .pa_start = OMAP34XX_HSUSB_OTG_BASE,
416 .pa_end = OMAP34XX_HSUSB_OTG_BASE + SZ_4K - 1,
417 .flags = ADDR_TYPE_RT
418 },
419};
420
421/* l4_core -> usbhsotg */
422static struct omap_hwmod_ocp_if omap3xxx_l4_core__usbhsotg = {
423 .master = &omap3xxx_l4_core_hwmod,
424 .slave = &omap3xxx_usbhsotg_hwmod,
425 .clk = "l4_ick",
426 .addr = omap3xxx_usbhsotg_addrs,
427 .addr_cnt = ARRAY_SIZE(omap3xxx_usbhsotg_addrs),
428 .user = OCP_USER_MPU,
429};
430
431static struct omap_hwmod_ocp_if *omap3xxx_usbhsotg_masters[] = {
432 &omap3xxx_usbhsotg__l3,
433};
434
435static struct omap_hwmod_ocp_if *omap3xxx_usbhsotg_slaves[] = {
436 &omap3xxx_l4_core__usbhsotg,
437};
438
Hema HK273ff8c2011-02-17 12:07:19 +0530439static struct omap_hwmod_addr_space am35xx_usbhsotg_addrs[] = {
440 {
441 .pa_start = AM35XX_IPSS_USBOTGSS_BASE,
442 .pa_end = AM35XX_IPSS_USBOTGSS_BASE + SZ_4K - 1,
443 .flags = ADDR_TYPE_RT
444 },
445};
446
447/* l4_core -> usbhsotg */
448static struct omap_hwmod_ocp_if am35xx_l4_core__usbhsotg = {
449 .master = &omap3xxx_l4_core_hwmod,
450 .slave = &am35xx_usbhsotg_hwmod,
451 .clk = "l4_ick",
452 .addr = am35xx_usbhsotg_addrs,
453 .addr_cnt = ARRAY_SIZE(am35xx_usbhsotg_addrs),
454 .user = OCP_USER_MPU,
455};
456
457static struct omap_hwmod_ocp_if *am35xx_usbhsotg_masters[] = {
458 &am35xx_usbhsotg__l3,
459};
460
461static struct omap_hwmod_ocp_if *am35xx_usbhsotg_slaves[] = {
462 &am35xx_l4_core__usbhsotg,
463};
Paul Walmsley73591542010-02-22 22:09:32 -0700464/* Slave interfaces on the L4_CORE interconnect */
465static struct omap_hwmod_ocp_if *omap3xxx_l4_core_slaves[] = {
Kevin Hilman4a7cf902010-07-26 16:34:32 -0600466 &omap3xxx_l3_main__l4_core,
Thara Gopinathd3442722010-05-29 22:02:24 +0530467 &omap3_l4_core__sr1,
468 &omap3_l4_core__sr2,
Paul Walmsley73591542010-02-22 22:09:32 -0700469};
470
471/* Master interfaces on the L4_CORE interconnect */
472static struct omap_hwmod_ocp_if *omap3xxx_l4_core_masters[] = {
473 &omap3xxx_l4_core__l4_wkup,
Kevin Hilman046465b2010-09-27 20:19:30 +0530474 &omap3_l4_core__uart1,
475 &omap3_l4_core__uart2,
Rajendra Nayak4fe20e92010-09-21 19:37:13 +0530476 &omap3_l4_core__i2c1,
477 &omap3_l4_core__i2c2,
478 &omap3_l4_core__i2c3,
Paul Walmsley73591542010-02-22 22:09:32 -0700479};
480
481/* L4 CORE */
482static struct omap_hwmod omap3xxx_l4_core_hwmod = {
Benoit Coussonfa983472010-07-26 16:34:29 -0600483 .name = "l4_core",
Paul Walmsley43b40992010-02-22 22:09:34 -0700484 .class = &l4_hwmod_class,
Paul Walmsley73591542010-02-22 22:09:32 -0700485 .masters = omap3xxx_l4_core_masters,
486 .masters_cnt = ARRAY_SIZE(omap3xxx_l4_core_masters),
487 .slaves = omap3xxx_l4_core_slaves,
488 .slaves_cnt = ARRAY_SIZE(omap3xxx_l4_core_slaves),
Kevin Hilman2eb18752010-07-26 16:34:28 -0600489 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
490 .flags = HWMOD_NO_IDLEST,
Paul Walmsley73591542010-02-22 22:09:32 -0700491};
492
493/* Slave interfaces on the L4_PER interconnect */
494static struct omap_hwmod_ocp_if *omap3xxx_l4_per_slaves[] = {
Kevin Hilman4a7cf902010-07-26 16:34:32 -0600495 &omap3xxx_l3_main__l4_per,
Paul Walmsley73591542010-02-22 22:09:32 -0700496};
497
498/* Master interfaces on the L4_PER interconnect */
499static struct omap_hwmod_ocp_if *omap3xxx_l4_per_masters[] = {
Kevin Hilman046465b2010-09-27 20:19:30 +0530500 &omap3_l4_per__uart3,
501 &omap3_l4_per__uart4,
Paul Walmsley73591542010-02-22 22:09:32 -0700502};
503
504/* L4 PER */
505static struct omap_hwmod omap3xxx_l4_per_hwmod = {
Benoit Coussonfa983472010-07-26 16:34:29 -0600506 .name = "l4_per",
Paul Walmsley43b40992010-02-22 22:09:34 -0700507 .class = &l4_hwmod_class,
Paul Walmsley73591542010-02-22 22:09:32 -0700508 .masters = omap3xxx_l4_per_masters,
509 .masters_cnt = ARRAY_SIZE(omap3xxx_l4_per_masters),
510 .slaves = omap3xxx_l4_per_slaves,
511 .slaves_cnt = ARRAY_SIZE(omap3xxx_l4_per_slaves),
Kevin Hilman2eb18752010-07-26 16:34:28 -0600512 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
513 .flags = HWMOD_NO_IDLEST,
Paul Walmsley73591542010-02-22 22:09:32 -0700514};
515
516/* Slave interfaces on the L4_WKUP interconnect */
517static struct omap_hwmod_ocp_if *omap3xxx_l4_wkup_slaves[] = {
518 &omap3xxx_l4_core__l4_wkup,
519};
520
521/* Master interfaces on the L4_WKUP interconnect */
522static struct omap_hwmod_ocp_if *omap3xxx_l4_wkup_masters[] = {
523};
524
525/* L4 WKUP */
526static struct omap_hwmod omap3xxx_l4_wkup_hwmod = {
Benoit Coussonfa983472010-07-26 16:34:29 -0600527 .name = "l4_wkup",
Paul Walmsley43b40992010-02-22 22:09:34 -0700528 .class = &l4_hwmod_class,
Paul Walmsley73591542010-02-22 22:09:32 -0700529 .masters = omap3xxx_l4_wkup_masters,
530 .masters_cnt = ARRAY_SIZE(omap3xxx_l4_wkup_masters),
531 .slaves = omap3xxx_l4_wkup_slaves,
532 .slaves_cnt = ARRAY_SIZE(omap3xxx_l4_wkup_slaves),
Kevin Hilman2eb18752010-07-26 16:34:28 -0600533 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
534 .flags = HWMOD_NO_IDLEST,
Paul Walmsley73591542010-02-22 22:09:32 -0700535};
536
537/* Master interfaces on the MPU device */
538static struct omap_hwmod_ocp_if *omap3xxx_mpu_masters[] = {
Kevin Hilman4a7cf902010-07-26 16:34:32 -0600539 &omap3xxx_mpu__l3_main,
Paul Walmsley73591542010-02-22 22:09:32 -0700540};
541
542/* MPU */
543static struct omap_hwmod omap3xxx_mpu_hwmod = {
Benoit Cousson5c2c0292010-05-20 12:31:10 -0600544 .name = "mpu",
Paul Walmsley43b40992010-02-22 22:09:34 -0700545 .class = &mpu_hwmod_class,
Paul Walmsley73591542010-02-22 22:09:32 -0700546 .main_clk = "arm_fck",
547 .masters = omap3xxx_mpu_masters,
548 .masters_cnt = ARRAY_SIZE(omap3xxx_mpu_masters),
549 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
550};
551
Kevin Hilman540064b2010-07-26 16:34:32 -0600552/*
553 * IVA2_2 interface data
554 */
555
556/* IVA2 <- L3 interface */
557static struct omap_hwmod_ocp_if omap3xxx_l3__iva = {
558 .master = &omap3xxx_l3_main_hwmod,
559 .slave = &omap3xxx_iva_hwmod,
560 .clk = "iva2_ck",
561 .user = OCP_USER_MPU | OCP_USER_SDMA,
562};
563
564static struct omap_hwmod_ocp_if *omap3xxx_iva_masters[] = {
565 &omap3xxx_l3__iva,
566};
567
568/*
569 * IVA2 (IVA2)
570 */
571
572static struct omap_hwmod omap3xxx_iva_hwmod = {
573 .name = "iva",
574 .class = &iva_hwmod_class,
575 .masters = omap3xxx_iva_masters,
576 .masters_cnt = ARRAY_SIZE(omap3xxx_iva_masters),
577 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
578};
579
Thara Gopinathce722d22011-02-23 00:14:05 -0700580/* timer class */
581static struct omap_hwmod_class_sysconfig omap3xxx_timer_1ms_sysc = {
582 .rev_offs = 0x0000,
583 .sysc_offs = 0x0010,
584 .syss_offs = 0x0014,
585 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_CLOCKACTIVITY |
586 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
587 SYSC_HAS_EMUFREE | SYSC_HAS_AUTOIDLE),
588 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
589 .sysc_fields = &omap_hwmod_sysc_type1,
590};
591
592static struct omap_hwmod_class omap3xxx_timer_1ms_hwmod_class = {
593 .name = "timer",
594 .sysc = &omap3xxx_timer_1ms_sysc,
595 .rev = OMAP_TIMER_IP_VERSION_1,
596};
597
598static struct omap_hwmod_class_sysconfig omap3xxx_timer_sysc = {
599 .rev_offs = 0x0000,
600 .sysc_offs = 0x0010,
601 .syss_offs = 0x0014,
602 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP |
603 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
604 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
605 .sysc_fields = &omap_hwmod_sysc_type1,
606};
607
608static struct omap_hwmod_class omap3xxx_timer_hwmod_class = {
609 .name = "timer",
610 .sysc = &omap3xxx_timer_sysc,
611 .rev = OMAP_TIMER_IP_VERSION_1,
612};
613
614/* timer1 */
615static struct omap_hwmod omap3xxx_timer1_hwmod;
616static struct omap_hwmod_irq_info omap3xxx_timer1_mpu_irqs[] = {
617 { .irq = 37, },
618};
619
620static struct omap_hwmod_addr_space omap3xxx_timer1_addrs[] = {
621 {
622 .pa_start = 0x48318000,
623 .pa_end = 0x48318000 + SZ_1K - 1,
624 .flags = ADDR_TYPE_RT
625 },
626};
627
628/* l4_wkup -> timer1 */
629static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__timer1 = {
630 .master = &omap3xxx_l4_wkup_hwmod,
631 .slave = &omap3xxx_timer1_hwmod,
632 .clk = "gpt1_ick",
633 .addr = omap3xxx_timer1_addrs,
634 .addr_cnt = ARRAY_SIZE(omap3xxx_timer1_addrs),
635 .user = OCP_USER_MPU | OCP_USER_SDMA,
636};
637
638/* timer1 slave port */
639static struct omap_hwmod_ocp_if *omap3xxx_timer1_slaves[] = {
640 &omap3xxx_l4_wkup__timer1,
641};
642
643/* timer1 hwmod */
644static struct omap_hwmod omap3xxx_timer1_hwmod = {
645 .name = "timer1",
646 .mpu_irqs = omap3xxx_timer1_mpu_irqs,
647 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer1_mpu_irqs),
648 .main_clk = "gpt1_fck",
649 .prcm = {
650 .omap2 = {
651 .prcm_reg_id = 1,
652 .module_bit = OMAP3430_EN_GPT1_SHIFT,
653 .module_offs = WKUP_MOD,
654 .idlest_reg_id = 1,
655 .idlest_idle_bit = OMAP3430_ST_GPT1_SHIFT,
656 },
657 },
658 .slaves = omap3xxx_timer1_slaves,
659 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer1_slaves),
660 .class = &omap3xxx_timer_1ms_hwmod_class,
661 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
662};
663
664/* timer2 */
665static struct omap_hwmod omap3xxx_timer2_hwmod;
666static struct omap_hwmod_irq_info omap3xxx_timer2_mpu_irqs[] = {
667 { .irq = 38, },
668};
669
670static struct omap_hwmod_addr_space omap3xxx_timer2_addrs[] = {
671 {
672 .pa_start = 0x49032000,
673 .pa_end = 0x49032000 + SZ_1K - 1,
674 .flags = ADDR_TYPE_RT
675 },
676};
677
678/* l4_per -> timer2 */
679static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer2 = {
680 .master = &omap3xxx_l4_per_hwmod,
681 .slave = &omap3xxx_timer2_hwmod,
682 .clk = "gpt2_ick",
683 .addr = omap3xxx_timer2_addrs,
684 .addr_cnt = ARRAY_SIZE(omap3xxx_timer2_addrs),
685 .user = OCP_USER_MPU | OCP_USER_SDMA,
686};
687
688/* timer2 slave port */
689static struct omap_hwmod_ocp_if *omap3xxx_timer2_slaves[] = {
690 &omap3xxx_l4_per__timer2,
691};
692
693/* timer2 hwmod */
694static struct omap_hwmod omap3xxx_timer2_hwmod = {
695 .name = "timer2",
696 .mpu_irqs = omap3xxx_timer2_mpu_irqs,
697 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer2_mpu_irqs),
698 .main_clk = "gpt2_fck",
699 .prcm = {
700 .omap2 = {
701 .prcm_reg_id = 1,
702 .module_bit = OMAP3430_EN_GPT2_SHIFT,
703 .module_offs = OMAP3430_PER_MOD,
704 .idlest_reg_id = 1,
705 .idlest_idle_bit = OMAP3430_ST_GPT2_SHIFT,
706 },
707 },
708 .slaves = omap3xxx_timer2_slaves,
709 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer2_slaves),
710 .class = &omap3xxx_timer_1ms_hwmod_class,
711 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
712};
713
714/* timer3 */
715static struct omap_hwmod omap3xxx_timer3_hwmod;
716static struct omap_hwmod_irq_info omap3xxx_timer3_mpu_irqs[] = {
717 { .irq = 39, },
718};
719
720static struct omap_hwmod_addr_space omap3xxx_timer3_addrs[] = {
721 {
722 .pa_start = 0x49034000,
723 .pa_end = 0x49034000 + SZ_1K - 1,
724 .flags = ADDR_TYPE_RT
725 },
726};
727
728/* l4_per -> timer3 */
729static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer3 = {
730 .master = &omap3xxx_l4_per_hwmod,
731 .slave = &omap3xxx_timer3_hwmod,
732 .clk = "gpt3_ick",
733 .addr = omap3xxx_timer3_addrs,
734 .addr_cnt = ARRAY_SIZE(omap3xxx_timer3_addrs),
735 .user = OCP_USER_MPU | OCP_USER_SDMA,
736};
737
738/* timer3 slave port */
739static struct omap_hwmod_ocp_if *omap3xxx_timer3_slaves[] = {
740 &omap3xxx_l4_per__timer3,
741};
742
743/* timer3 hwmod */
744static struct omap_hwmod omap3xxx_timer3_hwmod = {
745 .name = "timer3",
746 .mpu_irqs = omap3xxx_timer3_mpu_irqs,
747 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer3_mpu_irqs),
748 .main_clk = "gpt3_fck",
749 .prcm = {
750 .omap2 = {
751 .prcm_reg_id = 1,
752 .module_bit = OMAP3430_EN_GPT3_SHIFT,
753 .module_offs = OMAP3430_PER_MOD,
754 .idlest_reg_id = 1,
755 .idlest_idle_bit = OMAP3430_ST_GPT3_SHIFT,
756 },
757 },
758 .slaves = omap3xxx_timer3_slaves,
759 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer3_slaves),
760 .class = &omap3xxx_timer_hwmod_class,
761 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
762};
763
764/* timer4 */
765static struct omap_hwmod omap3xxx_timer4_hwmod;
766static struct omap_hwmod_irq_info omap3xxx_timer4_mpu_irqs[] = {
767 { .irq = 40, },
768};
769
770static struct omap_hwmod_addr_space omap3xxx_timer4_addrs[] = {
771 {
772 .pa_start = 0x49036000,
773 .pa_end = 0x49036000 + SZ_1K - 1,
774 .flags = ADDR_TYPE_RT
775 },
776};
777
778/* l4_per -> timer4 */
779static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer4 = {
780 .master = &omap3xxx_l4_per_hwmod,
781 .slave = &omap3xxx_timer4_hwmod,
782 .clk = "gpt4_ick",
783 .addr = omap3xxx_timer4_addrs,
784 .addr_cnt = ARRAY_SIZE(omap3xxx_timer4_addrs),
785 .user = OCP_USER_MPU | OCP_USER_SDMA,
786};
787
788/* timer4 slave port */
789static struct omap_hwmod_ocp_if *omap3xxx_timer4_slaves[] = {
790 &omap3xxx_l4_per__timer4,
791};
792
793/* timer4 hwmod */
794static struct omap_hwmod omap3xxx_timer4_hwmod = {
795 .name = "timer4",
796 .mpu_irqs = omap3xxx_timer4_mpu_irqs,
797 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer4_mpu_irqs),
798 .main_clk = "gpt4_fck",
799 .prcm = {
800 .omap2 = {
801 .prcm_reg_id = 1,
802 .module_bit = OMAP3430_EN_GPT4_SHIFT,
803 .module_offs = OMAP3430_PER_MOD,
804 .idlest_reg_id = 1,
805 .idlest_idle_bit = OMAP3430_ST_GPT4_SHIFT,
806 },
807 },
808 .slaves = omap3xxx_timer4_slaves,
809 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer4_slaves),
810 .class = &omap3xxx_timer_hwmod_class,
811 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
812};
813
814/* timer5 */
815static struct omap_hwmod omap3xxx_timer5_hwmod;
816static struct omap_hwmod_irq_info omap3xxx_timer5_mpu_irqs[] = {
817 { .irq = 41, },
818};
819
820static struct omap_hwmod_addr_space omap3xxx_timer5_addrs[] = {
821 {
822 .pa_start = 0x49038000,
823 .pa_end = 0x49038000 + SZ_1K - 1,
824 .flags = ADDR_TYPE_RT
825 },
826};
827
828/* l4_per -> timer5 */
829static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer5 = {
830 .master = &omap3xxx_l4_per_hwmod,
831 .slave = &omap3xxx_timer5_hwmod,
832 .clk = "gpt5_ick",
833 .addr = omap3xxx_timer5_addrs,
834 .addr_cnt = ARRAY_SIZE(omap3xxx_timer5_addrs),
835 .user = OCP_USER_MPU | OCP_USER_SDMA,
836};
837
838/* timer5 slave port */
839static struct omap_hwmod_ocp_if *omap3xxx_timer5_slaves[] = {
840 &omap3xxx_l4_per__timer5,
841};
842
843/* timer5 hwmod */
844static struct omap_hwmod omap3xxx_timer5_hwmod = {
845 .name = "timer5",
846 .mpu_irqs = omap3xxx_timer5_mpu_irqs,
847 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer5_mpu_irqs),
848 .main_clk = "gpt5_fck",
849 .prcm = {
850 .omap2 = {
851 .prcm_reg_id = 1,
852 .module_bit = OMAP3430_EN_GPT5_SHIFT,
853 .module_offs = OMAP3430_PER_MOD,
854 .idlest_reg_id = 1,
855 .idlest_idle_bit = OMAP3430_ST_GPT5_SHIFT,
856 },
857 },
858 .slaves = omap3xxx_timer5_slaves,
859 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer5_slaves),
860 .class = &omap3xxx_timer_hwmod_class,
861 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
862};
863
864/* timer6 */
865static struct omap_hwmod omap3xxx_timer6_hwmod;
866static struct omap_hwmod_irq_info omap3xxx_timer6_mpu_irqs[] = {
867 { .irq = 42, },
868};
869
870static struct omap_hwmod_addr_space omap3xxx_timer6_addrs[] = {
871 {
872 .pa_start = 0x4903A000,
873 .pa_end = 0x4903A000 + SZ_1K - 1,
874 .flags = ADDR_TYPE_RT
875 },
876};
877
878/* l4_per -> timer6 */
879static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer6 = {
880 .master = &omap3xxx_l4_per_hwmod,
881 .slave = &omap3xxx_timer6_hwmod,
882 .clk = "gpt6_ick",
883 .addr = omap3xxx_timer6_addrs,
884 .addr_cnt = ARRAY_SIZE(omap3xxx_timer6_addrs),
885 .user = OCP_USER_MPU | OCP_USER_SDMA,
886};
887
888/* timer6 slave port */
889static struct omap_hwmod_ocp_if *omap3xxx_timer6_slaves[] = {
890 &omap3xxx_l4_per__timer6,
891};
892
893/* timer6 hwmod */
894static struct omap_hwmod omap3xxx_timer6_hwmod = {
895 .name = "timer6",
896 .mpu_irqs = omap3xxx_timer6_mpu_irqs,
897 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer6_mpu_irqs),
898 .main_clk = "gpt6_fck",
899 .prcm = {
900 .omap2 = {
901 .prcm_reg_id = 1,
902 .module_bit = OMAP3430_EN_GPT6_SHIFT,
903 .module_offs = OMAP3430_PER_MOD,
904 .idlest_reg_id = 1,
905 .idlest_idle_bit = OMAP3430_ST_GPT6_SHIFT,
906 },
907 },
908 .slaves = omap3xxx_timer6_slaves,
909 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer6_slaves),
910 .class = &omap3xxx_timer_hwmod_class,
911 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
912};
913
914/* timer7 */
915static struct omap_hwmod omap3xxx_timer7_hwmod;
916static struct omap_hwmod_irq_info omap3xxx_timer7_mpu_irqs[] = {
917 { .irq = 43, },
918};
919
920static struct omap_hwmod_addr_space omap3xxx_timer7_addrs[] = {
921 {
922 .pa_start = 0x4903C000,
923 .pa_end = 0x4903C000 + SZ_1K - 1,
924 .flags = ADDR_TYPE_RT
925 },
926};
927
928/* l4_per -> timer7 */
929static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer7 = {
930 .master = &omap3xxx_l4_per_hwmod,
931 .slave = &omap3xxx_timer7_hwmod,
932 .clk = "gpt7_ick",
933 .addr = omap3xxx_timer7_addrs,
934 .addr_cnt = ARRAY_SIZE(omap3xxx_timer7_addrs),
935 .user = OCP_USER_MPU | OCP_USER_SDMA,
936};
937
938/* timer7 slave port */
939static struct omap_hwmod_ocp_if *omap3xxx_timer7_slaves[] = {
940 &omap3xxx_l4_per__timer7,
941};
942
943/* timer7 hwmod */
944static struct omap_hwmod omap3xxx_timer7_hwmod = {
945 .name = "timer7",
946 .mpu_irqs = omap3xxx_timer7_mpu_irqs,
947 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer7_mpu_irqs),
948 .main_clk = "gpt7_fck",
949 .prcm = {
950 .omap2 = {
951 .prcm_reg_id = 1,
952 .module_bit = OMAP3430_EN_GPT7_SHIFT,
953 .module_offs = OMAP3430_PER_MOD,
954 .idlest_reg_id = 1,
955 .idlest_idle_bit = OMAP3430_ST_GPT7_SHIFT,
956 },
957 },
958 .slaves = omap3xxx_timer7_slaves,
959 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer7_slaves),
960 .class = &omap3xxx_timer_hwmod_class,
961 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
962};
963
964/* timer8 */
965static struct omap_hwmod omap3xxx_timer8_hwmod;
966static struct omap_hwmod_irq_info omap3xxx_timer8_mpu_irqs[] = {
967 { .irq = 44, },
968};
969
970static struct omap_hwmod_addr_space omap3xxx_timer8_addrs[] = {
971 {
972 .pa_start = 0x4903E000,
973 .pa_end = 0x4903E000 + SZ_1K - 1,
974 .flags = ADDR_TYPE_RT
975 },
976};
977
978/* l4_per -> timer8 */
979static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer8 = {
980 .master = &omap3xxx_l4_per_hwmod,
981 .slave = &omap3xxx_timer8_hwmod,
982 .clk = "gpt8_ick",
983 .addr = omap3xxx_timer8_addrs,
984 .addr_cnt = ARRAY_SIZE(omap3xxx_timer8_addrs),
985 .user = OCP_USER_MPU | OCP_USER_SDMA,
986};
987
988/* timer8 slave port */
989static struct omap_hwmod_ocp_if *omap3xxx_timer8_slaves[] = {
990 &omap3xxx_l4_per__timer8,
991};
992
993/* timer8 hwmod */
994static struct omap_hwmod omap3xxx_timer8_hwmod = {
995 .name = "timer8",
996 .mpu_irqs = omap3xxx_timer8_mpu_irqs,
997 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer8_mpu_irqs),
998 .main_clk = "gpt8_fck",
999 .prcm = {
1000 .omap2 = {
1001 .prcm_reg_id = 1,
1002 .module_bit = OMAP3430_EN_GPT8_SHIFT,
1003 .module_offs = OMAP3430_PER_MOD,
1004 .idlest_reg_id = 1,
1005 .idlest_idle_bit = OMAP3430_ST_GPT8_SHIFT,
1006 },
1007 },
1008 .slaves = omap3xxx_timer8_slaves,
1009 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer8_slaves),
1010 .class = &omap3xxx_timer_hwmod_class,
1011 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
1012};
1013
1014/* timer9 */
1015static struct omap_hwmod omap3xxx_timer9_hwmod;
1016static struct omap_hwmod_irq_info omap3xxx_timer9_mpu_irqs[] = {
1017 { .irq = 45, },
1018};
1019
1020static struct omap_hwmod_addr_space omap3xxx_timer9_addrs[] = {
1021 {
1022 .pa_start = 0x49040000,
1023 .pa_end = 0x49040000 + SZ_1K - 1,
1024 .flags = ADDR_TYPE_RT
1025 },
1026};
1027
1028/* l4_per -> timer9 */
1029static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer9 = {
1030 .master = &omap3xxx_l4_per_hwmod,
1031 .slave = &omap3xxx_timer9_hwmod,
1032 .clk = "gpt9_ick",
1033 .addr = omap3xxx_timer9_addrs,
1034 .addr_cnt = ARRAY_SIZE(omap3xxx_timer9_addrs),
1035 .user = OCP_USER_MPU | OCP_USER_SDMA,
1036};
1037
1038/* timer9 slave port */
1039static struct omap_hwmod_ocp_if *omap3xxx_timer9_slaves[] = {
1040 &omap3xxx_l4_per__timer9,
1041};
1042
1043/* timer9 hwmod */
1044static struct omap_hwmod omap3xxx_timer9_hwmod = {
1045 .name = "timer9",
1046 .mpu_irqs = omap3xxx_timer9_mpu_irqs,
1047 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer9_mpu_irqs),
1048 .main_clk = "gpt9_fck",
1049 .prcm = {
1050 .omap2 = {
1051 .prcm_reg_id = 1,
1052 .module_bit = OMAP3430_EN_GPT9_SHIFT,
1053 .module_offs = OMAP3430_PER_MOD,
1054 .idlest_reg_id = 1,
1055 .idlest_idle_bit = OMAP3430_ST_GPT9_SHIFT,
1056 },
1057 },
1058 .slaves = omap3xxx_timer9_slaves,
1059 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer9_slaves),
1060 .class = &omap3xxx_timer_hwmod_class,
1061 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
1062};
1063
1064/* timer10 */
1065static struct omap_hwmod omap3xxx_timer10_hwmod;
1066static struct omap_hwmod_irq_info omap3xxx_timer10_mpu_irqs[] = {
1067 { .irq = 46, },
1068};
1069
1070static struct omap_hwmod_addr_space omap3xxx_timer10_addrs[] = {
1071 {
1072 .pa_start = 0x48086000,
1073 .pa_end = 0x48086000 + SZ_1K - 1,
1074 .flags = ADDR_TYPE_RT
1075 },
1076};
1077
1078/* l4_core -> timer10 */
1079static struct omap_hwmod_ocp_if omap3xxx_l4_core__timer10 = {
1080 .master = &omap3xxx_l4_core_hwmod,
1081 .slave = &omap3xxx_timer10_hwmod,
1082 .clk = "gpt10_ick",
1083 .addr = omap3xxx_timer10_addrs,
1084 .addr_cnt = ARRAY_SIZE(omap3xxx_timer10_addrs),
1085 .user = OCP_USER_MPU | OCP_USER_SDMA,
1086};
1087
1088/* timer10 slave port */
1089static struct omap_hwmod_ocp_if *omap3xxx_timer10_slaves[] = {
1090 &omap3xxx_l4_core__timer10,
1091};
1092
1093/* timer10 hwmod */
1094static struct omap_hwmod omap3xxx_timer10_hwmod = {
1095 .name = "timer10",
1096 .mpu_irqs = omap3xxx_timer10_mpu_irqs,
1097 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer10_mpu_irqs),
1098 .main_clk = "gpt10_fck",
1099 .prcm = {
1100 .omap2 = {
1101 .prcm_reg_id = 1,
1102 .module_bit = OMAP3430_EN_GPT10_SHIFT,
1103 .module_offs = CORE_MOD,
1104 .idlest_reg_id = 1,
1105 .idlest_idle_bit = OMAP3430_ST_GPT10_SHIFT,
1106 },
1107 },
1108 .slaves = omap3xxx_timer10_slaves,
1109 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer10_slaves),
1110 .class = &omap3xxx_timer_1ms_hwmod_class,
1111 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
1112};
1113
1114/* timer11 */
1115static struct omap_hwmod omap3xxx_timer11_hwmod;
1116static struct omap_hwmod_irq_info omap3xxx_timer11_mpu_irqs[] = {
1117 { .irq = 47, },
1118};
1119
1120static struct omap_hwmod_addr_space omap3xxx_timer11_addrs[] = {
1121 {
1122 .pa_start = 0x48088000,
1123 .pa_end = 0x48088000 + SZ_1K - 1,
1124 .flags = ADDR_TYPE_RT
1125 },
1126};
1127
1128/* l4_core -> timer11 */
1129static struct omap_hwmod_ocp_if omap3xxx_l4_core__timer11 = {
1130 .master = &omap3xxx_l4_core_hwmod,
1131 .slave = &omap3xxx_timer11_hwmod,
1132 .clk = "gpt11_ick",
1133 .addr = omap3xxx_timer11_addrs,
1134 .addr_cnt = ARRAY_SIZE(omap3xxx_timer11_addrs),
1135 .user = OCP_USER_MPU | OCP_USER_SDMA,
1136};
1137
1138/* timer11 slave port */
1139static struct omap_hwmod_ocp_if *omap3xxx_timer11_slaves[] = {
1140 &omap3xxx_l4_core__timer11,
1141};
1142
1143/* timer11 hwmod */
1144static struct omap_hwmod omap3xxx_timer11_hwmod = {
1145 .name = "timer11",
1146 .mpu_irqs = omap3xxx_timer11_mpu_irqs,
1147 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer11_mpu_irqs),
1148 .main_clk = "gpt11_fck",
1149 .prcm = {
1150 .omap2 = {
1151 .prcm_reg_id = 1,
1152 .module_bit = OMAP3430_EN_GPT11_SHIFT,
1153 .module_offs = CORE_MOD,
1154 .idlest_reg_id = 1,
1155 .idlest_idle_bit = OMAP3430_ST_GPT11_SHIFT,
1156 },
1157 },
1158 .slaves = omap3xxx_timer11_slaves,
1159 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer11_slaves),
1160 .class = &omap3xxx_timer_hwmod_class,
1161 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
1162};
1163
1164/* timer12*/
1165static struct omap_hwmod omap3xxx_timer12_hwmod;
1166static struct omap_hwmod_irq_info omap3xxx_timer12_mpu_irqs[] = {
1167 { .irq = 95, },
1168};
1169
1170static struct omap_hwmod_addr_space omap3xxx_timer12_addrs[] = {
1171 {
1172 .pa_start = 0x48304000,
1173 .pa_end = 0x48304000 + SZ_1K - 1,
1174 .flags = ADDR_TYPE_RT
1175 },
1176};
1177
1178/* l4_core -> timer12 */
1179static struct omap_hwmod_ocp_if omap3xxx_l4_core__timer12 = {
1180 .master = &omap3xxx_l4_core_hwmod,
1181 .slave = &omap3xxx_timer12_hwmod,
1182 .clk = "gpt12_ick",
1183 .addr = omap3xxx_timer12_addrs,
1184 .addr_cnt = ARRAY_SIZE(omap3xxx_timer12_addrs),
1185 .user = OCP_USER_MPU | OCP_USER_SDMA,
1186};
1187
1188/* timer12 slave port */
1189static struct omap_hwmod_ocp_if *omap3xxx_timer12_slaves[] = {
1190 &omap3xxx_l4_core__timer12,
1191};
1192
1193/* timer12 hwmod */
1194static struct omap_hwmod omap3xxx_timer12_hwmod = {
1195 .name = "timer12",
1196 .mpu_irqs = omap3xxx_timer12_mpu_irqs,
1197 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_timer12_mpu_irqs),
1198 .main_clk = "gpt12_fck",
1199 .prcm = {
1200 .omap2 = {
1201 .prcm_reg_id = 1,
1202 .module_bit = OMAP3430_EN_GPT12_SHIFT,
1203 .module_offs = WKUP_MOD,
1204 .idlest_reg_id = 1,
1205 .idlest_idle_bit = OMAP3430_ST_GPT12_SHIFT,
1206 },
1207 },
1208 .slaves = omap3xxx_timer12_slaves,
1209 .slaves_cnt = ARRAY_SIZE(omap3xxx_timer12_slaves),
1210 .class = &omap3xxx_timer_hwmod_class,
1211 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
1212};
1213
Varadarajan, Charulatha6b667f82010-09-23 20:02:38 +05301214/* l4_wkup -> wd_timer2 */
1215static struct omap_hwmod_addr_space omap3xxx_wd_timer2_addrs[] = {
1216 {
1217 .pa_start = 0x48314000,
1218 .pa_end = 0x4831407f,
1219 .flags = ADDR_TYPE_RT
1220 },
1221};
1222
1223static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__wd_timer2 = {
1224 .master = &omap3xxx_l4_wkup_hwmod,
1225 .slave = &omap3xxx_wd_timer2_hwmod,
1226 .clk = "wdt2_ick",
1227 .addr = omap3xxx_wd_timer2_addrs,
1228 .addr_cnt = ARRAY_SIZE(omap3xxx_wd_timer2_addrs),
1229 .user = OCP_USER_MPU | OCP_USER_SDMA,
1230};
1231
1232/*
1233 * 'wd_timer' class
1234 * 32-bit watchdog upward counter that generates a pulse on the reset pin on
1235 * overflow condition
1236 */
1237
1238static struct omap_hwmod_class_sysconfig omap3xxx_wd_timer_sysc = {
1239 .rev_offs = 0x0000,
1240 .sysc_offs = 0x0010,
1241 .syss_offs = 0x0014,
1242 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_EMUFREE |
1243 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
1244 SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY),
1245 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1246 .sysc_fields = &omap_hwmod_sysc_type1,
1247};
1248
Rajendra Nayak4fe20e92010-09-21 19:37:13 +05301249/* I2C common */
1250static struct omap_hwmod_class_sysconfig i2c_sysc = {
1251 .rev_offs = 0x00,
1252 .sysc_offs = 0x20,
1253 .syss_offs = 0x10,
1254 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
1255 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
1256 SYSC_HAS_AUTOIDLE),
1257 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1258 .sysc_fields = &omap_hwmod_sysc_type1,
1259};
1260
Varadarajan, Charulatha6b667f82010-09-23 20:02:38 +05301261static struct omap_hwmod_class omap3xxx_wd_timer_hwmod_class = {
Paul Walmsleyff2516f2010-12-21 15:39:15 -07001262 .name = "wd_timer",
1263 .sysc = &omap3xxx_wd_timer_sysc,
1264 .pre_shutdown = &omap2_wd_timer_disable
Varadarajan, Charulatha6b667f82010-09-23 20:02:38 +05301265};
1266
1267/* wd_timer2 */
1268static struct omap_hwmod_ocp_if *omap3xxx_wd_timer2_slaves[] = {
1269 &omap3xxx_l4_wkup__wd_timer2,
1270};
1271
1272static struct omap_hwmod omap3xxx_wd_timer2_hwmod = {
1273 .name = "wd_timer2",
1274 .class = &omap3xxx_wd_timer_hwmod_class,
1275 .main_clk = "wdt2_fck",
1276 .prcm = {
1277 .omap2 = {
1278 .prcm_reg_id = 1,
1279 .module_bit = OMAP3430_EN_WDT2_SHIFT,
1280 .module_offs = WKUP_MOD,
1281 .idlest_reg_id = 1,
1282 .idlest_idle_bit = OMAP3430_ST_WDT2_SHIFT,
1283 },
1284 },
1285 .slaves = omap3xxx_wd_timer2_slaves,
1286 .slaves_cnt = ARRAY_SIZE(omap3xxx_wd_timer2_slaves),
1287 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
1288};
1289
Kevin Hilman046465b2010-09-27 20:19:30 +05301290/* UART common */
1291
1292static struct omap_hwmod_class_sysconfig uart_sysc = {
1293 .rev_offs = 0x50,
1294 .sysc_offs = 0x54,
1295 .syss_offs = 0x58,
1296 .sysc_flags = (SYSC_HAS_SIDLEMODE |
1297 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
1298 SYSC_HAS_AUTOIDLE),
1299 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1300 .sysc_fields = &omap_hwmod_sysc_type1,
1301};
1302
1303static struct omap_hwmod_class uart_class = {
1304 .name = "uart",
1305 .sysc = &uart_sysc,
1306};
1307
1308/* UART1 */
1309
1310static struct omap_hwmod_irq_info uart1_mpu_irqs[] = {
1311 { .irq = INT_24XX_UART1_IRQ, },
1312};
1313
1314static struct omap_hwmod_dma_info uart1_sdma_reqs[] = {
1315 { .name = "tx", .dma_req = OMAP24XX_DMA_UART1_TX, },
1316 { .name = "rx", .dma_req = OMAP24XX_DMA_UART1_RX, },
1317};
1318
1319static struct omap_hwmod_ocp_if *omap3xxx_uart1_slaves[] = {
1320 &omap3_l4_core__uart1,
1321};
1322
1323static struct omap_hwmod omap3xxx_uart1_hwmod = {
1324 .name = "uart1",
1325 .mpu_irqs = uart1_mpu_irqs,
1326 .mpu_irqs_cnt = ARRAY_SIZE(uart1_mpu_irqs),
1327 .sdma_reqs = uart1_sdma_reqs,
1328 .sdma_reqs_cnt = ARRAY_SIZE(uart1_sdma_reqs),
1329 .main_clk = "uart1_fck",
1330 .prcm = {
1331 .omap2 = {
1332 .module_offs = CORE_MOD,
1333 .prcm_reg_id = 1,
1334 .module_bit = OMAP3430_EN_UART1_SHIFT,
1335 .idlest_reg_id = 1,
1336 .idlest_idle_bit = OMAP3430_EN_UART1_SHIFT,
1337 },
1338 },
1339 .slaves = omap3xxx_uart1_slaves,
1340 .slaves_cnt = ARRAY_SIZE(omap3xxx_uart1_slaves),
1341 .class = &uart_class,
1342 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
1343};
1344
1345/* UART2 */
1346
1347static struct omap_hwmod_irq_info uart2_mpu_irqs[] = {
1348 { .irq = INT_24XX_UART2_IRQ, },
1349};
1350
1351static struct omap_hwmod_dma_info uart2_sdma_reqs[] = {
1352 { .name = "tx", .dma_req = OMAP24XX_DMA_UART2_TX, },
1353 { .name = "rx", .dma_req = OMAP24XX_DMA_UART2_RX, },
1354};
1355
1356static struct omap_hwmod_ocp_if *omap3xxx_uart2_slaves[] = {
1357 &omap3_l4_core__uart2,
1358};
1359
1360static struct omap_hwmod omap3xxx_uart2_hwmod = {
1361 .name = "uart2",
1362 .mpu_irqs = uart2_mpu_irqs,
1363 .mpu_irqs_cnt = ARRAY_SIZE(uart2_mpu_irqs),
1364 .sdma_reqs = uart2_sdma_reqs,
1365 .sdma_reqs_cnt = ARRAY_SIZE(uart2_sdma_reqs),
1366 .main_clk = "uart2_fck",
1367 .prcm = {
1368 .omap2 = {
1369 .module_offs = CORE_MOD,
1370 .prcm_reg_id = 1,
1371 .module_bit = OMAP3430_EN_UART2_SHIFT,
1372 .idlest_reg_id = 1,
1373 .idlest_idle_bit = OMAP3430_EN_UART2_SHIFT,
1374 },
1375 },
1376 .slaves = omap3xxx_uart2_slaves,
1377 .slaves_cnt = ARRAY_SIZE(omap3xxx_uart2_slaves),
1378 .class = &uart_class,
1379 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
1380};
1381
1382/* UART3 */
1383
1384static struct omap_hwmod_irq_info uart3_mpu_irqs[] = {
1385 { .irq = INT_24XX_UART3_IRQ, },
1386};
1387
1388static struct omap_hwmod_dma_info uart3_sdma_reqs[] = {
1389 { .name = "tx", .dma_req = OMAP24XX_DMA_UART3_TX, },
1390 { .name = "rx", .dma_req = OMAP24XX_DMA_UART3_RX, },
1391};
1392
1393static struct omap_hwmod_ocp_if *omap3xxx_uart3_slaves[] = {
1394 &omap3_l4_per__uart3,
1395};
1396
1397static struct omap_hwmod omap3xxx_uart3_hwmod = {
1398 .name = "uart3",
1399 .mpu_irqs = uart3_mpu_irqs,
1400 .mpu_irqs_cnt = ARRAY_SIZE(uart3_mpu_irqs),
1401 .sdma_reqs = uart3_sdma_reqs,
1402 .sdma_reqs_cnt = ARRAY_SIZE(uart3_sdma_reqs),
1403 .main_clk = "uart3_fck",
1404 .prcm = {
1405 .omap2 = {
1406 .module_offs = OMAP3430_PER_MOD,
1407 .prcm_reg_id = 1,
1408 .module_bit = OMAP3430_EN_UART3_SHIFT,
1409 .idlest_reg_id = 1,
1410 .idlest_idle_bit = OMAP3430_EN_UART3_SHIFT,
1411 },
1412 },
1413 .slaves = omap3xxx_uart3_slaves,
1414 .slaves_cnt = ARRAY_SIZE(omap3xxx_uart3_slaves),
1415 .class = &uart_class,
1416 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
1417};
1418
1419/* UART4 */
1420
1421static struct omap_hwmod_irq_info uart4_mpu_irqs[] = {
1422 { .irq = INT_36XX_UART4_IRQ, },
1423};
1424
1425static struct omap_hwmod_dma_info uart4_sdma_reqs[] = {
1426 { .name = "rx", .dma_req = OMAP36XX_DMA_UART4_RX, },
1427 { .name = "tx", .dma_req = OMAP36XX_DMA_UART4_TX, },
1428};
1429
1430static struct omap_hwmod_ocp_if *omap3xxx_uart4_slaves[] = {
1431 &omap3_l4_per__uart4,
1432};
1433
1434static struct omap_hwmod omap3xxx_uart4_hwmod = {
1435 .name = "uart4",
1436 .mpu_irqs = uart4_mpu_irqs,
1437 .mpu_irqs_cnt = ARRAY_SIZE(uart4_mpu_irqs),
1438 .sdma_reqs = uart4_sdma_reqs,
1439 .sdma_reqs_cnt = ARRAY_SIZE(uart4_sdma_reqs),
1440 .main_clk = "uart4_fck",
1441 .prcm = {
1442 .omap2 = {
1443 .module_offs = OMAP3430_PER_MOD,
1444 .prcm_reg_id = 1,
1445 .module_bit = OMAP3630_EN_UART4_SHIFT,
1446 .idlest_reg_id = 1,
1447 .idlest_idle_bit = OMAP3630_EN_UART4_SHIFT,
1448 },
1449 },
1450 .slaves = omap3xxx_uart4_slaves,
1451 .slaves_cnt = ARRAY_SIZE(omap3xxx_uart4_slaves),
1452 .class = &uart_class,
1453 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3630ES1),
1454};
1455
Rajendra Nayak4fe20e92010-09-21 19:37:13 +05301456static struct omap_hwmod_class i2c_class = {
1457 .name = "i2c",
1458 .sysc = &i2c_sysc,
1459};
1460
Senthilvadivu Guruswamye04d9e12011-01-24 06:21:51 +00001461/*
1462 * 'dss' class
1463 * display sub-system
1464 */
1465
1466static struct omap_hwmod_class_sysconfig omap3xxx_dss_sysc = {
1467 .rev_offs = 0x0000,
1468 .sysc_offs = 0x0010,
1469 .syss_offs = 0x0014,
1470 .sysc_flags = (SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
1471 .sysc_fields = &omap_hwmod_sysc_type1,
1472};
1473
1474static struct omap_hwmod_class omap3xxx_dss_hwmod_class = {
1475 .name = "dss",
1476 .sysc = &omap3xxx_dss_sysc,
1477};
1478
1479/* dss */
1480static struct omap_hwmod_irq_info omap3xxx_dss_irqs[] = {
1481 { .irq = 25 },
1482};
1483
1484static struct omap_hwmod_dma_info omap3xxx_dss_sdma_chs[] = {
1485 { .name = "dispc", .dma_req = 5 },
1486 { .name = "dsi1", .dma_req = 74 },
1487};
1488
1489/* dss */
1490/* dss master ports */
1491static struct omap_hwmod_ocp_if *omap3xxx_dss_masters[] = {
1492 &omap3xxx_dss__l3,
1493};
1494
1495static struct omap_hwmod_addr_space omap3xxx_dss_addrs[] = {
1496 {
1497 .pa_start = 0x48050000,
1498 .pa_end = 0x480503FF,
1499 .flags = ADDR_TYPE_RT
1500 },
1501};
1502
1503/* l4_core -> dss */
1504static struct omap_hwmod_ocp_if omap3430es1_l4_core__dss = {
1505 .master = &omap3xxx_l4_core_hwmod,
1506 .slave = &omap3430es1_dss_core_hwmod,
1507 .clk = "dss_ick",
1508 .addr = omap3xxx_dss_addrs,
1509 .addr_cnt = ARRAY_SIZE(omap3xxx_dss_addrs),
1510 .fw = {
1511 .omap2 = {
1512 .l4_fw_region = OMAP3ES1_L4_CORE_FW_DSS_CORE_REGION,
1513 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
1514 .flags = OMAP_FIREWALL_L4,
1515 }
1516 },
1517 .user = OCP_USER_MPU | OCP_USER_SDMA,
1518};
1519
1520static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss = {
1521 .master = &omap3xxx_l4_core_hwmod,
1522 .slave = &omap3xxx_dss_core_hwmod,
1523 .clk = "dss_ick",
1524 .addr = omap3xxx_dss_addrs,
1525 .addr_cnt = ARRAY_SIZE(omap3xxx_dss_addrs),
1526 .fw = {
1527 .omap2 = {
1528 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_CORE_REGION,
1529 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
1530 .flags = OMAP_FIREWALL_L4,
1531 }
1532 },
1533 .user = OCP_USER_MPU | OCP_USER_SDMA,
1534};
1535
1536/* dss slave ports */
1537static struct omap_hwmod_ocp_if *omap3430es1_dss_slaves[] = {
1538 &omap3430es1_l4_core__dss,
1539};
1540
1541static struct omap_hwmod_ocp_if *omap3xxx_dss_slaves[] = {
1542 &omap3xxx_l4_core__dss,
1543};
1544
1545static struct omap_hwmod_opt_clk dss_opt_clks[] = {
1546 { .role = "tv_clk", .clk = "dss_tv_fck" },
1547 { .role = "dssclk", .clk = "dss_96m_fck" },
1548 { .role = "sys_clk", .clk = "dss2_alwon_fck" },
1549};
1550
1551static struct omap_hwmod omap3430es1_dss_core_hwmod = {
1552 .name = "dss_core",
1553 .class = &omap3xxx_dss_hwmod_class,
1554 .main_clk = "dss1_alwon_fck", /* instead of dss_fck */
1555 .mpu_irqs = omap3xxx_dss_irqs,
1556 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_dss_irqs),
1557 .sdma_reqs = omap3xxx_dss_sdma_chs,
1558 .sdma_reqs_cnt = ARRAY_SIZE(omap3xxx_dss_sdma_chs),
1559
1560 .prcm = {
1561 .omap2 = {
1562 .prcm_reg_id = 1,
1563 .module_bit = OMAP3430_EN_DSS1_SHIFT,
1564 .module_offs = OMAP3430_DSS_MOD,
1565 .idlest_reg_id = 1,
1566 .idlest_stdby_bit = OMAP3430ES1_ST_DSS_SHIFT,
1567 },
1568 },
1569 .opt_clks = dss_opt_clks,
1570 .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks),
1571 .slaves = omap3430es1_dss_slaves,
1572 .slaves_cnt = ARRAY_SIZE(omap3430es1_dss_slaves),
1573 .masters = omap3xxx_dss_masters,
1574 .masters_cnt = ARRAY_SIZE(omap3xxx_dss_masters),
1575 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES1),
1576 .flags = HWMOD_NO_IDLEST,
1577};
1578
1579static struct omap_hwmod omap3xxx_dss_core_hwmod = {
1580 .name = "dss_core",
1581 .class = &omap3xxx_dss_hwmod_class,
1582 .main_clk = "dss1_alwon_fck", /* instead of dss_fck */
1583 .mpu_irqs = omap3xxx_dss_irqs,
1584 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_dss_irqs),
1585 .sdma_reqs = omap3xxx_dss_sdma_chs,
1586 .sdma_reqs_cnt = ARRAY_SIZE(omap3xxx_dss_sdma_chs),
1587
1588 .prcm = {
1589 .omap2 = {
1590 .prcm_reg_id = 1,
1591 .module_bit = OMAP3430_EN_DSS1_SHIFT,
1592 .module_offs = OMAP3430_DSS_MOD,
1593 .idlest_reg_id = 1,
1594 .idlest_idle_bit = OMAP3430ES2_ST_DSS_IDLE_SHIFT,
1595 .idlest_stdby_bit = OMAP3430ES2_ST_DSS_STDBY_SHIFT,
1596 },
1597 },
1598 .opt_clks = dss_opt_clks,
1599 .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks),
1600 .slaves = omap3xxx_dss_slaves,
1601 .slaves_cnt = ARRAY_SIZE(omap3xxx_dss_slaves),
1602 .masters = omap3xxx_dss_masters,
1603 .masters_cnt = ARRAY_SIZE(omap3xxx_dss_masters),
1604 .omap_chip = OMAP_CHIP_INIT(CHIP_GE_OMAP3430ES2 |
1605 CHIP_IS_OMAP3630ES1 | CHIP_GE_OMAP3630ES1_1),
1606};
1607
1608/*
1609 * 'dispc' class
1610 * display controller
1611 */
1612
1613static struct omap_hwmod_class_sysconfig omap3xxx_dispc_sysc = {
1614 .rev_offs = 0x0000,
1615 .sysc_offs = 0x0010,
1616 .syss_offs = 0x0014,
1617 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_CLOCKACTIVITY |
1618 SYSC_HAS_MIDLEMODE | SYSC_HAS_ENAWAKEUP |
1619 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
1620 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1621 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
1622 .sysc_fields = &omap_hwmod_sysc_type1,
1623};
1624
1625static struct omap_hwmod_class omap3xxx_dispc_hwmod_class = {
1626 .name = "dispc",
1627 .sysc = &omap3xxx_dispc_sysc,
1628};
1629
1630static struct omap_hwmod_addr_space omap3xxx_dss_dispc_addrs[] = {
1631 {
1632 .pa_start = 0x48050400,
1633 .pa_end = 0x480507FF,
1634 .flags = ADDR_TYPE_RT
1635 },
1636};
1637
1638/* l4_core -> dss_dispc */
1639static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_dispc = {
1640 .master = &omap3xxx_l4_core_hwmod,
1641 .slave = &omap3xxx_dss_dispc_hwmod,
1642 .clk = "dss_ick",
1643 .addr = omap3xxx_dss_dispc_addrs,
1644 .addr_cnt = ARRAY_SIZE(omap3xxx_dss_dispc_addrs),
1645 .fw = {
1646 .omap2 = {
1647 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_DISPC_REGION,
1648 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
1649 .flags = OMAP_FIREWALL_L4,
1650 }
1651 },
1652 .user = OCP_USER_MPU | OCP_USER_SDMA,
1653};
1654
1655/* dss_dispc slave ports */
1656static struct omap_hwmod_ocp_if *omap3xxx_dss_dispc_slaves[] = {
1657 &omap3xxx_l4_core__dss_dispc,
1658};
1659
1660static struct omap_hwmod omap3xxx_dss_dispc_hwmod = {
1661 .name = "dss_dispc",
1662 .class = &omap3xxx_dispc_hwmod_class,
1663 .main_clk = "dss1_alwon_fck",
1664 .prcm = {
1665 .omap2 = {
1666 .prcm_reg_id = 1,
1667 .module_bit = OMAP3430_EN_DSS1_SHIFT,
1668 .module_offs = OMAP3430_DSS_MOD,
1669 },
1670 },
1671 .slaves = omap3xxx_dss_dispc_slaves,
1672 .slaves_cnt = ARRAY_SIZE(omap3xxx_dss_dispc_slaves),
1673 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES1 |
1674 CHIP_GE_OMAP3430ES2 | CHIP_IS_OMAP3630ES1 |
1675 CHIP_GE_OMAP3630ES1_1),
1676 .flags = HWMOD_NO_IDLEST,
1677};
1678
1679/*
1680 * 'dsi' class
1681 * display serial interface controller
1682 */
1683
1684static struct omap_hwmod_class omap3xxx_dsi_hwmod_class = {
1685 .name = "dsi",
1686};
1687
1688/* dss_dsi1 */
1689static struct omap_hwmod_addr_space omap3xxx_dss_dsi1_addrs[] = {
1690 {
1691 .pa_start = 0x4804FC00,
1692 .pa_end = 0x4804FFFF,
1693 .flags = ADDR_TYPE_RT
1694 },
1695};
1696
1697/* l4_core -> dss_dsi1 */
1698static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_dsi1 = {
1699 .master = &omap3xxx_l4_core_hwmod,
1700 .slave = &omap3xxx_dss_dsi1_hwmod,
1701 .addr = omap3xxx_dss_dsi1_addrs,
1702 .addr_cnt = ARRAY_SIZE(omap3xxx_dss_dsi1_addrs),
1703 .fw = {
1704 .omap2 = {
1705 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_DSI_REGION,
1706 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
1707 .flags = OMAP_FIREWALL_L4,
1708 }
1709 },
1710 .user = OCP_USER_MPU | OCP_USER_SDMA,
1711};
1712
1713/* dss_dsi1 slave ports */
1714static struct omap_hwmod_ocp_if *omap3xxx_dss_dsi1_slaves[] = {
1715 &omap3xxx_l4_core__dss_dsi1,
1716};
1717
1718static struct omap_hwmod omap3xxx_dss_dsi1_hwmod = {
1719 .name = "dss_dsi1",
1720 .class = &omap3xxx_dsi_hwmod_class,
1721 .main_clk = "dss1_alwon_fck",
1722 .prcm = {
1723 .omap2 = {
1724 .prcm_reg_id = 1,
1725 .module_bit = OMAP3430_EN_DSS1_SHIFT,
1726 .module_offs = OMAP3430_DSS_MOD,
1727 },
1728 },
1729 .slaves = omap3xxx_dss_dsi1_slaves,
1730 .slaves_cnt = ARRAY_SIZE(omap3xxx_dss_dsi1_slaves),
1731 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES1 |
1732 CHIP_GE_OMAP3430ES2 | CHIP_IS_OMAP3630ES1 |
1733 CHIP_GE_OMAP3630ES1_1),
1734 .flags = HWMOD_NO_IDLEST,
1735};
1736
1737/*
1738 * 'rfbi' class
1739 * remote frame buffer interface
1740 */
1741
1742static struct omap_hwmod_class_sysconfig omap3xxx_rfbi_sysc = {
1743 .rev_offs = 0x0000,
1744 .sysc_offs = 0x0010,
1745 .syss_offs = 0x0014,
1746 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
1747 SYSC_HAS_AUTOIDLE),
1748 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1749 .sysc_fields = &omap_hwmod_sysc_type1,
1750};
1751
1752static struct omap_hwmod_class omap3xxx_rfbi_hwmod_class = {
1753 .name = "rfbi",
1754 .sysc = &omap3xxx_rfbi_sysc,
1755};
1756
1757static struct omap_hwmod_addr_space omap3xxx_dss_rfbi_addrs[] = {
1758 {
1759 .pa_start = 0x48050800,
1760 .pa_end = 0x48050BFF,
1761 .flags = ADDR_TYPE_RT
1762 },
1763};
1764
1765/* l4_core -> dss_rfbi */
1766static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_rfbi = {
1767 .master = &omap3xxx_l4_core_hwmod,
1768 .slave = &omap3xxx_dss_rfbi_hwmod,
1769 .clk = "dss_ick",
1770 .addr = omap3xxx_dss_rfbi_addrs,
1771 .addr_cnt = ARRAY_SIZE(omap3xxx_dss_rfbi_addrs),
1772 .fw = {
1773 .omap2 = {
1774 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_RFBI_REGION,
1775 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP ,
1776 .flags = OMAP_FIREWALL_L4,
1777 }
1778 },
1779 .user = OCP_USER_MPU | OCP_USER_SDMA,
1780};
1781
1782/* dss_rfbi slave ports */
1783static struct omap_hwmod_ocp_if *omap3xxx_dss_rfbi_slaves[] = {
1784 &omap3xxx_l4_core__dss_rfbi,
1785};
1786
1787static struct omap_hwmod omap3xxx_dss_rfbi_hwmod = {
1788 .name = "dss_rfbi",
1789 .class = &omap3xxx_rfbi_hwmod_class,
1790 .main_clk = "dss1_alwon_fck",
1791 .prcm = {
1792 .omap2 = {
1793 .prcm_reg_id = 1,
1794 .module_bit = OMAP3430_EN_DSS1_SHIFT,
1795 .module_offs = OMAP3430_DSS_MOD,
1796 },
1797 },
1798 .slaves = omap3xxx_dss_rfbi_slaves,
1799 .slaves_cnt = ARRAY_SIZE(omap3xxx_dss_rfbi_slaves),
1800 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES1 |
1801 CHIP_GE_OMAP3430ES2 | CHIP_IS_OMAP3630ES1 |
1802 CHIP_GE_OMAP3630ES1_1),
1803 .flags = HWMOD_NO_IDLEST,
1804};
1805
1806/*
1807 * 'venc' class
1808 * video encoder
1809 */
1810
1811static struct omap_hwmod_class omap3xxx_venc_hwmod_class = {
1812 .name = "venc",
1813};
1814
1815/* dss_venc */
1816static struct omap_hwmod_addr_space omap3xxx_dss_venc_addrs[] = {
1817 {
1818 .pa_start = 0x48050C00,
1819 .pa_end = 0x48050FFF,
1820 .flags = ADDR_TYPE_RT
1821 },
1822};
1823
1824/* l4_core -> dss_venc */
1825static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_venc = {
1826 .master = &omap3xxx_l4_core_hwmod,
1827 .slave = &omap3xxx_dss_venc_hwmod,
1828 .clk = "dss_tv_fck",
1829 .addr = omap3xxx_dss_venc_addrs,
1830 .addr_cnt = ARRAY_SIZE(omap3xxx_dss_venc_addrs),
1831 .fw = {
1832 .omap2 = {
1833 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_VENC_REGION,
1834 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
1835 .flags = OMAP_FIREWALL_L4,
1836 }
1837 },
1838 .user = OCP_USER_MPU | OCP_USER_SDMA,
1839};
1840
1841/* dss_venc slave ports */
1842static struct omap_hwmod_ocp_if *omap3xxx_dss_venc_slaves[] = {
1843 &omap3xxx_l4_core__dss_venc,
1844};
1845
1846static struct omap_hwmod omap3xxx_dss_venc_hwmod = {
1847 .name = "dss_venc",
1848 .class = &omap3xxx_venc_hwmod_class,
1849 .main_clk = "dss1_alwon_fck",
1850 .prcm = {
1851 .omap2 = {
1852 .prcm_reg_id = 1,
1853 .module_bit = OMAP3430_EN_DSS1_SHIFT,
1854 .module_offs = OMAP3430_DSS_MOD,
1855 },
1856 },
1857 .slaves = omap3xxx_dss_venc_slaves,
1858 .slaves_cnt = ARRAY_SIZE(omap3xxx_dss_venc_slaves),
1859 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES1 |
1860 CHIP_GE_OMAP3430ES2 | CHIP_IS_OMAP3630ES1 |
1861 CHIP_GE_OMAP3630ES1_1),
1862 .flags = HWMOD_NO_IDLEST,
1863};
1864
Rajendra Nayak4fe20e92010-09-21 19:37:13 +05301865/* I2C1 */
1866
1867static struct omap_i2c_dev_attr i2c1_dev_attr = {
1868 .fifo_depth = 8, /* bytes */
1869};
1870
1871static struct omap_hwmod_irq_info i2c1_mpu_irqs[] = {
1872 { .irq = INT_24XX_I2C1_IRQ, },
1873};
1874
1875static struct omap_hwmod_dma_info i2c1_sdma_reqs[] = {
1876 { .name = "tx", .dma_req = OMAP24XX_DMA_I2C1_TX },
1877 { .name = "rx", .dma_req = OMAP24XX_DMA_I2C1_RX },
1878};
1879
1880static struct omap_hwmod_ocp_if *omap3xxx_i2c1_slaves[] = {
1881 &omap3_l4_core__i2c1,
1882};
1883
1884static struct omap_hwmod omap3xxx_i2c1_hwmod = {
1885 .name = "i2c1",
1886 .mpu_irqs = i2c1_mpu_irqs,
1887 .mpu_irqs_cnt = ARRAY_SIZE(i2c1_mpu_irqs),
1888 .sdma_reqs = i2c1_sdma_reqs,
1889 .sdma_reqs_cnt = ARRAY_SIZE(i2c1_sdma_reqs),
1890 .main_clk = "i2c1_fck",
1891 .prcm = {
1892 .omap2 = {
1893 .module_offs = CORE_MOD,
1894 .prcm_reg_id = 1,
1895 .module_bit = OMAP3430_EN_I2C1_SHIFT,
1896 .idlest_reg_id = 1,
1897 .idlest_idle_bit = OMAP3430_ST_I2C1_SHIFT,
1898 },
1899 },
1900 .slaves = omap3xxx_i2c1_slaves,
1901 .slaves_cnt = ARRAY_SIZE(omap3xxx_i2c1_slaves),
1902 .class = &i2c_class,
1903 .dev_attr = &i2c1_dev_attr,
1904 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
1905};
1906
1907/* I2C2 */
1908
1909static struct omap_i2c_dev_attr i2c2_dev_attr = {
1910 .fifo_depth = 8, /* bytes */
1911};
1912
1913static struct omap_hwmod_irq_info i2c2_mpu_irqs[] = {
1914 { .irq = INT_24XX_I2C2_IRQ, },
1915};
1916
1917static struct omap_hwmod_dma_info i2c2_sdma_reqs[] = {
1918 { .name = "tx", .dma_req = OMAP24XX_DMA_I2C2_TX },
1919 { .name = "rx", .dma_req = OMAP24XX_DMA_I2C2_RX },
1920};
1921
1922static struct omap_hwmod_ocp_if *omap3xxx_i2c2_slaves[] = {
1923 &omap3_l4_core__i2c2,
1924};
1925
1926static struct omap_hwmod omap3xxx_i2c2_hwmod = {
1927 .name = "i2c2",
1928 .mpu_irqs = i2c2_mpu_irqs,
1929 .mpu_irqs_cnt = ARRAY_SIZE(i2c2_mpu_irqs),
1930 .sdma_reqs = i2c2_sdma_reqs,
1931 .sdma_reqs_cnt = ARRAY_SIZE(i2c2_sdma_reqs),
1932 .main_clk = "i2c2_fck",
1933 .prcm = {
1934 .omap2 = {
1935 .module_offs = CORE_MOD,
1936 .prcm_reg_id = 1,
1937 .module_bit = OMAP3430_EN_I2C2_SHIFT,
1938 .idlest_reg_id = 1,
1939 .idlest_idle_bit = OMAP3430_ST_I2C2_SHIFT,
1940 },
1941 },
1942 .slaves = omap3xxx_i2c2_slaves,
1943 .slaves_cnt = ARRAY_SIZE(omap3xxx_i2c2_slaves),
1944 .class = &i2c_class,
1945 .dev_attr = &i2c2_dev_attr,
1946 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
1947};
1948
1949/* I2C3 */
1950
1951static struct omap_i2c_dev_attr i2c3_dev_attr = {
1952 .fifo_depth = 64, /* bytes */
1953};
1954
1955static struct omap_hwmod_irq_info i2c3_mpu_irqs[] = {
1956 { .irq = INT_34XX_I2C3_IRQ, },
1957};
1958
1959static struct omap_hwmod_dma_info i2c3_sdma_reqs[] = {
1960 { .name = "tx", .dma_req = OMAP34XX_DMA_I2C3_TX },
1961 { .name = "rx", .dma_req = OMAP34XX_DMA_I2C3_RX },
1962};
1963
1964static struct omap_hwmod_ocp_if *omap3xxx_i2c3_slaves[] = {
1965 &omap3_l4_core__i2c3,
1966};
1967
1968static struct omap_hwmod omap3xxx_i2c3_hwmod = {
1969 .name = "i2c3",
1970 .mpu_irqs = i2c3_mpu_irqs,
1971 .mpu_irqs_cnt = ARRAY_SIZE(i2c3_mpu_irqs),
1972 .sdma_reqs = i2c3_sdma_reqs,
1973 .sdma_reqs_cnt = ARRAY_SIZE(i2c3_sdma_reqs),
1974 .main_clk = "i2c3_fck",
1975 .prcm = {
1976 .omap2 = {
1977 .module_offs = CORE_MOD,
1978 .prcm_reg_id = 1,
1979 .module_bit = OMAP3430_EN_I2C3_SHIFT,
1980 .idlest_reg_id = 1,
1981 .idlest_idle_bit = OMAP3430_ST_I2C3_SHIFT,
1982 },
1983 },
1984 .slaves = omap3xxx_i2c3_slaves,
1985 .slaves_cnt = ARRAY_SIZE(omap3xxx_i2c3_slaves),
1986 .class = &i2c_class,
1987 .dev_attr = &i2c3_dev_attr,
1988 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
1989};
1990
Varadarajan, Charulatha70034d32010-12-07 16:26:57 -08001991/* l4_wkup -> gpio1 */
1992static struct omap_hwmod_addr_space omap3xxx_gpio1_addrs[] = {
1993 {
1994 .pa_start = 0x48310000,
1995 .pa_end = 0x483101ff,
1996 .flags = ADDR_TYPE_RT
1997 },
1998};
1999
2000static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__gpio1 = {
2001 .master = &omap3xxx_l4_wkup_hwmod,
2002 .slave = &omap3xxx_gpio1_hwmod,
2003 .addr = omap3xxx_gpio1_addrs,
2004 .addr_cnt = ARRAY_SIZE(omap3xxx_gpio1_addrs),
2005 .user = OCP_USER_MPU | OCP_USER_SDMA,
2006};
2007
2008/* l4_per -> gpio2 */
2009static struct omap_hwmod_addr_space omap3xxx_gpio2_addrs[] = {
2010 {
2011 .pa_start = 0x49050000,
2012 .pa_end = 0x490501ff,
2013 .flags = ADDR_TYPE_RT
2014 },
2015};
2016
2017static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio2 = {
2018 .master = &omap3xxx_l4_per_hwmod,
2019 .slave = &omap3xxx_gpio2_hwmod,
2020 .addr = omap3xxx_gpio2_addrs,
2021 .addr_cnt = ARRAY_SIZE(omap3xxx_gpio2_addrs),
2022 .user = OCP_USER_MPU | OCP_USER_SDMA,
2023};
2024
2025/* l4_per -> gpio3 */
2026static struct omap_hwmod_addr_space omap3xxx_gpio3_addrs[] = {
2027 {
2028 .pa_start = 0x49052000,
2029 .pa_end = 0x490521ff,
2030 .flags = ADDR_TYPE_RT
2031 },
2032};
2033
2034static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio3 = {
2035 .master = &omap3xxx_l4_per_hwmod,
2036 .slave = &omap3xxx_gpio3_hwmod,
2037 .addr = omap3xxx_gpio3_addrs,
2038 .addr_cnt = ARRAY_SIZE(omap3xxx_gpio3_addrs),
2039 .user = OCP_USER_MPU | OCP_USER_SDMA,
2040};
2041
2042/* l4_per -> gpio4 */
2043static struct omap_hwmod_addr_space omap3xxx_gpio4_addrs[] = {
2044 {
2045 .pa_start = 0x49054000,
2046 .pa_end = 0x490541ff,
2047 .flags = ADDR_TYPE_RT
2048 },
2049};
2050
2051static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio4 = {
2052 .master = &omap3xxx_l4_per_hwmod,
2053 .slave = &omap3xxx_gpio4_hwmod,
2054 .addr = omap3xxx_gpio4_addrs,
2055 .addr_cnt = ARRAY_SIZE(omap3xxx_gpio4_addrs),
2056 .user = OCP_USER_MPU | OCP_USER_SDMA,
2057};
2058
2059/* l4_per -> gpio5 */
2060static struct omap_hwmod_addr_space omap3xxx_gpio5_addrs[] = {
2061 {
2062 .pa_start = 0x49056000,
2063 .pa_end = 0x490561ff,
2064 .flags = ADDR_TYPE_RT
2065 },
2066};
2067
2068static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio5 = {
2069 .master = &omap3xxx_l4_per_hwmod,
2070 .slave = &omap3xxx_gpio5_hwmod,
2071 .addr = omap3xxx_gpio5_addrs,
2072 .addr_cnt = ARRAY_SIZE(omap3xxx_gpio5_addrs),
2073 .user = OCP_USER_MPU | OCP_USER_SDMA,
2074};
2075
2076/* l4_per -> gpio6 */
2077static struct omap_hwmod_addr_space omap3xxx_gpio6_addrs[] = {
2078 {
2079 .pa_start = 0x49058000,
2080 .pa_end = 0x490581ff,
2081 .flags = ADDR_TYPE_RT
2082 },
2083};
2084
2085static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio6 = {
2086 .master = &omap3xxx_l4_per_hwmod,
2087 .slave = &omap3xxx_gpio6_hwmod,
2088 .addr = omap3xxx_gpio6_addrs,
2089 .addr_cnt = ARRAY_SIZE(omap3xxx_gpio6_addrs),
2090 .user = OCP_USER_MPU | OCP_USER_SDMA,
2091};
2092
2093/*
2094 * 'gpio' class
2095 * general purpose io module
2096 */
2097
2098static struct omap_hwmod_class_sysconfig omap3xxx_gpio_sysc = {
2099 .rev_offs = 0x0000,
2100 .sysc_offs = 0x0010,
2101 .syss_offs = 0x0014,
2102 .sysc_flags = (SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
2103 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
2104 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2105 .sysc_fields = &omap_hwmod_sysc_type1,
2106};
2107
2108static struct omap_hwmod_class omap3xxx_gpio_hwmod_class = {
2109 .name = "gpio",
2110 .sysc = &omap3xxx_gpio_sysc,
2111 .rev = 1,
2112};
2113
2114/* gpio_dev_attr*/
2115static struct omap_gpio_dev_attr gpio_dev_attr = {
2116 .bank_width = 32,
2117 .dbck_flag = true,
2118};
2119
2120/* gpio1 */
2121static struct omap_hwmod_irq_info omap3xxx_gpio1_irqs[] = {
2122 { .irq = 29 }, /* INT_34XX_GPIO_BANK1 */
2123};
2124
2125static struct omap_hwmod_opt_clk gpio1_opt_clks[] = {
2126 { .role = "dbclk", .clk = "gpio1_dbck", },
2127};
2128
2129static struct omap_hwmod_ocp_if *omap3xxx_gpio1_slaves[] = {
2130 &omap3xxx_l4_wkup__gpio1,
2131};
2132
2133static struct omap_hwmod omap3xxx_gpio1_hwmod = {
2134 .name = "gpio1",
2135 .mpu_irqs = omap3xxx_gpio1_irqs,
2136 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_gpio1_irqs),
2137 .main_clk = "gpio1_ick",
2138 .opt_clks = gpio1_opt_clks,
2139 .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks),
2140 .prcm = {
2141 .omap2 = {
2142 .prcm_reg_id = 1,
2143 .module_bit = OMAP3430_EN_GPIO1_SHIFT,
2144 .module_offs = WKUP_MOD,
2145 .idlest_reg_id = 1,
2146 .idlest_idle_bit = OMAP3430_ST_GPIO1_SHIFT,
2147 },
2148 },
2149 .slaves = omap3xxx_gpio1_slaves,
2150 .slaves_cnt = ARRAY_SIZE(omap3xxx_gpio1_slaves),
2151 .class = &omap3xxx_gpio_hwmod_class,
2152 .dev_attr = &gpio_dev_attr,
2153 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2154};
2155
2156/* gpio2 */
2157static struct omap_hwmod_irq_info omap3xxx_gpio2_irqs[] = {
2158 { .irq = 30 }, /* INT_34XX_GPIO_BANK2 */
2159};
2160
2161static struct omap_hwmod_opt_clk gpio2_opt_clks[] = {
2162 { .role = "dbclk", .clk = "gpio2_dbck", },
2163};
2164
2165static struct omap_hwmod_ocp_if *omap3xxx_gpio2_slaves[] = {
2166 &omap3xxx_l4_per__gpio2,
2167};
2168
2169static struct omap_hwmod omap3xxx_gpio2_hwmod = {
2170 .name = "gpio2",
2171 .mpu_irqs = omap3xxx_gpio2_irqs,
2172 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_gpio2_irqs),
2173 .main_clk = "gpio2_ick",
2174 .opt_clks = gpio2_opt_clks,
2175 .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks),
2176 .prcm = {
2177 .omap2 = {
2178 .prcm_reg_id = 1,
2179 .module_bit = OMAP3430_EN_GPIO2_SHIFT,
2180 .module_offs = OMAP3430_PER_MOD,
2181 .idlest_reg_id = 1,
2182 .idlest_idle_bit = OMAP3430_ST_GPIO2_SHIFT,
2183 },
2184 },
2185 .slaves = omap3xxx_gpio2_slaves,
2186 .slaves_cnt = ARRAY_SIZE(omap3xxx_gpio2_slaves),
2187 .class = &omap3xxx_gpio_hwmod_class,
2188 .dev_attr = &gpio_dev_attr,
2189 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2190};
2191
2192/* gpio3 */
2193static struct omap_hwmod_irq_info omap3xxx_gpio3_irqs[] = {
2194 { .irq = 31 }, /* INT_34XX_GPIO_BANK3 */
2195};
2196
2197static struct omap_hwmod_opt_clk gpio3_opt_clks[] = {
2198 { .role = "dbclk", .clk = "gpio3_dbck", },
2199};
2200
2201static struct omap_hwmod_ocp_if *omap3xxx_gpio3_slaves[] = {
2202 &omap3xxx_l4_per__gpio3,
2203};
2204
2205static struct omap_hwmod omap3xxx_gpio3_hwmod = {
2206 .name = "gpio3",
2207 .mpu_irqs = omap3xxx_gpio3_irqs,
2208 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_gpio3_irqs),
2209 .main_clk = "gpio3_ick",
2210 .opt_clks = gpio3_opt_clks,
2211 .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks),
2212 .prcm = {
2213 .omap2 = {
2214 .prcm_reg_id = 1,
2215 .module_bit = OMAP3430_EN_GPIO3_SHIFT,
2216 .module_offs = OMAP3430_PER_MOD,
2217 .idlest_reg_id = 1,
2218 .idlest_idle_bit = OMAP3430_ST_GPIO3_SHIFT,
2219 },
2220 },
2221 .slaves = omap3xxx_gpio3_slaves,
2222 .slaves_cnt = ARRAY_SIZE(omap3xxx_gpio3_slaves),
2223 .class = &omap3xxx_gpio_hwmod_class,
2224 .dev_attr = &gpio_dev_attr,
2225 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2226};
2227
2228/* gpio4 */
2229static struct omap_hwmod_irq_info omap3xxx_gpio4_irqs[] = {
2230 { .irq = 32 }, /* INT_34XX_GPIO_BANK4 */
2231};
2232
2233static struct omap_hwmod_opt_clk gpio4_opt_clks[] = {
2234 { .role = "dbclk", .clk = "gpio4_dbck", },
2235};
2236
2237static struct omap_hwmod_ocp_if *omap3xxx_gpio4_slaves[] = {
2238 &omap3xxx_l4_per__gpio4,
2239};
2240
2241static struct omap_hwmod omap3xxx_gpio4_hwmod = {
2242 .name = "gpio4",
2243 .mpu_irqs = omap3xxx_gpio4_irqs,
2244 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_gpio4_irqs),
2245 .main_clk = "gpio4_ick",
2246 .opt_clks = gpio4_opt_clks,
2247 .opt_clks_cnt = ARRAY_SIZE(gpio4_opt_clks),
2248 .prcm = {
2249 .omap2 = {
2250 .prcm_reg_id = 1,
2251 .module_bit = OMAP3430_EN_GPIO4_SHIFT,
2252 .module_offs = OMAP3430_PER_MOD,
2253 .idlest_reg_id = 1,
2254 .idlest_idle_bit = OMAP3430_ST_GPIO4_SHIFT,
2255 },
2256 },
2257 .slaves = omap3xxx_gpio4_slaves,
2258 .slaves_cnt = ARRAY_SIZE(omap3xxx_gpio4_slaves),
2259 .class = &omap3xxx_gpio_hwmod_class,
2260 .dev_attr = &gpio_dev_attr,
2261 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2262};
2263
2264/* gpio5 */
2265static struct omap_hwmod_irq_info omap3xxx_gpio5_irqs[] = {
2266 { .irq = 33 }, /* INT_34XX_GPIO_BANK5 */
2267};
2268
2269static struct omap_hwmod_opt_clk gpio5_opt_clks[] = {
2270 { .role = "dbclk", .clk = "gpio5_dbck", },
2271};
2272
2273static struct omap_hwmod_ocp_if *omap3xxx_gpio5_slaves[] = {
2274 &omap3xxx_l4_per__gpio5,
2275};
2276
2277static struct omap_hwmod omap3xxx_gpio5_hwmod = {
2278 .name = "gpio5",
2279 .mpu_irqs = omap3xxx_gpio5_irqs,
2280 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_gpio5_irqs),
2281 .main_clk = "gpio5_ick",
2282 .opt_clks = gpio5_opt_clks,
2283 .opt_clks_cnt = ARRAY_SIZE(gpio5_opt_clks),
2284 .prcm = {
2285 .omap2 = {
2286 .prcm_reg_id = 1,
2287 .module_bit = OMAP3430_EN_GPIO5_SHIFT,
2288 .module_offs = OMAP3430_PER_MOD,
2289 .idlest_reg_id = 1,
2290 .idlest_idle_bit = OMAP3430_ST_GPIO5_SHIFT,
2291 },
2292 },
2293 .slaves = omap3xxx_gpio5_slaves,
2294 .slaves_cnt = ARRAY_SIZE(omap3xxx_gpio5_slaves),
2295 .class = &omap3xxx_gpio_hwmod_class,
2296 .dev_attr = &gpio_dev_attr,
2297 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2298};
2299
2300/* gpio6 */
2301static struct omap_hwmod_irq_info omap3xxx_gpio6_irqs[] = {
2302 { .irq = 34 }, /* INT_34XX_GPIO_BANK6 */
2303};
2304
2305static struct omap_hwmod_opt_clk gpio6_opt_clks[] = {
2306 { .role = "dbclk", .clk = "gpio6_dbck", },
2307};
2308
2309static struct omap_hwmod_ocp_if *omap3xxx_gpio6_slaves[] = {
2310 &omap3xxx_l4_per__gpio6,
2311};
2312
2313static struct omap_hwmod omap3xxx_gpio6_hwmod = {
2314 .name = "gpio6",
2315 .mpu_irqs = omap3xxx_gpio6_irqs,
2316 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_gpio6_irqs),
2317 .main_clk = "gpio6_ick",
2318 .opt_clks = gpio6_opt_clks,
2319 .opt_clks_cnt = ARRAY_SIZE(gpio6_opt_clks),
2320 .prcm = {
2321 .omap2 = {
2322 .prcm_reg_id = 1,
2323 .module_bit = OMAP3430_EN_GPIO6_SHIFT,
2324 .module_offs = OMAP3430_PER_MOD,
2325 .idlest_reg_id = 1,
2326 .idlest_idle_bit = OMAP3430_ST_GPIO6_SHIFT,
2327 },
2328 },
2329 .slaves = omap3xxx_gpio6_slaves,
2330 .slaves_cnt = ARRAY_SIZE(omap3xxx_gpio6_slaves),
2331 .class = &omap3xxx_gpio_hwmod_class,
2332 .dev_attr = &gpio_dev_attr,
2333 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2334};
2335
G, Manjunath Kondaiah01438ab2010-12-20 18:27:19 -08002336/* dma_system -> L3 */
2337static struct omap_hwmod_ocp_if omap3xxx_dma_system__l3 = {
2338 .master = &omap3xxx_dma_system_hwmod,
2339 .slave = &omap3xxx_l3_main_hwmod,
2340 .clk = "core_l3_ick",
2341 .user = OCP_USER_MPU | OCP_USER_SDMA,
2342};
2343
2344/* dma attributes */
2345static struct omap_dma_dev_attr dma_dev_attr = {
2346 .dev_caps = RESERVE_CHANNEL | DMA_LINKED_LCH | GLOBAL_PRIORITY |
2347 IS_CSSA_32 | IS_CDSA_32 | IS_RW_PRIORITY,
2348 .lch_count = 32,
2349};
2350
2351static struct omap_hwmod_class_sysconfig omap3xxx_dma_sysc = {
2352 .rev_offs = 0x0000,
2353 .sysc_offs = 0x002c,
2354 .syss_offs = 0x0028,
2355 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
2356 SYSC_HAS_MIDLEMODE | SYSC_HAS_CLOCKACTIVITY |
2357 SYSC_HAS_EMUFREE | SYSC_HAS_AUTOIDLE),
2358 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
2359 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
2360 .sysc_fields = &omap_hwmod_sysc_type1,
2361};
2362
2363static struct omap_hwmod_class omap3xxx_dma_hwmod_class = {
2364 .name = "dma",
2365 .sysc = &omap3xxx_dma_sysc,
2366};
2367
2368/* dma_system */
2369static struct omap_hwmod_irq_info omap3xxx_dma_system_irqs[] = {
2370 { .name = "0", .irq = 12 }, /* INT_24XX_SDMA_IRQ0 */
2371 { .name = "1", .irq = 13 }, /* INT_24XX_SDMA_IRQ1 */
2372 { .name = "2", .irq = 14 }, /* INT_24XX_SDMA_IRQ2 */
2373 { .name = "3", .irq = 15 }, /* INT_24XX_SDMA_IRQ3 */
2374};
2375
2376static struct omap_hwmod_addr_space omap3xxx_dma_system_addrs[] = {
2377 {
2378 .pa_start = 0x48056000,
2379 .pa_end = 0x4a0560ff,
2380 .flags = ADDR_TYPE_RT
2381 },
2382};
2383
2384/* dma_system master ports */
2385static struct omap_hwmod_ocp_if *omap3xxx_dma_system_masters[] = {
2386 &omap3xxx_dma_system__l3,
2387};
2388
2389/* l4_cfg -> dma_system */
2390static struct omap_hwmod_ocp_if omap3xxx_l4_core__dma_system = {
2391 .master = &omap3xxx_l4_core_hwmod,
2392 .slave = &omap3xxx_dma_system_hwmod,
2393 .clk = "core_l4_ick",
2394 .addr = omap3xxx_dma_system_addrs,
2395 .addr_cnt = ARRAY_SIZE(omap3xxx_dma_system_addrs),
2396 .user = OCP_USER_MPU | OCP_USER_SDMA,
2397};
2398
2399/* dma_system slave ports */
2400static struct omap_hwmod_ocp_if *omap3xxx_dma_system_slaves[] = {
2401 &omap3xxx_l4_core__dma_system,
2402};
2403
2404static struct omap_hwmod omap3xxx_dma_system_hwmod = {
2405 .name = "dma",
2406 .class = &omap3xxx_dma_hwmod_class,
2407 .mpu_irqs = omap3xxx_dma_system_irqs,
2408 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_dma_system_irqs),
2409 .main_clk = "core_l3_ick",
2410 .prcm = {
2411 .omap2 = {
2412 .module_offs = CORE_MOD,
2413 .prcm_reg_id = 1,
2414 .module_bit = OMAP3430_ST_SDMA_SHIFT,
2415 .idlest_reg_id = 1,
2416 .idlest_idle_bit = OMAP3430_ST_SDMA_SHIFT,
2417 },
2418 },
2419 .slaves = omap3xxx_dma_system_slaves,
2420 .slaves_cnt = ARRAY_SIZE(omap3xxx_dma_system_slaves),
2421 .masters = omap3xxx_dma_system_masters,
2422 .masters_cnt = ARRAY_SIZE(omap3xxx_dma_system_masters),
2423 .dev_attr = &dma_dev_attr,
2424 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2425 .flags = HWMOD_NO_IDLEST,
2426};
2427
Thara Gopinathd3442722010-05-29 22:02:24 +05302428/* SR common */
2429static struct omap_hwmod_sysc_fields omap34xx_sr_sysc_fields = {
2430 .clkact_shift = 20,
2431};
2432
2433static struct omap_hwmod_class_sysconfig omap34xx_sr_sysc = {
2434 .sysc_offs = 0x24,
2435 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_NO_CACHE),
2436 .clockact = CLOCKACT_TEST_ICLK,
2437 .sysc_fields = &omap34xx_sr_sysc_fields,
2438};
2439
2440static struct omap_hwmod_class omap34xx_smartreflex_hwmod_class = {
2441 .name = "smartreflex",
2442 .sysc = &omap34xx_sr_sysc,
2443 .rev = 1,
2444};
2445
2446static struct omap_hwmod_sysc_fields omap36xx_sr_sysc_fields = {
2447 .sidle_shift = 24,
2448 .enwkup_shift = 26
2449};
2450
2451static struct omap_hwmod_class_sysconfig omap36xx_sr_sysc = {
2452 .sysc_offs = 0x38,
2453 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2454 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP |
2455 SYSC_NO_CACHE),
2456 .sysc_fields = &omap36xx_sr_sysc_fields,
2457};
2458
2459static struct omap_hwmod_class omap36xx_smartreflex_hwmod_class = {
2460 .name = "smartreflex",
2461 .sysc = &omap36xx_sr_sysc,
2462 .rev = 2,
2463};
2464
2465/* SR1 */
2466static struct omap_hwmod_ocp_if *omap3_sr1_slaves[] = {
2467 &omap3_l4_core__sr1,
2468};
2469
2470static struct omap_hwmod omap34xx_sr1_hwmod = {
2471 .name = "sr1_hwmod",
2472 .class = &omap34xx_smartreflex_hwmod_class,
2473 .main_clk = "sr1_fck",
2474 .vdd_name = "mpu",
2475 .prcm = {
2476 .omap2 = {
2477 .prcm_reg_id = 1,
2478 .module_bit = OMAP3430_EN_SR1_SHIFT,
2479 .module_offs = WKUP_MOD,
2480 .idlest_reg_id = 1,
2481 .idlest_idle_bit = OMAP3430_EN_SR1_SHIFT,
2482 },
2483 },
2484 .slaves = omap3_sr1_slaves,
2485 .slaves_cnt = ARRAY_SIZE(omap3_sr1_slaves),
2486 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES2 |
2487 CHIP_IS_OMAP3430ES3_0 |
2488 CHIP_IS_OMAP3430ES3_1),
2489 .flags = HWMOD_SET_DEFAULT_CLOCKACT,
2490};
2491
2492static struct omap_hwmod omap36xx_sr1_hwmod = {
2493 .name = "sr1_hwmod",
2494 .class = &omap36xx_smartreflex_hwmod_class,
2495 .main_clk = "sr1_fck",
2496 .vdd_name = "mpu",
2497 .prcm = {
2498 .omap2 = {
2499 .prcm_reg_id = 1,
2500 .module_bit = OMAP3430_EN_SR1_SHIFT,
2501 .module_offs = WKUP_MOD,
2502 .idlest_reg_id = 1,
2503 .idlest_idle_bit = OMAP3430_EN_SR1_SHIFT,
2504 },
2505 },
2506 .slaves = omap3_sr1_slaves,
2507 .slaves_cnt = ARRAY_SIZE(omap3_sr1_slaves),
2508 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3630ES1),
2509};
2510
2511/* SR2 */
2512static struct omap_hwmod_ocp_if *omap3_sr2_slaves[] = {
2513 &omap3_l4_core__sr2,
2514};
2515
2516static struct omap_hwmod omap34xx_sr2_hwmod = {
2517 .name = "sr2_hwmod",
2518 .class = &omap34xx_smartreflex_hwmod_class,
2519 .main_clk = "sr2_fck",
2520 .vdd_name = "core",
2521 .prcm = {
2522 .omap2 = {
2523 .prcm_reg_id = 1,
2524 .module_bit = OMAP3430_EN_SR2_SHIFT,
2525 .module_offs = WKUP_MOD,
2526 .idlest_reg_id = 1,
2527 .idlest_idle_bit = OMAP3430_EN_SR2_SHIFT,
2528 },
2529 },
2530 .slaves = omap3_sr2_slaves,
2531 .slaves_cnt = ARRAY_SIZE(omap3_sr2_slaves),
2532 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES2 |
2533 CHIP_IS_OMAP3430ES3_0 |
2534 CHIP_IS_OMAP3430ES3_1),
2535 .flags = HWMOD_SET_DEFAULT_CLOCKACT,
2536};
2537
2538static struct omap_hwmod omap36xx_sr2_hwmod = {
2539 .name = "sr2_hwmod",
2540 .class = &omap36xx_smartreflex_hwmod_class,
2541 .main_clk = "sr2_fck",
2542 .vdd_name = "core",
2543 .prcm = {
2544 .omap2 = {
2545 .prcm_reg_id = 1,
2546 .module_bit = OMAP3430_EN_SR2_SHIFT,
2547 .module_offs = WKUP_MOD,
2548 .idlest_reg_id = 1,
2549 .idlest_idle_bit = OMAP3430_EN_SR2_SHIFT,
2550 },
2551 },
2552 .slaves = omap3_sr2_slaves,
2553 .slaves_cnt = ARRAY_SIZE(omap3_sr2_slaves),
2554 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3630ES1),
2555};
2556
Charulatha V0f616a42011-02-17 09:53:10 -08002557/* l4 core -> mcspi1 interface */
2558static struct omap_hwmod_addr_space omap34xx_mcspi1_addr_space[] = {
2559 {
2560 .pa_start = 0x48098000,
2561 .pa_end = 0x480980ff,
2562 .flags = ADDR_TYPE_RT,
2563 },
2564};
2565
2566static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi1 = {
2567 .master = &omap3xxx_l4_core_hwmod,
2568 .slave = &omap34xx_mcspi1,
2569 .clk = "mcspi1_ick",
2570 .addr = omap34xx_mcspi1_addr_space,
2571 .addr_cnt = ARRAY_SIZE(omap34xx_mcspi1_addr_space),
2572 .user = OCP_USER_MPU | OCP_USER_SDMA,
2573};
2574
2575/* l4 core -> mcspi2 interface */
2576static struct omap_hwmod_addr_space omap34xx_mcspi2_addr_space[] = {
2577 {
2578 .pa_start = 0x4809a000,
2579 .pa_end = 0x4809a0ff,
2580 .flags = ADDR_TYPE_RT,
2581 },
2582};
2583
2584static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi2 = {
2585 .master = &omap3xxx_l4_core_hwmod,
2586 .slave = &omap34xx_mcspi2,
2587 .clk = "mcspi2_ick",
2588 .addr = omap34xx_mcspi2_addr_space,
2589 .addr_cnt = ARRAY_SIZE(omap34xx_mcspi2_addr_space),
2590 .user = OCP_USER_MPU | OCP_USER_SDMA,
2591};
2592
2593/* l4 core -> mcspi3 interface */
2594static struct omap_hwmod_addr_space omap34xx_mcspi3_addr_space[] = {
2595 {
2596 .pa_start = 0x480b8000,
2597 .pa_end = 0x480b80ff,
2598 .flags = ADDR_TYPE_RT,
2599 },
2600};
2601
2602static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi3 = {
2603 .master = &omap3xxx_l4_core_hwmod,
2604 .slave = &omap34xx_mcspi3,
2605 .clk = "mcspi3_ick",
2606 .addr = omap34xx_mcspi3_addr_space,
2607 .addr_cnt = ARRAY_SIZE(omap34xx_mcspi3_addr_space),
2608 .user = OCP_USER_MPU | OCP_USER_SDMA,
2609};
2610
2611/* l4 core -> mcspi4 interface */
2612static struct omap_hwmod_addr_space omap34xx_mcspi4_addr_space[] = {
2613 {
2614 .pa_start = 0x480ba000,
2615 .pa_end = 0x480ba0ff,
2616 .flags = ADDR_TYPE_RT,
2617 },
2618};
2619
2620static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi4 = {
2621 .master = &omap3xxx_l4_core_hwmod,
2622 .slave = &omap34xx_mcspi4,
2623 .clk = "mcspi4_ick",
2624 .addr = omap34xx_mcspi4_addr_space,
2625 .addr_cnt = ARRAY_SIZE(omap34xx_mcspi4_addr_space),
2626 .user = OCP_USER_MPU | OCP_USER_SDMA,
2627};
2628
2629/*
2630 * 'mcspi' class
2631 * multichannel serial port interface (mcspi) / master/slave synchronous serial
2632 * bus
2633 */
2634
2635static struct omap_hwmod_class_sysconfig omap34xx_mcspi_sysc = {
2636 .rev_offs = 0x0000,
2637 .sysc_offs = 0x0010,
2638 .syss_offs = 0x0014,
2639 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
2640 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
2641 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS),
2642 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2643 .sysc_fields = &omap_hwmod_sysc_type1,
2644};
2645
2646static struct omap_hwmod_class omap34xx_mcspi_class = {
2647 .name = "mcspi",
2648 .sysc = &omap34xx_mcspi_sysc,
2649 .rev = OMAP3_MCSPI_REV,
2650};
2651
2652/* mcspi1 */
2653static struct omap_hwmod_irq_info omap34xx_mcspi1_mpu_irqs[] = {
2654 { .name = "irq", .irq = 65 },
2655};
2656
2657static struct omap_hwmod_dma_info omap34xx_mcspi1_sdma_reqs[] = {
2658 { .name = "tx0", .dma_req = 35 },
2659 { .name = "rx0", .dma_req = 36 },
2660 { .name = "tx1", .dma_req = 37 },
2661 { .name = "rx1", .dma_req = 38 },
2662 { .name = "tx2", .dma_req = 39 },
2663 { .name = "rx2", .dma_req = 40 },
2664 { .name = "tx3", .dma_req = 41 },
2665 { .name = "rx3", .dma_req = 42 },
2666};
2667
2668static struct omap_hwmod_ocp_if *omap34xx_mcspi1_slaves[] = {
2669 &omap34xx_l4_core__mcspi1,
2670};
2671
2672static struct omap2_mcspi_dev_attr omap_mcspi1_dev_attr = {
2673 .num_chipselect = 4,
2674};
2675
2676static struct omap_hwmod omap34xx_mcspi1 = {
2677 .name = "mcspi1",
2678 .mpu_irqs = omap34xx_mcspi1_mpu_irqs,
2679 .mpu_irqs_cnt = ARRAY_SIZE(omap34xx_mcspi1_mpu_irqs),
2680 .sdma_reqs = omap34xx_mcspi1_sdma_reqs,
2681 .sdma_reqs_cnt = ARRAY_SIZE(omap34xx_mcspi1_sdma_reqs),
2682 .main_clk = "mcspi1_fck",
2683 .prcm = {
2684 .omap2 = {
2685 .module_offs = CORE_MOD,
2686 .prcm_reg_id = 1,
2687 .module_bit = OMAP3430_EN_MCSPI1_SHIFT,
2688 .idlest_reg_id = 1,
2689 .idlest_idle_bit = OMAP3430_ST_MCSPI1_SHIFT,
2690 },
2691 },
2692 .slaves = omap34xx_mcspi1_slaves,
2693 .slaves_cnt = ARRAY_SIZE(omap34xx_mcspi1_slaves),
2694 .class = &omap34xx_mcspi_class,
2695 .dev_attr = &omap_mcspi1_dev_attr,
2696 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2697};
2698
2699/* mcspi2 */
2700static struct omap_hwmod_irq_info omap34xx_mcspi2_mpu_irqs[] = {
2701 { .name = "irq", .irq = 66 },
2702};
2703
2704static struct omap_hwmod_dma_info omap34xx_mcspi2_sdma_reqs[] = {
2705 { .name = "tx0", .dma_req = 43 },
2706 { .name = "rx0", .dma_req = 44 },
2707 { .name = "tx1", .dma_req = 45 },
2708 { .name = "rx1", .dma_req = 46 },
2709};
2710
2711static struct omap_hwmod_ocp_if *omap34xx_mcspi2_slaves[] = {
2712 &omap34xx_l4_core__mcspi2,
2713};
2714
2715static struct omap2_mcspi_dev_attr omap_mcspi2_dev_attr = {
2716 .num_chipselect = 2,
2717};
2718
2719static struct omap_hwmod omap34xx_mcspi2 = {
2720 .name = "mcspi2",
2721 .mpu_irqs = omap34xx_mcspi2_mpu_irqs,
2722 .mpu_irqs_cnt = ARRAY_SIZE(omap34xx_mcspi2_mpu_irqs),
2723 .sdma_reqs = omap34xx_mcspi2_sdma_reqs,
2724 .sdma_reqs_cnt = ARRAY_SIZE(omap34xx_mcspi2_sdma_reqs),
2725 .main_clk = "mcspi2_fck",
2726 .prcm = {
2727 .omap2 = {
2728 .module_offs = CORE_MOD,
2729 .prcm_reg_id = 1,
2730 .module_bit = OMAP3430_EN_MCSPI2_SHIFT,
2731 .idlest_reg_id = 1,
2732 .idlest_idle_bit = OMAP3430_ST_MCSPI2_SHIFT,
2733 },
2734 },
2735 .slaves = omap34xx_mcspi2_slaves,
2736 .slaves_cnt = ARRAY_SIZE(omap34xx_mcspi2_slaves),
2737 .class = &omap34xx_mcspi_class,
2738 .dev_attr = &omap_mcspi2_dev_attr,
2739 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2740};
2741
2742/* mcspi3 */
2743static struct omap_hwmod_irq_info omap34xx_mcspi3_mpu_irqs[] = {
2744 { .name = "irq", .irq = 91 }, /* 91 */
2745};
2746
2747static struct omap_hwmod_dma_info omap34xx_mcspi3_sdma_reqs[] = {
2748 { .name = "tx0", .dma_req = 15 },
2749 { .name = "rx0", .dma_req = 16 },
2750 { .name = "tx1", .dma_req = 23 },
2751 { .name = "rx1", .dma_req = 24 },
2752};
2753
2754static struct omap_hwmod_ocp_if *omap34xx_mcspi3_slaves[] = {
2755 &omap34xx_l4_core__mcspi3,
2756};
2757
2758static struct omap2_mcspi_dev_attr omap_mcspi3_dev_attr = {
2759 .num_chipselect = 2,
2760};
2761
2762static struct omap_hwmod omap34xx_mcspi3 = {
2763 .name = "mcspi3",
2764 .mpu_irqs = omap34xx_mcspi3_mpu_irqs,
2765 .mpu_irqs_cnt = ARRAY_SIZE(omap34xx_mcspi3_mpu_irqs),
2766 .sdma_reqs = omap34xx_mcspi3_sdma_reqs,
2767 .sdma_reqs_cnt = ARRAY_SIZE(omap34xx_mcspi3_sdma_reqs),
2768 .main_clk = "mcspi3_fck",
2769 .prcm = {
2770 .omap2 = {
2771 .module_offs = CORE_MOD,
2772 .prcm_reg_id = 1,
2773 .module_bit = OMAP3430_EN_MCSPI3_SHIFT,
2774 .idlest_reg_id = 1,
2775 .idlest_idle_bit = OMAP3430_ST_MCSPI3_SHIFT,
2776 },
2777 },
2778 .slaves = omap34xx_mcspi3_slaves,
2779 .slaves_cnt = ARRAY_SIZE(omap34xx_mcspi3_slaves),
2780 .class = &omap34xx_mcspi_class,
2781 .dev_attr = &omap_mcspi3_dev_attr,
2782 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2783};
2784
2785/* SPI4 */
2786static struct omap_hwmod_irq_info omap34xx_mcspi4_mpu_irqs[] = {
2787 { .name = "irq", .irq = INT_34XX_SPI4_IRQ }, /* 48 */
2788};
2789
2790static struct omap_hwmod_dma_info omap34xx_mcspi4_sdma_reqs[] = {
2791 { .name = "tx0", .dma_req = 70 }, /* DMA_SPI4_TX0 */
2792 { .name = "rx0", .dma_req = 71 }, /* DMA_SPI4_RX0 */
2793};
2794
2795static struct omap_hwmod_ocp_if *omap34xx_mcspi4_slaves[] = {
2796 &omap34xx_l4_core__mcspi4,
2797};
2798
2799static struct omap2_mcspi_dev_attr omap_mcspi4_dev_attr = {
2800 .num_chipselect = 1,
2801};
2802
2803static struct omap_hwmod omap34xx_mcspi4 = {
2804 .name = "mcspi4",
2805 .mpu_irqs = omap34xx_mcspi4_mpu_irqs,
2806 .mpu_irqs_cnt = ARRAY_SIZE(omap34xx_mcspi4_mpu_irqs),
2807 .sdma_reqs = omap34xx_mcspi4_sdma_reqs,
2808 .sdma_reqs_cnt = ARRAY_SIZE(omap34xx_mcspi4_sdma_reqs),
2809 .main_clk = "mcspi4_fck",
2810 .prcm = {
2811 .omap2 = {
2812 .module_offs = CORE_MOD,
2813 .prcm_reg_id = 1,
2814 .module_bit = OMAP3430_EN_MCSPI4_SHIFT,
2815 .idlest_reg_id = 1,
2816 .idlest_idle_bit = OMAP3430_ST_MCSPI4_SHIFT,
2817 },
2818 },
2819 .slaves = omap34xx_mcspi4_slaves,
2820 .slaves_cnt = ARRAY_SIZE(omap34xx_mcspi4_slaves),
2821 .class = &omap34xx_mcspi_class,
2822 .dev_attr = &omap_mcspi4_dev_attr,
2823 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2824};
2825
Hema HK870ea2b2011-02-17 12:07:18 +05302826/*
2827 * usbhsotg
2828 */
2829static struct omap_hwmod_class_sysconfig omap3xxx_usbhsotg_sysc = {
2830 .rev_offs = 0x0400,
2831 .sysc_offs = 0x0404,
2832 .syss_offs = 0x0408,
2833 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE|
2834 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
2835 SYSC_HAS_AUTOIDLE),
2836 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
2837 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
2838 .sysc_fields = &omap_hwmod_sysc_type1,
2839};
2840
2841static struct omap_hwmod_class usbotg_class = {
2842 .name = "usbotg",
2843 .sysc = &omap3xxx_usbhsotg_sysc,
2844};
Hema HK870ea2b2011-02-17 12:07:18 +05302845/* usb_otg_hs */
2846static struct omap_hwmod_irq_info omap3xxx_usbhsotg_mpu_irqs[] = {
2847
2848 { .name = "mc", .irq = 92 },
2849 { .name = "dma", .irq = 93 },
2850};
2851
2852static struct omap_hwmod omap3xxx_usbhsotg_hwmod = {
2853 .name = "usb_otg_hs",
2854 .mpu_irqs = omap3xxx_usbhsotg_mpu_irqs,
2855 .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_usbhsotg_mpu_irqs),
2856 .main_clk = "hsotgusb_ick",
2857 .prcm = {
2858 .omap2 = {
2859 .prcm_reg_id = 1,
2860 .module_bit = OMAP3430_EN_HSOTGUSB_SHIFT,
2861 .module_offs = CORE_MOD,
2862 .idlest_reg_id = 1,
2863 .idlest_idle_bit = OMAP3430ES2_ST_HSOTGUSB_IDLE_SHIFT,
2864 .idlest_stdby_bit = OMAP3430ES2_ST_HSOTGUSB_STDBY_SHIFT
2865 },
2866 },
2867 .masters = omap3xxx_usbhsotg_masters,
2868 .masters_cnt = ARRAY_SIZE(omap3xxx_usbhsotg_masters),
2869 .slaves = omap3xxx_usbhsotg_slaves,
2870 .slaves_cnt = ARRAY_SIZE(omap3xxx_usbhsotg_slaves),
2871 .class = &usbotg_class,
2872
2873 /*
2874 * Erratum ID: i479 idle_req / idle_ack mechanism potentially
2875 * broken when autoidle is enabled
2876 * workaround is to disable the autoidle bit at module level.
2877 */
2878 .flags = HWMOD_NO_OCP_AUTOIDLE | HWMOD_SWSUP_SIDLE
2879 | HWMOD_SWSUP_MSTANDBY,
2880 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430)
2881};
Tony Lindgren04aa67d2011-02-22 10:54:12 -08002882
Hema HK273ff8c2011-02-17 12:07:19 +05302883/* usb_otg_hs */
2884static struct omap_hwmod_irq_info am35xx_usbhsotg_mpu_irqs[] = {
2885
2886 { .name = "mc", .irq = 71 },
2887};
2888
2889static struct omap_hwmod_class am35xx_usbotg_class = {
2890 .name = "am35xx_usbotg",
2891 .sysc = NULL,
2892};
2893
2894static struct omap_hwmod am35xx_usbhsotg_hwmod = {
2895 .name = "am35x_otg_hs",
2896 .mpu_irqs = am35xx_usbhsotg_mpu_irqs,
2897 .mpu_irqs_cnt = ARRAY_SIZE(am35xx_usbhsotg_mpu_irqs),
2898 .main_clk = NULL,
2899 .prcm = {
2900 .omap2 = {
2901 },
2902 },
2903 .masters = am35xx_usbhsotg_masters,
2904 .masters_cnt = ARRAY_SIZE(am35xx_usbhsotg_masters),
2905 .slaves = am35xx_usbhsotg_slaves,
2906 .slaves_cnt = ARRAY_SIZE(am35xx_usbhsotg_slaves),
2907 .class = &am35xx_usbotg_class,
2908 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES3_1)
2909};
Hema HK870ea2b2011-02-17 12:07:18 +05302910
Paul Walmsleyb1636052011-03-01 13:12:56 -08002911/* MMC/SD/SDIO common */
2912
2913static struct omap_hwmod_class_sysconfig omap34xx_mmc_sysc = {
2914 .rev_offs = 0x1fc,
2915 .sysc_offs = 0x10,
2916 .syss_offs = 0x14,
2917 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
2918 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
2919 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS),
2920 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2921 .sysc_fields = &omap_hwmod_sysc_type1,
2922};
2923
2924static struct omap_hwmod_class omap34xx_mmc_class = {
2925 .name = "mmc",
2926 .sysc = &omap34xx_mmc_sysc,
2927};
2928
2929/* MMC/SD/SDIO1 */
2930
2931static struct omap_hwmod_irq_info omap34xx_mmc1_mpu_irqs[] = {
2932 { .irq = 83, },
2933};
2934
2935static struct omap_hwmod_dma_info omap34xx_mmc1_sdma_reqs[] = {
2936 { .name = "tx", .dma_req = 61, },
2937 { .name = "rx", .dma_req = 62, },
2938};
2939
2940static struct omap_hwmod_opt_clk omap34xx_mmc1_opt_clks[] = {
2941 { .role = "dbck", .clk = "omap_32k_fck", },
2942};
2943
2944static struct omap_hwmod_ocp_if *omap3xxx_mmc1_slaves[] = {
2945 &omap3xxx_l4_core__mmc1,
2946};
2947
Kishore Kadiyala6ab89462011-03-01 13:12:56 -08002948static struct omap_mmc_dev_attr mmc1_dev_attr = {
2949 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
2950};
2951
Paul Walmsleyb1636052011-03-01 13:12:56 -08002952static struct omap_hwmod omap3xxx_mmc1_hwmod = {
2953 .name = "mmc1",
2954 .mpu_irqs = omap34xx_mmc1_mpu_irqs,
2955 .mpu_irqs_cnt = ARRAY_SIZE(omap34xx_mmc1_mpu_irqs),
2956 .sdma_reqs = omap34xx_mmc1_sdma_reqs,
2957 .sdma_reqs_cnt = ARRAY_SIZE(omap34xx_mmc1_sdma_reqs),
2958 .opt_clks = omap34xx_mmc1_opt_clks,
2959 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc1_opt_clks),
2960 .main_clk = "mmchs1_fck",
2961 .prcm = {
2962 .omap2 = {
2963 .module_offs = CORE_MOD,
2964 .prcm_reg_id = 1,
2965 .module_bit = OMAP3430_EN_MMC1_SHIFT,
2966 .idlest_reg_id = 1,
2967 .idlest_idle_bit = OMAP3430_ST_MMC1_SHIFT,
2968 },
2969 },
Kishore Kadiyala6ab89462011-03-01 13:12:56 -08002970 .dev_attr = &mmc1_dev_attr,
Paul Walmsleyb1636052011-03-01 13:12:56 -08002971 .slaves = omap3xxx_mmc1_slaves,
2972 .slaves_cnt = ARRAY_SIZE(omap3xxx_mmc1_slaves),
2973 .class = &omap34xx_mmc_class,
2974 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
2975};
2976
2977/* MMC/SD/SDIO2 */
2978
2979static struct omap_hwmod_irq_info omap34xx_mmc2_mpu_irqs[] = {
2980 { .irq = INT_24XX_MMC2_IRQ, },
2981};
2982
2983static struct omap_hwmod_dma_info omap34xx_mmc2_sdma_reqs[] = {
2984 { .name = "tx", .dma_req = 47, },
2985 { .name = "rx", .dma_req = 48, },
2986};
2987
2988static struct omap_hwmod_opt_clk omap34xx_mmc2_opt_clks[] = {
2989 { .role = "dbck", .clk = "omap_32k_fck", },
2990};
2991
2992static struct omap_hwmod_ocp_if *omap3xxx_mmc2_slaves[] = {
2993 &omap3xxx_l4_core__mmc2,
2994};
2995
2996static struct omap_hwmod omap3xxx_mmc2_hwmod = {
2997 .name = "mmc2",
2998 .mpu_irqs = omap34xx_mmc2_mpu_irqs,
2999 .mpu_irqs_cnt = ARRAY_SIZE(omap34xx_mmc2_mpu_irqs),
3000 .sdma_reqs = omap34xx_mmc2_sdma_reqs,
3001 .sdma_reqs_cnt = ARRAY_SIZE(omap34xx_mmc2_sdma_reqs),
3002 .opt_clks = omap34xx_mmc2_opt_clks,
3003 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc2_opt_clks),
3004 .main_clk = "mmchs2_fck",
3005 .prcm = {
3006 .omap2 = {
3007 .module_offs = CORE_MOD,
3008 .prcm_reg_id = 1,
3009 .module_bit = OMAP3430_EN_MMC2_SHIFT,
3010 .idlest_reg_id = 1,
3011 .idlest_idle_bit = OMAP3430_ST_MMC2_SHIFT,
3012 },
3013 },
3014 .slaves = omap3xxx_mmc2_slaves,
3015 .slaves_cnt = ARRAY_SIZE(omap3xxx_mmc2_slaves),
3016 .class = &omap34xx_mmc_class,
3017 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
3018};
3019
3020/* MMC/SD/SDIO3 */
3021
3022static struct omap_hwmod_irq_info omap34xx_mmc3_mpu_irqs[] = {
3023 { .irq = 94, },
3024};
3025
3026static struct omap_hwmod_dma_info omap34xx_mmc3_sdma_reqs[] = {
3027 { .name = "tx", .dma_req = 77, },
3028 { .name = "rx", .dma_req = 78, },
3029};
3030
3031static struct omap_hwmod_opt_clk omap34xx_mmc3_opt_clks[] = {
3032 { .role = "dbck", .clk = "omap_32k_fck", },
3033};
3034
3035static struct omap_hwmod_ocp_if *omap3xxx_mmc3_slaves[] = {
3036 &omap3xxx_l4_core__mmc3,
3037};
3038
3039static struct omap_hwmod omap3xxx_mmc3_hwmod = {
3040 .name = "mmc3",
3041 .mpu_irqs = omap34xx_mmc3_mpu_irqs,
3042 .mpu_irqs_cnt = ARRAY_SIZE(omap34xx_mmc3_mpu_irqs),
3043 .sdma_reqs = omap34xx_mmc3_sdma_reqs,
3044 .sdma_reqs_cnt = ARRAY_SIZE(omap34xx_mmc3_sdma_reqs),
3045 .opt_clks = omap34xx_mmc3_opt_clks,
3046 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc3_opt_clks),
3047 .main_clk = "mmchs3_fck",
3048 .prcm = {
3049 .omap2 = {
3050 .prcm_reg_id = 1,
3051 .module_bit = OMAP3430_EN_MMC3_SHIFT,
3052 .idlest_reg_id = 1,
3053 .idlest_idle_bit = OMAP3430_ST_MMC3_SHIFT,
3054 },
3055 },
3056 .slaves = omap3xxx_mmc3_slaves,
3057 .slaves_cnt = ARRAY_SIZE(omap3xxx_mmc3_slaves),
3058 .class = &omap34xx_mmc_class,
3059 .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430),
3060};
3061
Paul Walmsley73591542010-02-22 22:09:32 -07003062static __initdata struct omap_hwmod *omap3xxx_hwmods[] = {
Kevin Hilman4a7cf902010-07-26 16:34:32 -06003063 &omap3xxx_l3_main_hwmod,
Paul Walmsley73591542010-02-22 22:09:32 -07003064 &omap3xxx_l4_core_hwmod,
3065 &omap3xxx_l4_per_hwmod,
3066 &omap3xxx_l4_wkup_hwmod,
Paul Walmsleyb1636052011-03-01 13:12:56 -08003067 &omap3xxx_mmc1_hwmod,
3068 &omap3xxx_mmc2_hwmod,
3069 &omap3xxx_mmc3_hwmod,
Paul Walmsley73591542010-02-22 22:09:32 -07003070 &omap3xxx_mpu_hwmod,
Kevin Hilman540064b2010-07-26 16:34:32 -06003071 &omap3xxx_iva_hwmod,
Thara Gopinathce722d22011-02-23 00:14:05 -07003072
3073 &omap3xxx_timer1_hwmod,
3074 &omap3xxx_timer2_hwmod,
3075 &omap3xxx_timer3_hwmod,
3076 &omap3xxx_timer4_hwmod,
3077 &omap3xxx_timer5_hwmod,
3078 &omap3xxx_timer6_hwmod,
3079 &omap3xxx_timer7_hwmod,
3080 &omap3xxx_timer8_hwmod,
3081 &omap3xxx_timer9_hwmod,
3082 &omap3xxx_timer10_hwmod,
3083 &omap3xxx_timer11_hwmod,
3084 &omap3xxx_timer12_hwmod,
3085
Varadarajan, Charulatha6b667f82010-09-23 20:02:38 +05303086 &omap3xxx_wd_timer2_hwmod,
Kevin Hilman046465b2010-09-27 20:19:30 +05303087 &omap3xxx_uart1_hwmod,
3088 &omap3xxx_uart2_hwmod,
3089 &omap3xxx_uart3_hwmod,
3090 &omap3xxx_uart4_hwmod,
Senthilvadivu Guruswamye04d9e12011-01-24 06:21:51 +00003091 /* dss class */
3092 &omap3430es1_dss_core_hwmod,
3093 &omap3xxx_dss_core_hwmod,
3094 &omap3xxx_dss_dispc_hwmod,
3095 &omap3xxx_dss_dsi1_hwmod,
3096 &omap3xxx_dss_rfbi_hwmod,
3097 &omap3xxx_dss_venc_hwmod,
3098
3099 /* i2c class */
Rajendra Nayak4fe20e92010-09-21 19:37:13 +05303100 &omap3xxx_i2c1_hwmod,
3101 &omap3xxx_i2c2_hwmod,
3102 &omap3xxx_i2c3_hwmod,
Thara Gopinathd3442722010-05-29 22:02:24 +05303103 &omap34xx_sr1_hwmod,
3104 &omap34xx_sr2_hwmod,
3105 &omap36xx_sr1_hwmod,
3106 &omap36xx_sr2_hwmod,
3107
Varadarajan, Charulatha70034d32010-12-07 16:26:57 -08003108
3109 /* gpio class */
3110 &omap3xxx_gpio1_hwmod,
3111 &omap3xxx_gpio2_hwmod,
3112 &omap3xxx_gpio3_hwmod,
3113 &omap3xxx_gpio4_hwmod,
3114 &omap3xxx_gpio5_hwmod,
3115 &omap3xxx_gpio6_hwmod,
G, Manjunath Kondaiah01438ab2010-12-20 18:27:19 -08003116
3117 /* dma_system class*/
3118 &omap3xxx_dma_system_hwmod,
Charulatha V0f616a42011-02-17 09:53:10 -08003119
3120 /* mcspi class */
3121 &omap34xx_mcspi1,
3122 &omap34xx_mcspi2,
3123 &omap34xx_mcspi3,
3124 &omap34xx_mcspi4,
Tony Lindgren04aa67d2011-02-22 10:54:12 -08003125
Hema HK870ea2b2011-02-17 12:07:18 +05303126 /* usbotg class */
3127 &omap3xxx_usbhsotg_hwmod,
3128
Hema HK273ff8c2011-02-17 12:07:19 +05303129 /* usbotg for am35x */
3130 &am35xx_usbhsotg_hwmod,
3131
Paul Walmsley73591542010-02-22 22:09:32 -07003132 NULL,
3133};
3134
3135int __init omap3xxx_hwmod_init(void)
3136{
Paul Walmsley550c8092011-02-28 11:58:14 -07003137 return omap_hwmod_register(omap3xxx_hwmods);
Paul Walmsley73591542010-02-22 22:09:32 -07003138}