blob: ee3624bd1996ccd7361f762843ce09fffac6d11a [file] [log] [blame]
Benoit Cousson55d2cb02010-05-12 17:54:36 +02001/*
2 * Hardware modules present on the OMAP44xx chips
3 *
Benoit Coussond63bd742011-01-27 11:17:03 +00004 * Copyright (C) 2009-2011 Texas Instruments, Inc.
Benoit Cousson55d2cb02010-05-12 17:54:36 +02005 * Copyright (C) 2009-2010 Nokia Corporation
6 *
7 * Paul Walmsley
8 * Benoit Cousson
9 *
10 * This file is automatically generated from the OMAP hardware databases.
11 * We respectfully ask that any modifications to this file be coordinated
12 * with the public linux-omap@vger.kernel.org mailing list and the
13 * authors above to ensure that the autogeneration scripts are kept
14 * up-to-date with the file contents.
15 *
16 * This program is free software; you can redistribute it and/or modify
17 * it under the terms of the GNU General Public License version 2 as
18 * published by the Free Software Foundation.
19 */
20
21#include <linux/io.h>
22
23#include <plat/omap_hwmod.h>
24#include <plat/cpu.h>
Avinash.H.M6d3c55f2011-07-10 05:27:16 -060025#include <plat/i2c.h>
Benoit Cousson9780a9c2010-12-07 16:26:57 -080026#include <plat/gpio.h>
Benoit Cousson531ce0d2010-12-20 18:27:19 -080027#include <plat/dma.h>
Benoit Cousson905a74d2011-02-18 14:01:06 +010028#include <plat/mcspi.h>
Kishon Vijay Abraham Icb7e9de2011-02-24 15:16:50 +053029#include <plat/mcbsp.h>
Kishore Kadiyala6ab89462011-03-01 13:12:56 -080030#include <plat/mmc.h>
Andy Green4d4441a2011-07-10 05:27:16 -060031#include <plat/i2c.h>
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +053032#include <plat/dmtimer.h>
Tomi Valkeinen13662dc2011-11-08 03:16:13 -070033#include <plat/common.h>
Benoit Cousson55d2cb02010-05-12 17:54:36 +020034
35#include "omap_hwmod_common_data.h"
36
Shweta Gulaticea6b942012-02-29 23:33:37 +010037#include "smartreflex.h"
Paul Walmsleyd198b512010-12-21 15:30:54 -070038#include "cm1_44xx.h"
39#include "cm2_44xx.h"
40#include "prm44xx.h"
Benoit Cousson55d2cb02010-05-12 17:54:36 +020041#include "prm-regbits-44xx.h"
Paul Walmsleyff2516f2010-12-21 15:39:15 -070042#include "wd_timer.h"
Benoit Cousson55d2cb02010-05-12 17:54:36 +020043
44/* Base offset for all OMAP4 interrupts external to MPUSS */
45#define OMAP44XX_IRQ_GIC_START 32
46
47/* Base offset for all OMAP4 dma requests */
48#define OMAP44XX_DMA_REQ_START 1
49
50/* Backward references (IPs with Bus Master capability) */
Benoit Cousson407a6882011-02-15 22:39:48 +010051static struct omap_hwmod omap44xx_aess_hwmod;
Benoit Cousson531ce0d2010-12-20 18:27:19 -080052static struct omap_hwmod omap44xx_dma_system_hwmod;
Benoit Cousson55d2cb02010-05-12 17:54:36 +020053static struct omap_hwmod omap44xx_dmm_hwmod;
Benoit Cousson8f25bdc2010-12-21 21:08:34 -070054static struct omap_hwmod omap44xx_dsp_hwmod;
Benoit Coussond63bd742011-01-27 11:17:03 +000055static struct omap_hwmod omap44xx_dss_hwmod;
Benoit Cousson55d2cb02010-05-12 17:54:36 +020056static struct omap_hwmod omap44xx_emif_fw_hwmod;
Benoit Cousson407a6882011-02-15 22:39:48 +010057static struct omap_hwmod omap44xx_hsi_hwmod;
58static struct omap_hwmod omap44xx_ipu_hwmod;
59static struct omap_hwmod omap44xx_iss_hwmod;
Benoit Cousson8f25bdc2010-12-21 21:08:34 -070060static struct omap_hwmod omap44xx_iva_hwmod;
Benoit Cousson55d2cb02010-05-12 17:54:36 +020061static struct omap_hwmod omap44xx_l3_instr_hwmod;
62static struct omap_hwmod omap44xx_l3_main_1_hwmod;
63static struct omap_hwmod omap44xx_l3_main_2_hwmod;
64static struct omap_hwmod omap44xx_l3_main_3_hwmod;
65static struct omap_hwmod omap44xx_l4_abe_hwmod;
66static struct omap_hwmod omap44xx_l4_cfg_hwmod;
67static struct omap_hwmod omap44xx_l4_per_hwmod;
68static struct omap_hwmod omap44xx_l4_wkup_hwmod;
Benoit Cousson407a6882011-02-15 22:39:48 +010069static struct omap_hwmod omap44xx_mmc1_hwmod;
70static struct omap_hwmod omap44xx_mmc2_hwmod;
Benoit Cousson55d2cb02010-05-12 17:54:36 +020071static struct omap_hwmod omap44xx_mpu_hwmod;
72static struct omap_hwmod omap44xx_mpu_private_hwmod;
Benoit Cousson5844c4e2011-02-17 12:41:05 +000073static struct omap_hwmod omap44xx_usb_otg_hs_hwmod;
Benoit Coussonaf88fa92011-12-15 23:15:18 -070074static struct omap_hwmod omap44xx_usb_host_hs_hwmod;
75static struct omap_hwmod omap44xx_usb_tll_hs_hwmod;
Benoit Cousson55d2cb02010-05-12 17:54:36 +020076
77/*
78 * Interconnects omap_hwmod structures
79 * hwmods that compose the global OMAP interconnect
80 */
81
82/*
83 * 'dmm' class
84 * instance(s): dmm
85 */
86static struct omap_hwmod_class omap44xx_dmm_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +000087 .name = "dmm",
Benoit Cousson55d2cb02010-05-12 17:54:36 +020088};
89
Benoit Cousson7e69ed92011-07-09 19:14:28 -060090/* dmm */
91static struct omap_hwmod_irq_info omap44xx_dmm_irqs[] = {
92 { .irq = 113 + OMAP44XX_IRQ_GIC_START },
93 { .irq = -1 }
94};
95
Benoit Cousson55d2cb02010-05-12 17:54:36 +020096/* l3_main_1 -> dmm */
97static struct omap_hwmod_ocp_if omap44xx_l3_main_1__dmm = {
98 .master = &omap44xx_l3_main_1_hwmod,
99 .slave = &omap44xx_dmm_hwmod,
100 .clk = "l3_div_ck",
Benoit Cousson659fa822010-12-21 21:08:34 -0700101 .user = OCP_USER_SDMA,
102};
103
104static struct omap_hwmod_addr_space omap44xx_dmm_addrs[] = {
105 {
106 .pa_start = 0x4e000000,
107 .pa_end = 0x4e0007ff,
108 .flags = ADDR_TYPE_RT
109 },
Paul Walmsley78183f32011-07-09 19:14:05 -0600110 { }
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200111};
112
113/* mpu -> dmm */
114static struct omap_hwmod_ocp_if omap44xx_mpu__dmm = {
115 .master = &omap44xx_mpu_hwmod,
116 .slave = &omap44xx_dmm_hwmod,
117 .clk = "l3_div_ck",
Benoit Cousson659fa822010-12-21 21:08:34 -0700118 .addr = omap44xx_dmm_addrs,
Benoit Cousson659fa822010-12-21 21:08:34 -0700119 .user = OCP_USER_MPU,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200120};
121
122/* dmm slave ports */
123static struct omap_hwmod_ocp_if *omap44xx_dmm_slaves[] = {
124 &omap44xx_l3_main_1__dmm,
125 &omap44xx_mpu__dmm,
126};
127
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200128static struct omap_hwmod omap44xx_dmm_hwmod = {
129 .name = "dmm",
130 .class = &omap44xx_dmm_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600131 .clkdm_name = "l3_emif_clkdm",
Benoit Coussond0f06312011-07-10 05:56:30 -0600132 .prcm = {
133 .omap4 = {
134 .clkctrl_offs = OMAP4_CM_MEMIF_DMM_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600135 .context_offs = OMAP4_RM_MEMIF_DMM_CONTEXT_OFFSET,
Benoit Coussond0f06312011-07-10 05:56:30 -0600136 },
137 },
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200138 .slaves = omap44xx_dmm_slaves,
139 .slaves_cnt = ARRAY_SIZE(omap44xx_dmm_slaves),
Benoit Coussona5322c62011-07-10 05:56:29 -0600140 .mpu_irqs = omap44xx_dmm_irqs,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200141};
142
143/*
144 * 'emif_fw' class
145 * instance(s): emif_fw
146 */
147static struct omap_hwmod_class omap44xx_emif_fw_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +0000148 .name = "emif_fw",
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200149};
150
Benoit Cousson7e69ed92011-07-09 19:14:28 -0600151/* emif_fw */
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200152/* dmm -> emif_fw */
153static struct omap_hwmod_ocp_if omap44xx_dmm__emif_fw = {
154 .master = &omap44xx_dmm_hwmod,
155 .slave = &omap44xx_emif_fw_hwmod,
156 .clk = "l3_div_ck",
157 .user = OCP_USER_MPU | OCP_USER_SDMA,
158};
159
Benoit Cousson659fa822010-12-21 21:08:34 -0700160static struct omap_hwmod_addr_space omap44xx_emif_fw_addrs[] = {
161 {
162 .pa_start = 0x4a20c000,
163 .pa_end = 0x4a20c0ff,
164 .flags = ADDR_TYPE_RT
165 },
Paul Walmsley78183f32011-07-09 19:14:05 -0600166 { }
Benoit Cousson659fa822010-12-21 21:08:34 -0700167};
168
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200169/* l4_cfg -> emif_fw */
170static struct omap_hwmod_ocp_if omap44xx_l4_cfg__emif_fw = {
171 .master = &omap44xx_l4_cfg_hwmod,
172 .slave = &omap44xx_emif_fw_hwmod,
173 .clk = "l4_div_ck",
Benoit Cousson659fa822010-12-21 21:08:34 -0700174 .addr = omap44xx_emif_fw_addrs,
Benoit Cousson659fa822010-12-21 21:08:34 -0700175 .user = OCP_USER_MPU,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200176};
177
178/* emif_fw slave ports */
179static struct omap_hwmod_ocp_if *omap44xx_emif_fw_slaves[] = {
180 &omap44xx_dmm__emif_fw,
181 &omap44xx_l4_cfg__emif_fw,
182};
183
184static struct omap_hwmod omap44xx_emif_fw_hwmod = {
185 .name = "emif_fw",
186 .class = &omap44xx_emif_fw_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600187 .clkdm_name = "l3_emif_clkdm",
Benoit Coussond0f06312011-07-10 05:56:30 -0600188 .prcm = {
189 .omap4 = {
190 .clkctrl_offs = OMAP4_CM_MEMIF_EMIF_FW_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600191 .context_offs = OMAP4_RM_MEMIF_EMIF_FW_CONTEXT_OFFSET,
Benoit Coussond0f06312011-07-10 05:56:30 -0600192 },
193 },
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200194 .slaves = omap44xx_emif_fw_slaves,
195 .slaves_cnt = ARRAY_SIZE(omap44xx_emif_fw_slaves),
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200196};
197
198/*
199 * 'l3' class
200 * instance(s): l3_instr, l3_main_1, l3_main_2, l3_main_3
201 */
202static struct omap_hwmod_class omap44xx_l3_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +0000203 .name = "l3",
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200204};
205
Benoit Cousson7e69ed92011-07-09 19:14:28 -0600206/* l3_instr */
Benoit Cousson8f25bdc2010-12-21 21:08:34 -0700207/* iva -> l3_instr */
208static struct omap_hwmod_ocp_if omap44xx_iva__l3_instr = {
209 .master = &omap44xx_iva_hwmod,
210 .slave = &omap44xx_l3_instr_hwmod,
211 .clk = "l3_div_ck",
212 .user = OCP_USER_MPU | OCP_USER_SDMA,
213};
214
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200215/* l3_main_3 -> l3_instr */
216static struct omap_hwmod_ocp_if omap44xx_l3_main_3__l3_instr = {
217 .master = &omap44xx_l3_main_3_hwmod,
218 .slave = &omap44xx_l3_instr_hwmod,
219 .clk = "l3_div_ck",
220 .user = OCP_USER_MPU | OCP_USER_SDMA,
221};
222
223/* l3_instr slave ports */
224static struct omap_hwmod_ocp_if *omap44xx_l3_instr_slaves[] = {
Benoit Cousson8f25bdc2010-12-21 21:08:34 -0700225 &omap44xx_iva__l3_instr,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200226 &omap44xx_l3_main_3__l3_instr,
227};
228
229static struct omap_hwmod omap44xx_l3_instr_hwmod = {
230 .name = "l3_instr",
231 .class = &omap44xx_l3_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600232 .clkdm_name = "l3_instr_clkdm",
Benoit Coussond0f06312011-07-10 05:56:30 -0600233 .prcm = {
234 .omap4 = {
235 .clkctrl_offs = OMAP4_CM_L3INSTR_L3_INSTR_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600236 .context_offs = OMAP4_RM_L3INSTR_L3_INSTR_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -0600237 .modulemode = MODULEMODE_HWCTRL,
Benoit Coussond0f06312011-07-10 05:56:30 -0600238 },
239 },
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200240 .slaves = omap44xx_l3_instr_slaves,
241 .slaves_cnt = ARRAY_SIZE(omap44xx_l3_instr_slaves),
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200242};
243
Benoit Cousson7e69ed92011-07-09 19:14:28 -0600244/* l3_main_1 */
Benoit Cousson9b4021b2011-07-09 19:14:27 -0600245static struct omap_hwmod_irq_info omap44xx_l3_main_1_irqs[] = {
246 { .name = "dbg_err", .irq = 9 + OMAP44XX_IRQ_GIC_START },
247 { .name = "app_err", .irq = 10 + OMAP44XX_IRQ_GIC_START },
248 { .irq = -1 }
249};
250
Benoit Cousson8f25bdc2010-12-21 21:08:34 -0700251/* dsp -> l3_main_1 */
252static struct omap_hwmod_ocp_if omap44xx_dsp__l3_main_1 = {
253 .master = &omap44xx_dsp_hwmod,
254 .slave = &omap44xx_l3_main_1_hwmod,
255 .clk = "l3_div_ck",
256 .user = OCP_USER_MPU | OCP_USER_SDMA,
257};
258
Benoit Coussond63bd742011-01-27 11:17:03 +0000259/* dss -> l3_main_1 */
260static struct omap_hwmod_ocp_if omap44xx_dss__l3_main_1 = {
261 .master = &omap44xx_dss_hwmod,
262 .slave = &omap44xx_l3_main_1_hwmod,
263 .clk = "l3_div_ck",
264 .user = OCP_USER_MPU | OCP_USER_SDMA,
265};
266
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200267/* l3_main_2 -> l3_main_1 */
268static struct omap_hwmod_ocp_if omap44xx_l3_main_2__l3_main_1 = {
269 .master = &omap44xx_l3_main_2_hwmod,
270 .slave = &omap44xx_l3_main_1_hwmod,
271 .clk = "l3_div_ck",
272 .user = OCP_USER_MPU | OCP_USER_SDMA,
273};
274
275/* l4_cfg -> l3_main_1 */
276static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l3_main_1 = {
277 .master = &omap44xx_l4_cfg_hwmod,
278 .slave = &omap44xx_l3_main_1_hwmod,
279 .clk = "l4_div_ck",
280 .user = OCP_USER_MPU | OCP_USER_SDMA,
281};
282
Benoit Cousson407a6882011-02-15 22:39:48 +0100283/* mmc1 -> l3_main_1 */
284static struct omap_hwmod_ocp_if omap44xx_mmc1__l3_main_1 = {
285 .master = &omap44xx_mmc1_hwmod,
286 .slave = &omap44xx_l3_main_1_hwmod,
287 .clk = "l3_div_ck",
288 .user = OCP_USER_MPU | OCP_USER_SDMA,
289};
290
291/* mmc2 -> l3_main_1 */
292static struct omap_hwmod_ocp_if omap44xx_mmc2__l3_main_1 = {
293 .master = &omap44xx_mmc2_hwmod,
294 .slave = &omap44xx_l3_main_1_hwmod,
295 .clk = "l3_div_ck",
296 .user = OCP_USER_MPU | OCP_USER_SDMA,
297};
298
sricharanc4645232011-02-07 21:12:11 +0530299static struct omap_hwmod_addr_space omap44xx_l3_main_1_addrs[] = {
300 {
301 .pa_start = 0x44000000,
302 .pa_end = 0x44000fff,
Benoit Cousson9b4021b2011-07-09 19:14:27 -0600303 .flags = ADDR_TYPE_RT
sricharanc4645232011-02-07 21:12:11 +0530304 },
Paul Walmsley78183f32011-07-09 19:14:05 -0600305 { }
sricharanc4645232011-02-07 21:12:11 +0530306};
307
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200308/* mpu -> l3_main_1 */
309static struct omap_hwmod_ocp_if omap44xx_mpu__l3_main_1 = {
310 .master = &omap44xx_mpu_hwmod,
311 .slave = &omap44xx_l3_main_1_hwmod,
312 .clk = "l3_div_ck",
sricharanc4645232011-02-07 21:12:11 +0530313 .addr = omap44xx_l3_main_1_addrs,
Benoit Cousson9b4021b2011-07-09 19:14:27 -0600314 .user = OCP_USER_MPU,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200315};
316
317/* l3_main_1 slave ports */
318static struct omap_hwmod_ocp_if *omap44xx_l3_main_1_slaves[] = {
Benoit Cousson8f25bdc2010-12-21 21:08:34 -0700319 &omap44xx_dsp__l3_main_1,
Benoit Coussond63bd742011-01-27 11:17:03 +0000320 &omap44xx_dss__l3_main_1,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200321 &omap44xx_l3_main_2__l3_main_1,
322 &omap44xx_l4_cfg__l3_main_1,
Benoit Cousson407a6882011-02-15 22:39:48 +0100323 &omap44xx_mmc1__l3_main_1,
324 &omap44xx_mmc2__l3_main_1,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200325 &omap44xx_mpu__l3_main_1,
326};
327
328static struct omap_hwmod omap44xx_l3_main_1_hwmod = {
329 .name = "l3_main_1",
330 .class = &omap44xx_l3_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600331 .clkdm_name = "l3_1_clkdm",
Benoit Cousson7e69ed92011-07-09 19:14:28 -0600332 .mpu_irqs = omap44xx_l3_main_1_irqs,
Benoit Coussond0f06312011-07-10 05:56:30 -0600333 .prcm = {
334 .omap4 = {
335 .clkctrl_offs = OMAP4_CM_L3_1_L3_1_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600336 .context_offs = OMAP4_RM_L3_1_L3_1_CONTEXT_OFFSET,
Benoit Coussond0f06312011-07-10 05:56:30 -0600337 },
338 },
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200339 .slaves = omap44xx_l3_main_1_slaves,
340 .slaves_cnt = ARRAY_SIZE(omap44xx_l3_main_1_slaves),
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200341};
342
Benoit Cousson7e69ed92011-07-09 19:14:28 -0600343/* l3_main_2 */
Benoit Coussond7cf5f32010-12-23 22:30:31 +0000344/* dma_system -> l3_main_2 */
345static struct omap_hwmod_ocp_if omap44xx_dma_system__l3_main_2 = {
346 .master = &omap44xx_dma_system_hwmod,
347 .slave = &omap44xx_l3_main_2_hwmod,
348 .clk = "l3_div_ck",
349 .user = OCP_USER_MPU | OCP_USER_SDMA,
350};
351
Benoit Cousson407a6882011-02-15 22:39:48 +0100352/* hsi -> l3_main_2 */
353static struct omap_hwmod_ocp_if omap44xx_hsi__l3_main_2 = {
354 .master = &omap44xx_hsi_hwmod,
355 .slave = &omap44xx_l3_main_2_hwmod,
356 .clk = "l3_div_ck",
357 .user = OCP_USER_MPU | OCP_USER_SDMA,
358};
359
360/* ipu -> l3_main_2 */
361static struct omap_hwmod_ocp_if omap44xx_ipu__l3_main_2 = {
362 .master = &omap44xx_ipu_hwmod,
363 .slave = &omap44xx_l3_main_2_hwmod,
364 .clk = "l3_div_ck",
365 .user = OCP_USER_MPU | OCP_USER_SDMA,
366};
367
368/* iss -> l3_main_2 */
369static struct omap_hwmod_ocp_if omap44xx_iss__l3_main_2 = {
370 .master = &omap44xx_iss_hwmod,
371 .slave = &omap44xx_l3_main_2_hwmod,
372 .clk = "l3_div_ck",
373 .user = OCP_USER_MPU | OCP_USER_SDMA,
374};
375
Benoit Cousson8f25bdc2010-12-21 21:08:34 -0700376/* iva -> l3_main_2 */
377static struct omap_hwmod_ocp_if omap44xx_iva__l3_main_2 = {
378 .master = &omap44xx_iva_hwmod,
379 .slave = &omap44xx_l3_main_2_hwmod,
380 .clk = "l3_div_ck",
381 .user = OCP_USER_MPU | OCP_USER_SDMA,
382};
383
sricharanc4645232011-02-07 21:12:11 +0530384static struct omap_hwmod_addr_space omap44xx_l3_main_2_addrs[] = {
385 {
386 .pa_start = 0x44800000,
387 .pa_end = 0x44801fff,
Benoit Cousson9b4021b2011-07-09 19:14:27 -0600388 .flags = ADDR_TYPE_RT
sricharanc4645232011-02-07 21:12:11 +0530389 },
Paul Walmsley78183f32011-07-09 19:14:05 -0600390 { }
sricharanc4645232011-02-07 21:12:11 +0530391};
392
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200393/* l3_main_1 -> l3_main_2 */
394static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l3_main_2 = {
395 .master = &omap44xx_l3_main_1_hwmod,
396 .slave = &omap44xx_l3_main_2_hwmod,
397 .clk = "l3_div_ck",
sricharanc4645232011-02-07 21:12:11 +0530398 .addr = omap44xx_l3_main_2_addrs,
Benoit Cousson9b4021b2011-07-09 19:14:27 -0600399 .user = OCP_USER_MPU,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200400};
401
402/* l4_cfg -> l3_main_2 */
403static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l3_main_2 = {
404 .master = &omap44xx_l4_cfg_hwmod,
405 .slave = &omap44xx_l3_main_2_hwmod,
406 .clk = "l4_div_ck",
407 .user = OCP_USER_MPU | OCP_USER_SDMA,
408};
409
Benoit Cousson5844c4e2011-02-17 12:41:05 +0000410/* usb_otg_hs -> l3_main_2 */
411static struct omap_hwmod_ocp_if omap44xx_usb_otg_hs__l3_main_2 = {
412 .master = &omap44xx_usb_otg_hs_hwmod,
413 .slave = &omap44xx_l3_main_2_hwmod,
414 .clk = "l3_div_ck",
415 .user = OCP_USER_MPU | OCP_USER_SDMA,
416};
417
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200418/* l3_main_2 slave ports */
419static struct omap_hwmod_ocp_if *omap44xx_l3_main_2_slaves[] = {
Benoit Cousson531ce0d2010-12-20 18:27:19 -0800420 &omap44xx_dma_system__l3_main_2,
Benoit Cousson407a6882011-02-15 22:39:48 +0100421 &omap44xx_hsi__l3_main_2,
422 &omap44xx_ipu__l3_main_2,
423 &omap44xx_iss__l3_main_2,
Benoit Cousson8f25bdc2010-12-21 21:08:34 -0700424 &omap44xx_iva__l3_main_2,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200425 &omap44xx_l3_main_1__l3_main_2,
426 &omap44xx_l4_cfg__l3_main_2,
Benoit Cousson5844c4e2011-02-17 12:41:05 +0000427 &omap44xx_usb_otg_hs__l3_main_2,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200428};
429
430static struct omap_hwmod omap44xx_l3_main_2_hwmod = {
431 .name = "l3_main_2",
432 .class = &omap44xx_l3_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600433 .clkdm_name = "l3_2_clkdm",
Benoit Coussond0f06312011-07-10 05:56:30 -0600434 .prcm = {
435 .omap4 = {
436 .clkctrl_offs = OMAP4_CM_L3_2_L3_2_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600437 .context_offs = OMAP4_RM_L3_2_L3_2_CONTEXT_OFFSET,
Benoit Coussond0f06312011-07-10 05:56:30 -0600438 },
439 },
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200440 .slaves = omap44xx_l3_main_2_slaves,
441 .slaves_cnt = ARRAY_SIZE(omap44xx_l3_main_2_slaves),
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200442};
443
Benoit Cousson7e69ed92011-07-09 19:14:28 -0600444/* l3_main_3 */
sricharanc4645232011-02-07 21:12:11 +0530445static struct omap_hwmod_addr_space omap44xx_l3_main_3_addrs[] = {
446 {
447 .pa_start = 0x45000000,
448 .pa_end = 0x45000fff,
Benoit Cousson9b4021b2011-07-09 19:14:27 -0600449 .flags = ADDR_TYPE_RT
sricharanc4645232011-02-07 21:12:11 +0530450 },
Paul Walmsley78183f32011-07-09 19:14:05 -0600451 { }
sricharanc4645232011-02-07 21:12:11 +0530452};
453
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200454/* l3_main_1 -> l3_main_3 */
455static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l3_main_3 = {
456 .master = &omap44xx_l3_main_1_hwmod,
457 .slave = &omap44xx_l3_main_3_hwmod,
458 .clk = "l3_div_ck",
sricharanc4645232011-02-07 21:12:11 +0530459 .addr = omap44xx_l3_main_3_addrs,
Benoit Cousson9b4021b2011-07-09 19:14:27 -0600460 .user = OCP_USER_MPU,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200461};
462
463/* l3_main_2 -> l3_main_3 */
464static struct omap_hwmod_ocp_if omap44xx_l3_main_2__l3_main_3 = {
465 .master = &omap44xx_l3_main_2_hwmod,
466 .slave = &omap44xx_l3_main_3_hwmod,
467 .clk = "l3_div_ck",
468 .user = OCP_USER_MPU | OCP_USER_SDMA,
469};
470
471/* l4_cfg -> l3_main_3 */
472static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l3_main_3 = {
473 .master = &omap44xx_l4_cfg_hwmod,
474 .slave = &omap44xx_l3_main_3_hwmod,
475 .clk = "l4_div_ck",
476 .user = OCP_USER_MPU | OCP_USER_SDMA,
477};
478
479/* l3_main_3 slave ports */
480static struct omap_hwmod_ocp_if *omap44xx_l3_main_3_slaves[] = {
481 &omap44xx_l3_main_1__l3_main_3,
482 &omap44xx_l3_main_2__l3_main_3,
483 &omap44xx_l4_cfg__l3_main_3,
484};
485
486static struct omap_hwmod omap44xx_l3_main_3_hwmod = {
487 .name = "l3_main_3",
488 .class = &omap44xx_l3_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600489 .clkdm_name = "l3_instr_clkdm",
Benoit Coussond0f06312011-07-10 05:56:30 -0600490 .prcm = {
491 .omap4 = {
492 .clkctrl_offs = OMAP4_CM_L3INSTR_L3_3_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600493 .context_offs = OMAP4_RM_L3INSTR_L3_3_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -0600494 .modulemode = MODULEMODE_HWCTRL,
Benoit Coussond0f06312011-07-10 05:56:30 -0600495 },
496 },
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200497 .slaves = omap44xx_l3_main_3_slaves,
498 .slaves_cnt = ARRAY_SIZE(omap44xx_l3_main_3_slaves),
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200499};
500
501/*
502 * 'l4' class
503 * instance(s): l4_abe, l4_cfg, l4_per, l4_wkup
504 */
505static struct omap_hwmod_class omap44xx_l4_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +0000506 .name = "l4",
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200507};
508
Benoit Cousson7e69ed92011-07-09 19:14:28 -0600509/* l4_abe */
Benoit Cousson407a6882011-02-15 22:39:48 +0100510/* aess -> l4_abe */
511static struct omap_hwmod_ocp_if omap44xx_aess__l4_abe = {
512 .master = &omap44xx_aess_hwmod,
513 .slave = &omap44xx_l4_abe_hwmod,
514 .clk = "ocp_abe_iclk",
515 .user = OCP_USER_MPU | OCP_USER_SDMA,
516};
517
Benoit Cousson8f25bdc2010-12-21 21:08:34 -0700518/* dsp -> l4_abe */
519static struct omap_hwmod_ocp_if omap44xx_dsp__l4_abe = {
520 .master = &omap44xx_dsp_hwmod,
521 .slave = &omap44xx_l4_abe_hwmod,
522 .clk = "ocp_abe_iclk",
523 .user = OCP_USER_MPU | OCP_USER_SDMA,
524};
525
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200526/* l3_main_1 -> l4_abe */
527static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l4_abe = {
528 .master = &omap44xx_l3_main_1_hwmod,
529 .slave = &omap44xx_l4_abe_hwmod,
530 .clk = "l3_div_ck",
531 .user = OCP_USER_MPU | OCP_USER_SDMA,
532};
533
534/* mpu -> l4_abe */
535static struct omap_hwmod_ocp_if omap44xx_mpu__l4_abe = {
536 .master = &omap44xx_mpu_hwmod,
537 .slave = &omap44xx_l4_abe_hwmod,
538 .clk = "ocp_abe_iclk",
539 .user = OCP_USER_MPU | OCP_USER_SDMA,
540};
541
542/* l4_abe slave ports */
543static struct omap_hwmod_ocp_if *omap44xx_l4_abe_slaves[] = {
Benoit Cousson407a6882011-02-15 22:39:48 +0100544 &omap44xx_aess__l4_abe,
Benoit Cousson8f25bdc2010-12-21 21:08:34 -0700545 &omap44xx_dsp__l4_abe,
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200546 &omap44xx_l3_main_1__l4_abe,
547 &omap44xx_mpu__l4_abe,
548};
549
550static struct omap_hwmod omap44xx_l4_abe_hwmod = {
551 .name = "l4_abe",
552 .class = &omap44xx_l4_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600553 .clkdm_name = "abe_clkdm",
Benoit Coussond0f06312011-07-10 05:56:30 -0600554 .prcm = {
555 .omap4 = {
556 .clkctrl_offs = OMAP4_CM1_ABE_L4ABE_CLKCTRL_OFFSET,
557 },
558 },
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200559 .slaves = omap44xx_l4_abe_slaves,
560 .slaves_cnt = ARRAY_SIZE(omap44xx_l4_abe_slaves),
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200561};
562
Benoit Cousson7e69ed92011-07-09 19:14:28 -0600563/* l4_cfg */
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200564/* l3_main_1 -> l4_cfg */
565static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l4_cfg = {
566 .master = &omap44xx_l3_main_1_hwmod,
567 .slave = &omap44xx_l4_cfg_hwmod,
568 .clk = "l3_div_ck",
569 .user = OCP_USER_MPU | OCP_USER_SDMA,
570};
571
572/* l4_cfg slave ports */
573static struct omap_hwmod_ocp_if *omap44xx_l4_cfg_slaves[] = {
574 &omap44xx_l3_main_1__l4_cfg,
575};
576
577static struct omap_hwmod omap44xx_l4_cfg_hwmod = {
578 .name = "l4_cfg",
579 .class = &omap44xx_l4_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600580 .clkdm_name = "l4_cfg_clkdm",
Benoit Coussond0f06312011-07-10 05:56:30 -0600581 .prcm = {
582 .omap4 = {
583 .clkctrl_offs = OMAP4_CM_L4CFG_L4_CFG_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600584 .context_offs = OMAP4_RM_L4CFG_L4_CFG_CONTEXT_OFFSET,
Benoit Coussond0f06312011-07-10 05:56:30 -0600585 },
586 },
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200587 .slaves = omap44xx_l4_cfg_slaves,
588 .slaves_cnt = ARRAY_SIZE(omap44xx_l4_cfg_slaves),
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200589};
590
Benoit Cousson7e69ed92011-07-09 19:14:28 -0600591/* l4_per */
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200592/* l3_main_2 -> l4_per */
593static struct omap_hwmod_ocp_if omap44xx_l3_main_2__l4_per = {
594 .master = &omap44xx_l3_main_2_hwmod,
595 .slave = &omap44xx_l4_per_hwmod,
596 .clk = "l3_div_ck",
597 .user = OCP_USER_MPU | OCP_USER_SDMA,
598};
599
600/* l4_per slave ports */
601static struct omap_hwmod_ocp_if *omap44xx_l4_per_slaves[] = {
602 &omap44xx_l3_main_2__l4_per,
603};
604
605static struct omap_hwmod omap44xx_l4_per_hwmod = {
606 .name = "l4_per",
607 .class = &omap44xx_l4_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600608 .clkdm_name = "l4_per_clkdm",
Benoit Coussond0f06312011-07-10 05:56:30 -0600609 .prcm = {
610 .omap4 = {
611 .clkctrl_offs = OMAP4_CM_L4PER_L4PER_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600612 .context_offs = OMAP4_RM_L4PER_L4_PER_CONTEXT_OFFSET,
Benoit Coussond0f06312011-07-10 05:56:30 -0600613 },
614 },
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200615 .slaves = omap44xx_l4_per_slaves,
616 .slaves_cnt = ARRAY_SIZE(omap44xx_l4_per_slaves),
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200617};
618
Benoit Cousson7e69ed92011-07-09 19:14:28 -0600619/* l4_wkup */
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200620/* l4_cfg -> l4_wkup */
621static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l4_wkup = {
622 .master = &omap44xx_l4_cfg_hwmod,
623 .slave = &omap44xx_l4_wkup_hwmod,
624 .clk = "l4_div_ck",
625 .user = OCP_USER_MPU | OCP_USER_SDMA,
626};
627
628/* l4_wkup slave ports */
629static struct omap_hwmod_ocp_if *omap44xx_l4_wkup_slaves[] = {
630 &omap44xx_l4_cfg__l4_wkup,
631};
632
633static struct omap_hwmod omap44xx_l4_wkup_hwmod = {
634 .name = "l4_wkup",
635 .class = &omap44xx_l4_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600636 .clkdm_name = "l4_wkup_clkdm",
Benoit Coussond0f06312011-07-10 05:56:30 -0600637 .prcm = {
638 .omap4 = {
639 .clkctrl_offs = OMAP4_CM_WKUP_L4WKUP_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600640 .context_offs = OMAP4_RM_WKUP_L4WKUP_CONTEXT_OFFSET,
Benoit Coussond0f06312011-07-10 05:56:30 -0600641 },
642 },
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200643 .slaves = omap44xx_l4_wkup_slaves,
644 .slaves_cnt = ARRAY_SIZE(omap44xx_l4_wkup_slaves),
Benoit Cousson55d2cb02010-05-12 17:54:36 +0200645};
646
647/*
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700648 * 'mpu_bus' class
649 * instance(s): mpu_private
650 */
651static struct omap_hwmod_class omap44xx_mpu_bus_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +0000652 .name = "mpu_bus",
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700653};
654
Benoit Cousson7e69ed92011-07-09 19:14:28 -0600655/* mpu_private */
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700656/* mpu -> mpu_private */
657static struct omap_hwmod_ocp_if omap44xx_mpu__mpu_private = {
658 .master = &omap44xx_mpu_hwmod,
659 .slave = &omap44xx_mpu_private_hwmod,
660 .clk = "l3_div_ck",
661 .user = OCP_USER_MPU | OCP_USER_SDMA,
662};
663
664/* mpu_private slave ports */
665static struct omap_hwmod_ocp_if *omap44xx_mpu_private_slaves[] = {
666 &omap44xx_mpu__mpu_private,
667};
668
669static struct omap_hwmod omap44xx_mpu_private_hwmod = {
670 .name = "mpu_private",
671 .class = &omap44xx_mpu_bus_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600672 .clkdm_name = "mpuss_clkdm",
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700673 .slaves = omap44xx_mpu_private_slaves,
674 .slaves_cnt = ARRAY_SIZE(omap44xx_mpu_private_slaves),
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700675};
676
677/*
678 * Modules omap_hwmod structures
679 *
680 * The following IPs are excluded for the moment because:
681 * - They do not need an explicit SW control using omap_hwmod API.
682 * - They still need to be validated with the driver
683 * properly adapted to omap_hwmod / omap_device
684 *
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700685 * c2c
686 * c2c_target_fw
687 * cm_core
688 * cm_core_aon
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700689 * ctrl_module_core
690 * ctrl_module_pad_core
691 * ctrl_module_pad_wkup
692 * ctrl_module_wkup
693 * debugss
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700694 * efuse_ctrl_cust
695 * efuse_ctrl_std
696 * elm
697 * emif1
698 * emif2
699 * fdif
700 * gpmc
701 * gpu
702 * hdq1w
Benoit Cousson00fe6102011-07-09 19:14:28 -0600703 * mcasp
704 * mpu_c0
705 * mpu_c1
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700706 * ocmc_ram
707 * ocp2scp_usb_phy
708 * ocp_wp_noc
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700709 * prcm_mpu
710 * prm
711 * scrm
712 * sl2if
713 * slimbus1
714 * slimbus2
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700715 * usb_host_fs
716 * usb_host_hs
Benoit Cousson3b54baa2010-12-21 21:08:33 -0700717 * usb_phy_cm
718 * usb_tll_hs
719 * usim
720 */
721
722/*
Benoit Cousson407a6882011-02-15 22:39:48 +0100723 * 'aess' class
724 * audio engine sub system
725 */
726
727static struct omap_hwmod_class_sysconfig omap44xx_aess_sysc = {
728 .rev_offs = 0x0000,
729 .sysc_offs = 0x0010,
730 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
731 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
Benoit Coussonc614ebf2011-07-01 22:54:01 +0200732 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART |
733 MSTANDBY_SMART_WKUP),
Benoit Cousson407a6882011-02-15 22:39:48 +0100734 .sysc_fields = &omap_hwmod_sysc_type2,
735};
736
737static struct omap_hwmod_class omap44xx_aess_hwmod_class = {
738 .name = "aess",
739 .sysc = &omap44xx_aess_sysc,
740};
741
742/* aess */
743static struct omap_hwmod_irq_info omap44xx_aess_irqs[] = {
744 { .irq = 99 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -0600745 { .irq = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +0100746};
747
748static struct omap_hwmod_dma_info omap44xx_aess_sdma_reqs[] = {
749 { .name = "fifo0", .dma_req = 100 + OMAP44XX_DMA_REQ_START },
750 { .name = "fifo1", .dma_req = 101 + OMAP44XX_DMA_REQ_START },
751 { .name = "fifo2", .dma_req = 102 + OMAP44XX_DMA_REQ_START },
752 { .name = "fifo3", .dma_req = 103 + OMAP44XX_DMA_REQ_START },
753 { .name = "fifo4", .dma_req = 104 + OMAP44XX_DMA_REQ_START },
754 { .name = "fifo5", .dma_req = 105 + OMAP44XX_DMA_REQ_START },
755 { .name = "fifo6", .dma_req = 106 + OMAP44XX_DMA_REQ_START },
756 { .name = "fifo7", .dma_req = 107 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -0600757 { .dma_req = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +0100758};
759
760/* aess master ports */
761static struct omap_hwmod_ocp_if *omap44xx_aess_masters[] = {
762 &omap44xx_aess__l4_abe,
763};
764
765static struct omap_hwmod_addr_space omap44xx_aess_addrs[] = {
766 {
767 .pa_start = 0x401f1000,
768 .pa_end = 0x401f13ff,
769 .flags = ADDR_TYPE_RT
770 },
Paul Walmsley78183f32011-07-09 19:14:05 -0600771 { }
Benoit Cousson407a6882011-02-15 22:39:48 +0100772};
773
774/* l4_abe -> aess */
775static struct omap_hwmod_ocp_if omap44xx_l4_abe__aess = {
776 .master = &omap44xx_l4_abe_hwmod,
777 .slave = &omap44xx_aess_hwmod,
778 .clk = "ocp_abe_iclk",
779 .addr = omap44xx_aess_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +0100780 .user = OCP_USER_MPU,
781};
782
783static struct omap_hwmod_addr_space omap44xx_aess_dma_addrs[] = {
784 {
785 .pa_start = 0x490f1000,
786 .pa_end = 0x490f13ff,
787 .flags = ADDR_TYPE_RT
788 },
Paul Walmsley78183f32011-07-09 19:14:05 -0600789 { }
Benoit Cousson407a6882011-02-15 22:39:48 +0100790};
791
792/* l4_abe -> aess (dma) */
793static struct omap_hwmod_ocp_if omap44xx_l4_abe__aess_dma = {
794 .master = &omap44xx_l4_abe_hwmod,
795 .slave = &omap44xx_aess_hwmod,
796 .clk = "ocp_abe_iclk",
797 .addr = omap44xx_aess_dma_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +0100798 .user = OCP_USER_SDMA,
799};
800
801/* aess slave ports */
802static struct omap_hwmod_ocp_if *omap44xx_aess_slaves[] = {
803 &omap44xx_l4_abe__aess,
804 &omap44xx_l4_abe__aess_dma,
805};
806
807static struct omap_hwmod omap44xx_aess_hwmod = {
808 .name = "aess",
809 .class = &omap44xx_aess_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600810 .clkdm_name = "abe_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +0100811 .mpu_irqs = omap44xx_aess_irqs,
Benoit Cousson407a6882011-02-15 22:39:48 +0100812 .sdma_reqs = omap44xx_aess_sdma_reqs,
Benoit Cousson407a6882011-02-15 22:39:48 +0100813 .main_clk = "aess_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -0600814 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +0100815 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -0600816 .clkctrl_offs = OMAP4_CM1_ABE_AESS_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600817 .context_offs = OMAP4_RM_ABE_AESS_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -0600818 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson407a6882011-02-15 22:39:48 +0100819 },
820 },
821 .slaves = omap44xx_aess_slaves,
822 .slaves_cnt = ARRAY_SIZE(omap44xx_aess_slaves),
823 .masters = omap44xx_aess_masters,
824 .masters_cnt = ARRAY_SIZE(omap44xx_aess_masters),
Benoit Cousson407a6882011-02-15 22:39:48 +0100825};
826
827/*
828 * 'bandgap' class
829 * bangap reference for ldo regulators
830 */
831
832static struct omap_hwmod_class omap44xx_bandgap_hwmod_class = {
833 .name = "bandgap",
834};
835
836/* bandgap */
837static struct omap_hwmod_opt_clk bandgap_opt_clks[] = {
838 { .role = "fclk", .clk = "bandgap_fclk" },
839};
840
841static struct omap_hwmod omap44xx_bandgap_hwmod = {
842 .name = "bandgap",
843 .class = &omap44xx_bandgap_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600844 .clkdm_name = "l4_wkup_clkdm",
Benoit Cousson00fe6102011-07-09 19:14:28 -0600845 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +0100846 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -0600847 .clkctrl_offs = OMAP4_CM_WKUP_BANDGAP_CLKCTRL_OFFSET,
Benoit Cousson407a6882011-02-15 22:39:48 +0100848 },
849 },
850 .opt_clks = bandgap_opt_clks,
851 .opt_clks_cnt = ARRAY_SIZE(bandgap_opt_clks),
Benoit Cousson407a6882011-02-15 22:39:48 +0100852};
853
854/*
855 * 'counter' class
856 * 32-bit ordinary counter, clocked by the falling edge of the 32 khz clock
857 */
858
859static struct omap_hwmod_class_sysconfig omap44xx_counter_sysc = {
860 .rev_offs = 0x0000,
861 .sysc_offs = 0x0004,
862 .sysc_flags = SYSC_HAS_SIDLEMODE,
863 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
864 SIDLE_SMART_WKUP),
865 .sysc_fields = &omap_hwmod_sysc_type1,
866};
867
868static struct omap_hwmod_class omap44xx_counter_hwmod_class = {
869 .name = "counter",
870 .sysc = &omap44xx_counter_sysc,
871};
872
873/* counter_32k */
874static struct omap_hwmod omap44xx_counter_32k_hwmod;
875static struct omap_hwmod_addr_space omap44xx_counter_32k_addrs[] = {
876 {
877 .pa_start = 0x4a304000,
878 .pa_end = 0x4a30401f,
879 .flags = ADDR_TYPE_RT
880 },
Paul Walmsley78183f32011-07-09 19:14:05 -0600881 { }
Benoit Cousson407a6882011-02-15 22:39:48 +0100882};
883
884/* l4_wkup -> counter_32k */
885static struct omap_hwmod_ocp_if omap44xx_l4_wkup__counter_32k = {
886 .master = &omap44xx_l4_wkup_hwmod,
887 .slave = &omap44xx_counter_32k_hwmod,
888 .clk = "l4_wkup_clk_mux_ck",
889 .addr = omap44xx_counter_32k_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +0100890 .user = OCP_USER_MPU | OCP_USER_SDMA,
891};
892
893/* counter_32k slave ports */
894static struct omap_hwmod_ocp_if *omap44xx_counter_32k_slaves[] = {
895 &omap44xx_l4_wkup__counter_32k,
896};
897
898static struct omap_hwmod omap44xx_counter_32k_hwmod = {
899 .name = "counter_32k",
900 .class = &omap44xx_counter_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600901 .clkdm_name = "l4_wkup_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +0100902 .flags = HWMOD_SWSUP_SIDLE,
903 .main_clk = "sys_32k_ck",
Benoit Cousson00fe6102011-07-09 19:14:28 -0600904 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +0100905 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -0600906 .clkctrl_offs = OMAP4_CM_WKUP_SYNCTIMER_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600907 .context_offs = OMAP4_RM_WKUP_SYNCTIMER_CONTEXT_OFFSET,
Benoit Cousson407a6882011-02-15 22:39:48 +0100908 },
909 },
910 .slaves = omap44xx_counter_32k_slaves,
911 .slaves_cnt = ARRAY_SIZE(omap44xx_counter_32k_slaves),
Benoit Cousson407a6882011-02-15 22:39:48 +0100912};
913
914/*
Benoit Coussond7cf5f32010-12-23 22:30:31 +0000915 * 'dma' class
916 * dma controller for data exchange between memory to memory (i.e. internal or
917 * external memory) and gp peripherals to memory or memory to gp peripherals
918 */
919
920static struct omap_hwmod_class_sysconfig omap44xx_dma_sysc = {
921 .rev_offs = 0x0000,
922 .sysc_offs = 0x002c,
923 .syss_offs = 0x0028,
924 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
925 SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE |
926 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
927 SYSS_HAS_RESET_STATUS),
928 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
929 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
930 .sysc_fields = &omap_hwmod_sysc_type1,
931};
932
933static struct omap_hwmod_class omap44xx_dma_hwmod_class = {
934 .name = "dma",
935 .sysc = &omap44xx_dma_sysc,
936};
937
938/* dma dev_attr */
939static struct omap_dma_dev_attr dma_dev_attr = {
940 .dev_caps = RESERVE_CHANNEL | DMA_LINKED_LCH | GLOBAL_PRIORITY |
941 IS_CSSA_32 | IS_CDSA_32 | IS_RW_PRIORITY,
942 .lch_count = 32,
943};
944
945/* dma_system */
946static struct omap_hwmod_irq_info omap44xx_dma_system_irqs[] = {
947 { .name = "0", .irq = 12 + OMAP44XX_IRQ_GIC_START },
948 { .name = "1", .irq = 13 + OMAP44XX_IRQ_GIC_START },
949 { .name = "2", .irq = 14 + OMAP44XX_IRQ_GIC_START },
950 { .name = "3", .irq = 15 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -0600951 { .irq = -1 }
Benoit Coussond7cf5f32010-12-23 22:30:31 +0000952};
953
954/* dma_system master ports */
955static struct omap_hwmod_ocp_if *omap44xx_dma_system_masters[] = {
956 &omap44xx_dma_system__l3_main_2,
957};
958
959static struct omap_hwmod_addr_space omap44xx_dma_system_addrs[] = {
960 {
961 .pa_start = 0x4a056000,
Benoit Cousson1286eeb2011-04-19 10:15:36 -0600962 .pa_end = 0x4a056fff,
Benoit Coussond7cf5f32010-12-23 22:30:31 +0000963 .flags = ADDR_TYPE_RT
964 },
Paul Walmsley78183f32011-07-09 19:14:05 -0600965 { }
Benoit Coussond7cf5f32010-12-23 22:30:31 +0000966};
967
968/* l4_cfg -> dma_system */
969static struct omap_hwmod_ocp_if omap44xx_l4_cfg__dma_system = {
970 .master = &omap44xx_l4_cfg_hwmod,
971 .slave = &omap44xx_dma_system_hwmod,
972 .clk = "l4_div_ck",
973 .addr = omap44xx_dma_system_addrs,
Benoit Coussond7cf5f32010-12-23 22:30:31 +0000974 .user = OCP_USER_MPU | OCP_USER_SDMA,
975};
976
977/* dma_system slave ports */
978static struct omap_hwmod_ocp_if *omap44xx_dma_system_slaves[] = {
979 &omap44xx_l4_cfg__dma_system,
980};
981
982static struct omap_hwmod omap44xx_dma_system_hwmod = {
983 .name = "dma_system",
984 .class = &omap44xx_dma_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -0600985 .clkdm_name = "l3_dma_clkdm",
Benoit Coussond7cf5f32010-12-23 22:30:31 +0000986 .mpu_irqs = omap44xx_dma_system_irqs,
Benoit Coussond7cf5f32010-12-23 22:30:31 +0000987 .main_clk = "l3_div_ck",
988 .prcm = {
989 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -0600990 .clkctrl_offs = OMAP4_CM_SDMA_SDMA_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -0600991 .context_offs = OMAP4_RM_SDMA_SDMA_CONTEXT_OFFSET,
Benoit Coussond7cf5f32010-12-23 22:30:31 +0000992 },
993 },
994 .dev_attr = &dma_dev_attr,
995 .slaves = omap44xx_dma_system_slaves,
996 .slaves_cnt = ARRAY_SIZE(omap44xx_dma_system_slaves),
997 .masters = omap44xx_dma_system_masters,
998 .masters_cnt = ARRAY_SIZE(omap44xx_dma_system_masters),
Benoit Coussond7cf5f32010-12-23 22:30:31 +0000999};
1000
1001/*
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001002 * 'dmic' class
1003 * digital microphone controller
1004 */
1005
1006static struct omap_hwmod_class_sysconfig omap44xx_dmic_sysc = {
1007 .rev_offs = 0x0000,
1008 .sysc_offs = 0x0010,
1009 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
1010 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
1011 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1012 SIDLE_SMART_WKUP),
1013 .sysc_fields = &omap_hwmod_sysc_type2,
1014};
1015
1016static struct omap_hwmod_class omap44xx_dmic_hwmod_class = {
1017 .name = "dmic",
1018 .sysc = &omap44xx_dmic_sysc,
1019};
1020
1021/* dmic */
1022static struct omap_hwmod omap44xx_dmic_hwmod;
1023static struct omap_hwmod_irq_info omap44xx_dmic_irqs[] = {
1024 { .irq = 114 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06001025 { .irq = -1 }
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001026};
1027
1028static struct omap_hwmod_dma_info omap44xx_dmic_sdma_reqs[] = {
1029 { .dma_req = 66 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06001030 { .dma_req = -1 }
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001031};
1032
1033static struct omap_hwmod_addr_space omap44xx_dmic_addrs[] = {
1034 {
Peter Ujfalusi6af486e2011-11-28 15:45:39 +02001035 .name = "mpu",
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001036 .pa_start = 0x4012e000,
1037 .pa_end = 0x4012e07f,
1038 .flags = ADDR_TYPE_RT
1039 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001040 { }
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001041};
1042
1043/* l4_abe -> dmic */
1044static struct omap_hwmod_ocp_if omap44xx_l4_abe__dmic = {
1045 .master = &omap44xx_l4_abe_hwmod,
1046 .slave = &omap44xx_dmic_hwmod,
1047 .clk = "ocp_abe_iclk",
1048 .addr = omap44xx_dmic_addrs,
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001049 .user = OCP_USER_MPU,
1050};
1051
1052static struct omap_hwmod_addr_space omap44xx_dmic_dma_addrs[] = {
1053 {
Peter Ujfalusi6af486e2011-11-28 15:45:39 +02001054 .name = "dma",
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001055 .pa_start = 0x4902e000,
1056 .pa_end = 0x4902e07f,
1057 .flags = ADDR_TYPE_RT
1058 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001059 { }
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001060};
1061
1062/* l4_abe -> dmic (dma) */
1063static struct omap_hwmod_ocp_if omap44xx_l4_abe__dmic_dma = {
1064 .master = &omap44xx_l4_abe_hwmod,
1065 .slave = &omap44xx_dmic_hwmod,
1066 .clk = "ocp_abe_iclk",
1067 .addr = omap44xx_dmic_dma_addrs,
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001068 .user = OCP_USER_SDMA,
1069};
1070
1071/* dmic slave ports */
1072static struct omap_hwmod_ocp_if *omap44xx_dmic_slaves[] = {
1073 &omap44xx_l4_abe__dmic,
1074 &omap44xx_l4_abe__dmic_dma,
1075};
1076
1077static struct omap_hwmod omap44xx_dmic_hwmod = {
1078 .name = "dmic",
1079 .class = &omap44xx_dmic_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001080 .clkdm_name = "abe_clkdm",
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001081 .mpu_irqs = omap44xx_dmic_irqs,
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001082 .sdma_reqs = omap44xx_dmic_sdma_reqs,
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001083 .main_clk = "dmic_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -06001084 .prcm = {
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001085 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001086 .clkctrl_offs = OMAP4_CM1_ABE_DMIC_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001087 .context_offs = OMAP4_RM_ABE_DMIC_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06001088 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001089 },
1090 },
1091 .slaves = omap44xx_dmic_slaves,
1092 .slaves_cnt = ARRAY_SIZE(omap44xx_dmic_slaves),
Benoit Cousson8ca476d2011-01-25 22:01:00 +00001093};
1094
1095/*
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07001096 * 'dsp' class
1097 * dsp sub-system
1098 */
1099
1100static struct omap_hwmod_class omap44xx_dsp_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +00001101 .name = "dsp",
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07001102};
1103
1104/* dsp */
1105static struct omap_hwmod_irq_info omap44xx_dsp_irqs[] = {
1106 { .irq = 28 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06001107 { .irq = -1 }
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07001108};
1109
1110static struct omap_hwmod_rst_info omap44xx_dsp_resets[] = {
1111 { .name = "mmu_cache", .rst_shift = 1 },
1112};
1113
1114static struct omap_hwmod_rst_info omap44xx_dsp_c0_resets[] = {
1115 { .name = "dsp", .rst_shift = 0 },
1116};
1117
1118/* dsp -> iva */
1119static struct omap_hwmod_ocp_if omap44xx_dsp__iva = {
1120 .master = &omap44xx_dsp_hwmod,
1121 .slave = &omap44xx_iva_hwmod,
1122 .clk = "dpll_iva_m5x2_ck",
1123};
1124
1125/* dsp master ports */
1126static struct omap_hwmod_ocp_if *omap44xx_dsp_masters[] = {
1127 &omap44xx_dsp__l3_main_1,
1128 &omap44xx_dsp__l4_abe,
1129 &omap44xx_dsp__iva,
1130};
1131
1132/* l4_cfg -> dsp */
1133static struct omap_hwmod_ocp_if omap44xx_l4_cfg__dsp = {
1134 .master = &omap44xx_l4_cfg_hwmod,
1135 .slave = &omap44xx_dsp_hwmod,
1136 .clk = "l4_div_ck",
1137 .user = OCP_USER_MPU | OCP_USER_SDMA,
1138};
1139
1140/* dsp slave ports */
1141static struct omap_hwmod_ocp_if *omap44xx_dsp_slaves[] = {
1142 &omap44xx_l4_cfg__dsp,
1143};
1144
1145/* Pseudo hwmod for reset control purpose only */
1146static struct omap_hwmod omap44xx_dsp_c0_hwmod = {
1147 .name = "dsp_c0",
1148 .class = &omap44xx_dsp_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001149 .clkdm_name = "tesla_clkdm",
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07001150 .flags = HWMOD_INIT_NO_RESET,
1151 .rst_lines = omap44xx_dsp_c0_resets,
1152 .rst_lines_cnt = ARRAY_SIZE(omap44xx_dsp_c0_resets),
1153 .prcm = {
1154 .omap4 = {
Benoit Coussoneaac3292011-07-10 05:56:31 -06001155 .rstctrl_offs = OMAP4_RM_TESLA_RSTCTRL_OFFSET,
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07001156 },
1157 },
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07001158};
1159
1160static struct omap_hwmod omap44xx_dsp_hwmod = {
1161 .name = "dsp",
1162 .class = &omap44xx_dsp_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001163 .clkdm_name = "tesla_clkdm",
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07001164 .mpu_irqs = omap44xx_dsp_irqs,
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07001165 .rst_lines = omap44xx_dsp_resets,
1166 .rst_lines_cnt = ARRAY_SIZE(omap44xx_dsp_resets),
1167 .main_clk = "dsp_fck",
1168 .prcm = {
1169 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001170 .clkctrl_offs = OMAP4_CM_TESLA_TESLA_CLKCTRL_OFFSET,
Benoit Coussoneaac3292011-07-10 05:56:31 -06001171 .rstctrl_offs = OMAP4_RM_TESLA_RSTCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001172 .context_offs = OMAP4_RM_TESLA_TESLA_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06001173 .modulemode = MODULEMODE_HWCTRL,
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07001174 },
1175 },
1176 .slaves = omap44xx_dsp_slaves,
1177 .slaves_cnt = ARRAY_SIZE(omap44xx_dsp_slaves),
1178 .masters = omap44xx_dsp_masters,
1179 .masters_cnt = ARRAY_SIZE(omap44xx_dsp_masters),
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07001180};
1181
1182/*
Benoit Coussond63bd742011-01-27 11:17:03 +00001183 * 'dss' class
1184 * display sub-system
1185 */
1186
1187static struct omap_hwmod_class_sysconfig omap44xx_dss_sysc = {
1188 .rev_offs = 0x0000,
1189 .syss_offs = 0x0014,
1190 .sysc_flags = SYSS_HAS_RESET_STATUS,
1191};
1192
1193static struct omap_hwmod_class omap44xx_dss_hwmod_class = {
1194 .name = "dss",
1195 .sysc = &omap44xx_dss_sysc,
Tomi Valkeinen13662dc2011-11-08 03:16:13 -07001196 .reset = omap_dss_reset,
Benoit Coussond63bd742011-01-27 11:17:03 +00001197};
1198
1199/* dss */
1200/* dss master ports */
1201static struct omap_hwmod_ocp_if *omap44xx_dss_masters[] = {
1202 &omap44xx_dss__l3_main_1,
1203};
1204
1205static struct omap_hwmod_addr_space omap44xx_dss_dma_addrs[] = {
1206 {
1207 .pa_start = 0x58000000,
1208 .pa_end = 0x5800007f,
1209 .flags = ADDR_TYPE_RT
1210 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001211 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001212};
1213
1214/* l3_main_2 -> dss */
1215static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss = {
1216 .master = &omap44xx_l3_main_2_hwmod,
1217 .slave = &omap44xx_dss_hwmod,
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001218 .clk = "dss_fck",
Benoit Coussond63bd742011-01-27 11:17:03 +00001219 .addr = omap44xx_dss_dma_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001220 .user = OCP_USER_SDMA,
1221};
1222
1223static struct omap_hwmod_addr_space omap44xx_dss_addrs[] = {
1224 {
1225 .pa_start = 0x48040000,
1226 .pa_end = 0x4804007f,
1227 .flags = ADDR_TYPE_RT
1228 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001229 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001230};
1231
1232/* l4_per -> dss */
1233static struct omap_hwmod_ocp_if omap44xx_l4_per__dss = {
1234 .master = &omap44xx_l4_per_hwmod,
1235 .slave = &omap44xx_dss_hwmod,
1236 .clk = "l4_div_ck",
1237 .addr = omap44xx_dss_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001238 .user = OCP_USER_MPU,
1239};
1240
1241/* dss slave ports */
1242static struct omap_hwmod_ocp_if *omap44xx_dss_slaves[] = {
1243 &omap44xx_l3_main_2__dss,
1244 &omap44xx_l4_per__dss,
1245};
1246
1247static struct omap_hwmod_opt_clk dss_opt_clks[] = {
1248 { .role = "sys_clk", .clk = "dss_sys_clk" },
1249 { .role = "tv_clk", .clk = "dss_tv_clk" },
Tomi Valkeinen4d0698d2011-11-08 03:16:12 -07001250 { .role = "hdmi_clk", .clk = "dss_48mhz_clk" },
Benoit Coussond63bd742011-01-27 11:17:03 +00001251};
1252
1253static struct omap_hwmod omap44xx_dss_hwmod = {
1254 .name = "dss_core",
Tomi Valkeinen37ad0852011-11-08 03:16:11 -07001255 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
Benoit Coussond63bd742011-01-27 11:17:03 +00001256 .class = &omap44xx_dss_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001257 .clkdm_name = "l3_dss_clkdm",
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001258 .main_clk = "dss_dss_clk",
Benoit Coussond63bd742011-01-27 11:17:03 +00001259 .prcm = {
1260 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001261 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001262 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
Benoit Coussond63bd742011-01-27 11:17:03 +00001263 },
1264 },
1265 .opt_clks = dss_opt_clks,
1266 .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks),
1267 .slaves = omap44xx_dss_slaves,
1268 .slaves_cnt = ARRAY_SIZE(omap44xx_dss_slaves),
1269 .masters = omap44xx_dss_masters,
1270 .masters_cnt = ARRAY_SIZE(omap44xx_dss_masters),
Benoit Coussond63bd742011-01-27 11:17:03 +00001271};
1272
1273/*
1274 * 'dispc' class
1275 * display controller
1276 */
1277
1278static struct omap_hwmod_class_sysconfig omap44xx_dispc_sysc = {
1279 .rev_offs = 0x0000,
1280 .sysc_offs = 0x0010,
1281 .syss_offs = 0x0014,
1282 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
1283 SYSC_HAS_ENAWAKEUP | SYSC_HAS_MIDLEMODE |
1284 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
1285 SYSS_HAS_RESET_STATUS),
1286 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1287 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
1288 .sysc_fields = &omap_hwmod_sysc_type1,
1289};
1290
1291static struct omap_hwmod_class omap44xx_dispc_hwmod_class = {
1292 .name = "dispc",
1293 .sysc = &omap44xx_dispc_sysc,
1294};
1295
1296/* dss_dispc */
1297static struct omap_hwmod omap44xx_dss_dispc_hwmod;
1298static struct omap_hwmod_irq_info omap44xx_dss_dispc_irqs[] = {
1299 { .irq = 25 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06001300 { .irq = -1 }
Benoit Coussond63bd742011-01-27 11:17:03 +00001301};
1302
1303static struct omap_hwmod_dma_info omap44xx_dss_dispc_sdma_reqs[] = {
1304 { .dma_req = 5 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06001305 { .dma_req = -1 }
Benoit Coussond63bd742011-01-27 11:17:03 +00001306};
1307
1308static struct omap_hwmod_addr_space omap44xx_dss_dispc_dma_addrs[] = {
1309 {
1310 .pa_start = 0x58001000,
1311 .pa_end = 0x58001fff,
1312 .flags = ADDR_TYPE_RT
1313 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001314 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001315};
1316
1317/* l3_main_2 -> dss_dispc */
1318static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_dispc = {
1319 .master = &omap44xx_l3_main_2_hwmod,
1320 .slave = &omap44xx_dss_dispc_hwmod,
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001321 .clk = "dss_fck",
Benoit Coussond63bd742011-01-27 11:17:03 +00001322 .addr = omap44xx_dss_dispc_dma_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001323 .user = OCP_USER_SDMA,
1324};
1325
1326static struct omap_hwmod_addr_space omap44xx_dss_dispc_addrs[] = {
1327 {
1328 .pa_start = 0x48041000,
1329 .pa_end = 0x48041fff,
1330 .flags = ADDR_TYPE_RT
1331 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001332 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001333};
1334
Archit Tanejab923d402011-10-06 18:04:08 -06001335static struct omap_dss_dispc_dev_attr omap44xx_dss_dispc_dev_attr = {
1336 .manager_count = 3,
1337 .has_framedonetv_irq = 1
1338};
1339
Benoit Coussond63bd742011-01-27 11:17:03 +00001340/* l4_per -> dss_dispc */
1341static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_dispc = {
1342 .master = &omap44xx_l4_per_hwmod,
1343 .slave = &omap44xx_dss_dispc_hwmod,
1344 .clk = "l4_div_ck",
1345 .addr = omap44xx_dss_dispc_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001346 .user = OCP_USER_MPU,
1347};
1348
1349/* dss_dispc slave ports */
1350static struct omap_hwmod_ocp_if *omap44xx_dss_dispc_slaves[] = {
1351 &omap44xx_l3_main_2__dss_dispc,
1352 &omap44xx_l4_per__dss_dispc,
1353};
1354
1355static struct omap_hwmod omap44xx_dss_dispc_hwmod = {
1356 .name = "dss_dispc",
1357 .class = &omap44xx_dispc_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001358 .clkdm_name = "l3_dss_clkdm",
Benoit Coussond63bd742011-01-27 11:17:03 +00001359 .mpu_irqs = omap44xx_dss_dispc_irqs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001360 .sdma_reqs = omap44xx_dss_dispc_sdma_reqs,
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001361 .main_clk = "dss_dss_clk",
Benoit Coussond63bd742011-01-27 11:17:03 +00001362 .prcm = {
1363 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001364 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001365 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
Benoit Coussond63bd742011-01-27 11:17:03 +00001366 },
1367 },
1368 .slaves = omap44xx_dss_dispc_slaves,
1369 .slaves_cnt = ARRAY_SIZE(omap44xx_dss_dispc_slaves),
Archit Tanejab923d402011-10-06 18:04:08 -06001370 .dev_attr = &omap44xx_dss_dispc_dev_attr
Benoit Coussond63bd742011-01-27 11:17:03 +00001371};
1372
1373/*
1374 * 'dsi' class
1375 * display serial interface controller
1376 */
1377
1378static struct omap_hwmod_class_sysconfig omap44xx_dsi_sysc = {
1379 .rev_offs = 0x0000,
1380 .sysc_offs = 0x0010,
1381 .syss_offs = 0x0014,
1382 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
1383 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
1384 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
1385 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1386 .sysc_fields = &omap_hwmod_sysc_type1,
1387};
1388
1389static struct omap_hwmod_class omap44xx_dsi_hwmod_class = {
1390 .name = "dsi",
1391 .sysc = &omap44xx_dsi_sysc,
1392};
1393
1394/* dss_dsi1 */
1395static struct omap_hwmod omap44xx_dss_dsi1_hwmod;
1396static struct omap_hwmod_irq_info omap44xx_dss_dsi1_irqs[] = {
1397 { .irq = 53 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06001398 { .irq = -1 }
Benoit Coussond63bd742011-01-27 11:17:03 +00001399};
1400
1401static struct omap_hwmod_dma_info omap44xx_dss_dsi1_sdma_reqs[] = {
1402 { .dma_req = 74 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06001403 { .dma_req = -1 }
Benoit Coussond63bd742011-01-27 11:17:03 +00001404};
1405
1406static struct omap_hwmod_addr_space omap44xx_dss_dsi1_dma_addrs[] = {
1407 {
1408 .pa_start = 0x58004000,
1409 .pa_end = 0x580041ff,
1410 .flags = ADDR_TYPE_RT
1411 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001412 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001413};
1414
1415/* l3_main_2 -> dss_dsi1 */
1416static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_dsi1 = {
1417 .master = &omap44xx_l3_main_2_hwmod,
1418 .slave = &omap44xx_dss_dsi1_hwmod,
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001419 .clk = "dss_fck",
Benoit Coussond63bd742011-01-27 11:17:03 +00001420 .addr = omap44xx_dss_dsi1_dma_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001421 .user = OCP_USER_SDMA,
1422};
1423
1424static struct omap_hwmod_addr_space omap44xx_dss_dsi1_addrs[] = {
1425 {
1426 .pa_start = 0x48044000,
1427 .pa_end = 0x480441ff,
1428 .flags = ADDR_TYPE_RT
1429 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001430 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001431};
1432
1433/* l4_per -> dss_dsi1 */
1434static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_dsi1 = {
1435 .master = &omap44xx_l4_per_hwmod,
1436 .slave = &omap44xx_dss_dsi1_hwmod,
1437 .clk = "l4_div_ck",
1438 .addr = omap44xx_dss_dsi1_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001439 .user = OCP_USER_MPU,
1440};
1441
1442/* dss_dsi1 slave ports */
1443static struct omap_hwmod_ocp_if *omap44xx_dss_dsi1_slaves[] = {
1444 &omap44xx_l3_main_2__dss_dsi1,
1445 &omap44xx_l4_per__dss_dsi1,
1446};
1447
Tomi Valkeinen3a23aaf2011-07-09 20:39:44 -06001448static struct omap_hwmod_opt_clk dss_dsi1_opt_clks[] = {
1449 { .role = "sys_clk", .clk = "dss_sys_clk" },
1450};
1451
Benoit Coussond63bd742011-01-27 11:17:03 +00001452static struct omap_hwmod omap44xx_dss_dsi1_hwmod = {
1453 .name = "dss_dsi1",
1454 .class = &omap44xx_dsi_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001455 .clkdm_name = "l3_dss_clkdm",
Benoit Coussond63bd742011-01-27 11:17:03 +00001456 .mpu_irqs = omap44xx_dss_dsi1_irqs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001457 .sdma_reqs = omap44xx_dss_dsi1_sdma_reqs,
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001458 .main_clk = "dss_dss_clk",
Benoit Coussond63bd742011-01-27 11:17:03 +00001459 .prcm = {
1460 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001461 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001462 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
Benoit Coussond63bd742011-01-27 11:17:03 +00001463 },
1464 },
Tomi Valkeinen3a23aaf2011-07-09 20:39:44 -06001465 .opt_clks = dss_dsi1_opt_clks,
1466 .opt_clks_cnt = ARRAY_SIZE(dss_dsi1_opt_clks),
Benoit Coussond63bd742011-01-27 11:17:03 +00001467 .slaves = omap44xx_dss_dsi1_slaves,
1468 .slaves_cnt = ARRAY_SIZE(omap44xx_dss_dsi1_slaves),
Benoit Coussond63bd742011-01-27 11:17:03 +00001469};
1470
1471/* dss_dsi2 */
1472static struct omap_hwmod omap44xx_dss_dsi2_hwmod;
1473static struct omap_hwmod_irq_info omap44xx_dss_dsi2_irqs[] = {
1474 { .irq = 84 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06001475 { .irq = -1 }
Benoit Coussond63bd742011-01-27 11:17:03 +00001476};
1477
1478static struct omap_hwmod_dma_info omap44xx_dss_dsi2_sdma_reqs[] = {
1479 { .dma_req = 83 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06001480 { .dma_req = -1 }
Benoit Coussond63bd742011-01-27 11:17:03 +00001481};
1482
1483static struct omap_hwmod_addr_space omap44xx_dss_dsi2_dma_addrs[] = {
1484 {
1485 .pa_start = 0x58005000,
1486 .pa_end = 0x580051ff,
1487 .flags = ADDR_TYPE_RT
1488 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001489 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001490};
1491
1492/* l3_main_2 -> dss_dsi2 */
1493static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_dsi2 = {
1494 .master = &omap44xx_l3_main_2_hwmod,
1495 .slave = &omap44xx_dss_dsi2_hwmod,
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001496 .clk = "dss_fck",
Benoit Coussond63bd742011-01-27 11:17:03 +00001497 .addr = omap44xx_dss_dsi2_dma_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001498 .user = OCP_USER_SDMA,
1499};
1500
1501static struct omap_hwmod_addr_space omap44xx_dss_dsi2_addrs[] = {
1502 {
1503 .pa_start = 0x48045000,
1504 .pa_end = 0x480451ff,
1505 .flags = ADDR_TYPE_RT
1506 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001507 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001508};
1509
1510/* l4_per -> dss_dsi2 */
1511static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_dsi2 = {
1512 .master = &omap44xx_l4_per_hwmod,
1513 .slave = &omap44xx_dss_dsi2_hwmod,
1514 .clk = "l4_div_ck",
1515 .addr = omap44xx_dss_dsi2_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001516 .user = OCP_USER_MPU,
1517};
1518
1519/* dss_dsi2 slave ports */
1520static struct omap_hwmod_ocp_if *omap44xx_dss_dsi2_slaves[] = {
1521 &omap44xx_l3_main_2__dss_dsi2,
1522 &omap44xx_l4_per__dss_dsi2,
1523};
1524
Tomi Valkeinen3a23aaf2011-07-09 20:39:44 -06001525static struct omap_hwmod_opt_clk dss_dsi2_opt_clks[] = {
1526 { .role = "sys_clk", .clk = "dss_sys_clk" },
1527};
1528
Benoit Coussond63bd742011-01-27 11:17:03 +00001529static struct omap_hwmod omap44xx_dss_dsi2_hwmod = {
1530 .name = "dss_dsi2",
1531 .class = &omap44xx_dsi_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001532 .clkdm_name = "l3_dss_clkdm",
Benoit Coussond63bd742011-01-27 11:17:03 +00001533 .mpu_irqs = omap44xx_dss_dsi2_irqs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001534 .sdma_reqs = omap44xx_dss_dsi2_sdma_reqs,
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001535 .main_clk = "dss_dss_clk",
Benoit Coussond63bd742011-01-27 11:17:03 +00001536 .prcm = {
1537 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001538 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001539 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
Benoit Coussond63bd742011-01-27 11:17:03 +00001540 },
1541 },
Tomi Valkeinen3a23aaf2011-07-09 20:39:44 -06001542 .opt_clks = dss_dsi2_opt_clks,
1543 .opt_clks_cnt = ARRAY_SIZE(dss_dsi2_opt_clks),
Benoit Coussond63bd742011-01-27 11:17:03 +00001544 .slaves = omap44xx_dss_dsi2_slaves,
1545 .slaves_cnt = ARRAY_SIZE(omap44xx_dss_dsi2_slaves),
Benoit Coussond63bd742011-01-27 11:17:03 +00001546};
1547
1548/*
1549 * 'hdmi' class
1550 * hdmi controller
1551 */
1552
1553static struct omap_hwmod_class_sysconfig omap44xx_hdmi_sysc = {
1554 .rev_offs = 0x0000,
1555 .sysc_offs = 0x0010,
1556 .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
1557 SYSC_HAS_SOFTRESET),
1558 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1559 SIDLE_SMART_WKUP),
1560 .sysc_fields = &omap_hwmod_sysc_type2,
1561};
1562
1563static struct omap_hwmod_class omap44xx_hdmi_hwmod_class = {
1564 .name = "hdmi",
1565 .sysc = &omap44xx_hdmi_sysc,
1566};
1567
1568/* dss_hdmi */
1569static struct omap_hwmod omap44xx_dss_hdmi_hwmod;
1570static struct omap_hwmod_irq_info omap44xx_dss_hdmi_irqs[] = {
1571 { .irq = 101 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06001572 { .irq = -1 }
Benoit Coussond63bd742011-01-27 11:17:03 +00001573};
1574
1575static struct omap_hwmod_dma_info omap44xx_dss_hdmi_sdma_reqs[] = {
1576 { .dma_req = 75 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06001577 { .dma_req = -1 }
Benoit Coussond63bd742011-01-27 11:17:03 +00001578};
1579
1580static struct omap_hwmod_addr_space omap44xx_dss_hdmi_dma_addrs[] = {
1581 {
1582 .pa_start = 0x58006000,
1583 .pa_end = 0x58006fff,
1584 .flags = ADDR_TYPE_RT
1585 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001586 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001587};
1588
1589/* l3_main_2 -> dss_hdmi */
1590static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_hdmi = {
1591 .master = &omap44xx_l3_main_2_hwmod,
1592 .slave = &omap44xx_dss_hdmi_hwmod,
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001593 .clk = "dss_fck",
Benoit Coussond63bd742011-01-27 11:17:03 +00001594 .addr = omap44xx_dss_hdmi_dma_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001595 .user = OCP_USER_SDMA,
1596};
1597
1598static struct omap_hwmod_addr_space omap44xx_dss_hdmi_addrs[] = {
1599 {
1600 .pa_start = 0x48046000,
1601 .pa_end = 0x48046fff,
1602 .flags = ADDR_TYPE_RT
1603 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001604 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001605};
1606
1607/* l4_per -> dss_hdmi */
1608static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_hdmi = {
1609 .master = &omap44xx_l4_per_hwmod,
1610 .slave = &omap44xx_dss_hdmi_hwmod,
1611 .clk = "l4_div_ck",
1612 .addr = omap44xx_dss_hdmi_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001613 .user = OCP_USER_MPU,
1614};
1615
1616/* dss_hdmi slave ports */
1617static struct omap_hwmod_ocp_if *omap44xx_dss_hdmi_slaves[] = {
1618 &omap44xx_l3_main_2__dss_hdmi,
1619 &omap44xx_l4_per__dss_hdmi,
1620};
1621
Tomi Valkeinen3a23aaf2011-07-09 20:39:44 -06001622static struct omap_hwmod_opt_clk dss_hdmi_opt_clks[] = {
1623 { .role = "sys_clk", .clk = "dss_sys_clk" },
1624};
1625
Benoit Coussond63bd742011-01-27 11:17:03 +00001626static struct omap_hwmod omap44xx_dss_hdmi_hwmod = {
1627 .name = "dss_hdmi",
1628 .class = &omap44xx_hdmi_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001629 .clkdm_name = "l3_dss_clkdm",
Benoit Coussond63bd742011-01-27 11:17:03 +00001630 .mpu_irqs = omap44xx_dss_hdmi_irqs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001631 .sdma_reqs = omap44xx_dss_hdmi_sdma_reqs,
Tomi Valkeinen4d0698d2011-11-08 03:16:12 -07001632 .main_clk = "dss_48mhz_clk",
Benoit Coussond63bd742011-01-27 11:17:03 +00001633 .prcm = {
1634 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001635 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001636 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
Benoit Coussond63bd742011-01-27 11:17:03 +00001637 },
1638 },
Tomi Valkeinen3a23aaf2011-07-09 20:39:44 -06001639 .opt_clks = dss_hdmi_opt_clks,
1640 .opt_clks_cnt = ARRAY_SIZE(dss_hdmi_opt_clks),
Benoit Coussond63bd742011-01-27 11:17:03 +00001641 .slaves = omap44xx_dss_hdmi_slaves,
1642 .slaves_cnt = ARRAY_SIZE(omap44xx_dss_hdmi_slaves),
Benoit Coussond63bd742011-01-27 11:17:03 +00001643};
1644
1645/*
1646 * 'rfbi' class
1647 * remote frame buffer interface
1648 */
1649
1650static struct omap_hwmod_class_sysconfig omap44xx_rfbi_sysc = {
1651 .rev_offs = 0x0000,
1652 .sysc_offs = 0x0010,
1653 .syss_offs = 0x0014,
1654 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
1655 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
1656 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1657 .sysc_fields = &omap_hwmod_sysc_type1,
1658};
1659
1660static struct omap_hwmod_class omap44xx_rfbi_hwmod_class = {
1661 .name = "rfbi",
1662 .sysc = &omap44xx_rfbi_sysc,
1663};
1664
1665/* dss_rfbi */
1666static struct omap_hwmod omap44xx_dss_rfbi_hwmod;
1667static struct omap_hwmod_dma_info omap44xx_dss_rfbi_sdma_reqs[] = {
1668 { .dma_req = 13 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06001669 { .dma_req = -1 }
Benoit Coussond63bd742011-01-27 11:17:03 +00001670};
1671
1672static struct omap_hwmod_addr_space omap44xx_dss_rfbi_dma_addrs[] = {
1673 {
1674 .pa_start = 0x58002000,
1675 .pa_end = 0x580020ff,
1676 .flags = ADDR_TYPE_RT
1677 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001678 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001679};
1680
1681/* l3_main_2 -> dss_rfbi */
1682static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_rfbi = {
1683 .master = &omap44xx_l3_main_2_hwmod,
1684 .slave = &omap44xx_dss_rfbi_hwmod,
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001685 .clk = "dss_fck",
Benoit Coussond63bd742011-01-27 11:17:03 +00001686 .addr = omap44xx_dss_rfbi_dma_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001687 .user = OCP_USER_SDMA,
1688};
1689
1690static struct omap_hwmod_addr_space omap44xx_dss_rfbi_addrs[] = {
1691 {
1692 .pa_start = 0x48042000,
1693 .pa_end = 0x480420ff,
1694 .flags = ADDR_TYPE_RT
1695 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001696 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001697};
1698
1699/* l4_per -> dss_rfbi */
1700static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_rfbi = {
1701 .master = &omap44xx_l4_per_hwmod,
1702 .slave = &omap44xx_dss_rfbi_hwmod,
1703 .clk = "l4_div_ck",
1704 .addr = omap44xx_dss_rfbi_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001705 .user = OCP_USER_MPU,
1706};
1707
1708/* dss_rfbi slave ports */
1709static struct omap_hwmod_ocp_if *omap44xx_dss_rfbi_slaves[] = {
1710 &omap44xx_l3_main_2__dss_rfbi,
1711 &omap44xx_l4_per__dss_rfbi,
1712};
1713
Tomi Valkeinen3a23aaf2011-07-09 20:39:44 -06001714static struct omap_hwmod_opt_clk dss_rfbi_opt_clks[] = {
1715 { .role = "ick", .clk = "dss_fck" },
1716};
1717
Benoit Coussond63bd742011-01-27 11:17:03 +00001718static struct omap_hwmod omap44xx_dss_rfbi_hwmod = {
1719 .name = "dss_rfbi",
1720 .class = &omap44xx_rfbi_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001721 .clkdm_name = "l3_dss_clkdm",
Benoit Coussond63bd742011-01-27 11:17:03 +00001722 .sdma_reqs = omap44xx_dss_rfbi_sdma_reqs,
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001723 .main_clk = "dss_dss_clk",
Benoit Coussond63bd742011-01-27 11:17:03 +00001724 .prcm = {
1725 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001726 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001727 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
Benoit Coussond63bd742011-01-27 11:17:03 +00001728 },
1729 },
Tomi Valkeinen3a23aaf2011-07-09 20:39:44 -06001730 .opt_clks = dss_rfbi_opt_clks,
1731 .opt_clks_cnt = ARRAY_SIZE(dss_rfbi_opt_clks),
Benoit Coussond63bd742011-01-27 11:17:03 +00001732 .slaves = omap44xx_dss_rfbi_slaves,
1733 .slaves_cnt = ARRAY_SIZE(omap44xx_dss_rfbi_slaves),
Benoit Coussond63bd742011-01-27 11:17:03 +00001734};
1735
1736/*
1737 * 'venc' class
1738 * video encoder
1739 */
1740
1741static struct omap_hwmod_class omap44xx_venc_hwmod_class = {
1742 .name = "venc",
1743};
1744
1745/* dss_venc */
1746static struct omap_hwmod omap44xx_dss_venc_hwmod;
1747static struct omap_hwmod_addr_space omap44xx_dss_venc_dma_addrs[] = {
1748 {
1749 .pa_start = 0x58003000,
1750 .pa_end = 0x580030ff,
1751 .flags = ADDR_TYPE_RT
1752 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001753 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001754};
1755
1756/* l3_main_2 -> dss_venc */
1757static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_venc = {
1758 .master = &omap44xx_l3_main_2_hwmod,
1759 .slave = &omap44xx_dss_venc_hwmod,
Tomi Valkeinenda7cdfa2011-07-09 20:39:45 -06001760 .clk = "dss_fck",
Benoit Coussond63bd742011-01-27 11:17:03 +00001761 .addr = omap44xx_dss_venc_dma_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001762 .user = OCP_USER_SDMA,
1763};
1764
1765static struct omap_hwmod_addr_space omap44xx_dss_venc_addrs[] = {
1766 {
1767 .pa_start = 0x48043000,
1768 .pa_end = 0x480430ff,
1769 .flags = ADDR_TYPE_RT
1770 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001771 { }
Benoit Coussond63bd742011-01-27 11:17:03 +00001772};
1773
1774/* l4_per -> dss_venc */
1775static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_venc = {
1776 .master = &omap44xx_l4_per_hwmod,
1777 .slave = &omap44xx_dss_venc_hwmod,
1778 .clk = "l4_div_ck",
1779 .addr = omap44xx_dss_venc_addrs,
Benoit Coussond63bd742011-01-27 11:17:03 +00001780 .user = OCP_USER_MPU,
1781};
1782
1783/* dss_venc slave ports */
1784static struct omap_hwmod_ocp_if *omap44xx_dss_venc_slaves[] = {
1785 &omap44xx_l3_main_2__dss_venc,
1786 &omap44xx_l4_per__dss_venc,
1787};
1788
1789static struct omap_hwmod omap44xx_dss_venc_hwmod = {
1790 .name = "dss_venc",
1791 .class = &omap44xx_venc_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001792 .clkdm_name = "l3_dss_clkdm",
Tomi Valkeinen4d0698d2011-11-08 03:16:12 -07001793 .main_clk = "dss_tv_clk",
Benoit Coussond63bd742011-01-27 11:17:03 +00001794 .prcm = {
1795 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001796 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001797 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
Benoit Coussond63bd742011-01-27 11:17:03 +00001798 },
1799 },
1800 .slaves = omap44xx_dss_venc_slaves,
1801 .slaves_cnt = ARRAY_SIZE(omap44xx_dss_venc_slaves),
Benoit Coussond63bd742011-01-27 11:17:03 +00001802};
1803
1804/*
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001805 * 'gpio' class
1806 * general purpose io module
1807 */
1808
1809static struct omap_hwmod_class_sysconfig omap44xx_gpio_sysc = {
1810 .rev_offs = 0x0000,
1811 .sysc_offs = 0x0010,
1812 .syss_offs = 0x0114,
Benoit Cousson0cfe8752010-12-21 21:08:33 -07001813 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
1814 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
1815 SYSS_HAS_RESET_STATUS),
Benoit Cousson7cffa6b2010-12-21 21:31:28 -07001816 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1817 SIDLE_SMART_WKUP),
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001818 .sysc_fields = &omap_hwmod_sysc_type1,
1819};
1820
1821static struct omap_hwmod_class omap44xx_gpio_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +00001822 .name = "gpio",
1823 .sysc = &omap44xx_gpio_sysc,
1824 .rev = 2,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001825};
1826
1827/* gpio dev_attr */
1828static struct omap_gpio_dev_attr gpio_dev_attr = {
Benoit Coussonfe134712010-12-23 22:30:32 +00001829 .bank_width = 32,
1830 .dbck_flag = true,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001831};
1832
1833/* gpio1 */
1834static struct omap_hwmod omap44xx_gpio1_hwmod;
1835static struct omap_hwmod_irq_info omap44xx_gpio1_irqs[] = {
1836 { .irq = 29 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06001837 { .irq = -1 }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001838};
1839
1840static struct omap_hwmod_addr_space omap44xx_gpio1_addrs[] = {
1841 {
1842 .pa_start = 0x4a310000,
1843 .pa_end = 0x4a3101ff,
1844 .flags = ADDR_TYPE_RT
1845 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001846 { }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001847};
1848
1849/* l4_wkup -> gpio1 */
1850static struct omap_hwmod_ocp_if omap44xx_l4_wkup__gpio1 = {
1851 .master = &omap44xx_l4_wkup_hwmod,
1852 .slave = &omap44xx_gpio1_hwmod,
Benoit Coussonb399bca2010-12-21 21:08:34 -07001853 .clk = "l4_wkup_clk_mux_ck",
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001854 .addr = omap44xx_gpio1_addrs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001855 .user = OCP_USER_MPU | OCP_USER_SDMA,
1856};
1857
1858/* gpio1 slave ports */
1859static struct omap_hwmod_ocp_if *omap44xx_gpio1_slaves[] = {
1860 &omap44xx_l4_wkup__gpio1,
1861};
1862
1863static struct omap_hwmod_opt_clk gpio1_opt_clks[] = {
Benoit Coussonb399bca2010-12-21 21:08:34 -07001864 { .role = "dbclk", .clk = "gpio1_dbclk" },
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001865};
1866
1867static struct omap_hwmod omap44xx_gpio1_hwmod = {
1868 .name = "gpio1",
1869 .class = &omap44xx_gpio_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001870 .clkdm_name = "l4_wkup_clkdm",
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001871 .mpu_irqs = omap44xx_gpio1_irqs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001872 .main_clk = "gpio1_ick",
1873 .prcm = {
1874 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001875 .clkctrl_offs = OMAP4_CM_WKUP_GPIO1_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001876 .context_offs = OMAP4_RM_WKUP_GPIO1_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06001877 .modulemode = MODULEMODE_HWCTRL,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001878 },
1879 },
1880 .opt_clks = gpio1_opt_clks,
1881 .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks),
1882 .dev_attr = &gpio_dev_attr,
1883 .slaves = omap44xx_gpio1_slaves,
1884 .slaves_cnt = ARRAY_SIZE(omap44xx_gpio1_slaves),
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001885};
1886
1887/* gpio2 */
1888static struct omap_hwmod omap44xx_gpio2_hwmod;
1889static struct omap_hwmod_irq_info omap44xx_gpio2_irqs[] = {
1890 { .irq = 30 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06001891 { .irq = -1 }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001892};
1893
1894static struct omap_hwmod_addr_space omap44xx_gpio2_addrs[] = {
1895 {
1896 .pa_start = 0x48055000,
1897 .pa_end = 0x480551ff,
1898 .flags = ADDR_TYPE_RT
1899 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001900 { }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001901};
1902
1903/* l4_per -> gpio2 */
1904static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio2 = {
1905 .master = &omap44xx_l4_per_hwmod,
1906 .slave = &omap44xx_gpio2_hwmod,
Benoit Coussonb399bca2010-12-21 21:08:34 -07001907 .clk = "l4_div_ck",
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001908 .addr = omap44xx_gpio2_addrs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001909 .user = OCP_USER_MPU | OCP_USER_SDMA,
1910};
1911
1912/* gpio2 slave ports */
1913static struct omap_hwmod_ocp_if *omap44xx_gpio2_slaves[] = {
1914 &omap44xx_l4_per__gpio2,
1915};
1916
1917static struct omap_hwmod_opt_clk gpio2_opt_clks[] = {
Benoit Coussonb399bca2010-12-21 21:08:34 -07001918 { .role = "dbclk", .clk = "gpio2_dbclk" },
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001919};
1920
1921static struct omap_hwmod omap44xx_gpio2_hwmod = {
1922 .name = "gpio2",
1923 .class = &omap44xx_gpio_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001924 .clkdm_name = "l4_per_clkdm",
Benoit Coussonb399bca2010-12-21 21:08:34 -07001925 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001926 .mpu_irqs = omap44xx_gpio2_irqs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001927 .main_clk = "gpio2_ick",
1928 .prcm = {
1929 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001930 .clkctrl_offs = OMAP4_CM_L4PER_GPIO2_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001931 .context_offs = OMAP4_RM_L4PER_GPIO2_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06001932 .modulemode = MODULEMODE_HWCTRL,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001933 },
1934 },
1935 .opt_clks = gpio2_opt_clks,
1936 .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks),
1937 .dev_attr = &gpio_dev_attr,
1938 .slaves = omap44xx_gpio2_slaves,
1939 .slaves_cnt = ARRAY_SIZE(omap44xx_gpio2_slaves),
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001940};
1941
1942/* gpio3 */
1943static struct omap_hwmod omap44xx_gpio3_hwmod;
1944static struct omap_hwmod_irq_info omap44xx_gpio3_irqs[] = {
1945 { .irq = 31 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06001946 { .irq = -1 }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001947};
1948
1949static struct omap_hwmod_addr_space omap44xx_gpio3_addrs[] = {
1950 {
1951 .pa_start = 0x48057000,
1952 .pa_end = 0x480571ff,
1953 .flags = ADDR_TYPE_RT
1954 },
Paul Walmsley78183f32011-07-09 19:14:05 -06001955 { }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001956};
1957
1958/* l4_per -> gpio3 */
1959static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio3 = {
1960 .master = &omap44xx_l4_per_hwmod,
1961 .slave = &omap44xx_gpio3_hwmod,
Benoit Coussonb399bca2010-12-21 21:08:34 -07001962 .clk = "l4_div_ck",
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001963 .addr = omap44xx_gpio3_addrs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001964 .user = OCP_USER_MPU | OCP_USER_SDMA,
1965};
1966
1967/* gpio3 slave ports */
1968static struct omap_hwmod_ocp_if *omap44xx_gpio3_slaves[] = {
1969 &omap44xx_l4_per__gpio3,
1970};
1971
1972static struct omap_hwmod_opt_clk gpio3_opt_clks[] = {
Benoit Coussonb399bca2010-12-21 21:08:34 -07001973 { .role = "dbclk", .clk = "gpio3_dbclk" },
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001974};
1975
1976static struct omap_hwmod omap44xx_gpio3_hwmod = {
1977 .name = "gpio3",
1978 .class = &omap44xx_gpio_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06001979 .clkdm_name = "l4_per_clkdm",
Benoit Coussonb399bca2010-12-21 21:08:34 -07001980 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001981 .mpu_irqs = omap44xx_gpio3_irqs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001982 .main_clk = "gpio3_ick",
1983 .prcm = {
1984 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06001985 .clkctrl_offs = OMAP4_CM_L4PER_GPIO3_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06001986 .context_offs = OMAP4_RM_L4PER_GPIO3_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06001987 .modulemode = MODULEMODE_HWCTRL,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001988 },
1989 },
1990 .opt_clks = gpio3_opt_clks,
1991 .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks),
1992 .dev_attr = &gpio_dev_attr,
1993 .slaves = omap44xx_gpio3_slaves,
1994 .slaves_cnt = ARRAY_SIZE(omap44xx_gpio3_slaves),
Benoit Cousson3b54baa2010-12-21 21:08:33 -07001995};
1996
1997/* gpio4 */
1998static struct omap_hwmod omap44xx_gpio4_hwmod;
1999static struct omap_hwmod_irq_info omap44xx_gpio4_irqs[] = {
2000 { .irq = 32 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002001 { .irq = -1 }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002002};
2003
2004static struct omap_hwmod_addr_space omap44xx_gpio4_addrs[] = {
2005 {
2006 .pa_start = 0x48059000,
2007 .pa_end = 0x480591ff,
2008 .flags = ADDR_TYPE_RT
2009 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002010 { }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002011};
2012
2013/* l4_per -> gpio4 */
2014static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio4 = {
2015 .master = &omap44xx_l4_per_hwmod,
2016 .slave = &omap44xx_gpio4_hwmod,
Benoit Coussonb399bca2010-12-21 21:08:34 -07002017 .clk = "l4_div_ck",
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002018 .addr = omap44xx_gpio4_addrs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002019 .user = OCP_USER_MPU | OCP_USER_SDMA,
2020};
2021
2022/* gpio4 slave ports */
2023static struct omap_hwmod_ocp_if *omap44xx_gpio4_slaves[] = {
2024 &omap44xx_l4_per__gpio4,
2025};
2026
2027static struct omap_hwmod_opt_clk gpio4_opt_clks[] = {
Benoit Coussonb399bca2010-12-21 21:08:34 -07002028 { .role = "dbclk", .clk = "gpio4_dbclk" },
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002029};
2030
2031static struct omap_hwmod omap44xx_gpio4_hwmod = {
2032 .name = "gpio4",
2033 .class = &omap44xx_gpio_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002034 .clkdm_name = "l4_per_clkdm",
Benoit Coussonb399bca2010-12-21 21:08:34 -07002035 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002036 .mpu_irqs = omap44xx_gpio4_irqs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002037 .main_clk = "gpio4_ick",
2038 .prcm = {
2039 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002040 .clkctrl_offs = OMAP4_CM_L4PER_GPIO4_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002041 .context_offs = OMAP4_RM_L4PER_GPIO4_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002042 .modulemode = MODULEMODE_HWCTRL,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002043 },
2044 },
2045 .opt_clks = gpio4_opt_clks,
2046 .opt_clks_cnt = ARRAY_SIZE(gpio4_opt_clks),
2047 .dev_attr = &gpio_dev_attr,
2048 .slaves = omap44xx_gpio4_slaves,
2049 .slaves_cnt = ARRAY_SIZE(omap44xx_gpio4_slaves),
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002050};
2051
2052/* gpio5 */
2053static struct omap_hwmod omap44xx_gpio5_hwmod;
2054static struct omap_hwmod_irq_info omap44xx_gpio5_irqs[] = {
2055 { .irq = 33 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002056 { .irq = -1 }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002057};
2058
2059static struct omap_hwmod_addr_space omap44xx_gpio5_addrs[] = {
2060 {
2061 .pa_start = 0x4805b000,
2062 .pa_end = 0x4805b1ff,
2063 .flags = ADDR_TYPE_RT
2064 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002065 { }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002066};
2067
2068/* l4_per -> gpio5 */
2069static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio5 = {
2070 .master = &omap44xx_l4_per_hwmod,
2071 .slave = &omap44xx_gpio5_hwmod,
Benoit Coussonb399bca2010-12-21 21:08:34 -07002072 .clk = "l4_div_ck",
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002073 .addr = omap44xx_gpio5_addrs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002074 .user = OCP_USER_MPU | OCP_USER_SDMA,
2075};
2076
2077/* gpio5 slave ports */
2078static struct omap_hwmod_ocp_if *omap44xx_gpio5_slaves[] = {
2079 &omap44xx_l4_per__gpio5,
2080};
2081
2082static struct omap_hwmod_opt_clk gpio5_opt_clks[] = {
Benoit Coussonb399bca2010-12-21 21:08:34 -07002083 { .role = "dbclk", .clk = "gpio5_dbclk" },
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002084};
2085
2086static struct omap_hwmod omap44xx_gpio5_hwmod = {
2087 .name = "gpio5",
2088 .class = &omap44xx_gpio_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002089 .clkdm_name = "l4_per_clkdm",
Benoit Coussonb399bca2010-12-21 21:08:34 -07002090 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002091 .mpu_irqs = omap44xx_gpio5_irqs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002092 .main_clk = "gpio5_ick",
2093 .prcm = {
2094 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002095 .clkctrl_offs = OMAP4_CM_L4PER_GPIO5_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002096 .context_offs = OMAP4_RM_L4PER_GPIO5_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002097 .modulemode = MODULEMODE_HWCTRL,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002098 },
2099 },
2100 .opt_clks = gpio5_opt_clks,
2101 .opt_clks_cnt = ARRAY_SIZE(gpio5_opt_clks),
2102 .dev_attr = &gpio_dev_attr,
2103 .slaves = omap44xx_gpio5_slaves,
2104 .slaves_cnt = ARRAY_SIZE(omap44xx_gpio5_slaves),
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002105};
2106
2107/* gpio6 */
2108static struct omap_hwmod omap44xx_gpio6_hwmod;
2109static struct omap_hwmod_irq_info omap44xx_gpio6_irqs[] = {
2110 { .irq = 34 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002111 { .irq = -1 }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002112};
2113
2114static struct omap_hwmod_addr_space omap44xx_gpio6_addrs[] = {
2115 {
2116 .pa_start = 0x4805d000,
2117 .pa_end = 0x4805d1ff,
2118 .flags = ADDR_TYPE_RT
2119 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002120 { }
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002121};
2122
2123/* l4_per -> gpio6 */
2124static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio6 = {
2125 .master = &omap44xx_l4_per_hwmod,
2126 .slave = &omap44xx_gpio6_hwmod,
Benoit Coussonb399bca2010-12-21 21:08:34 -07002127 .clk = "l4_div_ck",
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002128 .addr = omap44xx_gpio6_addrs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002129 .user = OCP_USER_MPU | OCP_USER_SDMA,
2130};
2131
2132/* gpio6 slave ports */
2133static struct omap_hwmod_ocp_if *omap44xx_gpio6_slaves[] = {
2134 &omap44xx_l4_per__gpio6,
2135};
2136
2137static struct omap_hwmod_opt_clk gpio6_opt_clks[] = {
Benoit Coussonb399bca2010-12-21 21:08:34 -07002138 { .role = "dbclk", .clk = "gpio6_dbclk" },
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002139};
2140
2141static struct omap_hwmod omap44xx_gpio6_hwmod = {
2142 .name = "gpio6",
2143 .class = &omap44xx_gpio_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002144 .clkdm_name = "l4_per_clkdm",
Benoit Coussonb399bca2010-12-21 21:08:34 -07002145 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002146 .mpu_irqs = omap44xx_gpio6_irqs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002147 .main_clk = "gpio6_ick",
2148 .prcm = {
2149 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002150 .clkctrl_offs = OMAP4_CM_L4PER_GPIO6_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002151 .context_offs = OMAP4_RM_L4PER_GPIO6_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002152 .modulemode = MODULEMODE_HWCTRL,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002153 },
2154 },
2155 .opt_clks = gpio6_opt_clks,
2156 .opt_clks_cnt = ARRAY_SIZE(gpio6_opt_clks),
2157 .dev_attr = &gpio_dev_attr,
2158 .slaves = omap44xx_gpio6_slaves,
2159 .slaves_cnt = ARRAY_SIZE(omap44xx_gpio6_slaves),
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002160};
2161
2162/*
Benoit Cousson407a6882011-02-15 22:39:48 +01002163 * 'hsi' class
2164 * mipi high-speed synchronous serial interface (multichannel and full-duplex
2165 * serial if)
2166 */
2167
2168static struct omap_hwmod_class_sysconfig omap44xx_hsi_sysc = {
2169 .rev_offs = 0x0000,
2170 .sysc_offs = 0x0010,
2171 .syss_offs = 0x0014,
2172 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_EMUFREE |
2173 SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
2174 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
2175 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
2176 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
Benoit Coussonc614ebf2011-07-01 22:54:01 +02002177 MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
Benoit Cousson407a6882011-02-15 22:39:48 +01002178 .sysc_fields = &omap_hwmod_sysc_type1,
2179};
2180
2181static struct omap_hwmod_class omap44xx_hsi_hwmod_class = {
2182 .name = "hsi",
2183 .sysc = &omap44xx_hsi_sysc,
2184};
2185
2186/* hsi */
2187static struct omap_hwmod_irq_info omap44xx_hsi_irqs[] = {
2188 { .name = "mpu_p1", .irq = 67 + OMAP44XX_IRQ_GIC_START },
2189 { .name = "mpu_p2", .irq = 68 + OMAP44XX_IRQ_GIC_START },
2190 { .name = "mpu_dma", .irq = 71 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002191 { .irq = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01002192};
2193
2194/* hsi master ports */
2195static struct omap_hwmod_ocp_if *omap44xx_hsi_masters[] = {
2196 &omap44xx_hsi__l3_main_2,
2197};
2198
2199static struct omap_hwmod_addr_space omap44xx_hsi_addrs[] = {
2200 {
2201 .pa_start = 0x4a058000,
2202 .pa_end = 0x4a05bfff,
2203 .flags = ADDR_TYPE_RT
2204 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002205 { }
Benoit Cousson407a6882011-02-15 22:39:48 +01002206};
2207
2208/* l4_cfg -> hsi */
2209static struct omap_hwmod_ocp_if omap44xx_l4_cfg__hsi = {
2210 .master = &omap44xx_l4_cfg_hwmod,
2211 .slave = &omap44xx_hsi_hwmod,
2212 .clk = "l4_div_ck",
2213 .addr = omap44xx_hsi_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +01002214 .user = OCP_USER_MPU | OCP_USER_SDMA,
2215};
2216
2217/* hsi slave ports */
2218static struct omap_hwmod_ocp_if *omap44xx_hsi_slaves[] = {
2219 &omap44xx_l4_cfg__hsi,
2220};
2221
2222static struct omap_hwmod omap44xx_hsi_hwmod = {
2223 .name = "hsi",
2224 .class = &omap44xx_hsi_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002225 .clkdm_name = "l3_init_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01002226 .mpu_irqs = omap44xx_hsi_irqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01002227 .main_clk = "hsi_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -06002228 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01002229 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002230 .clkctrl_offs = OMAP4_CM_L3INIT_HSI_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002231 .context_offs = OMAP4_RM_L3INIT_HSI_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002232 .modulemode = MODULEMODE_HWCTRL,
Benoit Cousson407a6882011-02-15 22:39:48 +01002233 },
2234 },
2235 .slaves = omap44xx_hsi_slaves,
2236 .slaves_cnt = ARRAY_SIZE(omap44xx_hsi_slaves),
2237 .masters = omap44xx_hsi_masters,
2238 .masters_cnt = ARRAY_SIZE(omap44xx_hsi_masters),
Benoit Cousson407a6882011-02-15 22:39:48 +01002239};
2240
2241/*
Benoit Coussonf7764712010-09-21 19:37:14 +05302242 * 'i2c' class
2243 * multimaster high-speed i2c controller
2244 */
2245
2246static struct omap_hwmod_class_sysconfig omap44xx_i2c_sysc = {
2247 .sysc_offs = 0x0010,
2248 .syss_offs = 0x0090,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07002249 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
2250 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
Benoit Cousson0cfe8752010-12-21 21:08:33 -07002251 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
Benoit Cousson7cffa6b2010-12-21 21:31:28 -07002252 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
2253 SIDLE_SMART_WKUP),
Shubhrajyoti D3e47dc62011-12-13 16:25:54 +05302254 .clockact = CLOCKACT_TEST_ICLK,
Benoit Coussonf7764712010-09-21 19:37:14 +05302255 .sysc_fields = &omap_hwmod_sysc_type1,
2256};
2257
2258static struct omap_hwmod_class omap44xx_i2c_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +00002259 .name = "i2c",
2260 .sysc = &omap44xx_i2c_sysc,
Andy Greendb791a72011-07-10 05:27:15 -06002261 .rev = OMAP_I2C_IP_VERSION_2,
Avinash.H.M6d3c55f2011-07-10 05:27:16 -06002262 .reset = &omap_i2c_reset,
Benoit Coussonf7764712010-09-21 19:37:14 +05302263};
2264
Andy Green4d4441a2011-07-10 05:27:16 -06002265static struct omap_i2c_dev_attr i2c_dev_attr = {
2266 .flags = OMAP_I2C_FLAG_BUS_SHIFT_NONE,
2267};
2268
Benoit Coussonf7764712010-09-21 19:37:14 +05302269/* i2c1 */
2270static struct omap_hwmod omap44xx_i2c1_hwmod;
2271static struct omap_hwmod_irq_info omap44xx_i2c1_irqs[] = {
2272 { .irq = 56 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002273 { .irq = -1 }
Benoit Coussonf7764712010-09-21 19:37:14 +05302274};
2275
2276static struct omap_hwmod_dma_info omap44xx_i2c1_sdma_reqs[] = {
2277 { .name = "tx", .dma_req = 26 + OMAP44XX_DMA_REQ_START },
2278 { .name = "rx", .dma_req = 27 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06002279 { .dma_req = -1 }
Benoit Coussonf7764712010-09-21 19:37:14 +05302280};
2281
2282static struct omap_hwmod_addr_space omap44xx_i2c1_addrs[] = {
2283 {
2284 .pa_start = 0x48070000,
2285 .pa_end = 0x480700ff,
2286 .flags = ADDR_TYPE_RT
2287 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002288 { }
Benoit Coussonf7764712010-09-21 19:37:14 +05302289};
2290
2291/* l4_per -> i2c1 */
2292static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c1 = {
2293 .master = &omap44xx_l4_per_hwmod,
2294 .slave = &omap44xx_i2c1_hwmod,
2295 .clk = "l4_div_ck",
2296 .addr = omap44xx_i2c1_addrs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302297 .user = OCP_USER_MPU | OCP_USER_SDMA,
2298};
2299
2300/* i2c1 slave ports */
2301static struct omap_hwmod_ocp_if *omap44xx_i2c1_slaves[] = {
2302 &omap44xx_l4_per__i2c1,
2303};
2304
2305static struct omap_hwmod omap44xx_i2c1_hwmod = {
2306 .name = "i2c1",
2307 .class = &omap44xx_i2c_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002308 .clkdm_name = "l4_per_clkdm",
Shubhrajyoti D3e47dc62011-12-13 16:25:54 +05302309 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
Benoit Coussonf7764712010-09-21 19:37:14 +05302310 .mpu_irqs = omap44xx_i2c1_irqs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302311 .sdma_reqs = omap44xx_i2c1_sdma_reqs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302312 .main_clk = "i2c1_fck",
2313 .prcm = {
2314 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002315 .clkctrl_offs = OMAP4_CM_L4PER_I2C1_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002316 .context_offs = OMAP4_RM_L4PER_I2C1_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002317 .modulemode = MODULEMODE_SWCTRL,
Benoit Coussonf7764712010-09-21 19:37:14 +05302318 },
2319 },
2320 .slaves = omap44xx_i2c1_slaves,
2321 .slaves_cnt = ARRAY_SIZE(omap44xx_i2c1_slaves),
Andy Green4d4441a2011-07-10 05:27:16 -06002322 .dev_attr = &i2c_dev_attr,
Benoit Coussonf7764712010-09-21 19:37:14 +05302323};
2324
2325/* i2c2 */
2326static struct omap_hwmod omap44xx_i2c2_hwmod;
2327static struct omap_hwmod_irq_info omap44xx_i2c2_irqs[] = {
2328 { .irq = 57 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002329 { .irq = -1 }
Benoit Coussonf7764712010-09-21 19:37:14 +05302330};
2331
2332static struct omap_hwmod_dma_info omap44xx_i2c2_sdma_reqs[] = {
2333 { .name = "tx", .dma_req = 28 + OMAP44XX_DMA_REQ_START },
2334 { .name = "rx", .dma_req = 29 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06002335 { .dma_req = -1 }
Benoit Coussonf7764712010-09-21 19:37:14 +05302336};
2337
2338static struct omap_hwmod_addr_space omap44xx_i2c2_addrs[] = {
2339 {
2340 .pa_start = 0x48072000,
2341 .pa_end = 0x480720ff,
2342 .flags = ADDR_TYPE_RT
2343 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002344 { }
Benoit Coussonf7764712010-09-21 19:37:14 +05302345};
2346
2347/* l4_per -> i2c2 */
2348static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c2 = {
2349 .master = &omap44xx_l4_per_hwmod,
2350 .slave = &omap44xx_i2c2_hwmod,
2351 .clk = "l4_div_ck",
2352 .addr = omap44xx_i2c2_addrs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302353 .user = OCP_USER_MPU | OCP_USER_SDMA,
2354};
2355
2356/* i2c2 slave ports */
2357static struct omap_hwmod_ocp_if *omap44xx_i2c2_slaves[] = {
2358 &omap44xx_l4_per__i2c2,
2359};
2360
2361static struct omap_hwmod omap44xx_i2c2_hwmod = {
2362 .name = "i2c2",
2363 .class = &omap44xx_i2c_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002364 .clkdm_name = "l4_per_clkdm",
Shubhrajyoti D3e47dc62011-12-13 16:25:54 +05302365 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
Benoit Coussonf7764712010-09-21 19:37:14 +05302366 .mpu_irqs = omap44xx_i2c2_irqs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302367 .sdma_reqs = omap44xx_i2c2_sdma_reqs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302368 .main_clk = "i2c2_fck",
2369 .prcm = {
2370 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002371 .clkctrl_offs = OMAP4_CM_L4PER_I2C2_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002372 .context_offs = OMAP4_RM_L4PER_I2C2_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002373 .modulemode = MODULEMODE_SWCTRL,
Benoit Coussonf7764712010-09-21 19:37:14 +05302374 },
2375 },
2376 .slaves = omap44xx_i2c2_slaves,
2377 .slaves_cnt = ARRAY_SIZE(omap44xx_i2c2_slaves),
Andy Green4d4441a2011-07-10 05:27:16 -06002378 .dev_attr = &i2c_dev_attr,
Benoit Coussonf7764712010-09-21 19:37:14 +05302379};
2380
2381/* i2c3 */
2382static struct omap_hwmod omap44xx_i2c3_hwmod;
2383static struct omap_hwmod_irq_info omap44xx_i2c3_irqs[] = {
2384 { .irq = 61 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002385 { .irq = -1 }
Benoit Coussonf7764712010-09-21 19:37:14 +05302386};
2387
2388static struct omap_hwmod_dma_info omap44xx_i2c3_sdma_reqs[] = {
2389 { .name = "tx", .dma_req = 24 + OMAP44XX_DMA_REQ_START },
2390 { .name = "rx", .dma_req = 25 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06002391 { .dma_req = -1 }
Benoit Coussonf7764712010-09-21 19:37:14 +05302392};
2393
2394static struct omap_hwmod_addr_space omap44xx_i2c3_addrs[] = {
2395 {
2396 .pa_start = 0x48060000,
2397 .pa_end = 0x480600ff,
2398 .flags = ADDR_TYPE_RT
2399 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002400 { }
Benoit Coussonf7764712010-09-21 19:37:14 +05302401};
2402
2403/* l4_per -> i2c3 */
2404static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c3 = {
2405 .master = &omap44xx_l4_per_hwmod,
2406 .slave = &omap44xx_i2c3_hwmod,
2407 .clk = "l4_div_ck",
2408 .addr = omap44xx_i2c3_addrs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302409 .user = OCP_USER_MPU | OCP_USER_SDMA,
2410};
2411
2412/* i2c3 slave ports */
2413static struct omap_hwmod_ocp_if *omap44xx_i2c3_slaves[] = {
2414 &omap44xx_l4_per__i2c3,
2415};
2416
2417static struct omap_hwmod omap44xx_i2c3_hwmod = {
2418 .name = "i2c3",
2419 .class = &omap44xx_i2c_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002420 .clkdm_name = "l4_per_clkdm",
Shubhrajyoti D3e47dc62011-12-13 16:25:54 +05302421 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
Benoit Coussonf7764712010-09-21 19:37:14 +05302422 .mpu_irqs = omap44xx_i2c3_irqs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302423 .sdma_reqs = omap44xx_i2c3_sdma_reqs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302424 .main_clk = "i2c3_fck",
2425 .prcm = {
2426 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002427 .clkctrl_offs = OMAP4_CM_L4PER_I2C3_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002428 .context_offs = OMAP4_RM_L4PER_I2C3_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002429 .modulemode = MODULEMODE_SWCTRL,
Benoit Coussonf7764712010-09-21 19:37:14 +05302430 },
2431 },
2432 .slaves = omap44xx_i2c3_slaves,
2433 .slaves_cnt = ARRAY_SIZE(omap44xx_i2c3_slaves),
Andy Green4d4441a2011-07-10 05:27:16 -06002434 .dev_attr = &i2c_dev_attr,
Benoit Coussonf7764712010-09-21 19:37:14 +05302435};
2436
2437/* i2c4 */
2438static struct omap_hwmod omap44xx_i2c4_hwmod;
2439static struct omap_hwmod_irq_info omap44xx_i2c4_irqs[] = {
2440 { .irq = 62 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002441 { .irq = -1 }
Benoit Coussonf7764712010-09-21 19:37:14 +05302442};
2443
2444static struct omap_hwmod_dma_info omap44xx_i2c4_sdma_reqs[] = {
2445 { .name = "tx", .dma_req = 123 + OMAP44XX_DMA_REQ_START },
2446 { .name = "rx", .dma_req = 124 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06002447 { .dma_req = -1 }
Benoit Coussonf7764712010-09-21 19:37:14 +05302448};
2449
2450static struct omap_hwmod_addr_space omap44xx_i2c4_addrs[] = {
2451 {
2452 .pa_start = 0x48350000,
2453 .pa_end = 0x483500ff,
2454 .flags = ADDR_TYPE_RT
2455 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002456 { }
Benoit Coussonf7764712010-09-21 19:37:14 +05302457};
2458
2459/* l4_per -> i2c4 */
2460static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c4 = {
2461 .master = &omap44xx_l4_per_hwmod,
2462 .slave = &omap44xx_i2c4_hwmod,
2463 .clk = "l4_div_ck",
2464 .addr = omap44xx_i2c4_addrs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302465 .user = OCP_USER_MPU | OCP_USER_SDMA,
2466};
2467
2468/* i2c4 slave ports */
2469static struct omap_hwmod_ocp_if *omap44xx_i2c4_slaves[] = {
2470 &omap44xx_l4_per__i2c4,
2471};
2472
2473static struct omap_hwmod omap44xx_i2c4_hwmod = {
2474 .name = "i2c4",
2475 .class = &omap44xx_i2c_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002476 .clkdm_name = "l4_per_clkdm",
Shubhrajyoti D3e47dc62011-12-13 16:25:54 +05302477 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
Benoit Coussonf7764712010-09-21 19:37:14 +05302478 .mpu_irqs = omap44xx_i2c4_irqs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302479 .sdma_reqs = omap44xx_i2c4_sdma_reqs,
Benoit Coussonf7764712010-09-21 19:37:14 +05302480 .main_clk = "i2c4_fck",
2481 .prcm = {
2482 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002483 .clkctrl_offs = OMAP4_CM_L4PER_I2C4_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002484 .context_offs = OMAP4_RM_L4PER_I2C4_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002485 .modulemode = MODULEMODE_SWCTRL,
Benoit Coussonf7764712010-09-21 19:37:14 +05302486 },
2487 },
2488 .slaves = omap44xx_i2c4_slaves,
2489 .slaves_cnt = ARRAY_SIZE(omap44xx_i2c4_slaves),
Andy Green4d4441a2011-07-10 05:27:16 -06002490 .dev_attr = &i2c_dev_attr,
Benoit Coussonf7764712010-09-21 19:37:14 +05302491};
2492
2493/*
Benoit Cousson407a6882011-02-15 22:39:48 +01002494 * 'ipu' class
2495 * imaging processor unit
2496 */
2497
2498static struct omap_hwmod_class omap44xx_ipu_hwmod_class = {
2499 .name = "ipu",
2500};
2501
2502/* ipu */
2503static struct omap_hwmod_irq_info omap44xx_ipu_irqs[] = {
2504 { .irq = 100 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002505 { .irq = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01002506};
2507
2508static struct omap_hwmod_rst_info omap44xx_ipu_c0_resets[] = {
2509 { .name = "cpu0", .rst_shift = 0 },
2510};
2511
2512static struct omap_hwmod_rst_info omap44xx_ipu_c1_resets[] = {
2513 { .name = "cpu1", .rst_shift = 1 },
2514};
2515
2516static struct omap_hwmod_rst_info omap44xx_ipu_resets[] = {
2517 { .name = "mmu_cache", .rst_shift = 2 },
2518};
2519
2520/* ipu master ports */
2521static struct omap_hwmod_ocp_if *omap44xx_ipu_masters[] = {
2522 &omap44xx_ipu__l3_main_2,
2523};
2524
2525/* l3_main_2 -> ipu */
2526static struct omap_hwmod_ocp_if omap44xx_l3_main_2__ipu = {
2527 .master = &omap44xx_l3_main_2_hwmod,
2528 .slave = &omap44xx_ipu_hwmod,
2529 .clk = "l3_div_ck",
2530 .user = OCP_USER_MPU | OCP_USER_SDMA,
2531};
2532
2533/* ipu slave ports */
2534static struct omap_hwmod_ocp_if *omap44xx_ipu_slaves[] = {
2535 &omap44xx_l3_main_2__ipu,
2536};
2537
2538/* Pseudo hwmod for reset control purpose only */
2539static struct omap_hwmod omap44xx_ipu_c0_hwmod = {
2540 .name = "ipu_c0",
2541 .class = &omap44xx_ipu_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002542 .clkdm_name = "ducati_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01002543 .flags = HWMOD_INIT_NO_RESET,
2544 .rst_lines = omap44xx_ipu_c0_resets,
2545 .rst_lines_cnt = ARRAY_SIZE(omap44xx_ipu_c0_resets),
Benoit Cousson00fe6102011-07-09 19:14:28 -06002546 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01002547 .omap4 = {
Benoit Coussoneaac3292011-07-10 05:56:31 -06002548 .rstctrl_offs = OMAP4_RM_DUCATI_RSTCTRL_OFFSET,
Benoit Cousson407a6882011-02-15 22:39:48 +01002549 },
2550 },
Benoit Cousson407a6882011-02-15 22:39:48 +01002551};
2552
2553/* Pseudo hwmod for reset control purpose only */
2554static struct omap_hwmod omap44xx_ipu_c1_hwmod = {
2555 .name = "ipu_c1",
2556 .class = &omap44xx_ipu_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002557 .clkdm_name = "ducati_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01002558 .flags = HWMOD_INIT_NO_RESET,
2559 .rst_lines = omap44xx_ipu_c1_resets,
2560 .rst_lines_cnt = ARRAY_SIZE(omap44xx_ipu_c1_resets),
Benoit Cousson00fe6102011-07-09 19:14:28 -06002561 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01002562 .omap4 = {
Benoit Coussoneaac3292011-07-10 05:56:31 -06002563 .rstctrl_offs = OMAP4_RM_DUCATI_RSTCTRL_OFFSET,
Benoit Cousson407a6882011-02-15 22:39:48 +01002564 },
2565 },
Benoit Cousson407a6882011-02-15 22:39:48 +01002566};
2567
2568static struct omap_hwmod omap44xx_ipu_hwmod = {
2569 .name = "ipu",
2570 .class = &omap44xx_ipu_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002571 .clkdm_name = "ducati_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01002572 .mpu_irqs = omap44xx_ipu_irqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01002573 .rst_lines = omap44xx_ipu_resets,
2574 .rst_lines_cnt = ARRAY_SIZE(omap44xx_ipu_resets),
2575 .main_clk = "ipu_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -06002576 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01002577 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002578 .clkctrl_offs = OMAP4_CM_DUCATI_DUCATI_CLKCTRL_OFFSET,
Benoit Coussoneaac3292011-07-10 05:56:31 -06002579 .rstctrl_offs = OMAP4_RM_DUCATI_RSTCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002580 .context_offs = OMAP4_RM_DUCATI_DUCATI_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002581 .modulemode = MODULEMODE_HWCTRL,
Benoit Cousson407a6882011-02-15 22:39:48 +01002582 },
2583 },
2584 .slaves = omap44xx_ipu_slaves,
2585 .slaves_cnt = ARRAY_SIZE(omap44xx_ipu_slaves),
2586 .masters = omap44xx_ipu_masters,
2587 .masters_cnt = ARRAY_SIZE(omap44xx_ipu_masters),
Benoit Cousson407a6882011-02-15 22:39:48 +01002588};
2589
2590/*
2591 * 'iss' class
2592 * external images sensor pixel data processor
2593 */
2594
2595static struct omap_hwmod_class_sysconfig omap44xx_iss_sysc = {
2596 .rev_offs = 0x0000,
2597 .sysc_offs = 0x0010,
2598 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS |
2599 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
2600 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
2601 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
Benoit Coussonc614ebf2011-07-01 22:54:01 +02002602 MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
Benoit Cousson407a6882011-02-15 22:39:48 +01002603 .sysc_fields = &omap_hwmod_sysc_type2,
2604};
2605
2606static struct omap_hwmod_class omap44xx_iss_hwmod_class = {
2607 .name = "iss",
2608 .sysc = &omap44xx_iss_sysc,
2609};
2610
2611/* iss */
2612static struct omap_hwmod_irq_info omap44xx_iss_irqs[] = {
2613 { .irq = 24 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002614 { .irq = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01002615};
2616
2617static struct omap_hwmod_dma_info omap44xx_iss_sdma_reqs[] = {
2618 { .name = "1", .dma_req = 8 + OMAP44XX_DMA_REQ_START },
2619 { .name = "2", .dma_req = 9 + OMAP44XX_DMA_REQ_START },
2620 { .name = "3", .dma_req = 11 + OMAP44XX_DMA_REQ_START },
2621 { .name = "4", .dma_req = 12 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06002622 { .dma_req = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01002623};
2624
2625/* iss master ports */
2626static struct omap_hwmod_ocp_if *omap44xx_iss_masters[] = {
2627 &omap44xx_iss__l3_main_2,
2628};
2629
2630static struct omap_hwmod_addr_space omap44xx_iss_addrs[] = {
2631 {
2632 .pa_start = 0x52000000,
2633 .pa_end = 0x520000ff,
2634 .flags = ADDR_TYPE_RT
2635 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002636 { }
Benoit Cousson407a6882011-02-15 22:39:48 +01002637};
2638
2639/* l3_main_2 -> iss */
2640static struct omap_hwmod_ocp_if omap44xx_l3_main_2__iss = {
2641 .master = &omap44xx_l3_main_2_hwmod,
2642 .slave = &omap44xx_iss_hwmod,
2643 .clk = "l3_div_ck",
2644 .addr = omap44xx_iss_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +01002645 .user = OCP_USER_MPU | OCP_USER_SDMA,
2646};
2647
2648/* iss slave ports */
2649static struct omap_hwmod_ocp_if *omap44xx_iss_slaves[] = {
2650 &omap44xx_l3_main_2__iss,
2651};
2652
2653static struct omap_hwmod_opt_clk iss_opt_clks[] = {
2654 { .role = "ctrlclk", .clk = "iss_ctrlclk" },
2655};
2656
2657static struct omap_hwmod omap44xx_iss_hwmod = {
2658 .name = "iss",
2659 .class = &omap44xx_iss_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002660 .clkdm_name = "iss_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01002661 .mpu_irqs = omap44xx_iss_irqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01002662 .sdma_reqs = omap44xx_iss_sdma_reqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01002663 .main_clk = "iss_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -06002664 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01002665 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002666 .clkctrl_offs = OMAP4_CM_CAM_ISS_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002667 .context_offs = OMAP4_RM_CAM_ISS_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002668 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson407a6882011-02-15 22:39:48 +01002669 },
2670 },
2671 .opt_clks = iss_opt_clks,
2672 .opt_clks_cnt = ARRAY_SIZE(iss_opt_clks),
2673 .slaves = omap44xx_iss_slaves,
2674 .slaves_cnt = ARRAY_SIZE(omap44xx_iss_slaves),
2675 .masters = omap44xx_iss_masters,
2676 .masters_cnt = ARRAY_SIZE(omap44xx_iss_masters),
Benoit Cousson407a6882011-02-15 22:39:48 +01002677};
2678
2679/*
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002680 * 'iva' class
2681 * multi-standard video encoder/decoder hardware accelerator
2682 */
2683
2684static struct omap_hwmod_class omap44xx_iva_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +00002685 .name = "iva",
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002686};
2687
2688/* iva */
2689static struct omap_hwmod_irq_info omap44xx_iva_irqs[] = {
2690 { .name = "sync_1", .irq = 103 + OMAP44XX_IRQ_GIC_START },
2691 { .name = "sync_0", .irq = 104 + OMAP44XX_IRQ_GIC_START },
2692 { .name = "mailbox_0", .irq = 107 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002693 { .irq = -1 }
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002694};
2695
2696static struct omap_hwmod_rst_info omap44xx_iva_resets[] = {
2697 { .name = "logic", .rst_shift = 2 },
2698};
2699
2700static struct omap_hwmod_rst_info omap44xx_iva_seq0_resets[] = {
2701 { .name = "seq0", .rst_shift = 0 },
2702};
2703
2704static struct omap_hwmod_rst_info omap44xx_iva_seq1_resets[] = {
2705 { .name = "seq1", .rst_shift = 1 },
2706};
2707
2708/* iva master ports */
2709static struct omap_hwmod_ocp_if *omap44xx_iva_masters[] = {
2710 &omap44xx_iva__l3_main_2,
2711 &omap44xx_iva__l3_instr,
2712};
2713
2714static struct omap_hwmod_addr_space omap44xx_iva_addrs[] = {
2715 {
2716 .pa_start = 0x5a000000,
2717 .pa_end = 0x5a07ffff,
2718 .flags = ADDR_TYPE_RT
2719 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002720 { }
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002721};
2722
2723/* l3_main_2 -> iva */
2724static struct omap_hwmod_ocp_if omap44xx_l3_main_2__iva = {
2725 .master = &omap44xx_l3_main_2_hwmod,
2726 .slave = &omap44xx_iva_hwmod,
2727 .clk = "l3_div_ck",
2728 .addr = omap44xx_iva_addrs,
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002729 .user = OCP_USER_MPU,
2730};
2731
2732/* iva slave ports */
2733static struct omap_hwmod_ocp_if *omap44xx_iva_slaves[] = {
2734 &omap44xx_dsp__iva,
2735 &omap44xx_l3_main_2__iva,
2736};
2737
2738/* Pseudo hwmod for reset control purpose only */
2739static struct omap_hwmod omap44xx_iva_seq0_hwmod = {
2740 .name = "iva_seq0",
2741 .class = &omap44xx_iva_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002742 .clkdm_name = "ivahd_clkdm",
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002743 .flags = HWMOD_INIT_NO_RESET,
2744 .rst_lines = omap44xx_iva_seq0_resets,
2745 .rst_lines_cnt = ARRAY_SIZE(omap44xx_iva_seq0_resets),
2746 .prcm = {
2747 .omap4 = {
Benoit Coussoneaac3292011-07-10 05:56:31 -06002748 .rstctrl_offs = OMAP4_RM_IVAHD_RSTCTRL_OFFSET,
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002749 },
2750 },
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002751};
2752
2753/* Pseudo hwmod for reset control purpose only */
2754static struct omap_hwmod omap44xx_iva_seq1_hwmod = {
2755 .name = "iva_seq1",
2756 .class = &omap44xx_iva_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002757 .clkdm_name = "ivahd_clkdm",
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002758 .flags = HWMOD_INIT_NO_RESET,
2759 .rst_lines = omap44xx_iva_seq1_resets,
2760 .rst_lines_cnt = ARRAY_SIZE(omap44xx_iva_seq1_resets),
2761 .prcm = {
2762 .omap4 = {
Benoit Coussoneaac3292011-07-10 05:56:31 -06002763 .rstctrl_offs = OMAP4_RM_IVAHD_RSTCTRL_OFFSET,
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002764 },
2765 },
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002766};
2767
2768static struct omap_hwmod omap44xx_iva_hwmod = {
2769 .name = "iva",
2770 .class = &omap44xx_iva_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002771 .clkdm_name = "ivahd_clkdm",
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002772 .mpu_irqs = omap44xx_iva_irqs,
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002773 .rst_lines = omap44xx_iva_resets,
2774 .rst_lines_cnt = ARRAY_SIZE(omap44xx_iva_resets),
2775 .main_clk = "iva_fck",
2776 .prcm = {
2777 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002778 .clkctrl_offs = OMAP4_CM_IVAHD_IVAHD_CLKCTRL_OFFSET,
Benoit Coussoneaac3292011-07-10 05:56:31 -06002779 .rstctrl_offs = OMAP4_RM_IVAHD_RSTCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002780 .context_offs = OMAP4_RM_IVAHD_IVAHD_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002781 .modulemode = MODULEMODE_HWCTRL,
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002782 },
2783 },
2784 .slaves = omap44xx_iva_slaves,
2785 .slaves_cnt = ARRAY_SIZE(omap44xx_iva_slaves),
2786 .masters = omap44xx_iva_masters,
2787 .masters_cnt = ARRAY_SIZE(omap44xx_iva_masters),
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07002788};
2789
2790/*
Benoit Cousson407a6882011-02-15 22:39:48 +01002791 * 'kbd' class
2792 * keyboard controller
2793 */
2794
2795static struct omap_hwmod_class_sysconfig omap44xx_kbd_sysc = {
2796 .rev_offs = 0x0000,
2797 .sysc_offs = 0x0010,
2798 .syss_offs = 0x0014,
2799 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
2800 SYSC_HAS_EMUFREE | SYSC_HAS_ENAWAKEUP |
2801 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
2802 SYSS_HAS_RESET_STATUS),
2803 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2804 .sysc_fields = &omap_hwmod_sysc_type1,
2805};
2806
2807static struct omap_hwmod_class omap44xx_kbd_hwmod_class = {
2808 .name = "kbd",
2809 .sysc = &omap44xx_kbd_sysc,
2810};
2811
2812/* kbd */
2813static struct omap_hwmod omap44xx_kbd_hwmod;
2814static struct omap_hwmod_irq_info omap44xx_kbd_irqs[] = {
2815 { .irq = 120 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002816 { .irq = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01002817};
2818
2819static struct omap_hwmod_addr_space omap44xx_kbd_addrs[] = {
2820 {
2821 .pa_start = 0x4a31c000,
2822 .pa_end = 0x4a31c07f,
2823 .flags = ADDR_TYPE_RT
2824 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002825 { }
Benoit Cousson407a6882011-02-15 22:39:48 +01002826};
2827
2828/* l4_wkup -> kbd */
2829static struct omap_hwmod_ocp_if omap44xx_l4_wkup__kbd = {
2830 .master = &omap44xx_l4_wkup_hwmod,
2831 .slave = &omap44xx_kbd_hwmod,
2832 .clk = "l4_wkup_clk_mux_ck",
2833 .addr = omap44xx_kbd_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +01002834 .user = OCP_USER_MPU | OCP_USER_SDMA,
2835};
2836
2837/* kbd slave ports */
2838static struct omap_hwmod_ocp_if *omap44xx_kbd_slaves[] = {
2839 &omap44xx_l4_wkup__kbd,
2840};
2841
2842static struct omap_hwmod omap44xx_kbd_hwmod = {
2843 .name = "kbd",
2844 .class = &omap44xx_kbd_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002845 .clkdm_name = "l4_wkup_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01002846 .mpu_irqs = omap44xx_kbd_irqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01002847 .main_clk = "kbd_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -06002848 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01002849 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002850 .clkctrl_offs = OMAP4_CM_WKUP_KEYBOARD_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002851 .context_offs = OMAP4_RM_WKUP_KEYBOARD_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06002852 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson407a6882011-02-15 22:39:48 +01002853 },
2854 },
2855 .slaves = omap44xx_kbd_slaves,
2856 .slaves_cnt = ARRAY_SIZE(omap44xx_kbd_slaves),
Benoit Cousson407a6882011-02-15 22:39:48 +01002857};
2858
2859/*
Benoit Coussonec5df922011-02-02 19:27:21 +00002860 * 'mailbox' class
2861 * mailbox module allowing communication between the on-chip processors using a
2862 * queued mailbox-interrupt mechanism.
2863 */
2864
2865static struct omap_hwmod_class_sysconfig omap44xx_mailbox_sysc = {
2866 .rev_offs = 0x0000,
2867 .sysc_offs = 0x0010,
2868 .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
2869 SYSC_HAS_SOFTRESET),
2870 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2871 .sysc_fields = &omap_hwmod_sysc_type2,
2872};
2873
2874static struct omap_hwmod_class omap44xx_mailbox_hwmod_class = {
2875 .name = "mailbox",
2876 .sysc = &omap44xx_mailbox_sysc,
2877};
2878
2879/* mailbox */
2880static struct omap_hwmod omap44xx_mailbox_hwmod;
2881static struct omap_hwmod_irq_info omap44xx_mailbox_irqs[] = {
2882 { .irq = 26 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002883 { .irq = -1 }
Benoit Coussonec5df922011-02-02 19:27:21 +00002884};
2885
2886static struct omap_hwmod_addr_space omap44xx_mailbox_addrs[] = {
2887 {
2888 .pa_start = 0x4a0f4000,
2889 .pa_end = 0x4a0f41ff,
2890 .flags = ADDR_TYPE_RT
2891 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002892 { }
Benoit Coussonec5df922011-02-02 19:27:21 +00002893};
2894
2895/* l4_cfg -> mailbox */
2896static struct omap_hwmod_ocp_if omap44xx_l4_cfg__mailbox = {
2897 .master = &omap44xx_l4_cfg_hwmod,
2898 .slave = &omap44xx_mailbox_hwmod,
2899 .clk = "l4_div_ck",
2900 .addr = omap44xx_mailbox_addrs,
Benoit Coussonec5df922011-02-02 19:27:21 +00002901 .user = OCP_USER_MPU | OCP_USER_SDMA,
2902};
2903
2904/* mailbox slave ports */
2905static struct omap_hwmod_ocp_if *omap44xx_mailbox_slaves[] = {
2906 &omap44xx_l4_cfg__mailbox,
2907};
2908
2909static struct omap_hwmod omap44xx_mailbox_hwmod = {
2910 .name = "mailbox",
2911 .class = &omap44xx_mailbox_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06002912 .clkdm_name = "l4_cfg_clkdm",
Benoit Coussonec5df922011-02-02 19:27:21 +00002913 .mpu_irqs = omap44xx_mailbox_irqs,
Benoit Cousson00fe6102011-07-09 19:14:28 -06002914 .prcm = {
Benoit Coussonec5df922011-02-02 19:27:21 +00002915 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06002916 .clkctrl_offs = OMAP4_CM_L4CFG_MAILBOX_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06002917 .context_offs = OMAP4_RM_L4CFG_MAILBOX_CONTEXT_OFFSET,
Benoit Coussonec5df922011-02-02 19:27:21 +00002918 },
2919 },
2920 .slaves = omap44xx_mailbox_slaves,
2921 .slaves_cnt = ARRAY_SIZE(omap44xx_mailbox_slaves),
Benoit Coussonec5df922011-02-02 19:27:21 +00002922};
2923
2924/*
Benoit Cousson4ddff492011-01-31 14:50:30 +00002925 * 'mcbsp' class
2926 * multi channel buffered serial port controller
2927 */
2928
2929static struct omap_hwmod_class_sysconfig omap44xx_mcbsp_sysc = {
2930 .sysc_offs = 0x008c,
2931 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_ENAWAKEUP |
2932 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
2933 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2934 .sysc_fields = &omap_hwmod_sysc_type1,
2935};
2936
2937static struct omap_hwmod_class omap44xx_mcbsp_hwmod_class = {
2938 .name = "mcbsp",
2939 .sysc = &omap44xx_mcbsp_sysc,
Kishon Vijay Abraham Icb7e9de2011-02-24 15:16:50 +05302940 .rev = MCBSP_CONFIG_TYPE4,
Benoit Cousson4ddff492011-01-31 14:50:30 +00002941};
2942
2943/* mcbsp1 */
2944static struct omap_hwmod omap44xx_mcbsp1_hwmod;
2945static struct omap_hwmod_irq_info omap44xx_mcbsp1_irqs[] = {
2946 { .irq = 17 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06002947 { .irq = -1 }
Benoit Cousson4ddff492011-01-31 14:50:30 +00002948};
2949
2950static struct omap_hwmod_dma_info omap44xx_mcbsp1_sdma_reqs[] = {
2951 { .name = "tx", .dma_req = 32 + OMAP44XX_DMA_REQ_START },
2952 { .name = "rx", .dma_req = 33 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06002953 { .dma_req = -1 }
Benoit Cousson4ddff492011-01-31 14:50:30 +00002954};
2955
2956static struct omap_hwmod_addr_space omap44xx_mcbsp1_addrs[] = {
2957 {
Kishon Vijay Abraham Icb7e9de2011-02-24 15:16:50 +05302958 .name = "mpu",
Benoit Cousson4ddff492011-01-31 14:50:30 +00002959 .pa_start = 0x40122000,
2960 .pa_end = 0x401220ff,
2961 .flags = ADDR_TYPE_RT
2962 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002963 { }
Benoit Cousson4ddff492011-01-31 14:50:30 +00002964};
2965
2966/* l4_abe -> mcbsp1 */
2967static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp1 = {
2968 .master = &omap44xx_l4_abe_hwmod,
2969 .slave = &omap44xx_mcbsp1_hwmod,
2970 .clk = "ocp_abe_iclk",
2971 .addr = omap44xx_mcbsp1_addrs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00002972 .user = OCP_USER_MPU,
2973};
2974
2975static struct omap_hwmod_addr_space omap44xx_mcbsp1_dma_addrs[] = {
2976 {
Kishon Vijay Abraham Icb7e9de2011-02-24 15:16:50 +05302977 .name = "dma",
Benoit Cousson4ddff492011-01-31 14:50:30 +00002978 .pa_start = 0x49022000,
2979 .pa_end = 0x490220ff,
2980 .flags = ADDR_TYPE_RT
2981 },
Paul Walmsley78183f32011-07-09 19:14:05 -06002982 { }
Benoit Cousson4ddff492011-01-31 14:50:30 +00002983};
2984
2985/* l4_abe -> mcbsp1 (dma) */
2986static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp1_dma = {
2987 .master = &omap44xx_l4_abe_hwmod,
2988 .slave = &omap44xx_mcbsp1_hwmod,
2989 .clk = "ocp_abe_iclk",
2990 .addr = omap44xx_mcbsp1_dma_addrs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00002991 .user = OCP_USER_SDMA,
2992};
2993
2994/* mcbsp1 slave ports */
2995static struct omap_hwmod_ocp_if *omap44xx_mcbsp1_slaves[] = {
2996 &omap44xx_l4_abe__mcbsp1,
2997 &omap44xx_l4_abe__mcbsp1_dma,
2998};
2999
3000static struct omap_hwmod omap44xx_mcbsp1_hwmod = {
3001 .name = "mcbsp1",
3002 .class = &omap44xx_mcbsp_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003003 .clkdm_name = "abe_clkdm",
Benoit Cousson4ddff492011-01-31 14:50:30 +00003004 .mpu_irqs = omap44xx_mcbsp1_irqs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003005 .sdma_reqs = omap44xx_mcbsp1_sdma_reqs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003006 .main_clk = "mcbsp1_fck",
3007 .prcm = {
3008 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003009 .clkctrl_offs = OMAP4_CM1_ABE_MCBSP1_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003010 .context_offs = OMAP4_RM_ABE_MCBSP1_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003011 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003012 },
3013 },
3014 .slaves = omap44xx_mcbsp1_slaves,
3015 .slaves_cnt = ARRAY_SIZE(omap44xx_mcbsp1_slaves),
Benoit Cousson4ddff492011-01-31 14:50:30 +00003016};
3017
3018/* mcbsp2 */
3019static struct omap_hwmod omap44xx_mcbsp2_hwmod;
3020static struct omap_hwmod_irq_info omap44xx_mcbsp2_irqs[] = {
3021 { .irq = 22 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003022 { .irq = -1 }
Benoit Cousson4ddff492011-01-31 14:50:30 +00003023};
3024
3025static struct omap_hwmod_dma_info omap44xx_mcbsp2_sdma_reqs[] = {
3026 { .name = "tx", .dma_req = 16 + OMAP44XX_DMA_REQ_START },
3027 { .name = "rx", .dma_req = 17 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003028 { .dma_req = -1 }
Benoit Cousson4ddff492011-01-31 14:50:30 +00003029};
3030
3031static struct omap_hwmod_addr_space omap44xx_mcbsp2_addrs[] = {
3032 {
Kishon Vijay Abraham Icb7e9de2011-02-24 15:16:50 +05303033 .name = "mpu",
Benoit Cousson4ddff492011-01-31 14:50:30 +00003034 .pa_start = 0x40124000,
3035 .pa_end = 0x401240ff,
3036 .flags = ADDR_TYPE_RT
3037 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003038 { }
Benoit Cousson4ddff492011-01-31 14:50:30 +00003039};
3040
3041/* l4_abe -> mcbsp2 */
3042static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp2 = {
3043 .master = &omap44xx_l4_abe_hwmod,
3044 .slave = &omap44xx_mcbsp2_hwmod,
3045 .clk = "ocp_abe_iclk",
3046 .addr = omap44xx_mcbsp2_addrs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003047 .user = OCP_USER_MPU,
3048};
3049
3050static struct omap_hwmod_addr_space omap44xx_mcbsp2_dma_addrs[] = {
3051 {
Kishon Vijay Abraham Icb7e9de2011-02-24 15:16:50 +05303052 .name = "dma",
Benoit Cousson4ddff492011-01-31 14:50:30 +00003053 .pa_start = 0x49024000,
3054 .pa_end = 0x490240ff,
3055 .flags = ADDR_TYPE_RT
3056 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003057 { }
Benoit Cousson4ddff492011-01-31 14:50:30 +00003058};
3059
3060/* l4_abe -> mcbsp2 (dma) */
3061static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp2_dma = {
3062 .master = &omap44xx_l4_abe_hwmod,
3063 .slave = &omap44xx_mcbsp2_hwmod,
3064 .clk = "ocp_abe_iclk",
3065 .addr = omap44xx_mcbsp2_dma_addrs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003066 .user = OCP_USER_SDMA,
3067};
3068
3069/* mcbsp2 slave ports */
3070static struct omap_hwmod_ocp_if *omap44xx_mcbsp2_slaves[] = {
3071 &omap44xx_l4_abe__mcbsp2,
3072 &omap44xx_l4_abe__mcbsp2_dma,
3073};
3074
3075static struct omap_hwmod omap44xx_mcbsp2_hwmod = {
3076 .name = "mcbsp2",
3077 .class = &omap44xx_mcbsp_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003078 .clkdm_name = "abe_clkdm",
Benoit Cousson4ddff492011-01-31 14:50:30 +00003079 .mpu_irqs = omap44xx_mcbsp2_irqs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003080 .sdma_reqs = omap44xx_mcbsp2_sdma_reqs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003081 .main_clk = "mcbsp2_fck",
3082 .prcm = {
3083 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003084 .clkctrl_offs = OMAP4_CM1_ABE_MCBSP2_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003085 .context_offs = OMAP4_RM_ABE_MCBSP2_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003086 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003087 },
3088 },
3089 .slaves = omap44xx_mcbsp2_slaves,
3090 .slaves_cnt = ARRAY_SIZE(omap44xx_mcbsp2_slaves),
Benoit Cousson4ddff492011-01-31 14:50:30 +00003091};
3092
3093/* mcbsp3 */
3094static struct omap_hwmod omap44xx_mcbsp3_hwmod;
3095static struct omap_hwmod_irq_info omap44xx_mcbsp3_irqs[] = {
3096 { .irq = 23 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003097 { .irq = -1 }
Benoit Cousson4ddff492011-01-31 14:50:30 +00003098};
3099
3100static struct omap_hwmod_dma_info omap44xx_mcbsp3_sdma_reqs[] = {
3101 { .name = "tx", .dma_req = 18 + OMAP44XX_DMA_REQ_START },
3102 { .name = "rx", .dma_req = 19 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003103 { .dma_req = -1 }
Benoit Cousson4ddff492011-01-31 14:50:30 +00003104};
3105
3106static struct omap_hwmod_addr_space omap44xx_mcbsp3_addrs[] = {
3107 {
Kishon Vijay Abraham Icb7e9de2011-02-24 15:16:50 +05303108 .name = "mpu",
Benoit Cousson4ddff492011-01-31 14:50:30 +00003109 .pa_start = 0x40126000,
3110 .pa_end = 0x401260ff,
3111 .flags = ADDR_TYPE_RT
3112 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003113 { }
Benoit Cousson4ddff492011-01-31 14:50:30 +00003114};
3115
3116/* l4_abe -> mcbsp3 */
3117static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp3 = {
3118 .master = &omap44xx_l4_abe_hwmod,
3119 .slave = &omap44xx_mcbsp3_hwmod,
3120 .clk = "ocp_abe_iclk",
3121 .addr = omap44xx_mcbsp3_addrs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003122 .user = OCP_USER_MPU,
3123};
3124
3125static struct omap_hwmod_addr_space omap44xx_mcbsp3_dma_addrs[] = {
3126 {
Kishon Vijay Abraham Icb7e9de2011-02-24 15:16:50 +05303127 .name = "dma",
Benoit Cousson4ddff492011-01-31 14:50:30 +00003128 .pa_start = 0x49026000,
3129 .pa_end = 0x490260ff,
3130 .flags = ADDR_TYPE_RT
3131 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003132 { }
Benoit Cousson4ddff492011-01-31 14:50:30 +00003133};
3134
3135/* l4_abe -> mcbsp3 (dma) */
3136static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp3_dma = {
3137 .master = &omap44xx_l4_abe_hwmod,
3138 .slave = &omap44xx_mcbsp3_hwmod,
3139 .clk = "ocp_abe_iclk",
3140 .addr = omap44xx_mcbsp3_dma_addrs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003141 .user = OCP_USER_SDMA,
3142};
3143
3144/* mcbsp3 slave ports */
3145static struct omap_hwmod_ocp_if *omap44xx_mcbsp3_slaves[] = {
3146 &omap44xx_l4_abe__mcbsp3,
3147 &omap44xx_l4_abe__mcbsp3_dma,
3148};
3149
3150static struct omap_hwmod omap44xx_mcbsp3_hwmod = {
3151 .name = "mcbsp3",
3152 .class = &omap44xx_mcbsp_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003153 .clkdm_name = "abe_clkdm",
Benoit Cousson4ddff492011-01-31 14:50:30 +00003154 .mpu_irqs = omap44xx_mcbsp3_irqs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003155 .sdma_reqs = omap44xx_mcbsp3_sdma_reqs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003156 .main_clk = "mcbsp3_fck",
3157 .prcm = {
3158 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003159 .clkctrl_offs = OMAP4_CM1_ABE_MCBSP3_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003160 .context_offs = OMAP4_RM_ABE_MCBSP3_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003161 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003162 },
3163 },
3164 .slaves = omap44xx_mcbsp3_slaves,
3165 .slaves_cnt = ARRAY_SIZE(omap44xx_mcbsp3_slaves),
Benoit Cousson4ddff492011-01-31 14:50:30 +00003166};
3167
3168/* mcbsp4 */
3169static struct omap_hwmod omap44xx_mcbsp4_hwmod;
3170static struct omap_hwmod_irq_info omap44xx_mcbsp4_irqs[] = {
3171 { .irq = 16 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003172 { .irq = -1 }
Benoit Cousson4ddff492011-01-31 14:50:30 +00003173};
3174
3175static struct omap_hwmod_dma_info omap44xx_mcbsp4_sdma_reqs[] = {
3176 { .name = "tx", .dma_req = 30 + OMAP44XX_DMA_REQ_START },
3177 { .name = "rx", .dma_req = 31 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003178 { .dma_req = -1 }
Benoit Cousson4ddff492011-01-31 14:50:30 +00003179};
3180
3181static struct omap_hwmod_addr_space omap44xx_mcbsp4_addrs[] = {
3182 {
3183 .pa_start = 0x48096000,
3184 .pa_end = 0x480960ff,
3185 .flags = ADDR_TYPE_RT
3186 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003187 { }
Benoit Cousson4ddff492011-01-31 14:50:30 +00003188};
3189
3190/* l4_per -> mcbsp4 */
3191static struct omap_hwmod_ocp_if omap44xx_l4_per__mcbsp4 = {
3192 .master = &omap44xx_l4_per_hwmod,
3193 .slave = &omap44xx_mcbsp4_hwmod,
3194 .clk = "l4_div_ck",
3195 .addr = omap44xx_mcbsp4_addrs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003196 .user = OCP_USER_MPU | OCP_USER_SDMA,
3197};
3198
3199/* mcbsp4 slave ports */
3200static struct omap_hwmod_ocp_if *omap44xx_mcbsp4_slaves[] = {
3201 &omap44xx_l4_per__mcbsp4,
3202};
3203
3204static struct omap_hwmod omap44xx_mcbsp4_hwmod = {
3205 .name = "mcbsp4",
3206 .class = &omap44xx_mcbsp_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003207 .clkdm_name = "l4_per_clkdm",
Benoit Cousson4ddff492011-01-31 14:50:30 +00003208 .mpu_irqs = omap44xx_mcbsp4_irqs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003209 .sdma_reqs = omap44xx_mcbsp4_sdma_reqs,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003210 .main_clk = "mcbsp4_fck",
3211 .prcm = {
3212 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003213 .clkctrl_offs = OMAP4_CM_L4PER_MCBSP4_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003214 .context_offs = OMAP4_RM_L4PER_MCBSP4_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003215 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson4ddff492011-01-31 14:50:30 +00003216 },
3217 },
3218 .slaves = omap44xx_mcbsp4_slaves,
3219 .slaves_cnt = ARRAY_SIZE(omap44xx_mcbsp4_slaves),
Benoit Cousson4ddff492011-01-31 14:50:30 +00003220};
3221
3222/*
Benoit Cousson407a6882011-02-15 22:39:48 +01003223 * 'mcpdm' class
3224 * multi channel pdm controller (proprietary interface with phoenix power
3225 * ic)
3226 */
3227
3228static struct omap_hwmod_class_sysconfig omap44xx_mcpdm_sysc = {
3229 .rev_offs = 0x0000,
3230 .sysc_offs = 0x0010,
3231 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
3232 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
3233 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
3234 SIDLE_SMART_WKUP),
3235 .sysc_fields = &omap_hwmod_sysc_type2,
3236};
3237
3238static struct omap_hwmod_class omap44xx_mcpdm_hwmod_class = {
3239 .name = "mcpdm",
3240 .sysc = &omap44xx_mcpdm_sysc,
3241};
3242
3243/* mcpdm */
3244static struct omap_hwmod omap44xx_mcpdm_hwmod;
3245static struct omap_hwmod_irq_info omap44xx_mcpdm_irqs[] = {
3246 { .irq = 112 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003247 { .irq = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003248};
3249
3250static struct omap_hwmod_dma_info omap44xx_mcpdm_sdma_reqs[] = {
3251 { .name = "up_link", .dma_req = 64 + OMAP44XX_DMA_REQ_START },
3252 { .name = "dn_link", .dma_req = 65 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003253 { .dma_req = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003254};
3255
3256static struct omap_hwmod_addr_space omap44xx_mcpdm_addrs[] = {
3257 {
3258 .pa_start = 0x40132000,
3259 .pa_end = 0x4013207f,
3260 .flags = ADDR_TYPE_RT
3261 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003262 { }
Benoit Cousson407a6882011-02-15 22:39:48 +01003263};
3264
3265/* l4_abe -> mcpdm */
3266static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcpdm = {
3267 .master = &omap44xx_l4_abe_hwmod,
3268 .slave = &omap44xx_mcpdm_hwmod,
3269 .clk = "ocp_abe_iclk",
3270 .addr = omap44xx_mcpdm_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003271 .user = OCP_USER_MPU,
3272};
3273
3274static struct omap_hwmod_addr_space omap44xx_mcpdm_dma_addrs[] = {
3275 {
3276 .pa_start = 0x49032000,
3277 .pa_end = 0x4903207f,
3278 .flags = ADDR_TYPE_RT
3279 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003280 { }
Benoit Cousson407a6882011-02-15 22:39:48 +01003281};
3282
3283/* l4_abe -> mcpdm (dma) */
3284static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcpdm_dma = {
3285 .master = &omap44xx_l4_abe_hwmod,
3286 .slave = &omap44xx_mcpdm_hwmod,
3287 .clk = "ocp_abe_iclk",
3288 .addr = omap44xx_mcpdm_dma_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003289 .user = OCP_USER_SDMA,
3290};
3291
3292/* mcpdm slave ports */
3293static struct omap_hwmod_ocp_if *omap44xx_mcpdm_slaves[] = {
3294 &omap44xx_l4_abe__mcpdm,
3295 &omap44xx_l4_abe__mcpdm_dma,
3296};
3297
3298static struct omap_hwmod omap44xx_mcpdm_hwmod = {
3299 .name = "mcpdm",
3300 .class = &omap44xx_mcpdm_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003301 .clkdm_name = "abe_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01003302 .mpu_irqs = omap44xx_mcpdm_irqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003303 .sdma_reqs = omap44xx_mcpdm_sdma_reqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003304 .main_clk = "mcpdm_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -06003305 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01003306 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003307 .clkctrl_offs = OMAP4_CM1_ABE_PDM_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003308 .context_offs = OMAP4_RM_ABE_PDM_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003309 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson407a6882011-02-15 22:39:48 +01003310 },
3311 },
3312 .slaves = omap44xx_mcpdm_slaves,
3313 .slaves_cnt = ARRAY_SIZE(omap44xx_mcpdm_slaves),
Benoit Cousson407a6882011-02-15 22:39:48 +01003314};
3315
3316/*
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303317 * 'mcspi' class
3318 * multichannel serial port interface (mcspi) / master/slave synchronous serial
3319 * bus
3320 */
3321
3322static struct omap_hwmod_class_sysconfig omap44xx_mcspi_sysc = {
3323 .rev_offs = 0x0000,
3324 .sysc_offs = 0x0010,
3325 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
3326 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
3327 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
3328 SIDLE_SMART_WKUP),
3329 .sysc_fields = &omap_hwmod_sysc_type2,
3330};
3331
3332static struct omap_hwmod_class omap44xx_mcspi_hwmod_class = {
3333 .name = "mcspi",
3334 .sysc = &omap44xx_mcspi_sysc,
Benoit Cousson905a74d2011-02-18 14:01:06 +01003335 .rev = OMAP4_MCSPI_REV,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303336};
3337
3338/* mcspi1 */
3339static struct omap_hwmod omap44xx_mcspi1_hwmod;
3340static struct omap_hwmod_irq_info omap44xx_mcspi1_irqs[] = {
3341 { .irq = 65 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003342 { .irq = -1 }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303343};
3344
3345static struct omap_hwmod_dma_info omap44xx_mcspi1_sdma_reqs[] = {
3346 { .name = "tx0", .dma_req = 34 + OMAP44XX_DMA_REQ_START },
3347 { .name = "rx0", .dma_req = 35 + OMAP44XX_DMA_REQ_START },
3348 { .name = "tx1", .dma_req = 36 + OMAP44XX_DMA_REQ_START },
3349 { .name = "rx1", .dma_req = 37 + OMAP44XX_DMA_REQ_START },
3350 { .name = "tx2", .dma_req = 38 + OMAP44XX_DMA_REQ_START },
3351 { .name = "rx2", .dma_req = 39 + OMAP44XX_DMA_REQ_START },
3352 { .name = "tx3", .dma_req = 40 + OMAP44XX_DMA_REQ_START },
3353 { .name = "rx3", .dma_req = 41 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003354 { .dma_req = -1 }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303355};
3356
3357static struct omap_hwmod_addr_space omap44xx_mcspi1_addrs[] = {
3358 {
3359 .pa_start = 0x48098000,
3360 .pa_end = 0x480981ff,
3361 .flags = ADDR_TYPE_RT
3362 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003363 { }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303364};
3365
3366/* l4_per -> mcspi1 */
3367static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi1 = {
3368 .master = &omap44xx_l4_per_hwmod,
3369 .slave = &omap44xx_mcspi1_hwmod,
3370 .clk = "l4_div_ck",
3371 .addr = omap44xx_mcspi1_addrs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303372 .user = OCP_USER_MPU | OCP_USER_SDMA,
3373};
3374
3375/* mcspi1 slave ports */
3376static struct omap_hwmod_ocp_if *omap44xx_mcspi1_slaves[] = {
3377 &omap44xx_l4_per__mcspi1,
3378};
3379
Benoit Cousson905a74d2011-02-18 14:01:06 +01003380/* mcspi1 dev_attr */
3381static struct omap2_mcspi_dev_attr mcspi1_dev_attr = {
3382 .num_chipselect = 4,
3383};
3384
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303385static struct omap_hwmod omap44xx_mcspi1_hwmod = {
3386 .name = "mcspi1",
3387 .class = &omap44xx_mcspi_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003388 .clkdm_name = "l4_per_clkdm",
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303389 .mpu_irqs = omap44xx_mcspi1_irqs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303390 .sdma_reqs = omap44xx_mcspi1_sdma_reqs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303391 .main_clk = "mcspi1_fck",
3392 .prcm = {
3393 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003394 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI1_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003395 .context_offs = OMAP4_RM_L4PER_MCSPI1_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003396 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303397 },
3398 },
Benoit Cousson905a74d2011-02-18 14:01:06 +01003399 .dev_attr = &mcspi1_dev_attr,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303400 .slaves = omap44xx_mcspi1_slaves,
3401 .slaves_cnt = ARRAY_SIZE(omap44xx_mcspi1_slaves),
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303402};
3403
3404/* mcspi2 */
3405static struct omap_hwmod omap44xx_mcspi2_hwmod;
3406static struct omap_hwmod_irq_info omap44xx_mcspi2_irqs[] = {
3407 { .irq = 66 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003408 { .irq = -1 }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303409};
3410
3411static struct omap_hwmod_dma_info omap44xx_mcspi2_sdma_reqs[] = {
3412 { .name = "tx0", .dma_req = 42 + OMAP44XX_DMA_REQ_START },
3413 { .name = "rx0", .dma_req = 43 + OMAP44XX_DMA_REQ_START },
3414 { .name = "tx1", .dma_req = 44 + OMAP44XX_DMA_REQ_START },
3415 { .name = "rx1", .dma_req = 45 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003416 { .dma_req = -1 }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303417};
3418
3419static struct omap_hwmod_addr_space omap44xx_mcspi2_addrs[] = {
3420 {
3421 .pa_start = 0x4809a000,
3422 .pa_end = 0x4809a1ff,
3423 .flags = ADDR_TYPE_RT
3424 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003425 { }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303426};
3427
3428/* l4_per -> mcspi2 */
3429static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi2 = {
3430 .master = &omap44xx_l4_per_hwmod,
3431 .slave = &omap44xx_mcspi2_hwmod,
3432 .clk = "l4_div_ck",
3433 .addr = omap44xx_mcspi2_addrs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303434 .user = OCP_USER_MPU | OCP_USER_SDMA,
3435};
3436
3437/* mcspi2 slave ports */
3438static struct omap_hwmod_ocp_if *omap44xx_mcspi2_slaves[] = {
3439 &omap44xx_l4_per__mcspi2,
3440};
3441
Benoit Cousson905a74d2011-02-18 14:01:06 +01003442/* mcspi2 dev_attr */
3443static struct omap2_mcspi_dev_attr mcspi2_dev_attr = {
3444 .num_chipselect = 2,
3445};
3446
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303447static struct omap_hwmod omap44xx_mcspi2_hwmod = {
3448 .name = "mcspi2",
3449 .class = &omap44xx_mcspi_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003450 .clkdm_name = "l4_per_clkdm",
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303451 .mpu_irqs = omap44xx_mcspi2_irqs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303452 .sdma_reqs = omap44xx_mcspi2_sdma_reqs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303453 .main_clk = "mcspi2_fck",
3454 .prcm = {
3455 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003456 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI2_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003457 .context_offs = OMAP4_RM_L4PER_MCSPI2_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003458 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303459 },
3460 },
Benoit Cousson905a74d2011-02-18 14:01:06 +01003461 .dev_attr = &mcspi2_dev_attr,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303462 .slaves = omap44xx_mcspi2_slaves,
3463 .slaves_cnt = ARRAY_SIZE(omap44xx_mcspi2_slaves),
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303464};
3465
3466/* mcspi3 */
3467static struct omap_hwmod omap44xx_mcspi3_hwmod;
3468static struct omap_hwmod_irq_info omap44xx_mcspi3_irqs[] = {
3469 { .irq = 91 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003470 { .irq = -1 }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303471};
3472
3473static struct omap_hwmod_dma_info omap44xx_mcspi3_sdma_reqs[] = {
3474 { .name = "tx0", .dma_req = 14 + OMAP44XX_DMA_REQ_START },
3475 { .name = "rx0", .dma_req = 15 + OMAP44XX_DMA_REQ_START },
3476 { .name = "tx1", .dma_req = 22 + OMAP44XX_DMA_REQ_START },
3477 { .name = "rx1", .dma_req = 23 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003478 { .dma_req = -1 }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303479};
3480
3481static struct omap_hwmod_addr_space omap44xx_mcspi3_addrs[] = {
3482 {
3483 .pa_start = 0x480b8000,
3484 .pa_end = 0x480b81ff,
3485 .flags = ADDR_TYPE_RT
3486 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003487 { }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303488};
3489
3490/* l4_per -> mcspi3 */
3491static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi3 = {
3492 .master = &omap44xx_l4_per_hwmod,
3493 .slave = &omap44xx_mcspi3_hwmod,
3494 .clk = "l4_div_ck",
3495 .addr = omap44xx_mcspi3_addrs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303496 .user = OCP_USER_MPU | OCP_USER_SDMA,
3497};
3498
3499/* mcspi3 slave ports */
3500static struct omap_hwmod_ocp_if *omap44xx_mcspi3_slaves[] = {
3501 &omap44xx_l4_per__mcspi3,
3502};
3503
Benoit Cousson905a74d2011-02-18 14:01:06 +01003504/* mcspi3 dev_attr */
3505static struct omap2_mcspi_dev_attr mcspi3_dev_attr = {
3506 .num_chipselect = 2,
3507};
3508
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303509static struct omap_hwmod omap44xx_mcspi3_hwmod = {
3510 .name = "mcspi3",
3511 .class = &omap44xx_mcspi_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003512 .clkdm_name = "l4_per_clkdm",
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303513 .mpu_irqs = omap44xx_mcspi3_irqs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303514 .sdma_reqs = omap44xx_mcspi3_sdma_reqs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303515 .main_clk = "mcspi3_fck",
3516 .prcm = {
3517 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003518 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI3_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003519 .context_offs = OMAP4_RM_L4PER_MCSPI3_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003520 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303521 },
3522 },
Benoit Cousson905a74d2011-02-18 14:01:06 +01003523 .dev_attr = &mcspi3_dev_attr,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303524 .slaves = omap44xx_mcspi3_slaves,
3525 .slaves_cnt = ARRAY_SIZE(omap44xx_mcspi3_slaves),
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303526};
3527
3528/* mcspi4 */
3529static struct omap_hwmod omap44xx_mcspi4_hwmod;
3530static struct omap_hwmod_irq_info omap44xx_mcspi4_irqs[] = {
3531 { .irq = 48 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003532 { .irq = -1 }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303533};
3534
3535static struct omap_hwmod_dma_info omap44xx_mcspi4_sdma_reqs[] = {
3536 { .name = "tx0", .dma_req = 69 + OMAP44XX_DMA_REQ_START },
3537 { .name = "rx0", .dma_req = 70 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003538 { .dma_req = -1 }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303539};
3540
3541static struct omap_hwmod_addr_space omap44xx_mcspi4_addrs[] = {
3542 {
3543 .pa_start = 0x480ba000,
3544 .pa_end = 0x480ba1ff,
3545 .flags = ADDR_TYPE_RT
3546 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003547 { }
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303548};
3549
3550/* l4_per -> mcspi4 */
3551static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi4 = {
3552 .master = &omap44xx_l4_per_hwmod,
3553 .slave = &omap44xx_mcspi4_hwmod,
3554 .clk = "l4_div_ck",
3555 .addr = omap44xx_mcspi4_addrs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303556 .user = OCP_USER_MPU | OCP_USER_SDMA,
3557};
3558
3559/* mcspi4 slave ports */
3560static struct omap_hwmod_ocp_if *omap44xx_mcspi4_slaves[] = {
3561 &omap44xx_l4_per__mcspi4,
3562};
3563
Benoit Cousson905a74d2011-02-18 14:01:06 +01003564/* mcspi4 dev_attr */
3565static struct omap2_mcspi_dev_attr mcspi4_dev_attr = {
3566 .num_chipselect = 1,
3567};
3568
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303569static struct omap_hwmod omap44xx_mcspi4_hwmod = {
3570 .name = "mcspi4",
3571 .class = &omap44xx_mcspi_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003572 .clkdm_name = "l4_per_clkdm",
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303573 .mpu_irqs = omap44xx_mcspi4_irqs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303574 .sdma_reqs = omap44xx_mcspi4_sdma_reqs,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303575 .main_clk = "mcspi4_fck",
3576 .prcm = {
3577 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003578 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI4_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003579 .context_offs = OMAP4_RM_L4PER_MCSPI4_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003580 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303581 },
3582 },
Benoit Cousson905a74d2011-02-18 14:01:06 +01003583 .dev_attr = &mcspi4_dev_attr,
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303584 .slaves = omap44xx_mcspi4_slaves,
3585 .slaves_cnt = ARRAY_SIZE(omap44xx_mcspi4_slaves),
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05303586};
3587
3588/*
Benoit Cousson407a6882011-02-15 22:39:48 +01003589 * 'mmc' class
3590 * multimedia card high-speed/sd/sdio (mmc/sd/sdio) host controller
3591 */
3592
3593static struct omap_hwmod_class_sysconfig omap44xx_mmc_sysc = {
3594 .rev_offs = 0x0000,
3595 .sysc_offs = 0x0010,
3596 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE |
3597 SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
3598 SYSC_HAS_SOFTRESET),
3599 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
3600 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
Benoit Coussonc614ebf2011-07-01 22:54:01 +02003601 MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
Benoit Cousson407a6882011-02-15 22:39:48 +01003602 .sysc_fields = &omap_hwmod_sysc_type2,
3603};
3604
3605static struct omap_hwmod_class omap44xx_mmc_hwmod_class = {
3606 .name = "mmc",
3607 .sysc = &omap44xx_mmc_sysc,
3608};
3609
3610/* mmc1 */
3611static struct omap_hwmod_irq_info omap44xx_mmc1_irqs[] = {
3612 { .irq = 83 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003613 { .irq = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003614};
3615
3616static struct omap_hwmod_dma_info omap44xx_mmc1_sdma_reqs[] = {
3617 { .name = "tx", .dma_req = 60 + OMAP44XX_DMA_REQ_START },
3618 { .name = "rx", .dma_req = 61 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003619 { .dma_req = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003620};
3621
3622/* mmc1 master ports */
3623static struct omap_hwmod_ocp_if *omap44xx_mmc1_masters[] = {
3624 &omap44xx_mmc1__l3_main_1,
3625};
3626
3627static struct omap_hwmod_addr_space omap44xx_mmc1_addrs[] = {
3628 {
3629 .pa_start = 0x4809c000,
3630 .pa_end = 0x4809c3ff,
3631 .flags = ADDR_TYPE_RT
3632 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003633 { }
Benoit Cousson407a6882011-02-15 22:39:48 +01003634};
3635
3636/* l4_per -> mmc1 */
3637static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc1 = {
3638 .master = &omap44xx_l4_per_hwmod,
3639 .slave = &omap44xx_mmc1_hwmod,
3640 .clk = "l4_div_ck",
3641 .addr = omap44xx_mmc1_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003642 .user = OCP_USER_MPU | OCP_USER_SDMA,
3643};
3644
3645/* mmc1 slave ports */
3646static struct omap_hwmod_ocp_if *omap44xx_mmc1_slaves[] = {
3647 &omap44xx_l4_per__mmc1,
3648};
3649
Kishore Kadiyala6ab89462011-03-01 13:12:56 -08003650/* mmc1 dev_attr */
3651static struct omap_mmc_dev_attr mmc1_dev_attr = {
3652 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
3653};
3654
Benoit Cousson407a6882011-02-15 22:39:48 +01003655static struct omap_hwmod omap44xx_mmc1_hwmod = {
3656 .name = "mmc1",
3657 .class = &omap44xx_mmc_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003658 .clkdm_name = "l3_init_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01003659 .mpu_irqs = omap44xx_mmc1_irqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003660 .sdma_reqs = omap44xx_mmc1_sdma_reqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003661 .main_clk = "mmc1_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -06003662 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01003663 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003664 .clkctrl_offs = OMAP4_CM_L3INIT_MMC1_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003665 .context_offs = OMAP4_RM_L3INIT_MMC1_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003666 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson407a6882011-02-15 22:39:48 +01003667 },
3668 },
Kishore Kadiyala6ab89462011-03-01 13:12:56 -08003669 .dev_attr = &mmc1_dev_attr,
Benoit Cousson407a6882011-02-15 22:39:48 +01003670 .slaves = omap44xx_mmc1_slaves,
3671 .slaves_cnt = ARRAY_SIZE(omap44xx_mmc1_slaves),
3672 .masters = omap44xx_mmc1_masters,
3673 .masters_cnt = ARRAY_SIZE(omap44xx_mmc1_masters),
Benoit Cousson407a6882011-02-15 22:39:48 +01003674};
3675
3676/* mmc2 */
3677static struct omap_hwmod_irq_info omap44xx_mmc2_irqs[] = {
3678 { .irq = 86 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003679 { .irq = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003680};
3681
3682static struct omap_hwmod_dma_info omap44xx_mmc2_sdma_reqs[] = {
3683 { .name = "tx", .dma_req = 46 + OMAP44XX_DMA_REQ_START },
3684 { .name = "rx", .dma_req = 47 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003685 { .dma_req = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003686};
3687
3688/* mmc2 master ports */
3689static struct omap_hwmod_ocp_if *omap44xx_mmc2_masters[] = {
3690 &omap44xx_mmc2__l3_main_1,
3691};
3692
3693static struct omap_hwmod_addr_space omap44xx_mmc2_addrs[] = {
3694 {
3695 .pa_start = 0x480b4000,
3696 .pa_end = 0x480b43ff,
3697 .flags = ADDR_TYPE_RT
3698 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003699 { }
Benoit Cousson407a6882011-02-15 22:39:48 +01003700};
3701
3702/* l4_per -> mmc2 */
3703static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc2 = {
3704 .master = &omap44xx_l4_per_hwmod,
3705 .slave = &omap44xx_mmc2_hwmod,
3706 .clk = "l4_div_ck",
3707 .addr = omap44xx_mmc2_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003708 .user = OCP_USER_MPU | OCP_USER_SDMA,
3709};
3710
3711/* mmc2 slave ports */
3712static struct omap_hwmod_ocp_if *omap44xx_mmc2_slaves[] = {
3713 &omap44xx_l4_per__mmc2,
3714};
3715
3716static struct omap_hwmod omap44xx_mmc2_hwmod = {
3717 .name = "mmc2",
3718 .class = &omap44xx_mmc_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003719 .clkdm_name = "l3_init_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01003720 .mpu_irqs = omap44xx_mmc2_irqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003721 .sdma_reqs = omap44xx_mmc2_sdma_reqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003722 .main_clk = "mmc2_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -06003723 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01003724 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003725 .clkctrl_offs = OMAP4_CM_L3INIT_MMC2_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003726 .context_offs = OMAP4_RM_L3INIT_MMC2_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003727 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson407a6882011-02-15 22:39:48 +01003728 },
3729 },
3730 .slaves = omap44xx_mmc2_slaves,
3731 .slaves_cnt = ARRAY_SIZE(omap44xx_mmc2_slaves),
3732 .masters = omap44xx_mmc2_masters,
3733 .masters_cnt = ARRAY_SIZE(omap44xx_mmc2_masters),
Benoit Cousson407a6882011-02-15 22:39:48 +01003734};
3735
3736/* mmc3 */
3737static struct omap_hwmod omap44xx_mmc3_hwmod;
3738static struct omap_hwmod_irq_info omap44xx_mmc3_irqs[] = {
3739 { .irq = 94 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003740 { .irq = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003741};
3742
3743static struct omap_hwmod_dma_info omap44xx_mmc3_sdma_reqs[] = {
3744 { .name = "tx", .dma_req = 76 + OMAP44XX_DMA_REQ_START },
3745 { .name = "rx", .dma_req = 77 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003746 { .dma_req = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003747};
3748
3749static struct omap_hwmod_addr_space omap44xx_mmc3_addrs[] = {
3750 {
3751 .pa_start = 0x480ad000,
3752 .pa_end = 0x480ad3ff,
3753 .flags = ADDR_TYPE_RT
3754 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003755 { }
Benoit Cousson407a6882011-02-15 22:39:48 +01003756};
3757
3758/* l4_per -> mmc3 */
3759static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc3 = {
3760 .master = &omap44xx_l4_per_hwmod,
3761 .slave = &omap44xx_mmc3_hwmod,
3762 .clk = "l4_div_ck",
3763 .addr = omap44xx_mmc3_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003764 .user = OCP_USER_MPU | OCP_USER_SDMA,
3765};
3766
3767/* mmc3 slave ports */
3768static struct omap_hwmod_ocp_if *omap44xx_mmc3_slaves[] = {
3769 &omap44xx_l4_per__mmc3,
3770};
3771
3772static struct omap_hwmod omap44xx_mmc3_hwmod = {
3773 .name = "mmc3",
3774 .class = &omap44xx_mmc_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003775 .clkdm_name = "l4_per_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01003776 .mpu_irqs = omap44xx_mmc3_irqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003777 .sdma_reqs = omap44xx_mmc3_sdma_reqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003778 .main_clk = "mmc3_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -06003779 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01003780 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003781 .clkctrl_offs = OMAP4_CM_L4PER_MMCSD3_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003782 .context_offs = OMAP4_RM_L4PER_MMCSD3_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003783 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson407a6882011-02-15 22:39:48 +01003784 },
3785 },
3786 .slaves = omap44xx_mmc3_slaves,
3787 .slaves_cnt = ARRAY_SIZE(omap44xx_mmc3_slaves),
Benoit Cousson407a6882011-02-15 22:39:48 +01003788};
3789
3790/* mmc4 */
3791static struct omap_hwmod omap44xx_mmc4_hwmod;
3792static struct omap_hwmod_irq_info omap44xx_mmc4_irqs[] = {
3793 { .irq = 96 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003794 { .irq = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003795};
3796
3797static struct omap_hwmod_dma_info omap44xx_mmc4_sdma_reqs[] = {
3798 { .name = "tx", .dma_req = 56 + OMAP44XX_DMA_REQ_START },
3799 { .name = "rx", .dma_req = 57 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003800 { .dma_req = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003801};
3802
3803static struct omap_hwmod_addr_space omap44xx_mmc4_addrs[] = {
3804 {
3805 .pa_start = 0x480d1000,
3806 .pa_end = 0x480d13ff,
3807 .flags = ADDR_TYPE_RT
3808 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003809 { }
Benoit Cousson407a6882011-02-15 22:39:48 +01003810};
3811
3812/* l4_per -> mmc4 */
3813static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc4 = {
3814 .master = &omap44xx_l4_per_hwmod,
3815 .slave = &omap44xx_mmc4_hwmod,
3816 .clk = "l4_div_ck",
3817 .addr = omap44xx_mmc4_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003818 .user = OCP_USER_MPU | OCP_USER_SDMA,
3819};
3820
3821/* mmc4 slave ports */
3822static struct omap_hwmod_ocp_if *omap44xx_mmc4_slaves[] = {
3823 &omap44xx_l4_per__mmc4,
3824};
3825
3826static struct omap_hwmod omap44xx_mmc4_hwmod = {
3827 .name = "mmc4",
3828 .class = &omap44xx_mmc_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003829 .clkdm_name = "l4_per_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01003830 .mpu_irqs = omap44xx_mmc4_irqs,
Paul Walmsley212738a2011-07-09 19:14:06 -06003831
Benoit Cousson407a6882011-02-15 22:39:48 +01003832 .sdma_reqs = omap44xx_mmc4_sdma_reqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003833 .main_clk = "mmc4_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -06003834 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01003835 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003836 .clkctrl_offs = OMAP4_CM_L4PER_MMCSD4_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003837 .context_offs = OMAP4_RM_L4PER_MMCSD4_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003838 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson407a6882011-02-15 22:39:48 +01003839 },
3840 },
3841 .slaves = omap44xx_mmc4_slaves,
3842 .slaves_cnt = ARRAY_SIZE(omap44xx_mmc4_slaves),
Benoit Cousson407a6882011-02-15 22:39:48 +01003843};
3844
3845/* mmc5 */
3846static struct omap_hwmod omap44xx_mmc5_hwmod;
3847static struct omap_hwmod_irq_info omap44xx_mmc5_irqs[] = {
3848 { .irq = 59 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003849 { .irq = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003850};
3851
3852static struct omap_hwmod_dma_info omap44xx_mmc5_sdma_reqs[] = {
3853 { .name = "tx", .dma_req = 58 + OMAP44XX_DMA_REQ_START },
3854 { .name = "rx", .dma_req = 59 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06003855 { .dma_req = -1 }
Benoit Cousson407a6882011-02-15 22:39:48 +01003856};
3857
3858static struct omap_hwmod_addr_space omap44xx_mmc5_addrs[] = {
3859 {
3860 .pa_start = 0x480d5000,
3861 .pa_end = 0x480d53ff,
3862 .flags = ADDR_TYPE_RT
3863 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003864 { }
Benoit Cousson407a6882011-02-15 22:39:48 +01003865};
3866
3867/* l4_per -> mmc5 */
3868static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc5 = {
3869 .master = &omap44xx_l4_per_hwmod,
3870 .slave = &omap44xx_mmc5_hwmod,
3871 .clk = "l4_div_ck",
3872 .addr = omap44xx_mmc5_addrs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003873 .user = OCP_USER_MPU | OCP_USER_SDMA,
3874};
3875
3876/* mmc5 slave ports */
3877static struct omap_hwmod_ocp_if *omap44xx_mmc5_slaves[] = {
3878 &omap44xx_l4_per__mmc5,
3879};
3880
3881static struct omap_hwmod omap44xx_mmc5_hwmod = {
3882 .name = "mmc5",
3883 .class = &omap44xx_mmc_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003884 .clkdm_name = "l4_per_clkdm",
Benoit Cousson407a6882011-02-15 22:39:48 +01003885 .mpu_irqs = omap44xx_mmc5_irqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003886 .sdma_reqs = omap44xx_mmc5_sdma_reqs,
Benoit Cousson407a6882011-02-15 22:39:48 +01003887 .main_clk = "mmc5_fck",
Benoit Cousson00fe6102011-07-09 19:14:28 -06003888 .prcm = {
Benoit Cousson407a6882011-02-15 22:39:48 +01003889 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003890 .clkctrl_offs = OMAP4_CM_L4PER_MMCSD5_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003891 .context_offs = OMAP4_RM_L4PER_MMCSD5_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06003892 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson407a6882011-02-15 22:39:48 +01003893 },
3894 },
3895 .slaves = omap44xx_mmc5_slaves,
3896 .slaves_cnt = ARRAY_SIZE(omap44xx_mmc5_slaves),
Benoit Cousson407a6882011-02-15 22:39:48 +01003897};
3898
3899/*
Benoit Cousson55d2cb02010-05-12 17:54:36 +02003900 * 'mpu' class
3901 * mpu sub-system
3902 */
3903
3904static struct omap_hwmod_class omap44xx_mpu_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +00003905 .name = "mpu",
Benoit Cousson55d2cb02010-05-12 17:54:36 +02003906};
3907
3908/* mpu */
3909static struct omap_hwmod_irq_info omap44xx_mpu_irqs[] = {
3910 { .name = "pl310", .irq = 0 + OMAP44XX_IRQ_GIC_START },
3911 { .name = "cti0", .irq = 1 + OMAP44XX_IRQ_GIC_START },
3912 { .name = "cti1", .irq = 2 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003913 { .irq = -1 }
Benoit Cousson55d2cb02010-05-12 17:54:36 +02003914};
3915
3916/* mpu master ports */
3917static struct omap_hwmod_ocp_if *omap44xx_mpu_masters[] = {
3918 &omap44xx_mpu__l3_main_1,
3919 &omap44xx_mpu__l4_abe,
3920 &omap44xx_mpu__dmm,
3921};
3922
3923static struct omap_hwmod omap44xx_mpu_hwmod = {
3924 .name = "mpu",
3925 .class = &omap44xx_mpu_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06003926 .clkdm_name = "mpuss_clkdm",
Benoit Cousson7ecc53732011-07-09 19:14:28 -06003927 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET,
Benoit Cousson55d2cb02010-05-12 17:54:36 +02003928 .mpu_irqs = omap44xx_mpu_irqs,
Benoit Cousson55d2cb02010-05-12 17:54:36 +02003929 .main_clk = "dpll_mpu_m2_ck",
3930 .prcm = {
3931 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06003932 .clkctrl_offs = OMAP4_CM_MPU_MPU_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06003933 .context_offs = OMAP4_RM_MPU_MPU_CONTEXT_OFFSET,
Benoit Cousson55d2cb02010-05-12 17:54:36 +02003934 },
3935 },
3936 .masters = omap44xx_mpu_masters,
3937 .masters_cnt = ARRAY_SIZE(omap44xx_mpu_masters),
Benoit Cousson55d2cb02010-05-12 17:54:36 +02003938};
3939
Benoit Cousson92b18d12010-09-23 20:02:41 +05303940/*
Benoit Cousson1f6a7172010-12-23 22:30:30 +00003941 * 'smartreflex' class
3942 * smartreflex module (monitor silicon performance and outputs a measure of
3943 * performance error)
3944 */
3945
3946/* The IP is not compliant to type1 / type2 scheme */
3947static struct omap_hwmod_sysc_fields omap_hwmod_sysc_type_smartreflex = {
3948 .sidle_shift = 24,
3949 .enwkup_shift = 26,
3950};
3951
3952static struct omap_hwmod_class_sysconfig omap44xx_smartreflex_sysc = {
3953 .sysc_offs = 0x0038,
3954 .sysc_flags = (SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE),
3955 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
3956 SIDLE_SMART_WKUP),
3957 .sysc_fields = &omap_hwmod_sysc_type_smartreflex,
3958};
3959
3960static struct omap_hwmod_class omap44xx_smartreflex_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +00003961 .name = "smartreflex",
3962 .sysc = &omap44xx_smartreflex_sysc,
3963 .rev = 2,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00003964};
3965
3966/* smartreflex_core */
Shweta Gulaticea6b942012-02-29 23:33:37 +01003967static struct omap_smartreflex_dev_attr smartreflex_core_dev_attr = {
3968 .sensor_voltdm_name = "core",
3969};
3970
Benoit Cousson1f6a7172010-12-23 22:30:30 +00003971static struct omap_hwmod omap44xx_smartreflex_core_hwmod;
3972static struct omap_hwmod_irq_info omap44xx_smartreflex_core_irqs[] = {
3973 { .irq = 19 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06003974 { .irq = -1 }
Benoit Cousson1f6a7172010-12-23 22:30:30 +00003975};
3976
3977static struct omap_hwmod_addr_space omap44xx_smartreflex_core_addrs[] = {
3978 {
3979 .pa_start = 0x4a0dd000,
3980 .pa_end = 0x4a0dd03f,
3981 .flags = ADDR_TYPE_RT
3982 },
Paul Walmsley78183f32011-07-09 19:14:05 -06003983 { }
Benoit Cousson1f6a7172010-12-23 22:30:30 +00003984};
3985
3986/* l4_cfg -> smartreflex_core */
3987static struct omap_hwmod_ocp_if omap44xx_l4_cfg__smartreflex_core = {
3988 .master = &omap44xx_l4_cfg_hwmod,
3989 .slave = &omap44xx_smartreflex_core_hwmod,
3990 .clk = "l4_div_ck",
3991 .addr = omap44xx_smartreflex_core_addrs,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00003992 .user = OCP_USER_MPU | OCP_USER_SDMA,
3993};
3994
3995/* smartreflex_core slave ports */
3996static struct omap_hwmod_ocp_if *omap44xx_smartreflex_core_slaves[] = {
3997 &omap44xx_l4_cfg__smartreflex_core,
3998};
3999
4000static struct omap_hwmod omap44xx_smartreflex_core_hwmod = {
4001 .name = "smartreflex_core",
4002 .class = &omap44xx_smartreflex_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004003 .clkdm_name = "l4_ao_clkdm",
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004004 .mpu_irqs = omap44xx_smartreflex_core_irqs,
Paul Walmsley212738a2011-07-09 19:14:06 -06004005
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004006 .main_clk = "smartreflex_core_fck",
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004007 .prcm = {
4008 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004009 .clkctrl_offs = OMAP4_CM_ALWON_SR_CORE_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004010 .context_offs = OMAP4_RM_ALWON_SR_CORE_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004011 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004012 },
4013 },
4014 .slaves = omap44xx_smartreflex_core_slaves,
4015 .slaves_cnt = ARRAY_SIZE(omap44xx_smartreflex_core_slaves),
Shweta Gulaticea6b942012-02-29 23:33:37 +01004016 .dev_attr = &smartreflex_core_dev_attr,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004017};
4018
4019/* smartreflex_iva */
Shweta Gulaticea6b942012-02-29 23:33:37 +01004020static struct omap_smartreflex_dev_attr smartreflex_iva_dev_attr = {
4021 .sensor_voltdm_name = "iva",
4022};
4023
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004024static struct omap_hwmod omap44xx_smartreflex_iva_hwmod;
4025static struct omap_hwmod_irq_info omap44xx_smartreflex_iva_irqs[] = {
4026 { .irq = 102 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004027 { .irq = -1 }
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004028};
4029
4030static struct omap_hwmod_addr_space omap44xx_smartreflex_iva_addrs[] = {
4031 {
4032 .pa_start = 0x4a0db000,
4033 .pa_end = 0x4a0db03f,
4034 .flags = ADDR_TYPE_RT
4035 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004036 { }
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004037};
4038
4039/* l4_cfg -> smartreflex_iva */
4040static struct omap_hwmod_ocp_if omap44xx_l4_cfg__smartreflex_iva = {
4041 .master = &omap44xx_l4_cfg_hwmod,
4042 .slave = &omap44xx_smartreflex_iva_hwmod,
4043 .clk = "l4_div_ck",
4044 .addr = omap44xx_smartreflex_iva_addrs,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004045 .user = OCP_USER_MPU | OCP_USER_SDMA,
4046};
4047
4048/* smartreflex_iva slave ports */
4049static struct omap_hwmod_ocp_if *omap44xx_smartreflex_iva_slaves[] = {
4050 &omap44xx_l4_cfg__smartreflex_iva,
4051};
4052
4053static struct omap_hwmod omap44xx_smartreflex_iva_hwmod = {
4054 .name = "smartreflex_iva",
4055 .class = &omap44xx_smartreflex_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004056 .clkdm_name = "l4_ao_clkdm",
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004057 .mpu_irqs = omap44xx_smartreflex_iva_irqs,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004058 .main_clk = "smartreflex_iva_fck",
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004059 .prcm = {
4060 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004061 .clkctrl_offs = OMAP4_CM_ALWON_SR_IVA_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004062 .context_offs = OMAP4_RM_ALWON_SR_IVA_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004063 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004064 },
4065 },
4066 .slaves = omap44xx_smartreflex_iva_slaves,
4067 .slaves_cnt = ARRAY_SIZE(omap44xx_smartreflex_iva_slaves),
Shweta Gulaticea6b942012-02-29 23:33:37 +01004068 .dev_attr = &smartreflex_iva_dev_attr,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004069};
4070
4071/* smartreflex_mpu */
Shweta Gulaticea6b942012-02-29 23:33:37 +01004072static struct omap_smartreflex_dev_attr smartreflex_mpu_dev_attr = {
4073 .sensor_voltdm_name = "mpu",
4074};
4075
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004076static struct omap_hwmod omap44xx_smartreflex_mpu_hwmod;
4077static struct omap_hwmod_irq_info omap44xx_smartreflex_mpu_irqs[] = {
4078 { .irq = 18 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004079 { .irq = -1 }
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004080};
4081
4082static struct omap_hwmod_addr_space omap44xx_smartreflex_mpu_addrs[] = {
4083 {
4084 .pa_start = 0x4a0d9000,
4085 .pa_end = 0x4a0d903f,
4086 .flags = ADDR_TYPE_RT
4087 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004088 { }
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004089};
4090
4091/* l4_cfg -> smartreflex_mpu */
4092static struct omap_hwmod_ocp_if omap44xx_l4_cfg__smartreflex_mpu = {
4093 .master = &omap44xx_l4_cfg_hwmod,
4094 .slave = &omap44xx_smartreflex_mpu_hwmod,
4095 .clk = "l4_div_ck",
4096 .addr = omap44xx_smartreflex_mpu_addrs,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004097 .user = OCP_USER_MPU | OCP_USER_SDMA,
4098};
4099
4100/* smartreflex_mpu slave ports */
4101static struct omap_hwmod_ocp_if *omap44xx_smartreflex_mpu_slaves[] = {
4102 &omap44xx_l4_cfg__smartreflex_mpu,
4103};
4104
4105static struct omap_hwmod omap44xx_smartreflex_mpu_hwmod = {
4106 .name = "smartreflex_mpu",
4107 .class = &omap44xx_smartreflex_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004108 .clkdm_name = "l4_ao_clkdm",
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004109 .mpu_irqs = omap44xx_smartreflex_mpu_irqs,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004110 .main_clk = "smartreflex_mpu_fck",
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004111 .prcm = {
4112 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004113 .clkctrl_offs = OMAP4_CM_ALWON_SR_MPU_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004114 .context_offs = OMAP4_RM_ALWON_SR_MPU_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004115 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004116 },
4117 },
4118 .slaves = omap44xx_smartreflex_mpu_slaves,
4119 .slaves_cnt = ARRAY_SIZE(omap44xx_smartreflex_mpu_slaves),
Shweta Gulaticea6b942012-02-29 23:33:37 +01004120 .dev_attr = &smartreflex_mpu_dev_attr,
Benoit Cousson1f6a7172010-12-23 22:30:30 +00004121};
4122
4123/*
Benoit Coussond11c2172011-02-02 12:04:36 +00004124 * 'spinlock' class
4125 * spinlock provides hardware assistance for synchronizing the processes
4126 * running on multiple processors
4127 */
4128
4129static struct omap_hwmod_class_sysconfig omap44xx_spinlock_sysc = {
4130 .rev_offs = 0x0000,
4131 .sysc_offs = 0x0010,
4132 .syss_offs = 0x0014,
4133 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
4134 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
4135 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
4136 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
4137 SIDLE_SMART_WKUP),
4138 .sysc_fields = &omap_hwmod_sysc_type1,
4139};
4140
4141static struct omap_hwmod_class omap44xx_spinlock_hwmod_class = {
4142 .name = "spinlock",
4143 .sysc = &omap44xx_spinlock_sysc,
4144};
4145
4146/* spinlock */
4147static struct omap_hwmod omap44xx_spinlock_hwmod;
4148static struct omap_hwmod_addr_space omap44xx_spinlock_addrs[] = {
4149 {
4150 .pa_start = 0x4a0f6000,
4151 .pa_end = 0x4a0f6fff,
4152 .flags = ADDR_TYPE_RT
4153 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004154 { }
Benoit Coussond11c2172011-02-02 12:04:36 +00004155};
4156
4157/* l4_cfg -> spinlock */
4158static struct omap_hwmod_ocp_if omap44xx_l4_cfg__spinlock = {
4159 .master = &omap44xx_l4_cfg_hwmod,
4160 .slave = &omap44xx_spinlock_hwmod,
4161 .clk = "l4_div_ck",
4162 .addr = omap44xx_spinlock_addrs,
Benoit Coussond11c2172011-02-02 12:04:36 +00004163 .user = OCP_USER_MPU | OCP_USER_SDMA,
4164};
4165
4166/* spinlock slave ports */
4167static struct omap_hwmod_ocp_if *omap44xx_spinlock_slaves[] = {
4168 &omap44xx_l4_cfg__spinlock,
4169};
4170
4171static struct omap_hwmod omap44xx_spinlock_hwmod = {
4172 .name = "spinlock",
4173 .class = &omap44xx_spinlock_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004174 .clkdm_name = "l4_cfg_clkdm",
Benoit Coussond11c2172011-02-02 12:04:36 +00004175 .prcm = {
4176 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004177 .clkctrl_offs = OMAP4_CM_L4CFG_HW_SEM_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004178 .context_offs = OMAP4_RM_L4CFG_HW_SEM_CONTEXT_OFFSET,
Benoit Coussond11c2172011-02-02 12:04:36 +00004179 },
4180 },
4181 .slaves = omap44xx_spinlock_slaves,
4182 .slaves_cnt = ARRAY_SIZE(omap44xx_spinlock_slaves),
Benoit Coussond11c2172011-02-02 12:04:36 +00004183};
4184
4185/*
Benoit Cousson35d1a662011-02-11 11:17:14 +00004186 * 'timer' class
4187 * general purpose timer module with accurate 1ms tick
4188 * This class contains several variants: ['timer_1ms', 'timer']
4189 */
4190
4191static struct omap_hwmod_class_sysconfig omap44xx_timer_1ms_sysc = {
4192 .rev_offs = 0x0000,
4193 .sysc_offs = 0x0010,
4194 .syss_offs = 0x0014,
4195 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
4196 SYSC_HAS_EMUFREE | SYSC_HAS_ENAWAKEUP |
4197 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
4198 SYSS_HAS_RESET_STATUS),
4199 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
4200 .sysc_fields = &omap_hwmod_sysc_type1,
4201};
4202
4203static struct omap_hwmod_class omap44xx_timer_1ms_hwmod_class = {
4204 .name = "timer",
4205 .sysc = &omap44xx_timer_1ms_sysc,
4206};
4207
4208static struct omap_hwmod_class_sysconfig omap44xx_timer_sysc = {
4209 .rev_offs = 0x0000,
4210 .sysc_offs = 0x0010,
4211 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
4212 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
4213 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
4214 SIDLE_SMART_WKUP),
4215 .sysc_fields = &omap_hwmod_sysc_type2,
4216};
4217
4218static struct omap_hwmod_class omap44xx_timer_hwmod_class = {
4219 .name = "timer",
4220 .sysc = &omap44xx_timer_sysc,
4221};
4222
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304223/* always-on timers dev attribute */
4224static struct omap_timer_capability_dev_attr capability_alwon_dev_attr = {
4225 .timer_capability = OMAP_TIMER_ALWON,
4226};
4227
4228/* pwm timers dev attribute */
4229static struct omap_timer_capability_dev_attr capability_pwm_dev_attr = {
4230 .timer_capability = OMAP_TIMER_HAS_PWM,
4231};
4232
Benoit Cousson35d1a662011-02-11 11:17:14 +00004233/* timer1 */
4234static struct omap_hwmod omap44xx_timer1_hwmod;
4235static struct omap_hwmod_irq_info omap44xx_timer1_irqs[] = {
4236 { .irq = 37 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004237 { .irq = -1 }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004238};
4239
4240static struct omap_hwmod_addr_space omap44xx_timer1_addrs[] = {
4241 {
4242 .pa_start = 0x4a318000,
4243 .pa_end = 0x4a31807f,
4244 .flags = ADDR_TYPE_RT
4245 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004246 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004247};
4248
4249/* l4_wkup -> timer1 */
4250static struct omap_hwmod_ocp_if omap44xx_l4_wkup__timer1 = {
4251 .master = &omap44xx_l4_wkup_hwmod,
4252 .slave = &omap44xx_timer1_hwmod,
4253 .clk = "l4_wkup_clk_mux_ck",
4254 .addr = omap44xx_timer1_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004255 .user = OCP_USER_MPU | OCP_USER_SDMA,
4256};
4257
4258/* timer1 slave ports */
4259static struct omap_hwmod_ocp_if *omap44xx_timer1_slaves[] = {
4260 &omap44xx_l4_wkup__timer1,
4261};
4262
4263static struct omap_hwmod omap44xx_timer1_hwmod = {
4264 .name = "timer1",
4265 .class = &omap44xx_timer_1ms_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004266 .clkdm_name = "l4_wkup_clkdm",
Benoit Cousson35d1a662011-02-11 11:17:14 +00004267 .mpu_irqs = omap44xx_timer1_irqs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004268 .main_clk = "timer1_fck",
4269 .prcm = {
4270 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004271 .clkctrl_offs = OMAP4_CM_WKUP_TIMER1_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004272 .context_offs = OMAP4_RM_WKUP_TIMER1_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004273 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004274 },
4275 },
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304276 .dev_attr = &capability_alwon_dev_attr,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004277 .slaves = omap44xx_timer1_slaves,
4278 .slaves_cnt = ARRAY_SIZE(omap44xx_timer1_slaves),
Benoit Cousson35d1a662011-02-11 11:17:14 +00004279};
4280
4281/* timer2 */
4282static struct omap_hwmod omap44xx_timer2_hwmod;
4283static struct omap_hwmod_irq_info omap44xx_timer2_irqs[] = {
4284 { .irq = 38 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004285 { .irq = -1 }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004286};
4287
4288static struct omap_hwmod_addr_space omap44xx_timer2_addrs[] = {
4289 {
4290 .pa_start = 0x48032000,
4291 .pa_end = 0x4803207f,
4292 .flags = ADDR_TYPE_RT
4293 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004294 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004295};
4296
4297/* l4_per -> timer2 */
4298static struct omap_hwmod_ocp_if omap44xx_l4_per__timer2 = {
4299 .master = &omap44xx_l4_per_hwmod,
4300 .slave = &omap44xx_timer2_hwmod,
4301 .clk = "l4_div_ck",
4302 .addr = omap44xx_timer2_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004303 .user = OCP_USER_MPU | OCP_USER_SDMA,
4304};
4305
4306/* timer2 slave ports */
4307static struct omap_hwmod_ocp_if *omap44xx_timer2_slaves[] = {
4308 &omap44xx_l4_per__timer2,
4309};
4310
4311static struct omap_hwmod omap44xx_timer2_hwmod = {
4312 .name = "timer2",
4313 .class = &omap44xx_timer_1ms_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004314 .clkdm_name = "l4_per_clkdm",
Benoit Cousson35d1a662011-02-11 11:17:14 +00004315 .mpu_irqs = omap44xx_timer2_irqs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004316 .main_clk = "timer2_fck",
4317 .prcm = {
4318 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004319 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER2_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004320 .context_offs = OMAP4_RM_L4PER_DMTIMER2_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004321 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004322 },
4323 },
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304324 .dev_attr = &capability_alwon_dev_attr,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004325 .slaves = omap44xx_timer2_slaves,
4326 .slaves_cnt = ARRAY_SIZE(omap44xx_timer2_slaves),
Benoit Cousson35d1a662011-02-11 11:17:14 +00004327};
4328
4329/* timer3 */
4330static struct omap_hwmod omap44xx_timer3_hwmod;
4331static struct omap_hwmod_irq_info omap44xx_timer3_irqs[] = {
4332 { .irq = 39 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004333 { .irq = -1 }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004334};
4335
4336static struct omap_hwmod_addr_space omap44xx_timer3_addrs[] = {
4337 {
4338 .pa_start = 0x48034000,
4339 .pa_end = 0x4803407f,
4340 .flags = ADDR_TYPE_RT
4341 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004342 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004343};
4344
4345/* l4_per -> timer3 */
4346static struct omap_hwmod_ocp_if omap44xx_l4_per__timer3 = {
4347 .master = &omap44xx_l4_per_hwmod,
4348 .slave = &omap44xx_timer3_hwmod,
4349 .clk = "l4_div_ck",
4350 .addr = omap44xx_timer3_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004351 .user = OCP_USER_MPU | OCP_USER_SDMA,
4352};
4353
4354/* timer3 slave ports */
4355static struct omap_hwmod_ocp_if *omap44xx_timer3_slaves[] = {
4356 &omap44xx_l4_per__timer3,
4357};
4358
4359static struct omap_hwmod omap44xx_timer3_hwmod = {
4360 .name = "timer3",
4361 .class = &omap44xx_timer_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004362 .clkdm_name = "l4_per_clkdm",
Benoit Cousson35d1a662011-02-11 11:17:14 +00004363 .mpu_irqs = omap44xx_timer3_irqs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004364 .main_clk = "timer3_fck",
4365 .prcm = {
4366 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004367 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER3_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004368 .context_offs = OMAP4_RM_L4PER_DMTIMER3_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004369 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004370 },
4371 },
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304372 .dev_attr = &capability_alwon_dev_attr,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004373 .slaves = omap44xx_timer3_slaves,
4374 .slaves_cnt = ARRAY_SIZE(omap44xx_timer3_slaves),
Benoit Cousson35d1a662011-02-11 11:17:14 +00004375};
4376
4377/* timer4 */
4378static struct omap_hwmod omap44xx_timer4_hwmod;
4379static struct omap_hwmod_irq_info omap44xx_timer4_irqs[] = {
4380 { .irq = 40 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004381 { .irq = -1 }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004382};
4383
4384static struct omap_hwmod_addr_space omap44xx_timer4_addrs[] = {
4385 {
4386 .pa_start = 0x48036000,
4387 .pa_end = 0x4803607f,
4388 .flags = ADDR_TYPE_RT
4389 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004390 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004391};
4392
4393/* l4_per -> timer4 */
4394static struct omap_hwmod_ocp_if omap44xx_l4_per__timer4 = {
4395 .master = &omap44xx_l4_per_hwmod,
4396 .slave = &omap44xx_timer4_hwmod,
4397 .clk = "l4_div_ck",
4398 .addr = omap44xx_timer4_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004399 .user = OCP_USER_MPU | OCP_USER_SDMA,
4400};
4401
4402/* timer4 slave ports */
4403static struct omap_hwmod_ocp_if *omap44xx_timer4_slaves[] = {
4404 &omap44xx_l4_per__timer4,
4405};
4406
4407static struct omap_hwmod omap44xx_timer4_hwmod = {
4408 .name = "timer4",
4409 .class = &omap44xx_timer_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004410 .clkdm_name = "l4_per_clkdm",
Benoit Cousson35d1a662011-02-11 11:17:14 +00004411 .mpu_irqs = omap44xx_timer4_irqs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004412 .main_clk = "timer4_fck",
4413 .prcm = {
4414 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004415 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER4_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004416 .context_offs = OMAP4_RM_L4PER_DMTIMER4_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004417 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004418 },
4419 },
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304420 .dev_attr = &capability_alwon_dev_attr,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004421 .slaves = omap44xx_timer4_slaves,
4422 .slaves_cnt = ARRAY_SIZE(omap44xx_timer4_slaves),
Benoit Cousson35d1a662011-02-11 11:17:14 +00004423};
4424
4425/* timer5 */
4426static struct omap_hwmod omap44xx_timer5_hwmod;
4427static struct omap_hwmod_irq_info omap44xx_timer5_irqs[] = {
4428 { .irq = 41 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004429 { .irq = -1 }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004430};
4431
4432static struct omap_hwmod_addr_space omap44xx_timer5_addrs[] = {
4433 {
4434 .pa_start = 0x40138000,
4435 .pa_end = 0x4013807f,
4436 .flags = ADDR_TYPE_RT
4437 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004438 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004439};
4440
4441/* l4_abe -> timer5 */
4442static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer5 = {
4443 .master = &omap44xx_l4_abe_hwmod,
4444 .slave = &omap44xx_timer5_hwmod,
4445 .clk = "ocp_abe_iclk",
4446 .addr = omap44xx_timer5_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004447 .user = OCP_USER_MPU,
4448};
4449
4450static struct omap_hwmod_addr_space omap44xx_timer5_dma_addrs[] = {
4451 {
4452 .pa_start = 0x49038000,
4453 .pa_end = 0x4903807f,
4454 .flags = ADDR_TYPE_RT
4455 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004456 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004457};
4458
4459/* l4_abe -> timer5 (dma) */
4460static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer5_dma = {
4461 .master = &omap44xx_l4_abe_hwmod,
4462 .slave = &omap44xx_timer5_hwmod,
4463 .clk = "ocp_abe_iclk",
4464 .addr = omap44xx_timer5_dma_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004465 .user = OCP_USER_SDMA,
4466};
4467
4468/* timer5 slave ports */
4469static struct omap_hwmod_ocp_if *omap44xx_timer5_slaves[] = {
4470 &omap44xx_l4_abe__timer5,
4471 &omap44xx_l4_abe__timer5_dma,
4472};
4473
4474static struct omap_hwmod omap44xx_timer5_hwmod = {
4475 .name = "timer5",
4476 .class = &omap44xx_timer_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004477 .clkdm_name = "abe_clkdm",
Benoit Cousson35d1a662011-02-11 11:17:14 +00004478 .mpu_irqs = omap44xx_timer5_irqs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004479 .main_clk = "timer5_fck",
4480 .prcm = {
4481 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004482 .clkctrl_offs = OMAP4_CM1_ABE_TIMER5_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004483 .context_offs = OMAP4_RM_ABE_TIMER5_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004484 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004485 },
4486 },
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304487 .dev_attr = &capability_alwon_dev_attr,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004488 .slaves = omap44xx_timer5_slaves,
4489 .slaves_cnt = ARRAY_SIZE(omap44xx_timer5_slaves),
Benoit Cousson35d1a662011-02-11 11:17:14 +00004490};
4491
4492/* timer6 */
4493static struct omap_hwmod omap44xx_timer6_hwmod;
4494static struct omap_hwmod_irq_info omap44xx_timer6_irqs[] = {
4495 { .irq = 42 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004496 { .irq = -1 }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004497};
4498
4499static struct omap_hwmod_addr_space omap44xx_timer6_addrs[] = {
4500 {
4501 .pa_start = 0x4013a000,
4502 .pa_end = 0x4013a07f,
4503 .flags = ADDR_TYPE_RT
4504 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004505 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004506};
4507
4508/* l4_abe -> timer6 */
4509static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer6 = {
4510 .master = &omap44xx_l4_abe_hwmod,
4511 .slave = &omap44xx_timer6_hwmod,
4512 .clk = "ocp_abe_iclk",
4513 .addr = omap44xx_timer6_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004514 .user = OCP_USER_MPU,
4515};
4516
4517static struct omap_hwmod_addr_space omap44xx_timer6_dma_addrs[] = {
4518 {
4519 .pa_start = 0x4903a000,
4520 .pa_end = 0x4903a07f,
4521 .flags = ADDR_TYPE_RT
4522 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004523 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004524};
4525
4526/* l4_abe -> timer6 (dma) */
4527static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer6_dma = {
4528 .master = &omap44xx_l4_abe_hwmod,
4529 .slave = &omap44xx_timer6_hwmod,
4530 .clk = "ocp_abe_iclk",
4531 .addr = omap44xx_timer6_dma_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004532 .user = OCP_USER_SDMA,
4533};
4534
4535/* timer6 slave ports */
4536static struct omap_hwmod_ocp_if *omap44xx_timer6_slaves[] = {
4537 &omap44xx_l4_abe__timer6,
4538 &omap44xx_l4_abe__timer6_dma,
4539};
4540
4541static struct omap_hwmod omap44xx_timer6_hwmod = {
4542 .name = "timer6",
4543 .class = &omap44xx_timer_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004544 .clkdm_name = "abe_clkdm",
Benoit Cousson35d1a662011-02-11 11:17:14 +00004545 .mpu_irqs = omap44xx_timer6_irqs,
Paul Walmsley212738a2011-07-09 19:14:06 -06004546
Benoit Cousson35d1a662011-02-11 11:17:14 +00004547 .main_clk = "timer6_fck",
4548 .prcm = {
4549 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004550 .clkctrl_offs = OMAP4_CM1_ABE_TIMER6_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004551 .context_offs = OMAP4_RM_ABE_TIMER6_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004552 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004553 },
4554 },
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304555 .dev_attr = &capability_alwon_dev_attr,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004556 .slaves = omap44xx_timer6_slaves,
4557 .slaves_cnt = ARRAY_SIZE(omap44xx_timer6_slaves),
Benoit Cousson35d1a662011-02-11 11:17:14 +00004558};
4559
4560/* timer7 */
4561static struct omap_hwmod omap44xx_timer7_hwmod;
4562static struct omap_hwmod_irq_info omap44xx_timer7_irqs[] = {
4563 { .irq = 43 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004564 { .irq = -1 }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004565};
4566
4567static struct omap_hwmod_addr_space omap44xx_timer7_addrs[] = {
4568 {
4569 .pa_start = 0x4013c000,
4570 .pa_end = 0x4013c07f,
4571 .flags = ADDR_TYPE_RT
4572 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004573 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004574};
4575
4576/* l4_abe -> timer7 */
4577static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer7 = {
4578 .master = &omap44xx_l4_abe_hwmod,
4579 .slave = &omap44xx_timer7_hwmod,
4580 .clk = "ocp_abe_iclk",
4581 .addr = omap44xx_timer7_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004582 .user = OCP_USER_MPU,
4583};
4584
4585static struct omap_hwmod_addr_space omap44xx_timer7_dma_addrs[] = {
4586 {
4587 .pa_start = 0x4903c000,
4588 .pa_end = 0x4903c07f,
4589 .flags = ADDR_TYPE_RT
4590 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004591 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004592};
4593
4594/* l4_abe -> timer7 (dma) */
4595static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer7_dma = {
4596 .master = &omap44xx_l4_abe_hwmod,
4597 .slave = &omap44xx_timer7_hwmod,
4598 .clk = "ocp_abe_iclk",
4599 .addr = omap44xx_timer7_dma_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004600 .user = OCP_USER_SDMA,
4601};
4602
4603/* timer7 slave ports */
4604static struct omap_hwmod_ocp_if *omap44xx_timer7_slaves[] = {
4605 &omap44xx_l4_abe__timer7,
4606 &omap44xx_l4_abe__timer7_dma,
4607};
4608
4609static struct omap_hwmod omap44xx_timer7_hwmod = {
4610 .name = "timer7",
4611 .class = &omap44xx_timer_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004612 .clkdm_name = "abe_clkdm",
Benoit Cousson35d1a662011-02-11 11:17:14 +00004613 .mpu_irqs = omap44xx_timer7_irqs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004614 .main_clk = "timer7_fck",
4615 .prcm = {
4616 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004617 .clkctrl_offs = OMAP4_CM1_ABE_TIMER7_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004618 .context_offs = OMAP4_RM_ABE_TIMER7_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004619 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004620 },
4621 },
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304622 .dev_attr = &capability_alwon_dev_attr,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004623 .slaves = omap44xx_timer7_slaves,
4624 .slaves_cnt = ARRAY_SIZE(omap44xx_timer7_slaves),
Benoit Cousson35d1a662011-02-11 11:17:14 +00004625};
4626
4627/* timer8 */
4628static struct omap_hwmod omap44xx_timer8_hwmod;
4629static struct omap_hwmod_irq_info omap44xx_timer8_irqs[] = {
4630 { .irq = 44 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004631 { .irq = -1 }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004632};
4633
4634static struct omap_hwmod_addr_space omap44xx_timer8_addrs[] = {
4635 {
4636 .pa_start = 0x4013e000,
4637 .pa_end = 0x4013e07f,
4638 .flags = ADDR_TYPE_RT
4639 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004640 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004641};
4642
4643/* l4_abe -> timer8 */
4644static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer8 = {
4645 .master = &omap44xx_l4_abe_hwmod,
4646 .slave = &omap44xx_timer8_hwmod,
4647 .clk = "ocp_abe_iclk",
4648 .addr = omap44xx_timer8_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004649 .user = OCP_USER_MPU,
4650};
4651
4652static struct omap_hwmod_addr_space omap44xx_timer8_dma_addrs[] = {
4653 {
4654 .pa_start = 0x4903e000,
4655 .pa_end = 0x4903e07f,
4656 .flags = ADDR_TYPE_RT
4657 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004658 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004659};
4660
4661/* l4_abe -> timer8 (dma) */
4662static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer8_dma = {
4663 .master = &omap44xx_l4_abe_hwmod,
4664 .slave = &omap44xx_timer8_hwmod,
4665 .clk = "ocp_abe_iclk",
4666 .addr = omap44xx_timer8_dma_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004667 .user = OCP_USER_SDMA,
4668};
4669
4670/* timer8 slave ports */
4671static struct omap_hwmod_ocp_if *omap44xx_timer8_slaves[] = {
4672 &omap44xx_l4_abe__timer8,
4673 &omap44xx_l4_abe__timer8_dma,
4674};
4675
4676static struct omap_hwmod omap44xx_timer8_hwmod = {
4677 .name = "timer8",
4678 .class = &omap44xx_timer_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004679 .clkdm_name = "abe_clkdm",
Benoit Cousson35d1a662011-02-11 11:17:14 +00004680 .mpu_irqs = omap44xx_timer8_irqs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004681 .main_clk = "timer8_fck",
4682 .prcm = {
4683 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004684 .clkctrl_offs = OMAP4_CM1_ABE_TIMER8_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004685 .context_offs = OMAP4_RM_ABE_TIMER8_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004686 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004687 },
4688 },
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304689 .dev_attr = &capability_pwm_dev_attr,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004690 .slaves = omap44xx_timer8_slaves,
4691 .slaves_cnt = ARRAY_SIZE(omap44xx_timer8_slaves),
Benoit Cousson35d1a662011-02-11 11:17:14 +00004692};
4693
4694/* timer9 */
4695static struct omap_hwmod omap44xx_timer9_hwmod;
4696static struct omap_hwmod_irq_info omap44xx_timer9_irqs[] = {
4697 { .irq = 45 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004698 { .irq = -1 }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004699};
4700
4701static struct omap_hwmod_addr_space omap44xx_timer9_addrs[] = {
4702 {
4703 .pa_start = 0x4803e000,
4704 .pa_end = 0x4803e07f,
4705 .flags = ADDR_TYPE_RT
4706 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004707 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004708};
4709
4710/* l4_per -> timer9 */
4711static struct omap_hwmod_ocp_if omap44xx_l4_per__timer9 = {
4712 .master = &omap44xx_l4_per_hwmod,
4713 .slave = &omap44xx_timer9_hwmod,
4714 .clk = "l4_div_ck",
4715 .addr = omap44xx_timer9_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004716 .user = OCP_USER_MPU | OCP_USER_SDMA,
4717};
4718
4719/* timer9 slave ports */
4720static struct omap_hwmod_ocp_if *omap44xx_timer9_slaves[] = {
4721 &omap44xx_l4_per__timer9,
4722};
4723
4724static struct omap_hwmod omap44xx_timer9_hwmod = {
4725 .name = "timer9",
4726 .class = &omap44xx_timer_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004727 .clkdm_name = "l4_per_clkdm",
Benoit Cousson35d1a662011-02-11 11:17:14 +00004728 .mpu_irqs = omap44xx_timer9_irqs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004729 .main_clk = "timer9_fck",
4730 .prcm = {
4731 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004732 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER9_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004733 .context_offs = OMAP4_RM_L4PER_DMTIMER9_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004734 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004735 },
4736 },
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304737 .dev_attr = &capability_pwm_dev_attr,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004738 .slaves = omap44xx_timer9_slaves,
4739 .slaves_cnt = ARRAY_SIZE(omap44xx_timer9_slaves),
Benoit Cousson35d1a662011-02-11 11:17:14 +00004740};
4741
4742/* timer10 */
4743static struct omap_hwmod omap44xx_timer10_hwmod;
4744static struct omap_hwmod_irq_info omap44xx_timer10_irqs[] = {
4745 { .irq = 46 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004746 { .irq = -1 }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004747};
4748
4749static struct omap_hwmod_addr_space omap44xx_timer10_addrs[] = {
4750 {
4751 .pa_start = 0x48086000,
4752 .pa_end = 0x4808607f,
4753 .flags = ADDR_TYPE_RT
4754 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004755 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004756};
4757
4758/* l4_per -> timer10 */
4759static struct omap_hwmod_ocp_if omap44xx_l4_per__timer10 = {
4760 .master = &omap44xx_l4_per_hwmod,
4761 .slave = &omap44xx_timer10_hwmod,
4762 .clk = "l4_div_ck",
4763 .addr = omap44xx_timer10_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004764 .user = OCP_USER_MPU | OCP_USER_SDMA,
4765};
4766
4767/* timer10 slave ports */
4768static struct omap_hwmod_ocp_if *omap44xx_timer10_slaves[] = {
4769 &omap44xx_l4_per__timer10,
4770};
4771
4772static struct omap_hwmod omap44xx_timer10_hwmod = {
4773 .name = "timer10",
4774 .class = &omap44xx_timer_1ms_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004775 .clkdm_name = "l4_per_clkdm",
Benoit Cousson35d1a662011-02-11 11:17:14 +00004776 .mpu_irqs = omap44xx_timer10_irqs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004777 .main_clk = "timer10_fck",
4778 .prcm = {
4779 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004780 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER10_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004781 .context_offs = OMAP4_RM_L4PER_DMTIMER10_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004782 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004783 },
4784 },
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304785 .dev_attr = &capability_pwm_dev_attr,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004786 .slaves = omap44xx_timer10_slaves,
4787 .slaves_cnt = ARRAY_SIZE(omap44xx_timer10_slaves),
Benoit Cousson35d1a662011-02-11 11:17:14 +00004788};
4789
4790/* timer11 */
4791static struct omap_hwmod omap44xx_timer11_hwmod;
4792static struct omap_hwmod_irq_info omap44xx_timer11_irqs[] = {
4793 { .irq = 47 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004794 { .irq = -1 }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004795};
4796
4797static struct omap_hwmod_addr_space omap44xx_timer11_addrs[] = {
4798 {
4799 .pa_start = 0x48088000,
4800 .pa_end = 0x4808807f,
4801 .flags = ADDR_TYPE_RT
4802 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004803 { }
Benoit Cousson35d1a662011-02-11 11:17:14 +00004804};
4805
4806/* l4_per -> timer11 */
4807static struct omap_hwmod_ocp_if omap44xx_l4_per__timer11 = {
4808 .master = &omap44xx_l4_per_hwmod,
4809 .slave = &omap44xx_timer11_hwmod,
4810 .clk = "l4_div_ck",
4811 .addr = omap44xx_timer11_addrs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004812 .user = OCP_USER_MPU | OCP_USER_SDMA,
4813};
4814
4815/* timer11 slave ports */
4816static struct omap_hwmod_ocp_if *omap44xx_timer11_slaves[] = {
4817 &omap44xx_l4_per__timer11,
4818};
4819
4820static struct omap_hwmod omap44xx_timer11_hwmod = {
4821 .name = "timer11",
4822 .class = &omap44xx_timer_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004823 .clkdm_name = "l4_per_clkdm",
Benoit Cousson35d1a662011-02-11 11:17:14 +00004824 .mpu_irqs = omap44xx_timer11_irqs,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004825 .main_clk = "timer11_fck",
4826 .prcm = {
4827 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004828 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER11_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004829 .context_offs = OMAP4_RM_L4PER_DMTIMER11_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004830 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004831 },
4832 },
Tarun Kanti DebBarmac345c8b2011-09-20 17:00:18 +05304833 .dev_attr = &capability_pwm_dev_attr,
Benoit Cousson35d1a662011-02-11 11:17:14 +00004834 .slaves = omap44xx_timer11_slaves,
4835 .slaves_cnt = ARRAY_SIZE(omap44xx_timer11_slaves),
Benoit Cousson35d1a662011-02-11 11:17:14 +00004836};
4837
4838/*
Benoit Coussondb12ba52010-09-27 20:19:19 +05304839 * 'uart' class
4840 * universal asynchronous receiver/transmitter (uart)
4841 */
4842
4843static struct omap_hwmod_class_sysconfig omap44xx_uart_sysc = {
4844 .rev_offs = 0x0050,
4845 .sysc_offs = 0x0054,
4846 .syss_offs = 0x0058,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07004847 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
Benoit Cousson0cfe8752010-12-21 21:08:33 -07004848 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
4849 SYSS_HAS_RESET_STATUS),
Benoit Cousson7cffa6b2010-12-21 21:31:28 -07004850 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
4851 SIDLE_SMART_WKUP),
Benoit Coussondb12ba52010-09-27 20:19:19 +05304852 .sysc_fields = &omap_hwmod_sysc_type1,
4853};
4854
4855static struct omap_hwmod_class omap44xx_uart_hwmod_class = {
Benoit Coussonfe134712010-12-23 22:30:32 +00004856 .name = "uart",
4857 .sysc = &omap44xx_uart_sysc,
Benoit Coussondb12ba52010-09-27 20:19:19 +05304858};
4859
4860/* uart1 */
4861static struct omap_hwmod omap44xx_uart1_hwmod;
4862static struct omap_hwmod_irq_info omap44xx_uart1_irqs[] = {
4863 { .irq = 72 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004864 { .irq = -1 }
Benoit Coussondb12ba52010-09-27 20:19:19 +05304865};
4866
4867static struct omap_hwmod_dma_info omap44xx_uart1_sdma_reqs[] = {
4868 { .name = "tx", .dma_req = 48 + OMAP44XX_DMA_REQ_START },
4869 { .name = "rx", .dma_req = 49 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06004870 { .dma_req = -1 }
Benoit Coussondb12ba52010-09-27 20:19:19 +05304871};
4872
4873static struct omap_hwmod_addr_space omap44xx_uart1_addrs[] = {
4874 {
4875 .pa_start = 0x4806a000,
4876 .pa_end = 0x4806a0ff,
4877 .flags = ADDR_TYPE_RT
4878 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004879 { }
Benoit Coussondb12ba52010-09-27 20:19:19 +05304880};
4881
4882/* l4_per -> uart1 */
4883static struct omap_hwmod_ocp_if omap44xx_l4_per__uart1 = {
4884 .master = &omap44xx_l4_per_hwmod,
4885 .slave = &omap44xx_uart1_hwmod,
4886 .clk = "l4_div_ck",
4887 .addr = omap44xx_uart1_addrs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05304888 .user = OCP_USER_MPU | OCP_USER_SDMA,
4889};
4890
4891/* uart1 slave ports */
4892static struct omap_hwmod_ocp_if *omap44xx_uart1_slaves[] = {
4893 &omap44xx_l4_per__uart1,
4894};
4895
4896static struct omap_hwmod omap44xx_uart1_hwmod = {
4897 .name = "uart1",
4898 .class = &omap44xx_uart_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004899 .clkdm_name = "l4_per_clkdm",
Benoit Coussondb12ba52010-09-27 20:19:19 +05304900 .mpu_irqs = omap44xx_uart1_irqs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05304901 .sdma_reqs = omap44xx_uart1_sdma_reqs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05304902 .main_clk = "uart1_fck",
4903 .prcm = {
4904 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004905 .clkctrl_offs = OMAP4_CM_L4PER_UART1_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004906 .context_offs = OMAP4_RM_L4PER_UART1_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004907 .modulemode = MODULEMODE_SWCTRL,
Benoit Coussondb12ba52010-09-27 20:19:19 +05304908 },
4909 },
4910 .slaves = omap44xx_uart1_slaves,
4911 .slaves_cnt = ARRAY_SIZE(omap44xx_uart1_slaves),
Benoit Coussondb12ba52010-09-27 20:19:19 +05304912};
4913
4914/* uart2 */
4915static struct omap_hwmod omap44xx_uart2_hwmod;
4916static struct omap_hwmod_irq_info omap44xx_uart2_irqs[] = {
4917 { .irq = 73 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004918 { .irq = -1 }
Benoit Coussondb12ba52010-09-27 20:19:19 +05304919};
4920
4921static struct omap_hwmod_dma_info omap44xx_uart2_sdma_reqs[] = {
4922 { .name = "tx", .dma_req = 50 + OMAP44XX_DMA_REQ_START },
4923 { .name = "rx", .dma_req = 51 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06004924 { .dma_req = -1 }
Benoit Coussondb12ba52010-09-27 20:19:19 +05304925};
4926
4927static struct omap_hwmod_addr_space omap44xx_uart2_addrs[] = {
4928 {
4929 .pa_start = 0x4806c000,
4930 .pa_end = 0x4806c0ff,
4931 .flags = ADDR_TYPE_RT
4932 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004933 { }
Benoit Coussondb12ba52010-09-27 20:19:19 +05304934};
4935
4936/* l4_per -> uart2 */
4937static struct omap_hwmod_ocp_if omap44xx_l4_per__uart2 = {
4938 .master = &omap44xx_l4_per_hwmod,
4939 .slave = &omap44xx_uart2_hwmod,
4940 .clk = "l4_div_ck",
4941 .addr = omap44xx_uart2_addrs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05304942 .user = OCP_USER_MPU | OCP_USER_SDMA,
4943};
4944
4945/* uart2 slave ports */
4946static struct omap_hwmod_ocp_if *omap44xx_uart2_slaves[] = {
4947 &omap44xx_l4_per__uart2,
4948};
4949
4950static struct omap_hwmod omap44xx_uart2_hwmod = {
4951 .name = "uart2",
4952 .class = &omap44xx_uart_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06004953 .clkdm_name = "l4_per_clkdm",
Benoit Coussondb12ba52010-09-27 20:19:19 +05304954 .mpu_irqs = omap44xx_uart2_irqs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05304955 .sdma_reqs = omap44xx_uart2_sdma_reqs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05304956 .main_clk = "uart2_fck",
4957 .prcm = {
4958 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06004959 .clkctrl_offs = OMAP4_CM_L4PER_UART2_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06004960 .context_offs = OMAP4_RM_L4PER_UART2_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06004961 .modulemode = MODULEMODE_SWCTRL,
Benoit Coussondb12ba52010-09-27 20:19:19 +05304962 },
4963 },
4964 .slaves = omap44xx_uart2_slaves,
4965 .slaves_cnt = ARRAY_SIZE(omap44xx_uart2_slaves),
Benoit Coussondb12ba52010-09-27 20:19:19 +05304966};
4967
4968/* uart3 */
4969static struct omap_hwmod omap44xx_uart3_hwmod;
4970static struct omap_hwmod_irq_info omap44xx_uart3_irqs[] = {
4971 { .irq = 74 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06004972 { .irq = -1 }
Benoit Coussondb12ba52010-09-27 20:19:19 +05304973};
4974
4975static struct omap_hwmod_dma_info omap44xx_uart3_sdma_reqs[] = {
4976 { .name = "tx", .dma_req = 52 + OMAP44XX_DMA_REQ_START },
4977 { .name = "rx", .dma_req = 53 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06004978 { .dma_req = -1 }
Benoit Coussondb12ba52010-09-27 20:19:19 +05304979};
4980
4981static struct omap_hwmod_addr_space omap44xx_uart3_addrs[] = {
4982 {
4983 .pa_start = 0x48020000,
4984 .pa_end = 0x480200ff,
4985 .flags = ADDR_TYPE_RT
4986 },
Paul Walmsley78183f32011-07-09 19:14:05 -06004987 { }
Benoit Coussondb12ba52010-09-27 20:19:19 +05304988};
4989
4990/* l4_per -> uart3 */
4991static struct omap_hwmod_ocp_if omap44xx_l4_per__uart3 = {
4992 .master = &omap44xx_l4_per_hwmod,
4993 .slave = &omap44xx_uart3_hwmod,
4994 .clk = "l4_div_ck",
4995 .addr = omap44xx_uart3_addrs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05304996 .user = OCP_USER_MPU | OCP_USER_SDMA,
4997};
4998
4999/* uart3 slave ports */
5000static struct omap_hwmod_ocp_if *omap44xx_uart3_slaves[] = {
5001 &omap44xx_l4_per__uart3,
5002};
5003
5004static struct omap_hwmod omap44xx_uart3_hwmod = {
5005 .name = "uart3",
5006 .class = &omap44xx_uart_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06005007 .clkdm_name = "l4_per_clkdm",
Benoit Cousson7ecc53732011-07-09 19:14:28 -06005008 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET,
Benoit Coussondb12ba52010-09-27 20:19:19 +05305009 .mpu_irqs = omap44xx_uart3_irqs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05305010 .sdma_reqs = omap44xx_uart3_sdma_reqs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05305011 .main_clk = "uart3_fck",
5012 .prcm = {
5013 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06005014 .clkctrl_offs = OMAP4_CM_L4PER_UART3_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06005015 .context_offs = OMAP4_RM_L4PER_UART3_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06005016 .modulemode = MODULEMODE_SWCTRL,
Benoit Coussondb12ba52010-09-27 20:19:19 +05305017 },
5018 },
5019 .slaves = omap44xx_uart3_slaves,
5020 .slaves_cnt = ARRAY_SIZE(omap44xx_uart3_slaves),
Benoit Coussondb12ba52010-09-27 20:19:19 +05305021};
5022
5023/* uart4 */
5024static struct omap_hwmod omap44xx_uart4_hwmod;
5025static struct omap_hwmod_irq_info omap44xx_uart4_irqs[] = {
5026 { .irq = 70 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06005027 { .irq = -1 }
Benoit Coussondb12ba52010-09-27 20:19:19 +05305028};
5029
5030static struct omap_hwmod_dma_info omap44xx_uart4_sdma_reqs[] = {
5031 { .name = "tx", .dma_req = 54 + OMAP44XX_DMA_REQ_START },
5032 { .name = "rx", .dma_req = 55 + OMAP44XX_DMA_REQ_START },
Paul Walmsleybc614952011-07-09 19:14:07 -06005033 { .dma_req = -1 }
Benoit Coussondb12ba52010-09-27 20:19:19 +05305034};
5035
5036static struct omap_hwmod_addr_space omap44xx_uart4_addrs[] = {
5037 {
5038 .pa_start = 0x4806e000,
5039 .pa_end = 0x4806e0ff,
5040 .flags = ADDR_TYPE_RT
5041 },
Paul Walmsley78183f32011-07-09 19:14:05 -06005042 { }
Benoit Coussondb12ba52010-09-27 20:19:19 +05305043};
5044
5045/* l4_per -> uart4 */
5046static struct omap_hwmod_ocp_if omap44xx_l4_per__uart4 = {
5047 .master = &omap44xx_l4_per_hwmod,
5048 .slave = &omap44xx_uart4_hwmod,
5049 .clk = "l4_div_ck",
5050 .addr = omap44xx_uart4_addrs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05305051 .user = OCP_USER_MPU | OCP_USER_SDMA,
5052};
5053
5054/* uart4 slave ports */
5055static struct omap_hwmod_ocp_if *omap44xx_uart4_slaves[] = {
5056 &omap44xx_l4_per__uart4,
5057};
5058
5059static struct omap_hwmod omap44xx_uart4_hwmod = {
5060 .name = "uart4",
5061 .class = &omap44xx_uart_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06005062 .clkdm_name = "l4_per_clkdm",
Benoit Coussondb12ba52010-09-27 20:19:19 +05305063 .mpu_irqs = omap44xx_uart4_irqs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05305064 .sdma_reqs = omap44xx_uart4_sdma_reqs,
Benoit Coussondb12ba52010-09-27 20:19:19 +05305065 .main_clk = "uart4_fck",
5066 .prcm = {
5067 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06005068 .clkctrl_offs = OMAP4_CM_L4PER_UART4_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06005069 .context_offs = OMAP4_RM_L4PER_UART4_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06005070 .modulemode = MODULEMODE_SWCTRL,
Benoit Coussondb12ba52010-09-27 20:19:19 +05305071 },
5072 },
5073 .slaves = omap44xx_uart4_slaves,
5074 .slaves_cnt = ARRAY_SIZE(omap44xx_uart4_slaves),
Benoit Coussondb12ba52010-09-27 20:19:19 +05305075};
5076
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005077/*
Benoit Cousson5844c4e2011-02-17 12:41:05 +00005078 * 'usb_otg_hs' class
5079 * high-speed on-the-go universal serial bus (usb_otg_hs) controller
5080 */
5081
5082static struct omap_hwmod_class_sysconfig omap44xx_usb_otg_hs_sysc = {
5083 .rev_offs = 0x0400,
5084 .sysc_offs = 0x0404,
5085 .syss_offs = 0x0408,
5086 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
5087 SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
5088 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
5089 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
5090 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
5091 MSTANDBY_SMART),
5092 .sysc_fields = &omap_hwmod_sysc_type1,
5093};
5094
5095static struct omap_hwmod_class omap44xx_usb_otg_hs_hwmod_class = {
Benoit Cousson00fe6102011-07-09 19:14:28 -06005096 .name = "usb_otg_hs",
5097 .sysc = &omap44xx_usb_otg_hs_sysc,
Benoit Cousson5844c4e2011-02-17 12:41:05 +00005098};
5099
5100/* usb_otg_hs */
5101static struct omap_hwmod_irq_info omap44xx_usb_otg_hs_irqs[] = {
5102 { .name = "mc", .irq = 92 + OMAP44XX_IRQ_GIC_START },
5103 { .name = "dma", .irq = 93 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06005104 { .irq = -1 }
Benoit Cousson5844c4e2011-02-17 12:41:05 +00005105};
5106
5107/* usb_otg_hs master ports */
5108static struct omap_hwmod_ocp_if *omap44xx_usb_otg_hs_masters[] = {
5109 &omap44xx_usb_otg_hs__l3_main_2,
5110};
5111
5112static struct omap_hwmod_addr_space omap44xx_usb_otg_hs_addrs[] = {
5113 {
5114 .pa_start = 0x4a0ab000,
5115 .pa_end = 0x4a0ab003,
5116 .flags = ADDR_TYPE_RT
5117 },
Paul Walmsley78183f32011-07-09 19:14:05 -06005118 { }
Benoit Cousson5844c4e2011-02-17 12:41:05 +00005119};
5120
5121/* l4_cfg -> usb_otg_hs */
5122static struct omap_hwmod_ocp_if omap44xx_l4_cfg__usb_otg_hs = {
5123 .master = &omap44xx_l4_cfg_hwmod,
5124 .slave = &omap44xx_usb_otg_hs_hwmod,
5125 .clk = "l4_div_ck",
5126 .addr = omap44xx_usb_otg_hs_addrs,
Benoit Cousson5844c4e2011-02-17 12:41:05 +00005127 .user = OCP_USER_MPU | OCP_USER_SDMA,
5128};
5129
5130/* usb_otg_hs slave ports */
5131static struct omap_hwmod_ocp_if *omap44xx_usb_otg_hs_slaves[] = {
5132 &omap44xx_l4_cfg__usb_otg_hs,
5133};
5134
5135static struct omap_hwmod_opt_clk usb_otg_hs_opt_clks[] = {
5136 { .role = "xclk", .clk = "usb_otg_hs_xclk" },
5137};
5138
5139static struct omap_hwmod omap44xx_usb_otg_hs_hwmod = {
5140 .name = "usb_otg_hs",
5141 .class = &omap44xx_usb_otg_hs_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06005142 .clkdm_name = "l3_init_clkdm",
Benoit Cousson5844c4e2011-02-17 12:41:05 +00005143 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
5144 .mpu_irqs = omap44xx_usb_otg_hs_irqs,
Benoit Cousson5844c4e2011-02-17 12:41:05 +00005145 .main_clk = "usb_otg_hs_ick",
5146 .prcm = {
5147 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06005148 .clkctrl_offs = OMAP4_CM_L3INIT_USB_OTG_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06005149 .context_offs = OMAP4_RM_L3INIT_USB_OTG_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06005150 .modulemode = MODULEMODE_HWCTRL,
Benoit Cousson5844c4e2011-02-17 12:41:05 +00005151 },
5152 },
5153 .opt_clks = usb_otg_hs_opt_clks,
Benoit Cousson00fe6102011-07-09 19:14:28 -06005154 .opt_clks_cnt = ARRAY_SIZE(usb_otg_hs_opt_clks),
Benoit Cousson5844c4e2011-02-17 12:41:05 +00005155 .slaves = omap44xx_usb_otg_hs_slaves,
5156 .slaves_cnt = ARRAY_SIZE(omap44xx_usb_otg_hs_slaves),
5157 .masters = omap44xx_usb_otg_hs_masters,
5158 .masters_cnt = ARRAY_SIZE(omap44xx_usb_otg_hs_masters),
Benoit Cousson5844c4e2011-02-17 12:41:05 +00005159};
5160
5161/*
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005162 * 'wd_timer' class
5163 * 32-bit watchdog upward counter that generates a pulse on the reset pin on
5164 * overflow condition
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005165 */
5166
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005167static struct omap_hwmod_class_sysconfig omap44xx_wd_timer_sysc = {
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005168 .rev_offs = 0x0000,
5169 .sysc_offs = 0x0010,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005170 .syss_offs = 0x0014,
5171 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_SIDLEMODE |
Benoit Cousson0cfe8752010-12-21 21:08:33 -07005172 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
Benoit Cousson7cffa6b2010-12-21 21:31:28 -07005173 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
5174 SIDLE_SMART_WKUP),
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005175 .sysc_fields = &omap_hwmod_sysc_type1,
5176};
5177
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005178static struct omap_hwmod_class omap44xx_wd_timer_hwmod_class = {
5179 .name = "wd_timer",
5180 .sysc = &omap44xx_wd_timer_sysc,
Benoit Coussonfe134712010-12-23 22:30:32 +00005181 .pre_shutdown = &omap2_wd_timer_disable,
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005182};
5183
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005184/* wd_timer2 */
5185static struct omap_hwmod omap44xx_wd_timer2_hwmod;
5186static struct omap_hwmod_irq_info omap44xx_wd_timer2_irqs[] = {
5187 { .irq = 80 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06005188 { .irq = -1 }
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005189};
5190
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005191static struct omap_hwmod_addr_space omap44xx_wd_timer2_addrs[] = {
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005192 {
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005193 .pa_start = 0x4a314000,
5194 .pa_end = 0x4a31407f,
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005195 .flags = ADDR_TYPE_RT
5196 },
Paul Walmsley78183f32011-07-09 19:14:05 -06005197 { }
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005198};
5199
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005200/* l4_wkup -> wd_timer2 */
5201static struct omap_hwmod_ocp_if omap44xx_l4_wkup__wd_timer2 = {
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005202 .master = &omap44xx_l4_wkup_hwmod,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005203 .slave = &omap44xx_wd_timer2_hwmod,
5204 .clk = "l4_wkup_clk_mux_ck",
5205 .addr = omap44xx_wd_timer2_addrs,
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005206 .user = OCP_USER_MPU | OCP_USER_SDMA,
5207};
5208
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005209/* wd_timer2 slave ports */
5210static struct omap_hwmod_ocp_if *omap44xx_wd_timer2_slaves[] = {
5211 &omap44xx_l4_wkup__wd_timer2,
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005212};
5213
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005214static struct omap_hwmod omap44xx_wd_timer2_hwmod = {
5215 .name = "wd_timer2",
5216 .class = &omap44xx_wd_timer_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06005217 .clkdm_name = "l4_wkup_clkdm",
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005218 .mpu_irqs = omap44xx_wd_timer2_irqs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005219 .main_clk = "wd_timer2_fck",
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005220 .prcm = {
5221 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06005222 .clkctrl_offs = OMAP4_CM_WKUP_WDT2_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06005223 .context_offs = OMAP4_RM_WKUP_WDT2_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06005224 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005225 },
5226 },
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005227 .slaves = omap44xx_wd_timer2_slaves,
5228 .slaves_cnt = ARRAY_SIZE(omap44xx_wd_timer2_slaves),
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005229};
5230
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005231/* wd_timer3 */
5232static struct omap_hwmod omap44xx_wd_timer3_hwmod;
5233static struct omap_hwmod_irq_info omap44xx_wd_timer3_irqs[] = {
5234 { .irq = 36 + OMAP44XX_IRQ_GIC_START },
Paul Walmsley212738a2011-07-09 19:14:06 -06005235 { .irq = -1 }
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005236};
5237
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005238static struct omap_hwmod_addr_space omap44xx_wd_timer3_addrs[] = {
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005239 {
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005240 .pa_start = 0x40130000,
5241 .pa_end = 0x4013007f,
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005242 .flags = ADDR_TYPE_RT
5243 },
Paul Walmsley78183f32011-07-09 19:14:05 -06005244 { }
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005245};
5246
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005247/* l4_abe -> wd_timer3 */
5248static struct omap_hwmod_ocp_if omap44xx_l4_abe__wd_timer3 = {
5249 .master = &omap44xx_l4_abe_hwmod,
5250 .slave = &omap44xx_wd_timer3_hwmod,
5251 .clk = "ocp_abe_iclk",
5252 .addr = omap44xx_wd_timer3_addrs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005253 .user = OCP_USER_MPU,
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005254};
5255
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005256static struct omap_hwmod_addr_space omap44xx_wd_timer3_dma_addrs[] = {
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005257 {
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005258 .pa_start = 0x49030000,
5259 .pa_end = 0x4903007f,
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005260 .flags = ADDR_TYPE_RT
5261 },
Paul Walmsley78183f32011-07-09 19:14:05 -06005262 { }
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005263};
5264
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005265/* l4_abe -> wd_timer3 (dma) */
5266static struct omap_hwmod_ocp_if omap44xx_l4_abe__wd_timer3_dma = {
5267 .master = &omap44xx_l4_abe_hwmod,
5268 .slave = &omap44xx_wd_timer3_hwmod,
5269 .clk = "ocp_abe_iclk",
5270 .addr = omap44xx_wd_timer3_dma_addrs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005271 .user = OCP_USER_SDMA,
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005272};
5273
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005274/* wd_timer3 slave ports */
5275static struct omap_hwmod_ocp_if *omap44xx_wd_timer3_slaves[] = {
5276 &omap44xx_l4_abe__wd_timer3,
5277 &omap44xx_l4_abe__wd_timer3_dma,
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005278};
5279
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005280static struct omap_hwmod omap44xx_wd_timer3_hwmod = {
5281 .name = "wd_timer3",
5282 .class = &omap44xx_wd_timer_hwmod_class,
Benoit Coussona5322c62011-07-10 05:56:29 -06005283 .clkdm_name = "abe_clkdm",
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005284 .mpu_irqs = omap44xx_wd_timer3_irqs,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005285 .main_clk = "wd_timer3_fck",
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005286 .prcm = {
5287 .omap4 = {
Benoit Coussond0f06312011-07-10 05:56:30 -06005288 .clkctrl_offs = OMAP4_CM1_ABE_WDT3_CLKCTRL_OFFSET,
Benoit Cousson27bb00b2011-07-10 05:56:32 -06005289 .context_offs = OMAP4_RM_ABE_WDT3_CONTEXT_OFFSET,
Benoit Cousson03fdefe52011-07-10 05:56:32 -06005290 .modulemode = MODULEMODE_SWCTRL,
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005291 },
5292 },
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005293 .slaves = omap44xx_wd_timer3_slaves,
5294 .slaves_cnt = ARRAY_SIZE(omap44xx_wd_timer3_slaves),
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005295};
5296
Benoit Coussonaf88fa92011-12-15 23:15:18 -07005297/*
5298 * 'usb_host_hs' class
5299 * high-speed multi-port usb host controller
5300 */
5301static struct omap_hwmod_ocp_if omap44xx_usb_host_hs__l3_main_2 = {
5302 .master = &omap44xx_usb_host_hs_hwmod,
5303 .slave = &omap44xx_l3_main_2_hwmod,
5304 .clk = "l3_div_ck",
5305 .user = OCP_USER_MPU | OCP_USER_SDMA,
5306};
5307
5308static struct omap_hwmod_class_sysconfig omap44xx_usb_host_hs_sysc = {
5309 .rev_offs = 0x0000,
5310 .sysc_offs = 0x0010,
5311 .syss_offs = 0x0014,
5312 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
5313 SYSC_HAS_SOFTRESET),
5314 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
5315 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
5316 MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
5317 .sysc_fields = &omap_hwmod_sysc_type2,
5318};
5319
5320static struct omap_hwmod_class omap44xx_usb_host_hs_hwmod_class = {
5321 .name = "usb_host_hs",
5322 .sysc = &omap44xx_usb_host_hs_sysc,
5323};
5324
5325static struct omap_hwmod_ocp_if *omap44xx_usb_host_hs_masters[] = {
5326 &omap44xx_usb_host_hs__l3_main_2,
5327};
5328
5329static struct omap_hwmod_addr_space omap44xx_usb_host_hs_addrs[] = {
5330 {
5331 .name = "uhh",
5332 .pa_start = 0x4a064000,
5333 .pa_end = 0x4a0647ff,
5334 .flags = ADDR_TYPE_RT
5335 },
5336 {
5337 .name = "ohci",
5338 .pa_start = 0x4a064800,
5339 .pa_end = 0x4a064bff,
5340 },
5341 {
5342 .name = "ehci",
5343 .pa_start = 0x4a064c00,
5344 .pa_end = 0x4a064fff,
5345 },
5346 {}
5347};
5348
5349static struct omap_hwmod_irq_info omap44xx_usb_host_hs_irqs[] = {
5350 { .name = "ohci-irq", .irq = 76 + OMAP44XX_IRQ_GIC_START },
5351 { .name = "ehci-irq", .irq = 77 + OMAP44XX_IRQ_GIC_START },
5352 { .irq = -1 }
5353};
5354
5355static struct omap_hwmod_ocp_if omap44xx_l4_cfg__usb_host_hs = {
5356 .master = &omap44xx_l4_cfg_hwmod,
5357 .slave = &omap44xx_usb_host_hs_hwmod,
5358 .clk = "l4_div_ck",
5359 .addr = omap44xx_usb_host_hs_addrs,
5360 .user = OCP_USER_MPU | OCP_USER_SDMA,
5361};
5362
5363static struct omap_hwmod_ocp_if *omap44xx_usb_host_hs_slaves[] = {
5364 &omap44xx_l4_cfg__usb_host_hs,
5365};
5366
5367static struct omap_hwmod omap44xx_usb_host_hs_hwmod = {
5368 .name = "usb_host_hs",
5369 .class = &omap44xx_usb_host_hs_hwmod_class,
5370 .clkdm_name = "l3_init_clkdm",
5371 .main_clk = "usb_host_hs_fck",
5372 .prcm = {
5373 .omap4 = {
5374 .clkctrl_offs = OMAP4_CM_L3INIT_USB_HOST_CLKCTRL_OFFSET,
5375 .context_offs = OMAP4_RM_L3INIT_USB_HOST_CONTEXT_OFFSET,
5376 .modulemode = MODULEMODE_SWCTRL,
5377 },
5378 },
5379 .mpu_irqs = omap44xx_usb_host_hs_irqs,
5380 .slaves = omap44xx_usb_host_hs_slaves,
5381 .slaves_cnt = ARRAY_SIZE(omap44xx_usb_host_hs_slaves),
5382 .masters = omap44xx_usb_host_hs_masters,
5383 .masters_cnt = ARRAY_SIZE(omap44xx_usb_host_hs_masters),
5384
5385 /*
5386 * Errata: USBHOST Configured In Smart-Idle Can Lead To a Deadlock
5387 * id: i660
5388 *
5389 * Description:
5390 * In the following configuration :
5391 * - USBHOST module is set to smart-idle mode
5392 * - PRCM asserts idle_req to the USBHOST module ( This typically
5393 * happens when the system is going to a low power mode : all ports
5394 * have been suspended, the master part of the USBHOST module has
5395 * entered the standby state, and SW has cut the functional clocks)
5396 * - an USBHOST interrupt occurs before the module is able to answer
5397 * idle_ack, typically a remote wakeup IRQ.
5398 * Then the USB HOST module will enter a deadlock situation where it
5399 * is no more accessible nor functional.
5400 *
5401 * Workaround:
5402 * Don't use smart idle; use only force idle, hence HWMOD_SWSUP_SIDLE
5403 */
5404
5405 /*
5406 * Errata: USB host EHCI may stall when entering smart-standby mode
5407 * Id: i571
5408 *
5409 * Description:
5410 * When the USBHOST module is set to smart-standby mode, and when it is
5411 * ready to enter the standby state (i.e. all ports are suspended and
5412 * all attached devices are in suspend mode), then it can wrongly assert
5413 * the Mstandby signal too early while there are still some residual OCP
5414 * transactions ongoing. If this condition occurs, the internal state
5415 * machine may go to an undefined state and the USB link may be stuck
5416 * upon the next resume.
5417 *
5418 * Workaround:
5419 * Don't use smart standby; use only force standby,
5420 * hence HWMOD_SWSUP_MSTANDBY
5421 */
5422
5423 /*
5424 * During system boot; If the hwmod framework resets the module
5425 * the module will have smart idle settings; which can lead to deadlock
5426 * (above Errata Id:i660); so, dont reset the module during boot;
5427 * Use HWMOD_INIT_NO_RESET.
5428 */
5429
5430 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
5431 HWMOD_INIT_NO_RESET,
5432};
5433
5434/*
5435 * 'usb_tll_hs' class
5436 * usb_tll_hs module is the adapter on the usb_host_hs ports
5437 */
5438static struct omap_hwmod_class_sysconfig omap44xx_usb_tll_hs_sysc = {
5439 .rev_offs = 0x0000,
5440 .sysc_offs = 0x0010,
5441 .syss_offs = 0x0014,
5442 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
5443 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
5444 SYSC_HAS_AUTOIDLE),
5445 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
5446 .sysc_fields = &omap_hwmod_sysc_type1,
5447};
5448
5449static struct omap_hwmod_class omap44xx_usb_tll_hs_hwmod_class = {
5450 .name = "usb_tll_hs",
5451 .sysc = &omap44xx_usb_tll_hs_sysc,
5452};
5453
5454static struct omap_hwmod_irq_info omap44xx_usb_tll_hs_irqs[] = {
5455 { .name = "tll-irq", .irq = 78 + OMAP44XX_IRQ_GIC_START },
5456 { .irq = -1 }
5457};
5458
5459static struct omap_hwmod_addr_space omap44xx_usb_tll_hs_addrs[] = {
5460 {
5461 .name = "tll",
5462 .pa_start = 0x4a062000,
5463 .pa_end = 0x4a063fff,
5464 .flags = ADDR_TYPE_RT
5465 },
5466 {}
5467};
5468
5469static struct omap_hwmod_ocp_if omap44xx_l4_cfg__usb_tll_hs = {
5470 .master = &omap44xx_l4_cfg_hwmod,
5471 .slave = &omap44xx_usb_tll_hs_hwmod,
5472 .clk = "l4_div_ck",
5473 .addr = omap44xx_usb_tll_hs_addrs,
5474 .user = OCP_USER_MPU | OCP_USER_SDMA,
5475};
5476
5477static struct omap_hwmod_ocp_if *omap44xx_usb_tll_hs_slaves[] = {
5478 &omap44xx_l4_cfg__usb_tll_hs,
5479};
5480
5481static struct omap_hwmod omap44xx_usb_tll_hs_hwmod = {
5482 .name = "usb_tll_hs",
5483 .class = &omap44xx_usb_tll_hs_hwmod_class,
5484 .clkdm_name = "l3_init_clkdm",
5485 .main_clk = "usb_tll_hs_ick",
5486 .prcm = {
5487 .omap4 = {
5488 .clkctrl_offs = OMAP4_CM_L3INIT_USB_TLL_CLKCTRL_OFFSET,
5489 .context_offs = OMAP4_RM_L3INIT_USB_TLL_CONTEXT_OFFSET,
5490 .modulemode = MODULEMODE_HWCTRL,
5491 },
5492 },
5493 .mpu_irqs = omap44xx_usb_tll_hs_irqs,
5494 .slaves = omap44xx_usb_tll_hs_slaves,
5495 .slaves_cnt = ARRAY_SIZE(omap44xx_usb_tll_hs_slaves),
5496};
5497
Benoit Cousson55d2cb02010-05-12 17:54:36 +02005498static __initdata struct omap_hwmod *omap44xx_hwmods[] = {
Benoit Coussonfe134712010-12-23 22:30:32 +00005499
Benoit Cousson55d2cb02010-05-12 17:54:36 +02005500 /* dmm class */
5501 &omap44xx_dmm_hwmod,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005502
Benoit Cousson55d2cb02010-05-12 17:54:36 +02005503 /* emif_fw class */
5504 &omap44xx_emif_fw_hwmod,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005505
Benoit Cousson55d2cb02010-05-12 17:54:36 +02005506 /* l3 class */
5507 &omap44xx_l3_instr_hwmod,
5508 &omap44xx_l3_main_1_hwmod,
5509 &omap44xx_l3_main_2_hwmod,
5510 &omap44xx_l3_main_3_hwmod,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005511
Benoit Cousson55d2cb02010-05-12 17:54:36 +02005512 /* l4 class */
5513 &omap44xx_l4_abe_hwmod,
5514 &omap44xx_l4_cfg_hwmod,
5515 &omap44xx_l4_per_hwmod,
5516 &omap44xx_l4_wkup_hwmod,
Benoit Cousson531ce0d2010-12-20 18:27:19 -08005517
Benoit Cousson55d2cb02010-05-12 17:54:36 +02005518 /* mpu_bus class */
5519 &omap44xx_mpu_private_hwmod,
5520
Benoit Cousson407a6882011-02-15 22:39:48 +01005521 /* aess class */
5522/* &omap44xx_aess_hwmod, */
5523
5524 /* bandgap class */
5525 &omap44xx_bandgap_hwmod,
5526
5527 /* counter class */
5528/* &omap44xx_counter_32k_hwmod, */
5529
Benoit Coussond7cf5f32010-12-23 22:30:31 +00005530 /* dma class */
5531 &omap44xx_dma_system_hwmod,
5532
Benoit Cousson8ca476d2011-01-25 22:01:00 +00005533 /* dmic class */
5534 &omap44xx_dmic_hwmod,
5535
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07005536 /* dsp class */
5537 &omap44xx_dsp_hwmod,
5538 &omap44xx_dsp_c0_hwmod,
5539
Benoit Coussond63bd742011-01-27 11:17:03 +00005540 /* dss class */
5541 &omap44xx_dss_hwmod,
5542 &omap44xx_dss_dispc_hwmod,
5543 &omap44xx_dss_dsi1_hwmod,
5544 &omap44xx_dss_dsi2_hwmod,
5545 &omap44xx_dss_hdmi_hwmod,
5546 &omap44xx_dss_rfbi_hwmod,
5547 &omap44xx_dss_venc_hwmod,
5548
Benoit Cousson9780a9c2010-12-07 16:26:57 -08005549 /* gpio class */
5550 &omap44xx_gpio1_hwmod,
5551 &omap44xx_gpio2_hwmod,
5552 &omap44xx_gpio3_hwmod,
5553 &omap44xx_gpio4_hwmod,
5554 &omap44xx_gpio5_hwmod,
5555 &omap44xx_gpio6_hwmod,
5556
Benoit Cousson407a6882011-02-15 22:39:48 +01005557 /* hsi class */
5558/* &omap44xx_hsi_hwmod, */
5559
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005560 /* i2c class */
5561 &omap44xx_i2c1_hwmod,
5562 &omap44xx_i2c2_hwmod,
5563 &omap44xx_i2c3_hwmod,
5564 &omap44xx_i2c4_hwmod,
5565
Benoit Cousson407a6882011-02-15 22:39:48 +01005566 /* ipu class */
5567 &omap44xx_ipu_hwmod,
5568 &omap44xx_ipu_c0_hwmod,
5569 &omap44xx_ipu_c1_hwmod,
5570
5571 /* iss class */
5572/* &omap44xx_iss_hwmod, */
5573
Benoit Cousson8f25bdc2010-12-21 21:08:34 -07005574 /* iva class */
5575 &omap44xx_iva_hwmod,
5576 &omap44xx_iva_seq0_hwmod,
5577 &omap44xx_iva_seq1_hwmod,
5578
Benoit Cousson407a6882011-02-15 22:39:48 +01005579 /* kbd class */
Shubhrajyoti D4998b2452011-05-04 14:57:44 -07005580 &omap44xx_kbd_hwmod,
Benoit Cousson407a6882011-02-15 22:39:48 +01005581
Benoit Coussonec5df922011-02-02 19:27:21 +00005582 /* mailbox class */
5583 &omap44xx_mailbox_hwmod,
5584
Benoit Cousson4ddff492011-01-31 14:50:30 +00005585 /* mcbsp class */
5586 &omap44xx_mcbsp1_hwmod,
5587 &omap44xx_mcbsp2_hwmod,
5588 &omap44xx_mcbsp3_hwmod,
5589 &omap44xx_mcbsp4_hwmod,
5590
Benoit Cousson407a6882011-02-15 22:39:48 +01005591 /* mcpdm class */
Peter Ujfalusid05e2ea2011-05-01 19:33:15 +01005592 &omap44xx_mcpdm_hwmod,
Benoit Cousson407a6882011-02-15 22:39:48 +01005593
Benoit Cousson9bcbd7f2011-02-02 17:52:13 +05305594 /* mcspi class */
5595 &omap44xx_mcspi1_hwmod,
5596 &omap44xx_mcspi2_hwmod,
5597 &omap44xx_mcspi3_hwmod,
5598 &omap44xx_mcspi4_hwmod,
5599
Benoit Cousson407a6882011-02-15 22:39:48 +01005600 /* mmc class */
Anand Gadiyar17203bd2011-03-01 13:12:56 -08005601 &omap44xx_mmc1_hwmod,
5602 &omap44xx_mmc2_hwmod,
5603 &omap44xx_mmc3_hwmod,
5604 &omap44xx_mmc4_hwmod,
5605 &omap44xx_mmc5_hwmod,
Benoit Cousson407a6882011-02-15 22:39:48 +01005606
Benoit Cousson55d2cb02010-05-12 17:54:36 +02005607 /* mpu class */
5608 &omap44xx_mpu_hwmod,
Benoit Coussondb12ba52010-09-27 20:19:19 +05305609
Benoit Cousson1f6a7172010-12-23 22:30:30 +00005610 /* smartreflex class */
5611 &omap44xx_smartreflex_core_hwmod,
5612 &omap44xx_smartreflex_iva_hwmod,
5613 &omap44xx_smartreflex_mpu_hwmod,
5614
Benoit Coussond11c2172011-02-02 12:04:36 +00005615 /* spinlock class */
5616 &omap44xx_spinlock_hwmod,
5617
Benoit Cousson35d1a662011-02-11 11:17:14 +00005618 /* timer class */
5619 &omap44xx_timer1_hwmod,
5620 &omap44xx_timer2_hwmod,
5621 &omap44xx_timer3_hwmod,
5622 &omap44xx_timer4_hwmod,
5623 &omap44xx_timer5_hwmod,
5624 &omap44xx_timer6_hwmod,
5625 &omap44xx_timer7_hwmod,
5626 &omap44xx_timer8_hwmod,
5627 &omap44xx_timer9_hwmod,
5628 &omap44xx_timer10_hwmod,
5629 &omap44xx_timer11_hwmod,
5630
Benoit Coussondb12ba52010-09-27 20:19:19 +05305631 /* uart class */
5632 &omap44xx_uart1_hwmod,
5633 &omap44xx_uart2_hwmod,
5634 &omap44xx_uart3_hwmod,
5635 &omap44xx_uart4_hwmod,
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005636
Benoit Coussonaf88fa92011-12-15 23:15:18 -07005637 /* usb host class */
5638 &omap44xx_usb_host_hs_hwmod,
5639 &omap44xx_usb_tll_hs_hwmod,
5640
Benoit Cousson5844c4e2011-02-17 12:41:05 +00005641 /* usb_otg_hs class */
5642 &omap44xx_usb_otg_hs_hwmod,
5643
Benoit Cousson3b54baa2010-12-21 21:08:33 -07005644 /* wd_timer class */
5645 &omap44xx_wd_timer2_hwmod,
5646 &omap44xx_wd_timer3_hwmod,
Benoit Cousson55d2cb02010-05-12 17:54:36 +02005647 NULL,
5648};
5649
5650int __init omap44xx_hwmod_init(void)
5651{
Paul Walmsley550c8092011-02-28 11:58:14 -07005652 return omap_hwmod_register(omap44xx_hwmods);
Benoit Cousson55d2cb02010-05-12 17:54:36 +02005653}
5654