Commit 972deb4f49b5b6703d9c6117ba0aeda2180d4447

Authored by Shubhrajyoti D
Committed by Wolfram Sang
1 parent 60937b2cdb

i2c: omap: Remove the OMAP_I2C_FLAG_RESET_REGS_POSTIDLE flag

The OMAP_I2C_FLAG_RESET_REGS_POSTIDLE is not used anymore
in the i2c driver. Remove the flag.

Signed-off-by: Shubhrajyoti D <shubhrajyoti@ti.com>
Reviewed-by: Felipe Balbi <balbi@ti.com>
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>

Showing 5 changed files with 6 additions and 13 deletions Inline Diff

arch/arm/mach-omap2/omap_hwmod_33xx_data.c
1 /* 1 /*
2 * omap_hwmod_33xx_data.c: Hardware modules present on the AM33XX chips 2 * omap_hwmod_33xx_data.c: Hardware modules present on the AM33XX chips
3 * 3 *
4 * Copyright (C) {2012} Texas Instruments Incorporated - http://www.ti.com/ 4 * Copyright (C) {2012} Texas Instruments Incorporated - http://www.ti.com/
5 * 5 *
6 * This file is automatically generated from the AM33XX hardware databases. 6 * This file is automatically generated from the AM33XX hardware databases.
7 * This program is free software; you can redistribute it and/or 7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License as 8 * modify it under the terms of the GNU General Public License as
9 * published by the Free Software Foundation version 2. 9 * published by the Free Software Foundation version 2.
10 * 10 *
11 * This program is distributed "as is" WITHOUT ANY WARRANTY of any 11 * This program is distributed "as is" WITHOUT ANY WARRANTY of any
12 * kind, whether express or implied; without even the implied warranty 12 * kind, whether express or implied; without even the implied warranty
13 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details. 14 * GNU General Public License for more details.
15 */ 15 */
16 16
17 #include <plat/omap_hwmod.h> 17 #include <plat/omap_hwmod.h>
18 #include <plat/cpu.h> 18 #include <plat/cpu.h>
19 #include <linux/platform_data/gpio-omap.h> 19 #include <linux/platform_data/gpio-omap.h>
20 #include <linux/platform_data/spi-omap2-mcspi.h> 20 #include <linux/platform_data/spi-omap2-mcspi.h>
21 #include <plat/dma.h> 21 #include <plat/dma.h>
22 #include <plat/mmc.h> 22 #include <plat/mmc.h>
23 #include <plat/i2c.h> 23 #include <plat/i2c.h>
24 24
25 #include "omap_hwmod_common_data.h" 25 #include "omap_hwmod_common_data.h"
26 26
27 #include "control.h" 27 #include "control.h"
28 #include "cm33xx.h" 28 #include "cm33xx.h"
29 #include "prm33xx.h" 29 #include "prm33xx.h"
30 #include "prm-regbits-33xx.h" 30 #include "prm-regbits-33xx.h"
31 31
32 /* 32 /*
33 * IP blocks 33 * IP blocks
34 */ 34 */
35 35
36 /* 36 /*
37 * 'emif_fw' class 37 * 'emif_fw' class
38 * instance(s): emif_fw 38 * instance(s): emif_fw
39 */ 39 */
40 static struct omap_hwmod_class am33xx_emif_fw_hwmod_class = { 40 static struct omap_hwmod_class am33xx_emif_fw_hwmod_class = {
41 .name = "emif_fw", 41 .name = "emif_fw",
42 }; 42 };
43 43
44 /* emif_fw */ 44 /* emif_fw */
45 static struct omap_hwmod am33xx_emif_fw_hwmod = { 45 static struct omap_hwmod am33xx_emif_fw_hwmod = {
46 .name = "emif_fw", 46 .name = "emif_fw",
47 .class = &am33xx_emif_fw_hwmod_class, 47 .class = &am33xx_emif_fw_hwmod_class,
48 .clkdm_name = "l4fw_clkdm", 48 .clkdm_name = "l4fw_clkdm",
49 .main_clk = "l4fw_gclk", 49 .main_clk = "l4fw_gclk",
50 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 50 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
51 .prcm = { 51 .prcm = {
52 .omap4 = { 52 .omap4 = {
53 .clkctrl_offs = AM33XX_CM_PER_EMIF_FW_CLKCTRL_OFFSET, 53 .clkctrl_offs = AM33XX_CM_PER_EMIF_FW_CLKCTRL_OFFSET,
54 .modulemode = MODULEMODE_SWCTRL, 54 .modulemode = MODULEMODE_SWCTRL,
55 }, 55 },
56 }, 56 },
57 }; 57 };
58 58
59 /* 59 /*
60 * 'emif' class 60 * 'emif' class
61 * instance(s): emif 61 * instance(s): emif
62 */ 62 */
63 static struct omap_hwmod_class_sysconfig am33xx_emif_sysc = { 63 static struct omap_hwmod_class_sysconfig am33xx_emif_sysc = {
64 .rev_offs = 0x0000, 64 .rev_offs = 0x0000,
65 }; 65 };
66 66
67 static struct omap_hwmod_class am33xx_emif_hwmod_class = { 67 static struct omap_hwmod_class am33xx_emif_hwmod_class = {
68 .name = "emif", 68 .name = "emif",
69 .sysc = &am33xx_emif_sysc, 69 .sysc = &am33xx_emif_sysc,
70 }; 70 };
71 71
72 static struct omap_hwmod_irq_info am33xx_emif_irqs[] = { 72 static struct omap_hwmod_irq_info am33xx_emif_irqs[] = {
73 { .name = "ddrerr0", .irq = 101 + OMAP_INTC_START, }, 73 { .name = "ddrerr0", .irq = 101 + OMAP_INTC_START, },
74 { .irq = -1 }, 74 { .irq = -1 },
75 }; 75 };
76 76
77 /* emif */ 77 /* emif */
78 static struct omap_hwmod am33xx_emif_hwmod = { 78 static struct omap_hwmod am33xx_emif_hwmod = {
79 .name = "emif", 79 .name = "emif",
80 .class = &am33xx_emif_hwmod_class, 80 .class = &am33xx_emif_hwmod_class,
81 .clkdm_name = "l3_clkdm", 81 .clkdm_name = "l3_clkdm",
82 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 82 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
83 .mpu_irqs = am33xx_emif_irqs, 83 .mpu_irqs = am33xx_emif_irqs,
84 .main_clk = "dpll_ddr_m2_div2_ck", 84 .main_clk = "dpll_ddr_m2_div2_ck",
85 .prcm = { 85 .prcm = {
86 .omap4 = { 86 .omap4 = {
87 .clkctrl_offs = AM33XX_CM_PER_EMIF_CLKCTRL_OFFSET, 87 .clkctrl_offs = AM33XX_CM_PER_EMIF_CLKCTRL_OFFSET,
88 .modulemode = MODULEMODE_SWCTRL, 88 .modulemode = MODULEMODE_SWCTRL,
89 }, 89 },
90 }, 90 },
91 }; 91 };
92 92
93 /* 93 /*
94 * 'l3' class 94 * 'l3' class
95 * instance(s): l3_main, l3_s, l3_instr 95 * instance(s): l3_main, l3_s, l3_instr
96 */ 96 */
97 static struct omap_hwmod_class am33xx_l3_hwmod_class = { 97 static struct omap_hwmod_class am33xx_l3_hwmod_class = {
98 .name = "l3", 98 .name = "l3",
99 }; 99 };
100 100
101 /* l3_main (l3_fast) */ 101 /* l3_main (l3_fast) */
102 static struct omap_hwmod_irq_info am33xx_l3_main_irqs[] = { 102 static struct omap_hwmod_irq_info am33xx_l3_main_irqs[] = {
103 { .name = "l3debug", .irq = 9 + OMAP_INTC_START, }, 103 { .name = "l3debug", .irq = 9 + OMAP_INTC_START, },
104 { .name = "l3appint", .irq = 10 + OMAP_INTC_START, }, 104 { .name = "l3appint", .irq = 10 + OMAP_INTC_START, },
105 { .irq = -1 }, 105 { .irq = -1 },
106 }; 106 };
107 107
108 static struct omap_hwmod am33xx_l3_main_hwmod = { 108 static struct omap_hwmod am33xx_l3_main_hwmod = {
109 .name = "l3_main", 109 .name = "l3_main",
110 .class = &am33xx_l3_hwmod_class, 110 .class = &am33xx_l3_hwmod_class,
111 .clkdm_name = "l3_clkdm", 111 .clkdm_name = "l3_clkdm",
112 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 112 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
113 .mpu_irqs = am33xx_l3_main_irqs, 113 .mpu_irqs = am33xx_l3_main_irqs,
114 .main_clk = "l3_gclk", 114 .main_clk = "l3_gclk",
115 .prcm = { 115 .prcm = {
116 .omap4 = { 116 .omap4 = {
117 .clkctrl_offs = AM33XX_CM_PER_L3_CLKCTRL_OFFSET, 117 .clkctrl_offs = AM33XX_CM_PER_L3_CLKCTRL_OFFSET,
118 .modulemode = MODULEMODE_SWCTRL, 118 .modulemode = MODULEMODE_SWCTRL,
119 }, 119 },
120 }, 120 },
121 }; 121 };
122 122
123 /* l3_s */ 123 /* l3_s */
124 static struct omap_hwmod am33xx_l3_s_hwmod = { 124 static struct omap_hwmod am33xx_l3_s_hwmod = {
125 .name = "l3_s", 125 .name = "l3_s",
126 .class = &am33xx_l3_hwmod_class, 126 .class = &am33xx_l3_hwmod_class,
127 .clkdm_name = "l3s_clkdm", 127 .clkdm_name = "l3s_clkdm",
128 }; 128 };
129 129
130 /* l3_instr */ 130 /* l3_instr */
131 static struct omap_hwmod am33xx_l3_instr_hwmod = { 131 static struct omap_hwmod am33xx_l3_instr_hwmod = {
132 .name = "l3_instr", 132 .name = "l3_instr",
133 .class = &am33xx_l3_hwmod_class, 133 .class = &am33xx_l3_hwmod_class,
134 .clkdm_name = "l3_clkdm", 134 .clkdm_name = "l3_clkdm",
135 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 135 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
136 .main_clk = "l3_gclk", 136 .main_clk = "l3_gclk",
137 .prcm = { 137 .prcm = {
138 .omap4 = { 138 .omap4 = {
139 .clkctrl_offs = AM33XX_CM_PER_L3_INSTR_CLKCTRL_OFFSET, 139 .clkctrl_offs = AM33XX_CM_PER_L3_INSTR_CLKCTRL_OFFSET,
140 .modulemode = MODULEMODE_SWCTRL, 140 .modulemode = MODULEMODE_SWCTRL,
141 }, 141 },
142 }, 142 },
143 }; 143 };
144 144
145 /* 145 /*
146 * 'l4' class 146 * 'l4' class
147 * instance(s): l4_ls, l4_hs, l4_wkup, l4_fw 147 * instance(s): l4_ls, l4_hs, l4_wkup, l4_fw
148 */ 148 */
149 static struct omap_hwmod_class am33xx_l4_hwmod_class = { 149 static struct omap_hwmod_class am33xx_l4_hwmod_class = {
150 .name = "l4", 150 .name = "l4",
151 }; 151 };
152 152
153 /* l4_ls */ 153 /* l4_ls */
154 static struct omap_hwmod am33xx_l4_ls_hwmod = { 154 static struct omap_hwmod am33xx_l4_ls_hwmod = {
155 .name = "l4_ls", 155 .name = "l4_ls",
156 .class = &am33xx_l4_hwmod_class, 156 .class = &am33xx_l4_hwmod_class,
157 .clkdm_name = "l4ls_clkdm", 157 .clkdm_name = "l4ls_clkdm",
158 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 158 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
159 .main_clk = "l4ls_gclk", 159 .main_clk = "l4ls_gclk",
160 .prcm = { 160 .prcm = {
161 .omap4 = { 161 .omap4 = {
162 .clkctrl_offs = AM33XX_CM_PER_L4LS_CLKCTRL_OFFSET, 162 .clkctrl_offs = AM33XX_CM_PER_L4LS_CLKCTRL_OFFSET,
163 .modulemode = MODULEMODE_SWCTRL, 163 .modulemode = MODULEMODE_SWCTRL,
164 }, 164 },
165 }, 165 },
166 }; 166 };
167 167
168 /* l4_hs */ 168 /* l4_hs */
169 static struct omap_hwmod am33xx_l4_hs_hwmod = { 169 static struct omap_hwmod am33xx_l4_hs_hwmod = {
170 .name = "l4_hs", 170 .name = "l4_hs",
171 .class = &am33xx_l4_hwmod_class, 171 .class = &am33xx_l4_hwmod_class,
172 .clkdm_name = "l4hs_clkdm", 172 .clkdm_name = "l4hs_clkdm",
173 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 173 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
174 .main_clk = "l4hs_gclk", 174 .main_clk = "l4hs_gclk",
175 .prcm = { 175 .prcm = {
176 .omap4 = { 176 .omap4 = {
177 .clkctrl_offs = AM33XX_CM_PER_L4HS_CLKCTRL_OFFSET, 177 .clkctrl_offs = AM33XX_CM_PER_L4HS_CLKCTRL_OFFSET,
178 .modulemode = MODULEMODE_SWCTRL, 178 .modulemode = MODULEMODE_SWCTRL,
179 }, 179 },
180 }, 180 },
181 }; 181 };
182 182
183 183
184 /* l4_wkup */ 184 /* l4_wkup */
185 static struct omap_hwmod am33xx_l4_wkup_hwmod = { 185 static struct omap_hwmod am33xx_l4_wkup_hwmod = {
186 .name = "l4_wkup", 186 .name = "l4_wkup",
187 .class = &am33xx_l4_hwmod_class, 187 .class = &am33xx_l4_hwmod_class,
188 .clkdm_name = "l4_wkup_clkdm", 188 .clkdm_name = "l4_wkup_clkdm",
189 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 189 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
190 .prcm = { 190 .prcm = {
191 .omap4 = { 191 .omap4 = {
192 .clkctrl_offs = AM33XX_CM_WKUP_L4WKUP_CLKCTRL_OFFSET, 192 .clkctrl_offs = AM33XX_CM_WKUP_L4WKUP_CLKCTRL_OFFSET,
193 .modulemode = MODULEMODE_SWCTRL, 193 .modulemode = MODULEMODE_SWCTRL,
194 }, 194 },
195 }, 195 },
196 }; 196 };
197 197
198 /* l4_fw */ 198 /* l4_fw */
199 static struct omap_hwmod am33xx_l4_fw_hwmod = { 199 static struct omap_hwmod am33xx_l4_fw_hwmod = {
200 .name = "l4_fw", 200 .name = "l4_fw",
201 .class = &am33xx_l4_hwmod_class, 201 .class = &am33xx_l4_hwmod_class,
202 .clkdm_name = "l4fw_clkdm", 202 .clkdm_name = "l4fw_clkdm",
203 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 203 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
204 .prcm = { 204 .prcm = {
205 .omap4 = { 205 .omap4 = {
206 .clkctrl_offs = AM33XX_CM_PER_L4FW_CLKCTRL_OFFSET, 206 .clkctrl_offs = AM33XX_CM_PER_L4FW_CLKCTRL_OFFSET,
207 .modulemode = MODULEMODE_SWCTRL, 207 .modulemode = MODULEMODE_SWCTRL,
208 }, 208 },
209 }, 209 },
210 }; 210 };
211 211
212 /* 212 /*
213 * 'mpu' class 213 * 'mpu' class
214 */ 214 */
215 static struct omap_hwmod_class am33xx_mpu_hwmod_class = { 215 static struct omap_hwmod_class am33xx_mpu_hwmod_class = {
216 .name = "mpu", 216 .name = "mpu",
217 }; 217 };
218 218
219 /* mpu */ 219 /* mpu */
220 static struct omap_hwmod_irq_info am33xx_mpu_irqs[] = { 220 static struct omap_hwmod_irq_info am33xx_mpu_irqs[] = {
221 { .name = "emuint", .irq = 0 + OMAP_INTC_START, }, 221 { .name = "emuint", .irq = 0 + OMAP_INTC_START, },
222 { .name = "commtx", .irq = 1 + OMAP_INTC_START, }, 222 { .name = "commtx", .irq = 1 + OMAP_INTC_START, },
223 { .name = "commrx", .irq = 2 + OMAP_INTC_START, }, 223 { .name = "commrx", .irq = 2 + OMAP_INTC_START, },
224 { .name = "bench", .irq = 3 + OMAP_INTC_START, }, 224 { .name = "bench", .irq = 3 + OMAP_INTC_START, },
225 { .irq = -1 }, 225 { .irq = -1 },
226 }; 226 };
227 227
228 static struct omap_hwmod am33xx_mpu_hwmod = { 228 static struct omap_hwmod am33xx_mpu_hwmod = {
229 .name = "mpu", 229 .name = "mpu",
230 .class = &am33xx_mpu_hwmod_class, 230 .class = &am33xx_mpu_hwmod_class,
231 .clkdm_name = "mpu_clkdm", 231 .clkdm_name = "mpu_clkdm",
232 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 232 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
233 .mpu_irqs = am33xx_mpu_irqs, 233 .mpu_irqs = am33xx_mpu_irqs,
234 .main_clk = "dpll_mpu_m2_ck", 234 .main_clk = "dpll_mpu_m2_ck",
235 .prcm = { 235 .prcm = {
236 .omap4 = { 236 .omap4 = {
237 .clkctrl_offs = AM33XX_CM_MPU_MPU_CLKCTRL_OFFSET, 237 .clkctrl_offs = AM33XX_CM_MPU_MPU_CLKCTRL_OFFSET,
238 .modulemode = MODULEMODE_SWCTRL, 238 .modulemode = MODULEMODE_SWCTRL,
239 }, 239 },
240 }, 240 },
241 }; 241 };
242 242
243 /* 243 /*
244 * 'wakeup m3' class 244 * 'wakeup m3' class
245 * Wakeup controller sub-system under wakeup domain 245 * Wakeup controller sub-system under wakeup domain
246 */ 246 */
247 static struct omap_hwmod_class am33xx_wkup_m3_hwmod_class = { 247 static struct omap_hwmod_class am33xx_wkup_m3_hwmod_class = {
248 .name = "wkup_m3", 248 .name = "wkup_m3",
249 }; 249 };
250 250
251 static struct omap_hwmod_rst_info am33xx_wkup_m3_resets[] = { 251 static struct omap_hwmod_rst_info am33xx_wkup_m3_resets[] = {
252 { .name = "wkup_m3", .rst_shift = 3, .st_shift = 5 }, 252 { .name = "wkup_m3", .rst_shift = 3, .st_shift = 5 },
253 }; 253 };
254 254
255 static struct omap_hwmod_irq_info am33xx_wkup_m3_irqs[] = { 255 static struct omap_hwmod_irq_info am33xx_wkup_m3_irqs[] = {
256 { .name = "txev", .irq = 78 + OMAP_INTC_START, }, 256 { .name = "txev", .irq = 78 + OMAP_INTC_START, },
257 { .irq = -1 }, 257 { .irq = -1 },
258 }; 258 };
259 259
260 /* wkup_m3 */ 260 /* wkup_m3 */
261 static struct omap_hwmod am33xx_wkup_m3_hwmod = { 261 static struct omap_hwmod am33xx_wkup_m3_hwmod = {
262 .name = "wkup_m3", 262 .name = "wkup_m3",
263 .class = &am33xx_wkup_m3_hwmod_class, 263 .class = &am33xx_wkup_m3_hwmod_class,
264 .clkdm_name = "l4_wkup_aon_clkdm", 264 .clkdm_name = "l4_wkup_aon_clkdm",
265 .flags = HWMOD_INIT_NO_RESET, /* Keep hardreset asserted */ 265 .flags = HWMOD_INIT_NO_RESET, /* Keep hardreset asserted */
266 .mpu_irqs = am33xx_wkup_m3_irqs, 266 .mpu_irqs = am33xx_wkup_m3_irqs,
267 .main_clk = "dpll_core_m4_div2_ck", 267 .main_clk = "dpll_core_m4_div2_ck",
268 .prcm = { 268 .prcm = {
269 .omap4 = { 269 .omap4 = {
270 .clkctrl_offs = AM33XX_CM_WKUP_WKUP_M3_CLKCTRL_OFFSET, 270 .clkctrl_offs = AM33XX_CM_WKUP_WKUP_M3_CLKCTRL_OFFSET,
271 .rstctrl_offs = AM33XX_RM_WKUP_RSTCTRL_OFFSET, 271 .rstctrl_offs = AM33XX_RM_WKUP_RSTCTRL_OFFSET,
272 .modulemode = MODULEMODE_SWCTRL, 272 .modulemode = MODULEMODE_SWCTRL,
273 }, 273 },
274 }, 274 },
275 .rst_lines = am33xx_wkup_m3_resets, 275 .rst_lines = am33xx_wkup_m3_resets,
276 .rst_lines_cnt = ARRAY_SIZE(am33xx_wkup_m3_resets), 276 .rst_lines_cnt = ARRAY_SIZE(am33xx_wkup_m3_resets),
277 }; 277 };
278 278
279 /* 279 /*
280 * 'pru-icss' class 280 * 'pru-icss' class
281 * Programmable Real-Time Unit and Industrial Communication Subsystem 281 * Programmable Real-Time Unit and Industrial Communication Subsystem
282 */ 282 */
283 static struct omap_hwmod_class am33xx_pruss_hwmod_class = { 283 static struct omap_hwmod_class am33xx_pruss_hwmod_class = {
284 .name = "pruss", 284 .name = "pruss",
285 }; 285 };
286 286
287 static struct omap_hwmod_rst_info am33xx_pruss_resets[] = { 287 static struct omap_hwmod_rst_info am33xx_pruss_resets[] = {
288 { .name = "pruss", .rst_shift = 1 }, 288 { .name = "pruss", .rst_shift = 1 },
289 }; 289 };
290 290
291 static struct omap_hwmod_irq_info am33xx_pruss_irqs[] = { 291 static struct omap_hwmod_irq_info am33xx_pruss_irqs[] = {
292 { .name = "evtout0", .irq = 20 + OMAP_INTC_START, }, 292 { .name = "evtout0", .irq = 20 + OMAP_INTC_START, },
293 { .name = "evtout1", .irq = 21 + OMAP_INTC_START, }, 293 { .name = "evtout1", .irq = 21 + OMAP_INTC_START, },
294 { .name = "evtout2", .irq = 22 + OMAP_INTC_START, }, 294 { .name = "evtout2", .irq = 22 + OMAP_INTC_START, },
295 { .name = "evtout3", .irq = 23 + OMAP_INTC_START, }, 295 { .name = "evtout3", .irq = 23 + OMAP_INTC_START, },
296 { .name = "evtout4", .irq = 24 + OMAP_INTC_START, }, 296 { .name = "evtout4", .irq = 24 + OMAP_INTC_START, },
297 { .name = "evtout5", .irq = 25 + OMAP_INTC_START, }, 297 { .name = "evtout5", .irq = 25 + OMAP_INTC_START, },
298 { .name = "evtout6", .irq = 26 + OMAP_INTC_START, }, 298 { .name = "evtout6", .irq = 26 + OMAP_INTC_START, },
299 { .name = "evtout7", .irq = 27 + OMAP_INTC_START, }, 299 { .name = "evtout7", .irq = 27 + OMAP_INTC_START, },
300 { .irq = -1 }, 300 { .irq = -1 },
301 }; 301 };
302 302
303 /* pru-icss */ 303 /* pru-icss */
304 /* Pseudo hwmod for reset control purpose only */ 304 /* Pseudo hwmod for reset control purpose only */
305 static struct omap_hwmod am33xx_pruss_hwmod = { 305 static struct omap_hwmod am33xx_pruss_hwmod = {
306 .name = "pruss", 306 .name = "pruss",
307 .class = &am33xx_pruss_hwmod_class, 307 .class = &am33xx_pruss_hwmod_class,
308 .clkdm_name = "pruss_ocp_clkdm", 308 .clkdm_name = "pruss_ocp_clkdm",
309 .mpu_irqs = am33xx_pruss_irqs, 309 .mpu_irqs = am33xx_pruss_irqs,
310 .main_clk = "pruss_ocp_gclk", 310 .main_clk = "pruss_ocp_gclk",
311 .prcm = { 311 .prcm = {
312 .omap4 = { 312 .omap4 = {
313 .clkctrl_offs = AM33XX_CM_PER_PRUSS_CLKCTRL_OFFSET, 313 .clkctrl_offs = AM33XX_CM_PER_PRUSS_CLKCTRL_OFFSET,
314 .rstctrl_offs = AM33XX_RM_PER_RSTCTRL_OFFSET, 314 .rstctrl_offs = AM33XX_RM_PER_RSTCTRL_OFFSET,
315 .modulemode = MODULEMODE_SWCTRL, 315 .modulemode = MODULEMODE_SWCTRL,
316 }, 316 },
317 }, 317 },
318 .rst_lines = am33xx_pruss_resets, 318 .rst_lines = am33xx_pruss_resets,
319 .rst_lines_cnt = ARRAY_SIZE(am33xx_pruss_resets), 319 .rst_lines_cnt = ARRAY_SIZE(am33xx_pruss_resets),
320 }; 320 };
321 321
322 /* gfx */ 322 /* gfx */
323 /* Pseudo hwmod for reset control purpose only */ 323 /* Pseudo hwmod for reset control purpose only */
324 static struct omap_hwmod_class am33xx_gfx_hwmod_class = { 324 static struct omap_hwmod_class am33xx_gfx_hwmod_class = {
325 .name = "gfx", 325 .name = "gfx",
326 }; 326 };
327 327
328 static struct omap_hwmod_rst_info am33xx_gfx_resets[] = { 328 static struct omap_hwmod_rst_info am33xx_gfx_resets[] = {
329 { .name = "gfx", .rst_shift = 0 }, 329 { .name = "gfx", .rst_shift = 0 },
330 }; 330 };
331 331
332 static struct omap_hwmod_irq_info am33xx_gfx_irqs[] = { 332 static struct omap_hwmod_irq_info am33xx_gfx_irqs[] = {
333 { .name = "gfxint", .irq = 37 + OMAP_INTC_START, }, 333 { .name = "gfxint", .irq = 37 + OMAP_INTC_START, },
334 { .irq = -1 }, 334 { .irq = -1 },
335 }; 335 };
336 336
337 static struct omap_hwmod am33xx_gfx_hwmod = { 337 static struct omap_hwmod am33xx_gfx_hwmod = {
338 .name = "gfx", 338 .name = "gfx",
339 .class = &am33xx_gfx_hwmod_class, 339 .class = &am33xx_gfx_hwmod_class,
340 .clkdm_name = "gfx_l3_clkdm", 340 .clkdm_name = "gfx_l3_clkdm",
341 .mpu_irqs = am33xx_gfx_irqs, 341 .mpu_irqs = am33xx_gfx_irqs,
342 .main_clk = "gfx_fck_div_ck", 342 .main_clk = "gfx_fck_div_ck",
343 .prcm = { 343 .prcm = {
344 .omap4 = { 344 .omap4 = {
345 .clkctrl_offs = AM33XX_CM_GFX_GFX_CLKCTRL_OFFSET, 345 .clkctrl_offs = AM33XX_CM_GFX_GFX_CLKCTRL_OFFSET,
346 .rstctrl_offs = AM33XX_RM_GFX_RSTCTRL_OFFSET, 346 .rstctrl_offs = AM33XX_RM_GFX_RSTCTRL_OFFSET,
347 .modulemode = MODULEMODE_SWCTRL, 347 .modulemode = MODULEMODE_SWCTRL,
348 }, 348 },
349 }, 349 },
350 .rst_lines = am33xx_gfx_resets, 350 .rst_lines = am33xx_gfx_resets,
351 .rst_lines_cnt = ARRAY_SIZE(am33xx_gfx_resets), 351 .rst_lines_cnt = ARRAY_SIZE(am33xx_gfx_resets),
352 }; 352 };
353 353
354 /* 354 /*
355 * 'prcm' class 355 * 'prcm' class
356 * power and reset manager (whole prcm infrastructure) 356 * power and reset manager (whole prcm infrastructure)
357 */ 357 */
358 static struct omap_hwmod_class am33xx_prcm_hwmod_class = { 358 static struct omap_hwmod_class am33xx_prcm_hwmod_class = {
359 .name = "prcm", 359 .name = "prcm",
360 }; 360 };
361 361
362 /* prcm */ 362 /* prcm */
363 static struct omap_hwmod am33xx_prcm_hwmod = { 363 static struct omap_hwmod am33xx_prcm_hwmod = {
364 .name = "prcm", 364 .name = "prcm",
365 .class = &am33xx_prcm_hwmod_class, 365 .class = &am33xx_prcm_hwmod_class,
366 .clkdm_name = "l4_wkup_clkdm", 366 .clkdm_name = "l4_wkup_clkdm",
367 }; 367 };
368 368
369 /* 369 /*
370 * 'adc/tsc' class 370 * 'adc/tsc' class
371 * TouchScreen Controller (Anolog-To-Digital Converter) 371 * TouchScreen Controller (Anolog-To-Digital Converter)
372 */ 372 */
373 static struct omap_hwmod_class_sysconfig am33xx_adc_tsc_sysc = { 373 static struct omap_hwmod_class_sysconfig am33xx_adc_tsc_sysc = {
374 .rev_offs = 0x00, 374 .rev_offs = 0x00,
375 .sysc_offs = 0x10, 375 .sysc_offs = 0x10,
376 .sysc_flags = SYSC_HAS_SIDLEMODE, 376 .sysc_flags = SYSC_HAS_SIDLEMODE,
377 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 377 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
378 SIDLE_SMART_WKUP), 378 SIDLE_SMART_WKUP),
379 .sysc_fields = &omap_hwmod_sysc_type2, 379 .sysc_fields = &omap_hwmod_sysc_type2,
380 }; 380 };
381 381
382 static struct omap_hwmod_class am33xx_adc_tsc_hwmod_class = { 382 static struct omap_hwmod_class am33xx_adc_tsc_hwmod_class = {
383 .name = "adc_tsc", 383 .name = "adc_tsc",
384 .sysc = &am33xx_adc_tsc_sysc, 384 .sysc = &am33xx_adc_tsc_sysc,
385 }; 385 };
386 386
387 static struct omap_hwmod_irq_info am33xx_adc_tsc_irqs[] = { 387 static struct omap_hwmod_irq_info am33xx_adc_tsc_irqs[] = {
388 { .irq = 16 + OMAP_INTC_START, }, 388 { .irq = 16 + OMAP_INTC_START, },
389 { .irq = -1 }, 389 { .irq = -1 },
390 }; 390 };
391 391
392 static struct omap_hwmod am33xx_adc_tsc_hwmod = { 392 static struct omap_hwmod am33xx_adc_tsc_hwmod = {
393 .name = "adc_tsc", 393 .name = "adc_tsc",
394 .class = &am33xx_adc_tsc_hwmod_class, 394 .class = &am33xx_adc_tsc_hwmod_class,
395 .clkdm_name = "l4_wkup_clkdm", 395 .clkdm_name = "l4_wkup_clkdm",
396 .mpu_irqs = am33xx_adc_tsc_irqs, 396 .mpu_irqs = am33xx_adc_tsc_irqs,
397 .main_clk = "adc_tsc_fck", 397 .main_clk = "adc_tsc_fck",
398 .prcm = { 398 .prcm = {
399 .omap4 = { 399 .omap4 = {
400 .clkctrl_offs = AM33XX_CM_WKUP_ADC_TSC_CLKCTRL_OFFSET, 400 .clkctrl_offs = AM33XX_CM_WKUP_ADC_TSC_CLKCTRL_OFFSET,
401 .modulemode = MODULEMODE_SWCTRL, 401 .modulemode = MODULEMODE_SWCTRL,
402 }, 402 },
403 }, 403 },
404 }; 404 };
405 405
406 /* 406 /*
407 * Modules omap_hwmod structures 407 * Modules omap_hwmod structures
408 * 408 *
409 * The following IPs are excluded for the moment because: 409 * The following IPs are excluded for the moment because:
410 * - They do not need an explicit SW control using omap_hwmod API. 410 * - They do not need an explicit SW control using omap_hwmod API.
411 * - They still need to be validated with the driver 411 * - They still need to be validated with the driver
412 * properly adapted to omap_hwmod / omap_device 412 * properly adapted to omap_hwmod / omap_device
413 * 413 *
414 * - cEFUSE (doesn't fall under any ocp_if) 414 * - cEFUSE (doesn't fall under any ocp_if)
415 * - clkdiv32k 415 * - clkdiv32k
416 * - debugss 416 * - debugss
417 * - ocmc ram 417 * - ocmc ram
418 * - ocp watch point 418 * - ocp watch point
419 * - aes0 419 * - aes0
420 * - sha0 420 * - sha0
421 */ 421 */
422 #if 0 422 #if 0
423 /* 423 /*
424 * 'cefuse' class 424 * 'cefuse' class
425 */ 425 */
426 static struct omap_hwmod_class am33xx_cefuse_hwmod_class = { 426 static struct omap_hwmod_class am33xx_cefuse_hwmod_class = {
427 .name = "cefuse", 427 .name = "cefuse",
428 }; 428 };
429 429
430 static struct omap_hwmod am33xx_cefuse_hwmod = { 430 static struct omap_hwmod am33xx_cefuse_hwmod = {
431 .name = "cefuse", 431 .name = "cefuse",
432 .class = &am33xx_cefuse_hwmod_class, 432 .class = &am33xx_cefuse_hwmod_class,
433 .clkdm_name = "l4_cefuse_clkdm", 433 .clkdm_name = "l4_cefuse_clkdm",
434 .main_clk = "cefuse_fck", 434 .main_clk = "cefuse_fck",
435 .prcm = { 435 .prcm = {
436 .omap4 = { 436 .omap4 = {
437 .clkctrl_offs = AM33XX_CM_CEFUSE_CEFUSE_CLKCTRL_OFFSET, 437 .clkctrl_offs = AM33XX_CM_CEFUSE_CEFUSE_CLKCTRL_OFFSET,
438 .modulemode = MODULEMODE_SWCTRL, 438 .modulemode = MODULEMODE_SWCTRL,
439 }, 439 },
440 }, 440 },
441 }; 441 };
442 442
443 /* 443 /*
444 * 'clkdiv32k' class 444 * 'clkdiv32k' class
445 */ 445 */
446 static struct omap_hwmod_class am33xx_clkdiv32k_hwmod_class = { 446 static struct omap_hwmod_class am33xx_clkdiv32k_hwmod_class = {
447 .name = "clkdiv32k", 447 .name = "clkdiv32k",
448 }; 448 };
449 449
450 static struct omap_hwmod am33xx_clkdiv32k_hwmod = { 450 static struct omap_hwmod am33xx_clkdiv32k_hwmod = {
451 .name = "clkdiv32k", 451 .name = "clkdiv32k",
452 .class = &am33xx_clkdiv32k_hwmod_class, 452 .class = &am33xx_clkdiv32k_hwmod_class,
453 .clkdm_name = "clk_24mhz_clkdm", 453 .clkdm_name = "clk_24mhz_clkdm",
454 .main_clk = "clkdiv32k_ick", 454 .main_clk = "clkdiv32k_ick",
455 .prcm = { 455 .prcm = {
456 .omap4 = { 456 .omap4 = {
457 .clkctrl_offs = AM33XX_CM_PER_CLKDIV32K_CLKCTRL_OFFSET, 457 .clkctrl_offs = AM33XX_CM_PER_CLKDIV32K_CLKCTRL_OFFSET,
458 .modulemode = MODULEMODE_SWCTRL, 458 .modulemode = MODULEMODE_SWCTRL,
459 }, 459 },
460 }, 460 },
461 }; 461 };
462 462
463 /* 463 /*
464 * 'debugss' class 464 * 'debugss' class
465 * debug sub system 465 * debug sub system
466 */ 466 */
467 static struct omap_hwmod_class am33xx_debugss_hwmod_class = { 467 static struct omap_hwmod_class am33xx_debugss_hwmod_class = {
468 .name = "debugss", 468 .name = "debugss",
469 }; 469 };
470 470
471 static struct omap_hwmod am33xx_debugss_hwmod = { 471 static struct omap_hwmod am33xx_debugss_hwmod = {
472 .name = "debugss", 472 .name = "debugss",
473 .class = &am33xx_debugss_hwmod_class, 473 .class = &am33xx_debugss_hwmod_class,
474 .clkdm_name = "l3_aon_clkdm", 474 .clkdm_name = "l3_aon_clkdm",
475 .main_clk = "debugss_ick", 475 .main_clk = "debugss_ick",
476 .prcm = { 476 .prcm = {
477 .omap4 = { 477 .omap4 = {
478 .clkctrl_offs = AM33XX_CM_WKUP_DEBUGSS_CLKCTRL_OFFSET, 478 .clkctrl_offs = AM33XX_CM_WKUP_DEBUGSS_CLKCTRL_OFFSET,
479 .modulemode = MODULEMODE_SWCTRL, 479 .modulemode = MODULEMODE_SWCTRL,
480 }, 480 },
481 }, 481 },
482 }; 482 };
483 483
484 /* ocmcram */ 484 /* ocmcram */
485 static struct omap_hwmod_class am33xx_ocmcram_hwmod_class = { 485 static struct omap_hwmod_class am33xx_ocmcram_hwmod_class = {
486 .name = "ocmcram", 486 .name = "ocmcram",
487 }; 487 };
488 488
489 static struct omap_hwmod am33xx_ocmcram_hwmod = { 489 static struct omap_hwmod am33xx_ocmcram_hwmod = {
490 .name = "ocmcram", 490 .name = "ocmcram",
491 .class = &am33xx_ocmcram_hwmod_class, 491 .class = &am33xx_ocmcram_hwmod_class,
492 .clkdm_name = "l3_clkdm", 492 .clkdm_name = "l3_clkdm",
493 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 493 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
494 .main_clk = "l3_gclk", 494 .main_clk = "l3_gclk",
495 .prcm = { 495 .prcm = {
496 .omap4 = { 496 .omap4 = {
497 .clkctrl_offs = AM33XX_CM_PER_OCMCRAM_CLKCTRL_OFFSET, 497 .clkctrl_offs = AM33XX_CM_PER_OCMCRAM_CLKCTRL_OFFSET,
498 .modulemode = MODULEMODE_SWCTRL, 498 .modulemode = MODULEMODE_SWCTRL,
499 }, 499 },
500 }, 500 },
501 }; 501 };
502 502
503 /* ocpwp */ 503 /* ocpwp */
504 static struct omap_hwmod_class am33xx_ocpwp_hwmod_class = { 504 static struct omap_hwmod_class am33xx_ocpwp_hwmod_class = {
505 .name = "ocpwp", 505 .name = "ocpwp",
506 }; 506 };
507 507
508 static struct omap_hwmod am33xx_ocpwp_hwmod = { 508 static struct omap_hwmod am33xx_ocpwp_hwmod = {
509 .name = "ocpwp", 509 .name = "ocpwp",
510 .class = &am33xx_ocpwp_hwmod_class, 510 .class = &am33xx_ocpwp_hwmod_class,
511 .clkdm_name = "l4ls_clkdm", 511 .clkdm_name = "l4ls_clkdm",
512 .main_clk = "l4ls_gclk", 512 .main_clk = "l4ls_gclk",
513 .prcm = { 513 .prcm = {
514 .omap4 = { 514 .omap4 = {
515 .clkctrl_offs = AM33XX_CM_PER_OCPWP_CLKCTRL_OFFSET, 515 .clkctrl_offs = AM33XX_CM_PER_OCPWP_CLKCTRL_OFFSET,
516 .modulemode = MODULEMODE_SWCTRL, 516 .modulemode = MODULEMODE_SWCTRL,
517 }, 517 },
518 }, 518 },
519 }; 519 };
520 520
521 /* 521 /*
522 * 'aes' class 522 * 'aes' class
523 */ 523 */
524 static struct omap_hwmod_class am33xx_aes_hwmod_class = { 524 static struct omap_hwmod_class am33xx_aes_hwmod_class = {
525 .name = "aes", 525 .name = "aes",
526 }; 526 };
527 527
528 static struct omap_hwmod_irq_info am33xx_aes0_irqs[] = { 528 static struct omap_hwmod_irq_info am33xx_aes0_irqs[] = {
529 { .irq = 102 + OMAP_INTC_START, }, 529 { .irq = 102 + OMAP_INTC_START, },
530 { .irq = -1 }, 530 { .irq = -1 },
531 }; 531 };
532 532
533 static struct omap_hwmod am33xx_aes0_hwmod = { 533 static struct omap_hwmod am33xx_aes0_hwmod = {
534 .name = "aes0", 534 .name = "aes0",
535 .class = &am33xx_aes_hwmod_class, 535 .class = &am33xx_aes_hwmod_class,
536 .clkdm_name = "l3_clkdm", 536 .clkdm_name = "l3_clkdm",
537 .mpu_irqs = am33xx_aes0_irqs, 537 .mpu_irqs = am33xx_aes0_irqs,
538 .main_clk = "l3_gclk", 538 .main_clk = "l3_gclk",
539 .prcm = { 539 .prcm = {
540 .omap4 = { 540 .omap4 = {
541 .clkctrl_offs = AM33XX_CM_PER_AES0_CLKCTRL_OFFSET, 541 .clkctrl_offs = AM33XX_CM_PER_AES0_CLKCTRL_OFFSET,
542 .modulemode = MODULEMODE_SWCTRL, 542 .modulemode = MODULEMODE_SWCTRL,
543 }, 543 },
544 }, 544 },
545 }; 545 };
546 546
547 /* sha0 */ 547 /* sha0 */
548 static struct omap_hwmod_class am33xx_sha0_hwmod_class = { 548 static struct omap_hwmod_class am33xx_sha0_hwmod_class = {
549 .name = "sha0", 549 .name = "sha0",
550 }; 550 };
551 551
552 static struct omap_hwmod_irq_info am33xx_sha0_irqs[] = { 552 static struct omap_hwmod_irq_info am33xx_sha0_irqs[] = {
553 { .irq = 108 + OMAP_INTC_START, }, 553 { .irq = 108 + OMAP_INTC_START, },
554 { .irq = -1 }, 554 { .irq = -1 },
555 }; 555 };
556 556
557 static struct omap_hwmod am33xx_sha0_hwmod = { 557 static struct omap_hwmod am33xx_sha0_hwmod = {
558 .name = "sha0", 558 .name = "sha0",
559 .class = &am33xx_sha0_hwmod_class, 559 .class = &am33xx_sha0_hwmod_class,
560 .clkdm_name = "l3_clkdm", 560 .clkdm_name = "l3_clkdm",
561 .mpu_irqs = am33xx_sha0_irqs, 561 .mpu_irqs = am33xx_sha0_irqs,
562 .main_clk = "l3_gclk", 562 .main_clk = "l3_gclk",
563 .prcm = { 563 .prcm = {
564 .omap4 = { 564 .omap4 = {
565 .clkctrl_offs = AM33XX_CM_PER_SHA0_CLKCTRL_OFFSET, 565 .clkctrl_offs = AM33XX_CM_PER_SHA0_CLKCTRL_OFFSET,
566 .modulemode = MODULEMODE_SWCTRL, 566 .modulemode = MODULEMODE_SWCTRL,
567 }, 567 },
568 }, 568 },
569 }; 569 };
570 570
571 #endif 571 #endif
572 572
573 /* 'smartreflex' class */ 573 /* 'smartreflex' class */
574 static struct omap_hwmod_class am33xx_smartreflex_hwmod_class = { 574 static struct omap_hwmod_class am33xx_smartreflex_hwmod_class = {
575 .name = "smartreflex", 575 .name = "smartreflex",
576 }; 576 };
577 577
578 /* smartreflex0 */ 578 /* smartreflex0 */
579 static struct omap_hwmod_irq_info am33xx_smartreflex0_irqs[] = { 579 static struct omap_hwmod_irq_info am33xx_smartreflex0_irqs[] = {
580 { .irq = 120 + OMAP_INTC_START, }, 580 { .irq = 120 + OMAP_INTC_START, },
581 { .irq = -1 }, 581 { .irq = -1 },
582 }; 582 };
583 583
584 static struct omap_hwmod am33xx_smartreflex0_hwmod = { 584 static struct omap_hwmod am33xx_smartreflex0_hwmod = {
585 .name = "smartreflex0", 585 .name = "smartreflex0",
586 .class = &am33xx_smartreflex_hwmod_class, 586 .class = &am33xx_smartreflex_hwmod_class,
587 .clkdm_name = "l4_wkup_clkdm", 587 .clkdm_name = "l4_wkup_clkdm",
588 .mpu_irqs = am33xx_smartreflex0_irqs, 588 .mpu_irqs = am33xx_smartreflex0_irqs,
589 .main_clk = "smartreflex0_fck", 589 .main_clk = "smartreflex0_fck",
590 .prcm = { 590 .prcm = {
591 .omap4 = { 591 .omap4 = {
592 .clkctrl_offs = AM33XX_CM_WKUP_SMARTREFLEX0_CLKCTRL_OFFSET, 592 .clkctrl_offs = AM33XX_CM_WKUP_SMARTREFLEX0_CLKCTRL_OFFSET,
593 .modulemode = MODULEMODE_SWCTRL, 593 .modulemode = MODULEMODE_SWCTRL,
594 }, 594 },
595 }, 595 },
596 }; 596 };
597 597
598 /* smartreflex1 */ 598 /* smartreflex1 */
599 static struct omap_hwmod_irq_info am33xx_smartreflex1_irqs[] = { 599 static struct omap_hwmod_irq_info am33xx_smartreflex1_irqs[] = {
600 { .irq = 121 + OMAP_INTC_START, }, 600 { .irq = 121 + OMAP_INTC_START, },
601 { .irq = -1 }, 601 { .irq = -1 },
602 }; 602 };
603 603
604 static struct omap_hwmod am33xx_smartreflex1_hwmod = { 604 static struct omap_hwmod am33xx_smartreflex1_hwmod = {
605 .name = "smartreflex1", 605 .name = "smartreflex1",
606 .class = &am33xx_smartreflex_hwmod_class, 606 .class = &am33xx_smartreflex_hwmod_class,
607 .clkdm_name = "l4_wkup_clkdm", 607 .clkdm_name = "l4_wkup_clkdm",
608 .mpu_irqs = am33xx_smartreflex1_irqs, 608 .mpu_irqs = am33xx_smartreflex1_irqs,
609 .main_clk = "smartreflex1_fck", 609 .main_clk = "smartreflex1_fck",
610 .prcm = { 610 .prcm = {
611 .omap4 = { 611 .omap4 = {
612 .clkctrl_offs = AM33XX_CM_WKUP_SMARTREFLEX1_CLKCTRL_OFFSET, 612 .clkctrl_offs = AM33XX_CM_WKUP_SMARTREFLEX1_CLKCTRL_OFFSET,
613 .modulemode = MODULEMODE_SWCTRL, 613 .modulemode = MODULEMODE_SWCTRL,
614 }, 614 },
615 }, 615 },
616 }; 616 };
617 617
618 /* 618 /*
619 * 'control' module class 619 * 'control' module class
620 */ 620 */
621 static struct omap_hwmod_class am33xx_control_hwmod_class = { 621 static struct omap_hwmod_class am33xx_control_hwmod_class = {
622 .name = "control", 622 .name = "control",
623 }; 623 };
624 624
625 static struct omap_hwmod_irq_info am33xx_control_irqs[] = { 625 static struct omap_hwmod_irq_info am33xx_control_irqs[] = {
626 { .irq = 8 + OMAP_INTC_START, }, 626 { .irq = 8 + OMAP_INTC_START, },
627 { .irq = -1 }, 627 { .irq = -1 },
628 }; 628 };
629 629
630 static struct omap_hwmod am33xx_control_hwmod = { 630 static struct omap_hwmod am33xx_control_hwmod = {
631 .name = "control", 631 .name = "control",
632 .class = &am33xx_control_hwmod_class, 632 .class = &am33xx_control_hwmod_class,
633 .clkdm_name = "l4_wkup_clkdm", 633 .clkdm_name = "l4_wkup_clkdm",
634 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 634 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
635 .mpu_irqs = am33xx_control_irqs, 635 .mpu_irqs = am33xx_control_irqs,
636 .main_clk = "dpll_core_m4_div2_ck", 636 .main_clk = "dpll_core_m4_div2_ck",
637 .prcm = { 637 .prcm = {
638 .omap4 = { 638 .omap4 = {
639 .clkctrl_offs = AM33XX_CM_WKUP_CONTROL_CLKCTRL_OFFSET, 639 .clkctrl_offs = AM33XX_CM_WKUP_CONTROL_CLKCTRL_OFFSET,
640 .modulemode = MODULEMODE_SWCTRL, 640 .modulemode = MODULEMODE_SWCTRL,
641 }, 641 },
642 }, 642 },
643 }; 643 };
644 644
645 /* 645 /*
646 * 'cpgmac' class 646 * 'cpgmac' class
647 * cpsw/cpgmac sub system 647 * cpsw/cpgmac sub system
648 */ 648 */
649 static struct omap_hwmod_class_sysconfig am33xx_cpgmac_sysc = { 649 static struct omap_hwmod_class_sysconfig am33xx_cpgmac_sysc = {
650 .rev_offs = 0x0, 650 .rev_offs = 0x0,
651 .sysc_offs = 0x8, 651 .sysc_offs = 0x8,
652 .syss_offs = 0x4, 652 .syss_offs = 0x4,
653 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE | 653 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE |
654 SYSS_HAS_RESET_STATUS), 654 SYSS_HAS_RESET_STATUS),
655 .idlemodes = (SIDLE_FORCE | SIDLE_NO | MSTANDBY_FORCE | 655 .idlemodes = (SIDLE_FORCE | SIDLE_NO | MSTANDBY_FORCE |
656 MSTANDBY_NO), 656 MSTANDBY_NO),
657 .sysc_fields = &omap_hwmod_sysc_type3, 657 .sysc_fields = &omap_hwmod_sysc_type3,
658 }; 658 };
659 659
660 static struct omap_hwmod_class am33xx_cpgmac0_hwmod_class = { 660 static struct omap_hwmod_class am33xx_cpgmac0_hwmod_class = {
661 .name = "cpgmac0", 661 .name = "cpgmac0",
662 .sysc = &am33xx_cpgmac_sysc, 662 .sysc = &am33xx_cpgmac_sysc,
663 }; 663 };
664 664
665 static struct omap_hwmod_irq_info am33xx_cpgmac0_irqs[] = { 665 static struct omap_hwmod_irq_info am33xx_cpgmac0_irqs[] = {
666 { .name = "c0_rx_thresh_pend", .irq = 40 + OMAP_INTC_START, }, 666 { .name = "c0_rx_thresh_pend", .irq = 40 + OMAP_INTC_START, },
667 { .name = "c0_rx_pend", .irq = 41 + OMAP_INTC_START, }, 667 { .name = "c0_rx_pend", .irq = 41 + OMAP_INTC_START, },
668 { .name = "c0_tx_pend", .irq = 42 + OMAP_INTC_START, }, 668 { .name = "c0_tx_pend", .irq = 42 + OMAP_INTC_START, },
669 { .name = "c0_misc_pend", .irq = 43 + OMAP_INTC_START, }, 669 { .name = "c0_misc_pend", .irq = 43 + OMAP_INTC_START, },
670 { .irq = -1 }, 670 { .irq = -1 },
671 }; 671 };
672 672
673 static struct omap_hwmod am33xx_cpgmac0_hwmod = { 673 static struct omap_hwmod am33xx_cpgmac0_hwmod = {
674 .name = "cpgmac0", 674 .name = "cpgmac0",
675 .class = &am33xx_cpgmac0_hwmod_class, 675 .class = &am33xx_cpgmac0_hwmod_class,
676 .clkdm_name = "cpsw_125mhz_clkdm", 676 .clkdm_name = "cpsw_125mhz_clkdm",
677 .mpu_irqs = am33xx_cpgmac0_irqs, 677 .mpu_irqs = am33xx_cpgmac0_irqs,
678 .main_clk = "cpsw_125mhz_gclk", 678 .main_clk = "cpsw_125mhz_gclk",
679 .prcm = { 679 .prcm = {
680 .omap4 = { 680 .omap4 = {
681 .clkctrl_offs = AM33XX_CM_PER_CPGMAC0_CLKCTRL_OFFSET, 681 .clkctrl_offs = AM33XX_CM_PER_CPGMAC0_CLKCTRL_OFFSET,
682 .modulemode = MODULEMODE_SWCTRL, 682 .modulemode = MODULEMODE_SWCTRL,
683 }, 683 },
684 }, 684 },
685 }; 685 };
686 686
687 /* 687 /*
688 * dcan class 688 * dcan class
689 */ 689 */
690 static struct omap_hwmod_class am33xx_dcan_hwmod_class = { 690 static struct omap_hwmod_class am33xx_dcan_hwmod_class = {
691 .name = "d_can", 691 .name = "d_can",
692 }; 692 };
693 693
694 /* dcan0 */ 694 /* dcan0 */
695 static struct omap_hwmod_irq_info am33xx_dcan0_irqs[] = { 695 static struct omap_hwmod_irq_info am33xx_dcan0_irqs[] = {
696 { .name = "d_can_ms", .irq = 52 + OMAP_INTC_START, }, 696 { .name = "d_can_ms", .irq = 52 + OMAP_INTC_START, },
697 { .name = "d_can_mo", .irq = 53 + OMAP_INTC_START, }, 697 { .name = "d_can_mo", .irq = 53 + OMAP_INTC_START, },
698 { .irq = -1 }, 698 { .irq = -1 },
699 }; 699 };
700 700
701 static struct omap_hwmod am33xx_dcan0_hwmod = { 701 static struct omap_hwmod am33xx_dcan0_hwmod = {
702 .name = "d_can0", 702 .name = "d_can0",
703 .class = &am33xx_dcan_hwmod_class, 703 .class = &am33xx_dcan_hwmod_class,
704 .clkdm_name = "l4ls_clkdm", 704 .clkdm_name = "l4ls_clkdm",
705 .mpu_irqs = am33xx_dcan0_irqs, 705 .mpu_irqs = am33xx_dcan0_irqs,
706 .main_clk = "dcan0_fck", 706 .main_clk = "dcan0_fck",
707 .prcm = { 707 .prcm = {
708 .omap4 = { 708 .omap4 = {
709 .clkctrl_offs = AM33XX_CM_PER_DCAN0_CLKCTRL_OFFSET, 709 .clkctrl_offs = AM33XX_CM_PER_DCAN0_CLKCTRL_OFFSET,
710 .modulemode = MODULEMODE_SWCTRL, 710 .modulemode = MODULEMODE_SWCTRL,
711 }, 711 },
712 }, 712 },
713 }; 713 };
714 714
715 /* dcan1 */ 715 /* dcan1 */
716 static struct omap_hwmod_irq_info am33xx_dcan1_irqs[] = { 716 static struct omap_hwmod_irq_info am33xx_dcan1_irqs[] = {
717 { .name = "d_can_ms", .irq = 55 + OMAP_INTC_START, }, 717 { .name = "d_can_ms", .irq = 55 + OMAP_INTC_START, },
718 { .name = "d_can_mo", .irq = 56 + OMAP_INTC_START, }, 718 { .name = "d_can_mo", .irq = 56 + OMAP_INTC_START, },
719 { .irq = -1 }, 719 { .irq = -1 },
720 }; 720 };
721 static struct omap_hwmod am33xx_dcan1_hwmod = { 721 static struct omap_hwmod am33xx_dcan1_hwmod = {
722 .name = "d_can1", 722 .name = "d_can1",
723 .class = &am33xx_dcan_hwmod_class, 723 .class = &am33xx_dcan_hwmod_class,
724 .clkdm_name = "l4ls_clkdm", 724 .clkdm_name = "l4ls_clkdm",
725 .mpu_irqs = am33xx_dcan1_irqs, 725 .mpu_irqs = am33xx_dcan1_irqs,
726 .main_clk = "dcan1_fck", 726 .main_clk = "dcan1_fck",
727 .prcm = { 727 .prcm = {
728 .omap4 = { 728 .omap4 = {
729 .clkctrl_offs = AM33XX_CM_PER_DCAN1_CLKCTRL_OFFSET, 729 .clkctrl_offs = AM33XX_CM_PER_DCAN1_CLKCTRL_OFFSET,
730 .modulemode = MODULEMODE_SWCTRL, 730 .modulemode = MODULEMODE_SWCTRL,
731 }, 731 },
732 }, 732 },
733 }; 733 };
734 734
735 /* elm */ 735 /* elm */
736 static struct omap_hwmod_class_sysconfig am33xx_elm_sysc = { 736 static struct omap_hwmod_class_sysconfig am33xx_elm_sysc = {
737 .rev_offs = 0x0000, 737 .rev_offs = 0x0000,
738 .sysc_offs = 0x0010, 738 .sysc_offs = 0x0010,
739 .syss_offs = 0x0014, 739 .syss_offs = 0x0014,
740 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 740 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
741 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE | 741 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE |
742 SYSS_HAS_RESET_STATUS), 742 SYSS_HAS_RESET_STATUS),
743 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 743 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
744 .sysc_fields = &omap_hwmod_sysc_type1, 744 .sysc_fields = &omap_hwmod_sysc_type1,
745 }; 745 };
746 746
747 static struct omap_hwmod_class am33xx_elm_hwmod_class = { 747 static struct omap_hwmod_class am33xx_elm_hwmod_class = {
748 .name = "elm", 748 .name = "elm",
749 .sysc = &am33xx_elm_sysc, 749 .sysc = &am33xx_elm_sysc,
750 }; 750 };
751 751
752 static struct omap_hwmod_irq_info am33xx_elm_irqs[] = { 752 static struct omap_hwmod_irq_info am33xx_elm_irqs[] = {
753 { .irq = 4 + OMAP_INTC_START, }, 753 { .irq = 4 + OMAP_INTC_START, },
754 { .irq = -1 }, 754 { .irq = -1 },
755 }; 755 };
756 756
757 static struct omap_hwmod am33xx_elm_hwmod = { 757 static struct omap_hwmod am33xx_elm_hwmod = {
758 .name = "elm", 758 .name = "elm",
759 .class = &am33xx_elm_hwmod_class, 759 .class = &am33xx_elm_hwmod_class,
760 .clkdm_name = "l4ls_clkdm", 760 .clkdm_name = "l4ls_clkdm",
761 .mpu_irqs = am33xx_elm_irqs, 761 .mpu_irqs = am33xx_elm_irqs,
762 .main_clk = "l4ls_gclk", 762 .main_clk = "l4ls_gclk",
763 .prcm = { 763 .prcm = {
764 .omap4 = { 764 .omap4 = {
765 .clkctrl_offs = AM33XX_CM_PER_ELM_CLKCTRL_OFFSET, 765 .clkctrl_offs = AM33XX_CM_PER_ELM_CLKCTRL_OFFSET,
766 .modulemode = MODULEMODE_SWCTRL, 766 .modulemode = MODULEMODE_SWCTRL,
767 }, 767 },
768 }, 768 },
769 }; 769 };
770 770
771 /* 771 /*
772 * 'epwmss' class: ecap0,1,2, ehrpwm0,1,2 772 * 'epwmss' class: ecap0,1,2, ehrpwm0,1,2
773 */ 773 */
774 static struct omap_hwmod_class_sysconfig am33xx_epwmss_sysc = { 774 static struct omap_hwmod_class_sysconfig am33xx_epwmss_sysc = {
775 .rev_offs = 0x0, 775 .rev_offs = 0x0,
776 .sysc_offs = 0x4, 776 .sysc_offs = 0x4,
777 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE), 777 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE),
778 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 778 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
779 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO | 779 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
780 MSTANDBY_SMART | MSTANDBY_SMART_WKUP), 780 MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
781 .sysc_fields = &omap_hwmod_sysc_type2, 781 .sysc_fields = &omap_hwmod_sysc_type2,
782 }; 782 };
783 783
784 static struct omap_hwmod_class am33xx_epwmss_hwmod_class = { 784 static struct omap_hwmod_class am33xx_epwmss_hwmod_class = {
785 .name = "epwmss", 785 .name = "epwmss",
786 .sysc = &am33xx_epwmss_sysc, 786 .sysc = &am33xx_epwmss_sysc,
787 }; 787 };
788 788
789 /* ehrpwm0 */ 789 /* ehrpwm0 */
790 static struct omap_hwmod_irq_info am33xx_ehrpwm0_irqs[] = { 790 static struct omap_hwmod_irq_info am33xx_ehrpwm0_irqs[] = {
791 { .name = "int", .irq = 86 + OMAP_INTC_START, }, 791 { .name = "int", .irq = 86 + OMAP_INTC_START, },
792 { .name = "tzint", .irq = 58 + OMAP_INTC_START, }, 792 { .name = "tzint", .irq = 58 + OMAP_INTC_START, },
793 { .irq = -1 }, 793 { .irq = -1 },
794 }; 794 };
795 795
796 static struct omap_hwmod am33xx_ehrpwm0_hwmod = { 796 static struct omap_hwmod am33xx_ehrpwm0_hwmod = {
797 .name = "ehrpwm0", 797 .name = "ehrpwm0",
798 .class = &am33xx_epwmss_hwmod_class, 798 .class = &am33xx_epwmss_hwmod_class,
799 .clkdm_name = "l4ls_clkdm", 799 .clkdm_name = "l4ls_clkdm",
800 .mpu_irqs = am33xx_ehrpwm0_irqs, 800 .mpu_irqs = am33xx_ehrpwm0_irqs,
801 .main_clk = "l4ls_gclk", 801 .main_clk = "l4ls_gclk",
802 .prcm = { 802 .prcm = {
803 .omap4 = { 803 .omap4 = {
804 .clkctrl_offs = AM33XX_CM_PER_EPWMSS0_CLKCTRL_OFFSET, 804 .clkctrl_offs = AM33XX_CM_PER_EPWMSS0_CLKCTRL_OFFSET,
805 .modulemode = MODULEMODE_SWCTRL, 805 .modulemode = MODULEMODE_SWCTRL,
806 }, 806 },
807 }, 807 },
808 }; 808 };
809 809
810 /* ehrpwm1 */ 810 /* ehrpwm1 */
811 static struct omap_hwmod_irq_info am33xx_ehrpwm1_irqs[] = { 811 static struct omap_hwmod_irq_info am33xx_ehrpwm1_irqs[] = {
812 { .name = "int", .irq = 87 + OMAP_INTC_START, }, 812 { .name = "int", .irq = 87 + OMAP_INTC_START, },
813 { .name = "tzint", .irq = 59 + OMAP_INTC_START, }, 813 { .name = "tzint", .irq = 59 + OMAP_INTC_START, },
814 { .irq = -1 }, 814 { .irq = -1 },
815 }; 815 };
816 816
817 static struct omap_hwmod am33xx_ehrpwm1_hwmod = { 817 static struct omap_hwmod am33xx_ehrpwm1_hwmod = {
818 .name = "ehrpwm1", 818 .name = "ehrpwm1",
819 .class = &am33xx_epwmss_hwmod_class, 819 .class = &am33xx_epwmss_hwmod_class,
820 .clkdm_name = "l4ls_clkdm", 820 .clkdm_name = "l4ls_clkdm",
821 .mpu_irqs = am33xx_ehrpwm1_irqs, 821 .mpu_irqs = am33xx_ehrpwm1_irqs,
822 .main_clk = "l4ls_gclk", 822 .main_clk = "l4ls_gclk",
823 .prcm = { 823 .prcm = {
824 .omap4 = { 824 .omap4 = {
825 .clkctrl_offs = AM33XX_CM_PER_EPWMSS1_CLKCTRL_OFFSET, 825 .clkctrl_offs = AM33XX_CM_PER_EPWMSS1_CLKCTRL_OFFSET,
826 .modulemode = MODULEMODE_SWCTRL, 826 .modulemode = MODULEMODE_SWCTRL,
827 }, 827 },
828 }, 828 },
829 }; 829 };
830 830
831 /* ehrpwm2 */ 831 /* ehrpwm2 */
832 static struct omap_hwmod_irq_info am33xx_ehrpwm2_irqs[] = { 832 static struct omap_hwmod_irq_info am33xx_ehrpwm2_irqs[] = {
833 { .name = "int", .irq = 39 + OMAP_INTC_START, }, 833 { .name = "int", .irq = 39 + OMAP_INTC_START, },
834 { .name = "tzint", .irq = 60 + OMAP_INTC_START, }, 834 { .name = "tzint", .irq = 60 + OMAP_INTC_START, },
835 { .irq = -1 }, 835 { .irq = -1 },
836 }; 836 };
837 837
838 static struct omap_hwmod am33xx_ehrpwm2_hwmod = { 838 static struct omap_hwmod am33xx_ehrpwm2_hwmod = {
839 .name = "ehrpwm2", 839 .name = "ehrpwm2",
840 .class = &am33xx_epwmss_hwmod_class, 840 .class = &am33xx_epwmss_hwmod_class,
841 .clkdm_name = "l4ls_clkdm", 841 .clkdm_name = "l4ls_clkdm",
842 .mpu_irqs = am33xx_ehrpwm2_irqs, 842 .mpu_irqs = am33xx_ehrpwm2_irqs,
843 .main_clk = "l4ls_gclk", 843 .main_clk = "l4ls_gclk",
844 .prcm = { 844 .prcm = {
845 .omap4 = { 845 .omap4 = {
846 .clkctrl_offs = AM33XX_CM_PER_EPWMSS2_CLKCTRL_OFFSET, 846 .clkctrl_offs = AM33XX_CM_PER_EPWMSS2_CLKCTRL_OFFSET,
847 .modulemode = MODULEMODE_SWCTRL, 847 .modulemode = MODULEMODE_SWCTRL,
848 }, 848 },
849 }, 849 },
850 }; 850 };
851 851
852 /* ecap0 */ 852 /* ecap0 */
853 static struct omap_hwmod_irq_info am33xx_ecap0_irqs[] = { 853 static struct omap_hwmod_irq_info am33xx_ecap0_irqs[] = {
854 { .irq = 31 + OMAP_INTC_START, }, 854 { .irq = 31 + OMAP_INTC_START, },
855 { .irq = -1 }, 855 { .irq = -1 },
856 }; 856 };
857 857
858 static struct omap_hwmod am33xx_ecap0_hwmod = { 858 static struct omap_hwmod am33xx_ecap0_hwmod = {
859 .name = "ecap0", 859 .name = "ecap0",
860 .class = &am33xx_epwmss_hwmod_class, 860 .class = &am33xx_epwmss_hwmod_class,
861 .clkdm_name = "l4ls_clkdm", 861 .clkdm_name = "l4ls_clkdm",
862 .mpu_irqs = am33xx_ecap0_irqs, 862 .mpu_irqs = am33xx_ecap0_irqs,
863 .main_clk = "l4ls_gclk", 863 .main_clk = "l4ls_gclk",
864 .prcm = { 864 .prcm = {
865 .omap4 = { 865 .omap4 = {
866 .clkctrl_offs = AM33XX_CM_PER_EPWMSS0_CLKCTRL_OFFSET, 866 .clkctrl_offs = AM33XX_CM_PER_EPWMSS0_CLKCTRL_OFFSET,
867 .modulemode = MODULEMODE_SWCTRL, 867 .modulemode = MODULEMODE_SWCTRL,
868 }, 868 },
869 }, 869 },
870 }; 870 };
871 871
872 /* ecap1 */ 872 /* ecap1 */
873 static struct omap_hwmod_irq_info am33xx_ecap1_irqs[] = { 873 static struct omap_hwmod_irq_info am33xx_ecap1_irqs[] = {
874 { .irq = 47 + OMAP_INTC_START, }, 874 { .irq = 47 + OMAP_INTC_START, },
875 { .irq = -1 }, 875 { .irq = -1 },
876 }; 876 };
877 877
878 static struct omap_hwmod am33xx_ecap1_hwmod = { 878 static struct omap_hwmod am33xx_ecap1_hwmod = {
879 .name = "ecap1", 879 .name = "ecap1",
880 .class = &am33xx_epwmss_hwmod_class, 880 .class = &am33xx_epwmss_hwmod_class,
881 .clkdm_name = "l4ls_clkdm", 881 .clkdm_name = "l4ls_clkdm",
882 .mpu_irqs = am33xx_ecap1_irqs, 882 .mpu_irqs = am33xx_ecap1_irqs,
883 .main_clk = "l4ls_gclk", 883 .main_clk = "l4ls_gclk",
884 .prcm = { 884 .prcm = {
885 .omap4 = { 885 .omap4 = {
886 .clkctrl_offs = AM33XX_CM_PER_EPWMSS1_CLKCTRL_OFFSET, 886 .clkctrl_offs = AM33XX_CM_PER_EPWMSS1_CLKCTRL_OFFSET,
887 .modulemode = MODULEMODE_SWCTRL, 887 .modulemode = MODULEMODE_SWCTRL,
888 }, 888 },
889 }, 889 },
890 }; 890 };
891 891
892 /* ecap2 */ 892 /* ecap2 */
893 static struct omap_hwmod_irq_info am33xx_ecap2_irqs[] = { 893 static struct omap_hwmod_irq_info am33xx_ecap2_irqs[] = {
894 { .irq = 61 + OMAP_INTC_START, }, 894 { .irq = 61 + OMAP_INTC_START, },
895 { .irq = -1 }, 895 { .irq = -1 },
896 }; 896 };
897 897
898 static struct omap_hwmod am33xx_ecap2_hwmod = { 898 static struct omap_hwmod am33xx_ecap2_hwmod = {
899 .name = "ecap2", 899 .name = "ecap2",
900 .mpu_irqs = am33xx_ecap2_irqs, 900 .mpu_irqs = am33xx_ecap2_irqs,
901 .class = &am33xx_epwmss_hwmod_class, 901 .class = &am33xx_epwmss_hwmod_class,
902 .clkdm_name = "l4ls_clkdm", 902 .clkdm_name = "l4ls_clkdm",
903 .main_clk = "l4ls_gclk", 903 .main_clk = "l4ls_gclk",
904 .prcm = { 904 .prcm = {
905 .omap4 = { 905 .omap4 = {
906 .clkctrl_offs = AM33XX_CM_PER_EPWMSS2_CLKCTRL_OFFSET, 906 .clkctrl_offs = AM33XX_CM_PER_EPWMSS2_CLKCTRL_OFFSET,
907 .modulemode = MODULEMODE_SWCTRL, 907 .modulemode = MODULEMODE_SWCTRL,
908 }, 908 },
909 }, 909 },
910 }; 910 };
911 911
912 /* 912 /*
913 * 'gpio' class: for gpio 0,1,2,3 913 * 'gpio' class: for gpio 0,1,2,3
914 */ 914 */
915 static struct omap_hwmod_class_sysconfig am33xx_gpio_sysc = { 915 static struct omap_hwmod_class_sysconfig am33xx_gpio_sysc = {
916 .rev_offs = 0x0000, 916 .rev_offs = 0x0000,
917 .sysc_offs = 0x0010, 917 .sysc_offs = 0x0010,
918 .syss_offs = 0x0114, 918 .syss_offs = 0x0114,
919 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP | 919 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
920 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET | 920 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
921 SYSS_HAS_RESET_STATUS), 921 SYSS_HAS_RESET_STATUS),
922 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 922 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
923 SIDLE_SMART_WKUP), 923 SIDLE_SMART_WKUP),
924 .sysc_fields = &omap_hwmod_sysc_type1, 924 .sysc_fields = &omap_hwmod_sysc_type1,
925 }; 925 };
926 926
927 static struct omap_hwmod_class am33xx_gpio_hwmod_class = { 927 static struct omap_hwmod_class am33xx_gpio_hwmod_class = {
928 .name = "gpio", 928 .name = "gpio",
929 .sysc = &am33xx_gpio_sysc, 929 .sysc = &am33xx_gpio_sysc,
930 .rev = 2, 930 .rev = 2,
931 }; 931 };
932 932
933 static struct omap_gpio_dev_attr gpio_dev_attr = { 933 static struct omap_gpio_dev_attr gpio_dev_attr = {
934 .bank_width = 32, 934 .bank_width = 32,
935 .dbck_flag = true, 935 .dbck_flag = true,
936 }; 936 };
937 937
938 /* gpio0 */ 938 /* gpio0 */
939 static struct omap_hwmod_opt_clk gpio0_opt_clks[] = { 939 static struct omap_hwmod_opt_clk gpio0_opt_clks[] = {
940 { .role = "dbclk", .clk = "gpio0_dbclk" }, 940 { .role = "dbclk", .clk = "gpio0_dbclk" },
941 }; 941 };
942 942
943 static struct omap_hwmod_irq_info am33xx_gpio0_irqs[] = { 943 static struct omap_hwmod_irq_info am33xx_gpio0_irqs[] = {
944 { .irq = 96 + OMAP_INTC_START, }, 944 { .irq = 96 + OMAP_INTC_START, },
945 { .irq = -1 }, 945 { .irq = -1 },
946 }; 946 };
947 947
948 static struct omap_hwmod am33xx_gpio0_hwmod = { 948 static struct omap_hwmod am33xx_gpio0_hwmod = {
949 .name = "gpio1", 949 .name = "gpio1",
950 .class = &am33xx_gpio_hwmod_class, 950 .class = &am33xx_gpio_hwmod_class,
951 .clkdm_name = "l4_wkup_clkdm", 951 .clkdm_name = "l4_wkup_clkdm",
952 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 952 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
953 .mpu_irqs = am33xx_gpio0_irqs, 953 .mpu_irqs = am33xx_gpio0_irqs,
954 .main_clk = "dpll_core_m4_div2_ck", 954 .main_clk = "dpll_core_m4_div2_ck",
955 .prcm = { 955 .prcm = {
956 .omap4 = { 956 .omap4 = {
957 .clkctrl_offs = AM33XX_CM_WKUP_GPIO0_CLKCTRL_OFFSET, 957 .clkctrl_offs = AM33XX_CM_WKUP_GPIO0_CLKCTRL_OFFSET,
958 .modulemode = MODULEMODE_SWCTRL, 958 .modulemode = MODULEMODE_SWCTRL,
959 }, 959 },
960 }, 960 },
961 .opt_clks = gpio0_opt_clks, 961 .opt_clks = gpio0_opt_clks,
962 .opt_clks_cnt = ARRAY_SIZE(gpio0_opt_clks), 962 .opt_clks_cnt = ARRAY_SIZE(gpio0_opt_clks),
963 .dev_attr = &gpio_dev_attr, 963 .dev_attr = &gpio_dev_attr,
964 }; 964 };
965 965
966 /* gpio1 */ 966 /* gpio1 */
967 static struct omap_hwmod_irq_info am33xx_gpio1_irqs[] = { 967 static struct omap_hwmod_irq_info am33xx_gpio1_irqs[] = {
968 { .irq = 98 + OMAP_INTC_START, }, 968 { .irq = 98 + OMAP_INTC_START, },
969 { .irq = -1 }, 969 { .irq = -1 },
970 }; 970 };
971 971
972 static struct omap_hwmod_opt_clk gpio1_opt_clks[] = { 972 static struct omap_hwmod_opt_clk gpio1_opt_clks[] = {
973 { .role = "dbclk", .clk = "gpio1_dbclk" }, 973 { .role = "dbclk", .clk = "gpio1_dbclk" },
974 }; 974 };
975 975
976 static struct omap_hwmod am33xx_gpio1_hwmod = { 976 static struct omap_hwmod am33xx_gpio1_hwmod = {
977 .name = "gpio2", 977 .name = "gpio2",
978 .class = &am33xx_gpio_hwmod_class, 978 .class = &am33xx_gpio_hwmod_class,
979 .clkdm_name = "l4ls_clkdm", 979 .clkdm_name = "l4ls_clkdm",
980 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 980 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
981 .mpu_irqs = am33xx_gpio1_irqs, 981 .mpu_irqs = am33xx_gpio1_irqs,
982 .main_clk = "l4ls_gclk", 982 .main_clk = "l4ls_gclk",
983 .prcm = { 983 .prcm = {
984 .omap4 = { 984 .omap4 = {
985 .clkctrl_offs = AM33XX_CM_PER_GPIO1_CLKCTRL_OFFSET, 985 .clkctrl_offs = AM33XX_CM_PER_GPIO1_CLKCTRL_OFFSET,
986 .modulemode = MODULEMODE_SWCTRL, 986 .modulemode = MODULEMODE_SWCTRL,
987 }, 987 },
988 }, 988 },
989 .opt_clks = gpio1_opt_clks, 989 .opt_clks = gpio1_opt_clks,
990 .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks), 990 .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks),
991 .dev_attr = &gpio_dev_attr, 991 .dev_attr = &gpio_dev_attr,
992 }; 992 };
993 993
994 /* gpio2 */ 994 /* gpio2 */
995 static struct omap_hwmod_irq_info am33xx_gpio2_irqs[] = { 995 static struct omap_hwmod_irq_info am33xx_gpio2_irqs[] = {
996 { .irq = 32 + OMAP_INTC_START, }, 996 { .irq = 32 + OMAP_INTC_START, },
997 { .irq = -1 }, 997 { .irq = -1 },
998 }; 998 };
999 999
1000 static struct omap_hwmod_opt_clk gpio2_opt_clks[] = { 1000 static struct omap_hwmod_opt_clk gpio2_opt_clks[] = {
1001 { .role = "dbclk", .clk = "gpio2_dbclk" }, 1001 { .role = "dbclk", .clk = "gpio2_dbclk" },
1002 }; 1002 };
1003 1003
1004 static struct omap_hwmod am33xx_gpio2_hwmod = { 1004 static struct omap_hwmod am33xx_gpio2_hwmod = {
1005 .name = "gpio3", 1005 .name = "gpio3",
1006 .class = &am33xx_gpio_hwmod_class, 1006 .class = &am33xx_gpio_hwmod_class,
1007 .clkdm_name = "l4ls_clkdm", 1007 .clkdm_name = "l4ls_clkdm",
1008 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 1008 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
1009 .mpu_irqs = am33xx_gpio2_irqs, 1009 .mpu_irqs = am33xx_gpio2_irqs,
1010 .main_clk = "l4ls_gclk", 1010 .main_clk = "l4ls_gclk",
1011 .prcm = { 1011 .prcm = {
1012 .omap4 = { 1012 .omap4 = {
1013 .clkctrl_offs = AM33XX_CM_PER_GPIO2_CLKCTRL_OFFSET, 1013 .clkctrl_offs = AM33XX_CM_PER_GPIO2_CLKCTRL_OFFSET,
1014 .modulemode = MODULEMODE_SWCTRL, 1014 .modulemode = MODULEMODE_SWCTRL,
1015 }, 1015 },
1016 }, 1016 },
1017 .opt_clks = gpio2_opt_clks, 1017 .opt_clks = gpio2_opt_clks,
1018 .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks), 1018 .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks),
1019 .dev_attr = &gpio_dev_attr, 1019 .dev_attr = &gpio_dev_attr,
1020 }; 1020 };
1021 1021
1022 /* gpio3 */ 1022 /* gpio3 */
1023 static struct omap_hwmod_irq_info am33xx_gpio3_irqs[] = { 1023 static struct omap_hwmod_irq_info am33xx_gpio3_irqs[] = {
1024 { .irq = 62 + OMAP_INTC_START, }, 1024 { .irq = 62 + OMAP_INTC_START, },
1025 { .irq = -1 }, 1025 { .irq = -1 },
1026 }; 1026 };
1027 1027
1028 static struct omap_hwmod_opt_clk gpio3_opt_clks[] = { 1028 static struct omap_hwmod_opt_clk gpio3_opt_clks[] = {
1029 { .role = "dbclk", .clk = "gpio3_dbclk" }, 1029 { .role = "dbclk", .clk = "gpio3_dbclk" },
1030 }; 1030 };
1031 1031
1032 static struct omap_hwmod am33xx_gpio3_hwmod = { 1032 static struct omap_hwmod am33xx_gpio3_hwmod = {
1033 .name = "gpio4", 1033 .name = "gpio4",
1034 .class = &am33xx_gpio_hwmod_class, 1034 .class = &am33xx_gpio_hwmod_class,
1035 .clkdm_name = "l4ls_clkdm", 1035 .clkdm_name = "l4ls_clkdm",
1036 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 1036 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
1037 .mpu_irqs = am33xx_gpio3_irqs, 1037 .mpu_irqs = am33xx_gpio3_irqs,
1038 .main_clk = "l4ls_gclk", 1038 .main_clk = "l4ls_gclk",
1039 .prcm = { 1039 .prcm = {
1040 .omap4 = { 1040 .omap4 = {
1041 .clkctrl_offs = AM33XX_CM_PER_GPIO3_CLKCTRL_OFFSET, 1041 .clkctrl_offs = AM33XX_CM_PER_GPIO3_CLKCTRL_OFFSET,
1042 .modulemode = MODULEMODE_SWCTRL, 1042 .modulemode = MODULEMODE_SWCTRL,
1043 }, 1043 },
1044 }, 1044 },
1045 .opt_clks = gpio3_opt_clks, 1045 .opt_clks = gpio3_opt_clks,
1046 .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks), 1046 .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks),
1047 .dev_attr = &gpio_dev_attr, 1047 .dev_attr = &gpio_dev_attr,
1048 }; 1048 };
1049 1049
1050 /* gpmc */ 1050 /* gpmc */
1051 static struct omap_hwmod_class_sysconfig gpmc_sysc = { 1051 static struct omap_hwmod_class_sysconfig gpmc_sysc = {
1052 .rev_offs = 0x0, 1052 .rev_offs = 0x0,
1053 .sysc_offs = 0x10, 1053 .sysc_offs = 0x10,
1054 .syss_offs = 0x14, 1054 .syss_offs = 0x14,
1055 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE | 1055 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
1056 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 1056 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
1057 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1057 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1058 .sysc_fields = &omap_hwmod_sysc_type1, 1058 .sysc_fields = &omap_hwmod_sysc_type1,
1059 }; 1059 };
1060 1060
1061 static struct omap_hwmod_class am33xx_gpmc_hwmod_class = { 1061 static struct omap_hwmod_class am33xx_gpmc_hwmod_class = {
1062 .name = "gpmc", 1062 .name = "gpmc",
1063 .sysc = &gpmc_sysc, 1063 .sysc = &gpmc_sysc,
1064 }; 1064 };
1065 1065
1066 static struct omap_hwmod_irq_info am33xx_gpmc_irqs[] = { 1066 static struct omap_hwmod_irq_info am33xx_gpmc_irqs[] = {
1067 { .irq = 100 + OMAP_INTC_START, }, 1067 { .irq = 100 + OMAP_INTC_START, },
1068 { .irq = -1 }, 1068 { .irq = -1 },
1069 }; 1069 };
1070 1070
1071 static struct omap_hwmod am33xx_gpmc_hwmod = { 1071 static struct omap_hwmod am33xx_gpmc_hwmod = {
1072 .name = "gpmc", 1072 .name = "gpmc",
1073 .class = &am33xx_gpmc_hwmod_class, 1073 .class = &am33xx_gpmc_hwmod_class,
1074 .clkdm_name = "l3s_clkdm", 1074 .clkdm_name = "l3s_clkdm",
1075 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET), 1075 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET),
1076 .mpu_irqs = am33xx_gpmc_irqs, 1076 .mpu_irqs = am33xx_gpmc_irqs,
1077 .main_clk = "l3s_gclk", 1077 .main_clk = "l3s_gclk",
1078 .prcm = { 1078 .prcm = {
1079 .omap4 = { 1079 .omap4 = {
1080 .clkctrl_offs = AM33XX_CM_PER_GPMC_CLKCTRL_OFFSET, 1080 .clkctrl_offs = AM33XX_CM_PER_GPMC_CLKCTRL_OFFSET,
1081 .modulemode = MODULEMODE_SWCTRL, 1081 .modulemode = MODULEMODE_SWCTRL,
1082 }, 1082 },
1083 }, 1083 },
1084 }; 1084 };
1085 1085
1086 /* 'i2c' class */ 1086 /* 'i2c' class */
1087 static struct omap_hwmod_class_sysconfig am33xx_i2c_sysc = { 1087 static struct omap_hwmod_class_sysconfig am33xx_i2c_sysc = {
1088 .sysc_offs = 0x0010, 1088 .sysc_offs = 0x0010,
1089 .syss_offs = 0x0090, 1089 .syss_offs = 0x0090,
1090 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY | 1090 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
1091 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE | 1091 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
1092 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 1092 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
1093 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1093 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1094 SIDLE_SMART_WKUP), 1094 SIDLE_SMART_WKUP),
1095 .sysc_fields = &omap_hwmod_sysc_type1, 1095 .sysc_fields = &omap_hwmod_sysc_type1,
1096 }; 1096 };
1097 1097
1098 static struct omap_hwmod_class i2c_class = { 1098 static struct omap_hwmod_class i2c_class = {
1099 .name = "i2c", 1099 .name = "i2c",
1100 .sysc = &am33xx_i2c_sysc, 1100 .sysc = &am33xx_i2c_sysc,
1101 .rev = OMAP_I2C_IP_VERSION_2, 1101 .rev = OMAP_I2C_IP_VERSION_2,
1102 .reset = &omap_i2c_reset, 1102 .reset = &omap_i2c_reset,
1103 }; 1103 };
1104 1104
1105 static struct omap_i2c_dev_attr i2c_dev_attr = { 1105 static struct omap_i2c_dev_attr i2c_dev_attr = {
1106 .flags = OMAP_I2C_FLAG_BUS_SHIFT_NONE | 1106 .flags = OMAP_I2C_FLAG_BUS_SHIFT_NONE,
1107 OMAP_I2C_FLAG_RESET_REGS_POSTIDLE,
1108 }; 1107 };
1109 1108
1110 /* i2c1 */ 1109 /* i2c1 */
1111 static struct omap_hwmod_irq_info i2c1_mpu_irqs[] = { 1110 static struct omap_hwmod_irq_info i2c1_mpu_irqs[] = {
1112 { .irq = 70 + OMAP_INTC_START, }, 1111 { .irq = 70 + OMAP_INTC_START, },
1113 { .irq = -1 }, 1112 { .irq = -1 },
1114 }; 1113 };
1115 1114
1116 static struct omap_hwmod_dma_info i2c1_edma_reqs[] = { 1115 static struct omap_hwmod_dma_info i2c1_edma_reqs[] = {
1117 { .name = "tx", .dma_req = 0, }, 1116 { .name = "tx", .dma_req = 0, },
1118 { .name = "rx", .dma_req = 0, }, 1117 { .name = "rx", .dma_req = 0, },
1119 { .dma_req = -1 } 1118 { .dma_req = -1 }
1120 }; 1119 };
1121 1120
1122 static struct omap_hwmod am33xx_i2c1_hwmod = { 1121 static struct omap_hwmod am33xx_i2c1_hwmod = {
1123 .name = "i2c1", 1122 .name = "i2c1",
1124 .class = &i2c_class, 1123 .class = &i2c_class,
1125 .clkdm_name = "l4_wkup_clkdm", 1124 .clkdm_name = "l4_wkup_clkdm",
1126 .mpu_irqs = i2c1_mpu_irqs, 1125 .mpu_irqs = i2c1_mpu_irqs,
1127 .sdma_reqs = i2c1_edma_reqs, 1126 .sdma_reqs = i2c1_edma_reqs,
1128 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT, 1127 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
1129 .main_clk = "dpll_per_m2_div4_wkupdm_ck", 1128 .main_clk = "dpll_per_m2_div4_wkupdm_ck",
1130 .prcm = { 1129 .prcm = {
1131 .omap4 = { 1130 .omap4 = {
1132 .clkctrl_offs = AM33XX_CM_WKUP_I2C0_CLKCTRL_OFFSET, 1131 .clkctrl_offs = AM33XX_CM_WKUP_I2C0_CLKCTRL_OFFSET,
1133 .modulemode = MODULEMODE_SWCTRL, 1132 .modulemode = MODULEMODE_SWCTRL,
1134 }, 1133 },
1135 }, 1134 },
1136 .dev_attr = &i2c_dev_attr, 1135 .dev_attr = &i2c_dev_attr,
1137 }; 1136 };
1138 1137
1139 /* i2c1 */ 1138 /* i2c1 */
1140 static struct omap_hwmod_irq_info i2c2_mpu_irqs[] = { 1139 static struct omap_hwmod_irq_info i2c2_mpu_irqs[] = {
1141 { .irq = 71 + OMAP_INTC_START, }, 1140 { .irq = 71 + OMAP_INTC_START, },
1142 { .irq = -1 }, 1141 { .irq = -1 },
1143 }; 1142 };
1144 1143
1145 static struct omap_hwmod_dma_info i2c2_edma_reqs[] = { 1144 static struct omap_hwmod_dma_info i2c2_edma_reqs[] = {
1146 { .name = "tx", .dma_req = 0, }, 1145 { .name = "tx", .dma_req = 0, },
1147 { .name = "rx", .dma_req = 0, }, 1146 { .name = "rx", .dma_req = 0, },
1148 { .dma_req = -1 } 1147 { .dma_req = -1 }
1149 }; 1148 };
1150 1149
1151 static struct omap_hwmod am33xx_i2c2_hwmod = { 1150 static struct omap_hwmod am33xx_i2c2_hwmod = {
1152 .name = "i2c2", 1151 .name = "i2c2",
1153 .class = &i2c_class, 1152 .class = &i2c_class,
1154 .clkdm_name = "l4ls_clkdm", 1153 .clkdm_name = "l4ls_clkdm",
1155 .mpu_irqs = i2c2_mpu_irqs, 1154 .mpu_irqs = i2c2_mpu_irqs,
1156 .sdma_reqs = i2c2_edma_reqs, 1155 .sdma_reqs = i2c2_edma_reqs,
1157 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT, 1156 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
1158 .main_clk = "dpll_per_m2_div4_ck", 1157 .main_clk = "dpll_per_m2_div4_ck",
1159 .prcm = { 1158 .prcm = {
1160 .omap4 = { 1159 .omap4 = {
1161 .clkctrl_offs = AM33XX_CM_PER_I2C1_CLKCTRL_OFFSET, 1160 .clkctrl_offs = AM33XX_CM_PER_I2C1_CLKCTRL_OFFSET,
1162 .modulemode = MODULEMODE_SWCTRL, 1161 .modulemode = MODULEMODE_SWCTRL,
1163 }, 1162 },
1164 }, 1163 },
1165 .dev_attr = &i2c_dev_attr, 1164 .dev_attr = &i2c_dev_attr,
1166 }; 1165 };
1167 1166
1168 /* i2c3 */ 1167 /* i2c3 */
1169 static struct omap_hwmod_dma_info i2c3_edma_reqs[] = { 1168 static struct omap_hwmod_dma_info i2c3_edma_reqs[] = {
1170 { .name = "tx", .dma_req = 0, }, 1169 { .name = "tx", .dma_req = 0, },
1171 { .name = "rx", .dma_req = 0, }, 1170 { .name = "rx", .dma_req = 0, },
1172 { .dma_req = -1 } 1171 { .dma_req = -1 }
1173 }; 1172 };
1174 1173
1175 static struct omap_hwmod_irq_info i2c3_mpu_irqs[] = { 1174 static struct omap_hwmod_irq_info i2c3_mpu_irqs[] = {
1176 { .irq = 30 + OMAP_INTC_START, }, 1175 { .irq = 30 + OMAP_INTC_START, },
1177 { .irq = -1 }, 1176 { .irq = -1 },
1178 }; 1177 };
1179 1178
1180 static struct omap_hwmod am33xx_i2c3_hwmod = { 1179 static struct omap_hwmod am33xx_i2c3_hwmod = {
1181 .name = "i2c3", 1180 .name = "i2c3",
1182 .class = &i2c_class, 1181 .class = &i2c_class,
1183 .clkdm_name = "l4ls_clkdm", 1182 .clkdm_name = "l4ls_clkdm",
1184 .mpu_irqs = i2c3_mpu_irqs, 1183 .mpu_irqs = i2c3_mpu_irqs,
1185 .sdma_reqs = i2c3_edma_reqs, 1184 .sdma_reqs = i2c3_edma_reqs,
1186 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT, 1185 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
1187 .main_clk = "dpll_per_m2_div4_ck", 1186 .main_clk = "dpll_per_m2_div4_ck",
1188 .prcm = { 1187 .prcm = {
1189 .omap4 = { 1188 .omap4 = {
1190 .clkctrl_offs = AM33XX_CM_PER_I2C2_CLKCTRL_OFFSET, 1189 .clkctrl_offs = AM33XX_CM_PER_I2C2_CLKCTRL_OFFSET,
1191 .modulemode = MODULEMODE_SWCTRL, 1190 .modulemode = MODULEMODE_SWCTRL,
1192 }, 1191 },
1193 }, 1192 },
1194 .dev_attr = &i2c_dev_attr, 1193 .dev_attr = &i2c_dev_attr,
1195 }; 1194 };
1196 1195
1197 1196
1198 /* lcdc */ 1197 /* lcdc */
1199 static struct omap_hwmod_class_sysconfig lcdc_sysc = { 1198 static struct omap_hwmod_class_sysconfig lcdc_sysc = {
1200 .rev_offs = 0x0, 1199 .rev_offs = 0x0,
1201 .sysc_offs = 0x54, 1200 .sysc_offs = 0x54,
1202 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE), 1201 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE),
1203 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1202 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1204 .sysc_fields = &omap_hwmod_sysc_type2, 1203 .sysc_fields = &omap_hwmod_sysc_type2,
1205 }; 1204 };
1206 1205
1207 static struct omap_hwmod_class am33xx_lcdc_hwmod_class = { 1206 static struct omap_hwmod_class am33xx_lcdc_hwmod_class = {
1208 .name = "lcdc", 1207 .name = "lcdc",
1209 .sysc = &lcdc_sysc, 1208 .sysc = &lcdc_sysc,
1210 }; 1209 };
1211 1210
1212 static struct omap_hwmod_irq_info am33xx_lcdc_irqs[] = { 1211 static struct omap_hwmod_irq_info am33xx_lcdc_irqs[] = {
1213 { .irq = 36 + OMAP_INTC_START, }, 1212 { .irq = 36 + OMAP_INTC_START, },
1214 { .irq = -1 }, 1213 { .irq = -1 },
1215 }; 1214 };
1216 1215
1217 static struct omap_hwmod am33xx_lcdc_hwmod = { 1216 static struct omap_hwmod am33xx_lcdc_hwmod = {
1218 .name = "lcdc", 1217 .name = "lcdc",
1219 .class = &am33xx_lcdc_hwmod_class, 1218 .class = &am33xx_lcdc_hwmod_class,
1220 .clkdm_name = "lcdc_clkdm", 1219 .clkdm_name = "lcdc_clkdm",
1221 .mpu_irqs = am33xx_lcdc_irqs, 1220 .mpu_irqs = am33xx_lcdc_irqs,
1222 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY, 1221 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
1223 .main_clk = "lcd_gclk", 1222 .main_clk = "lcd_gclk",
1224 .prcm = { 1223 .prcm = {
1225 .omap4 = { 1224 .omap4 = {
1226 .clkctrl_offs = AM33XX_CM_PER_LCDC_CLKCTRL_OFFSET, 1225 .clkctrl_offs = AM33XX_CM_PER_LCDC_CLKCTRL_OFFSET,
1227 .modulemode = MODULEMODE_SWCTRL, 1226 .modulemode = MODULEMODE_SWCTRL,
1228 }, 1227 },
1229 }, 1228 },
1230 }; 1229 };
1231 1230
1232 /* 1231 /*
1233 * 'mailbox' class 1232 * 'mailbox' class
1234 * mailbox module allowing communication between the on-chip processors using a 1233 * mailbox module allowing communication between the on-chip processors using a
1235 * queued mailbox-interrupt mechanism. 1234 * queued mailbox-interrupt mechanism.
1236 */ 1235 */
1237 static struct omap_hwmod_class_sysconfig am33xx_mailbox_sysc = { 1236 static struct omap_hwmod_class_sysconfig am33xx_mailbox_sysc = {
1238 .rev_offs = 0x0000, 1237 .rev_offs = 0x0000,
1239 .sysc_offs = 0x0010, 1238 .sysc_offs = 0x0010,
1240 .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE | 1239 .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
1241 SYSC_HAS_SOFTRESET), 1240 SYSC_HAS_SOFTRESET),
1242 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1241 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1243 .sysc_fields = &omap_hwmod_sysc_type2, 1242 .sysc_fields = &omap_hwmod_sysc_type2,
1244 }; 1243 };
1245 1244
1246 static struct omap_hwmod_class am33xx_mailbox_hwmod_class = { 1245 static struct omap_hwmod_class am33xx_mailbox_hwmod_class = {
1247 .name = "mailbox", 1246 .name = "mailbox",
1248 .sysc = &am33xx_mailbox_sysc, 1247 .sysc = &am33xx_mailbox_sysc,
1249 }; 1248 };
1250 1249
1251 static struct omap_hwmod_irq_info am33xx_mailbox_irqs[] = { 1250 static struct omap_hwmod_irq_info am33xx_mailbox_irqs[] = {
1252 { .irq = 77 + OMAP_INTC_START, }, 1251 { .irq = 77 + OMAP_INTC_START, },
1253 { .irq = -1 }, 1252 { .irq = -1 },
1254 }; 1253 };
1255 1254
1256 static struct omap_hwmod am33xx_mailbox_hwmod = { 1255 static struct omap_hwmod am33xx_mailbox_hwmod = {
1257 .name = "mailbox", 1256 .name = "mailbox",
1258 .class = &am33xx_mailbox_hwmod_class, 1257 .class = &am33xx_mailbox_hwmod_class,
1259 .clkdm_name = "l4ls_clkdm", 1258 .clkdm_name = "l4ls_clkdm",
1260 .mpu_irqs = am33xx_mailbox_irqs, 1259 .mpu_irqs = am33xx_mailbox_irqs,
1261 .main_clk = "l4ls_gclk", 1260 .main_clk = "l4ls_gclk",
1262 .prcm = { 1261 .prcm = {
1263 .omap4 = { 1262 .omap4 = {
1264 .clkctrl_offs = AM33XX_CM_PER_MAILBOX0_CLKCTRL_OFFSET, 1263 .clkctrl_offs = AM33XX_CM_PER_MAILBOX0_CLKCTRL_OFFSET,
1265 .modulemode = MODULEMODE_SWCTRL, 1264 .modulemode = MODULEMODE_SWCTRL,
1266 }, 1265 },
1267 }, 1266 },
1268 }; 1267 };
1269 1268
1270 /* 1269 /*
1271 * 'mcasp' class 1270 * 'mcasp' class
1272 */ 1271 */
1273 static struct omap_hwmod_class_sysconfig am33xx_mcasp_sysc = { 1272 static struct omap_hwmod_class_sysconfig am33xx_mcasp_sysc = {
1274 .rev_offs = 0x0, 1273 .rev_offs = 0x0,
1275 .sysc_offs = 0x4, 1274 .sysc_offs = 0x4,
1276 .sysc_flags = SYSC_HAS_SIDLEMODE, 1275 .sysc_flags = SYSC_HAS_SIDLEMODE,
1277 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1276 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1278 .sysc_fields = &omap_hwmod_sysc_type3, 1277 .sysc_fields = &omap_hwmod_sysc_type3,
1279 }; 1278 };
1280 1279
1281 static struct omap_hwmod_class am33xx_mcasp_hwmod_class = { 1280 static struct omap_hwmod_class am33xx_mcasp_hwmod_class = {
1282 .name = "mcasp", 1281 .name = "mcasp",
1283 .sysc = &am33xx_mcasp_sysc, 1282 .sysc = &am33xx_mcasp_sysc,
1284 }; 1283 };
1285 1284
1286 /* mcasp0 */ 1285 /* mcasp0 */
1287 static struct omap_hwmod_irq_info am33xx_mcasp0_irqs[] = { 1286 static struct omap_hwmod_irq_info am33xx_mcasp0_irqs[] = {
1288 { .name = "ax", .irq = 80 + OMAP_INTC_START, }, 1287 { .name = "ax", .irq = 80 + OMAP_INTC_START, },
1289 { .name = "ar", .irq = 81 + OMAP_INTC_START, }, 1288 { .name = "ar", .irq = 81 + OMAP_INTC_START, },
1290 { .irq = -1 }, 1289 { .irq = -1 },
1291 }; 1290 };
1292 1291
1293 static struct omap_hwmod_dma_info am33xx_mcasp0_edma_reqs[] = { 1292 static struct omap_hwmod_dma_info am33xx_mcasp0_edma_reqs[] = {
1294 { .name = "tx", .dma_req = 8, }, 1293 { .name = "tx", .dma_req = 8, },
1295 { .name = "rx", .dma_req = 9, }, 1294 { .name = "rx", .dma_req = 9, },
1296 { .dma_req = -1 } 1295 { .dma_req = -1 }
1297 }; 1296 };
1298 1297
1299 static struct omap_hwmod am33xx_mcasp0_hwmod = { 1298 static struct omap_hwmod am33xx_mcasp0_hwmod = {
1300 .name = "mcasp0", 1299 .name = "mcasp0",
1301 .class = &am33xx_mcasp_hwmod_class, 1300 .class = &am33xx_mcasp_hwmod_class,
1302 .clkdm_name = "l3s_clkdm", 1301 .clkdm_name = "l3s_clkdm",
1303 .mpu_irqs = am33xx_mcasp0_irqs, 1302 .mpu_irqs = am33xx_mcasp0_irqs,
1304 .sdma_reqs = am33xx_mcasp0_edma_reqs, 1303 .sdma_reqs = am33xx_mcasp0_edma_reqs,
1305 .main_clk = "mcasp0_fck", 1304 .main_clk = "mcasp0_fck",
1306 .prcm = { 1305 .prcm = {
1307 .omap4 = { 1306 .omap4 = {
1308 .clkctrl_offs = AM33XX_CM_PER_MCASP0_CLKCTRL_OFFSET, 1307 .clkctrl_offs = AM33XX_CM_PER_MCASP0_CLKCTRL_OFFSET,
1309 .modulemode = MODULEMODE_SWCTRL, 1308 .modulemode = MODULEMODE_SWCTRL,
1310 }, 1309 },
1311 }, 1310 },
1312 }; 1311 };
1313 1312
1314 /* mcasp1 */ 1313 /* mcasp1 */
1315 static struct omap_hwmod_irq_info am33xx_mcasp1_irqs[] = { 1314 static struct omap_hwmod_irq_info am33xx_mcasp1_irqs[] = {
1316 { .name = "ax", .irq = 82 + OMAP_INTC_START, }, 1315 { .name = "ax", .irq = 82 + OMAP_INTC_START, },
1317 { .name = "ar", .irq = 83 + OMAP_INTC_START, }, 1316 { .name = "ar", .irq = 83 + OMAP_INTC_START, },
1318 { .irq = -1 }, 1317 { .irq = -1 },
1319 }; 1318 };
1320 1319
1321 static struct omap_hwmod_dma_info am33xx_mcasp1_edma_reqs[] = { 1320 static struct omap_hwmod_dma_info am33xx_mcasp1_edma_reqs[] = {
1322 { .name = "tx", .dma_req = 10, }, 1321 { .name = "tx", .dma_req = 10, },
1323 { .name = "rx", .dma_req = 11, }, 1322 { .name = "rx", .dma_req = 11, },
1324 { .dma_req = -1 } 1323 { .dma_req = -1 }
1325 }; 1324 };
1326 1325
1327 static struct omap_hwmod am33xx_mcasp1_hwmod = { 1326 static struct omap_hwmod am33xx_mcasp1_hwmod = {
1328 .name = "mcasp1", 1327 .name = "mcasp1",
1329 .class = &am33xx_mcasp_hwmod_class, 1328 .class = &am33xx_mcasp_hwmod_class,
1330 .clkdm_name = "l3s_clkdm", 1329 .clkdm_name = "l3s_clkdm",
1331 .mpu_irqs = am33xx_mcasp1_irqs, 1330 .mpu_irqs = am33xx_mcasp1_irqs,
1332 .sdma_reqs = am33xx_mcasp1_edma_reqs, 1331 .sdma_reqs = am33xx_mcasp1_edma_reqs,
1333 .main_clk = "mcasp1_fck", 1332 .main_clk = "mcasp1_fck",
1334 .prcm = { 1333 .prcm = {
1335 .omap4 = { 1334 .omap4 = {
1336 .clkctrl_offs = AM33XX_CM_PER_MCASP1_CLKCTRL_OFFSET, 1335 .clkctrl_offs = AM33XX_CM_PER_MCASP1_CLKCTRL_OFFSET,
1337 .modulemode = MODULEMODE_SWCTRL, 1336 .modulemode = MODULEMODE_SWCTRL,
1338 }, 1337 },
1339 }, 1338 },
1340 }; 1339 };
1341 1340
1342 /* 'mmc' class */ 1341 /* 'mmc' class */
1343 static struct omap_hwmod_class_sysconfig am33xx_mmc_sysc = { 1342 static struct omap_hwmod_class_sysconfig am33xx_mmc_sysc = {
1344 .rev_offs = 0x1fc, 1343 .rev_offs = 0x1fc,
1345 .sysc_offs = 0x10, 1344 .sysc_offs = 0x10,
1346 .syss_offs = 0x14, 1345 .syss_offs = 0x14,
1347 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 1346 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
1348 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET | 1347 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
1349 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS), 1348 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS),
1350 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1349 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1351 .sysc_fields = &omap_hwmod_sysc_type1, 1350 .sysc_fields = &omap_hwmod_sysc_type1,
1352 }; 1351 };
1353 1352
1354 static struct omap_hwmod_class am33xx_mmc_hwmod_class = { 1353 static struct omap_hwmod_class am33xx_mmc_hwmod_class = {
1355 .name = "mmc", 1354 .name = "mmc",
1356 .sysc = &am33xx_mmc_sysc, 1355 .sysc = &am33xx_mmc_sysc,
1357 }; 1356 };
1358 1357
1359 /* mmc0 */ 1358 /* mmc0 */
1360 static struct omap_hwmod_irq_info am33xx_mmc0_irqs[] = { 1359 static struct omap_hwmod_irq_info am33xx_mmc0_irqs[] = {
1361 { .irq = 64 + OMAP_INTC_START, }, 1360 { .irq = 64 + OMAP_INTC_START, },
1362 { .irq = -1 }, 1361 { .irq = -1 },
1363 }; 1362 };
1364 1363
1365 static struct omap_hwmod_dma_info am33xx_mmc0_edma_reqs[] = { 1364 static struct omap_hwmod_dma_info am33xx_mmc0_edma_reqs[] = {
1366 { .name = "tx", .dma_req = 24, }, 1365 { .name = "tx", .dma_req = 24, },
1367 { .name = "rx", .dma_req = 25, }, 1366 { .name = "rx", .dma_req = 25, },
1368 { .dma_req = -1 } 1367 { .dma_req = -1 }
1369 }; 1368 };
1370 1369
1371 static struct omap_mmc_dev_attr am33xx_mmc0_dev_attr = { 1370 static struct omap_mmc_dev_attr am33xx_mmc0_dev_attr = {
1372 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT, 1371 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
1373 }; 1372 };
1374 1373
1375 static struct omap_hwmod am33xx_mmc0_hwmod = { 1374 static struct omap_hwmod am33xx_mmc0_hwmod = {
1376 .name = "mmc1", 1375 .name = "mmc1",
1377 .class = &am33xx_mmc_hwmod_class, 1376 .class = &am33xx_mmc_hwmod_class,
1378 .clkdm_name = "l4ls_clkdm", 1377 .clkdm_name = "l4ls_clkdm",
1379 .mpu_irqs = am33xx_mmc0_irqs, 1378 .mpu_irqs = am33xx_mmc0_irqs,
1380 .sdma_reqs = am33xx_mmc0_edma_reqs, 1379 .sdma_reqs = am33xx_mmc0_edma_reqs,
1381 .main_clk = "mmc_clk", 1380 .main_clk = "mmc_clk",
1382 .prcm = { 1381 .prcm = {
1383 .omap4 = { 1382 .omap4 = {
1384 .clkctrl_offs = AM33XX_CM_PER_MMC0_CLKCTRL_OFFSET, 1383 .clkctrl_offs = AM33XX_CM_PER_MMC0_CLKCTRL_OFFSET,
1385 .modulemode = MODULEMODE_SWCTRL, 1384 .modulemode = MODULEMODE_SWCTRL,
1386 }, 1385 },
1387 }, 1386 },
1388 .dev_attr = &am33xx_mmc0_dev_attr, 1387 .dev_attr = &am33xx_mmc0_dev_attr,
1389 }; 1388 };
1390 1389
1391 /* mmc1 */ 1390 /* mmc1 */
1392 static struct omap_hwmod_irq_info am33xx_mmc1_irqs[] = { 1391 static struct omap_hwmod_irq_info am33xx_mmc1_irqs[] = {
1393 { .irq = 28 + OMAP_INTC_START, }, 1392 { .irq = 28 + OMAP_INTC_START, },
1394 { .irq = -1 }, 1393 { .irq = -1 },
1395 }; 1394 };
1396 1395
1397 static struct omap_hwmod_dma_info am33xx_mmc1_edma_reqs[] = { 1396 static struct omap_hwmod_dma_info am33xx_mmc1_edma_reqs[] = {
1398 { .name = "tx", .dma_req = 2, }, 1397 { .name = "tx", .dma_req = 2, },
1399 { .name = "rx", .dma_req = 3, }, 1398 { .name = "rx", .dma_req = 3, },
1400 { .dma_req = -1 } 1399 { .dma_req = -1 }
1401 }; 1400 };
1402 1401
1403 static struct omap_mmc_dev_attr am33xx_mmc1_dev_attr = { 1402 static struct omap_mmc_dev_attr am33xx_mmc1_dev_attr = {
1404 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT, 1403 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
1405 }; 1404 };
1406 1405
1407 static struct omap_hwmod am33xx_mmc1_hwmod = { 1406 static struct omap_hwmod am33xx_mmc1_hwmod = {
1408 .name = "mmc2", 1407 .name = "mmc2",
1409 .class = &am33xx_mmc_hwmod_class, 1408 .class = &am33xx_mmc_hwmod_class,
1410 .clkdm_name = "l4ls_clkdm", 1409 .clkdm_name = "l4ls_clkdm",
1411 .mpu_irqs = am33xx_mmc1_irqs, 1410 .mpu_irqs = am33xx_mmc1_irqs,
1412 .sdma_reqs = am33xx_mmc1_edma_reqs, 1411 .sdma_reqs = am33xx_mmc1_edma_reqs,
1413 .main_clk = "mmc_clk", 1412 .main_clk = "mmc_clk",
1414 .prcm = { 1413 .prcm = {
1415 .omap4 = { 1414 .omap4 = {
1416 .clkctrl_offs = AM33XX_CM_PER_MMC1_CLKCTRL_OFFSET, 1415 .clkctrl_offs = AM33XX_CM_PER_MMC1_CLKCTRL_OFFSET,
1417 .modulemode = MODULEMODE_SWCTRL, 1416 .modulemode = MODULEMODE_SWCTRL,
1418 }, 1417 },
1419 }, 1418 },
1420 .dev_attr = &am33xx_mmc1_dev_attr, 1419 .dev_attr = &am33xx_mmc1_dev_attr,
1421 }; 1420 };
1422 1421
1423 /* mmc2 */ 1422 /* mmc2 */
1424 static struct omap_hwmod_irq_info am33xx_mmc2_irqs[] = { 1423 static struct omap_hwmod_irq_info am33xx_mmc2_irqs[] = {
1425 { .irq = 29 + OMAP_INTC_START, }, 1424 { .irq = 29 + OMAP_INTC_START, },
1426 { .irq = -1 }, 1425 { .irq = -1 },
1427 }; 1426 };
1428 1427
1429 static struct omap_hwmod_dma_info am33xx_mmc2_edma_reqs[] = { 1428 static struct omap_hwmod_dma_info am33xx_mmc2_edma_reqs[] = {
1430 { .name = "tx", .dma_req = 64, }, 1429 { .name = "tx", .dma_req = 64, },
1431 { .name = "rx", .dma_req = 65, }, 1430 { .name = "rx", .dma_req = 65, },
1432 { .dma_req = -1 } 1431 { .dma_req = -1 }
1433 }; 1432 };
1434 1433
1435 static struct omap_mmc_dev_attr am33xx_mmc2_dev_attr = { 1434 static struct omap_mmc_dev_attr am33xx_mmc2_dev_attr = {
1436 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT, 1435 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
1437 }; 1436 };
1438 static struct omap_hwmod am33xx_mmc2_hwmod = { 1437 static struct omap_hwmod am33xx_mmc2_hwmod = {
1439 .name = "mmc3", 1438 .name = "mmc3",
1440 .class = &am33xx_mmc_hwmod_class, 1439 .class = &am33xx_mmc_hwmod_class,
1441 .clkdm_name = "l3s_clkdm", 1440 .clkdm_name = "l3s_clkdm",
1442 .mpu_irqs = am33xx_mmc2_irqs, 1441 .mpu_irqs = am33xx_mmc2_irqs,
1443 .sdma_reqs = am33xx_mmc2_edma_reqs, 1442 .sdma_reqs = am33xx_mmc2_edma_reqs,
1444 .main_clk = "mmc_clk", 1443 .main_clk = "mmc_clk",
1445 .prcm = { 1444 .prcm = {
1446 .omap4 = { 1445 .omap4 = {
1447 .clkctrl_offs = AM33XX_CM_PER_MMC2_CLKCTRL_OFFSET, 1446 .clkctrl_offs = AM33XX_CM_PER_MMC2_CLKCTRL_OFFSET,
1448 .modulemode = MODULEMODE_SWCTRL, 1447 .modulemode = MODULEMODE_SWCTRL,
1449 }, 1448 },
1450 }, 1449 },
1451 .dev_attr = &am33xx_mmc2_dev_attr, 1450 .dev_attr = &am33xx_mmc2_dev_attr,
1452 }; 1451 };
1453 1452
1454 /* 1453 /*
1455 * 'rtc' class 1454 * 'rtc' class
1456 * rtc subsystem 1455 * rtc subsystem
1457 */ 1456 */
1458 static struct omap_hwmod_class_sysconfig am33xx_rtc_sysc = { 1457 static struct omap_hwmod_class_sysconfig am33xx_rtc_sysc = {
1459 .rev_offs = 0x0074, 1458 .rev_offs = 0x0074,
1460 .sysc_offs = 0x0078, 1459 .sysc_offs = 0x0078,
1461 .sysc_flags = SYSC_HAS_SIDLEMODE, 1460 .sysc_flags = SYSC_HAS_SIDLEMODE,
1462 .idlemodes = (SIDLE_FORCE | SIDLE_NO | 1461 .idlemodes = (SIDLE_FORCE | SIDLE_NO |
1463 SIDLE_SMART | SIDLE_SMART_WKUP), 1462 SIDLE_SMART | SIDLE_SMART_WKUP),
1464 .sysc_fields = &omap_hwmod_sysc_type3, 1463 .sysc_fields = &omap_hwmod_sysc_type3,
1465 }; 1464 };
1466 1465
1467 static struct omap_hwmod_class am33xx_rtc_hwmod_class = { 1466 static struct omap_hwmod_class am33xx_rtc_hwmod_class = {
1468 .name = "rtc", 1467 .name = "rtc",
1469 .sysc = &am33xx_rtc_sysc, 1468 .sysc = &am33xx_rtc_sysc,
1470 }; 1469 };
1471 1470
1472 static struct omap_hwmod_irq_info am33xx_rtc_irqs[] = { 1471 static struct omap_hwmod_irq_info am33xx_rtc_irqs[] = {
1473 { .name = "rtcint", .irq = 75 + OMAP_INTC_START, }, 1472 { .name = "rtcint", .irq = 75 + OMAP_INTC_START, },
1474 { .name = "rtcalarmint", .irq = 76 + OMAP_INTC_START, }, 1473 { .name = "rtcalarmint", .irq = 76 + OMAP_INTC_START, },
1475 { .irq = -1 }, 1474 { .irq = -1 },
1476 }; 1475 };
1477 1476
1478 static struct omap_hwmod am33xx_rtc_hwmod = { 1477 static struct omap_hwmod am33xx_rtc_hwmod = {
1479 .name = "rtc", 1478 .name = "rtc",
1480 .class = &am33xx_rtc_hwmod_class, 1479 .class = &am33xx_rtc_hwmod_class,
1481 .clkdm_name = "l4_rtc_clkdm", 1480 .clkdm_name = "l4_rtc_clkdm",
1482 .mpu_irqs = am33xx_rtc_irqs, 1481 .mpu_irqs = am33xx_rtc_irqs,
1483 .main_clk = "clk_32768_ck", 1482 .main_clk = "clk_32768_ck",
1484 .prcm = { 1483 .prcm = {
1485 .omap4 = { 1484 .omap4 = {
1486 .clkctrl_offs = AM33XX_CM_RTC_RTC_CLKCTRL_OFFSET, 1485 .clkctrl_offs = AM33XX_CM_RTC_RTC_CLKCTRL_OFFSET,
1487 .modulemode = MODULEMODE_SWCTRL, 1486 .modulemode = MODULEMODE_SWCTRL,
1488 }, 1487 },
1489 }, 1488 },
1490 }; 1489 };
1491 1490
1492 /* 'spi' class */ 1491 /* 'spi' class */
1493 static struct omap_hwmod_class_sysconfig am33xx_mcspi_sysc = { 1492 static struct omap_hwmod_class_sysconfig am33xx_mcspi_sysc = {
1494 .rev_offs = 0x0000, 1493 .rev_offs = 0x0000,
1495 .sysc_offs = 0x0110, 1494 .sysc_offs = 0x0110,
1496 .syss_offs = 0x0114, 1495 .syss_offs = 0x0114,
1497 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 1496 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
1498 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE | 1497 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE |
1499 SYSS_HAS_RESET_STATUS), 1498 SYSS_HAS_RESET_STATUS),
1500 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1499 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1501 .sysc_fields = &omap_hwmod_sysc_type1, 1500 .sysc_fields = &omap_hwmod_sysc_type1,
1502 }; 1501 };
1503 1502
1504 static struct omap_hwmod_class am33xx_spi_hwmod_class = { 1503 static struct omap_hwmod_class am33xx_spi_hwmod_class = {
1505 .name = "mcspi", 1504 .name = "mcspi",
1506 .sysc = &am33xx_mcspi_sysc, 1505 .sysc = &am33xx_mcspi_sysc,
1507 .rev = OMAP4_MCSPI_REV, 1506 .rev = OMAP4_MCSPI_REV,
1508 }; 1507 };
1509 1508
1510 /* spi0 */ 1509 /* spi0 */
1511 static struct omap_hwmod_irq_info am33xx_spi0_irqs[] = { 1510 static struct omap_hwmod_irq_info am33xx_spi0_irqs[] = {
1512 { .irq = 65 + OMAP_INTC_START, }, 1511 { .irq = 65 + OMAP_INTC_START, },
1513 { .irq = -1 }, 1512 { .irq = -1 },
1514 }; 1513 };
1515 1514
1516 static struct omap_hwmod_dma_info am33xx_mcspi0_edma_reqs[] = { 1515 static struct omap_hwmod_dma_info am33xx_mcspi0_edma_reqs[] = {
1517 { .name = "rx0", .dma_req = 17 }, 1516 { .name = "rx0", .dma_req = 17 },
1518 { .name = "tx0", .dma_req = 16 }, 1517 { .name = "tx0", .dma_req = 16 },
1519 { .name = "rx1", .dma_req = 19 }, 1518 { .name = "rx1", .dma_req = 19 },
1520 { .name = "tx1", .dma_req = 18 }, 1519 { .name = "tx1", .dma_req = 18 },
1521 { .dma_req = -1 } 1520 { .dma_req = -1 }
1522 }; 1521 };
1523 1522
1524 static struct omap2_mcspi_dev_attr mcspi_attrib = { 1523 static struct omap2_mcspi_dev_attr mcspi_attrib = {
1525 .num_chipselect = 2, 1524 .num_chipselect = 2,
1526 }; 1525 };
1527 static struct omap_hwmod am33xx_spi0_hwmod = { 1526 static struct omap_hwmod am33xx_spi0_hwmod = {
1528 .name = "spi0", 1527 .name = "spi0",
1529 .class = &am33xx_spi_hwmod_class, 1528 .class = &am33xx_spi_hwmod_class,
1530 .clkdm_name = "l4ls_clkdm", 1529 .clkdm_name = "l4ls_clkdm",
1531 .mpu_irqs = am33xx_spi0_irqs, 1530 .mpu_irqs = am33xx_spi0_irqs,
1532 .sdma_reqs = am33xx_mcspi0_edma_reqs, 1531 .sdma_reqs = am33xx_mcspi0_edma_reqs,
1533 .main_clk = "dpll_per_m2_div4_ck", 1532 .main_clk = "dpll_per_m2_div4_ck",
1534 .prcm = { 1533 .prcm = {
1535 .omap4 = { 1534 .omap4 = {
1536 .clkctrl_offs = AM33XX_CM_PER_SPI0_CLKCTRL_OFFSET, 1535 .clkctrl_offs = AM33XX_CM_PER_SPI0_CLKCTRL_OFFSET,
1537 .modulemode = MODULEMODE_SWCTRL, 1536 .modulemode = MODULEMODE_SWCTRL,
1538 }, 1537 },
1539 }, 1538 },
1540 .dev_attr = &mcspi_attrib, 1539 .dev_attr = &mcspi_attrib,
1541 }; 1540 };
1542 1541
1543 /* spi1 */ 1542 /* spi1 */
1544 static struct omap_hwmod_irq_info am33xx_spi1_irqs[] = { 1543 static struct omap_hwmod_irq_info am33xx_spi1_irqs[] = {
1545 { .irq = 125 + OMAP_INTC_START, }, 1544 { .irq = 125 + OMAP_INTC_START, },
1546 { .irq = -1 }, 1545 { .irq = -1 },
1547 }; 1546 };
1548 1547
1549 static struct omap_hwmod_dma_info am33xx_mcspi1_edma_reqs[] = { 1548 static struct omap_hwmod_dma_info am33xx_mcspi1_edma_reqs[] = {
1550 { .name = "rx0", .dma_req = 43 }, 1549 { .name = "rx0", .dma_req = 43 },
1551 { .name = "tx0", .dma_req = 42 }, 1550 { .name = "tx0", .dma_req = 42 },
1552 { .name = "rx1", .dma_req = 45 }, 1551 { .name = "rx1", .dma_req = 45 },
1553 { .name = "tx1", .dma_req = 44 }, 1552 { .name = "tx1", .dma_req = 44 },
1554 { .dma_req = -1 } 1553 { .dma_req = -1 }
1555 }; 1554 };
1556 1555
1557 static struct omap_hwmod am33xx_spi1_hwmod = { 1556 static struct omap_hwmod am33xx_spi1_hwmod = {
1558 .name = "spi1", 1557 .name = "spi1",
1559 .class = &am33xx_spi_hwmod_class, 1558 .class = &am33xx_spi_hwmod_class,
1560 .clkdm_name = "l4ls_clkdm", 1559 .clkdm_name = "l4ls_clkdm",
1561 .mpu_irqs = am33xx_spi1_irqs, 1560 .mpu_irqs = am33xx_spi1_irqs,
1562 .sdma_reqs = am33xx_mcspi1_edma_reqs, 1561 .sdma_reqs = am33xx_mcspi1_edma_reqs,
1563 .main_clk = "dpll_per_m2_div4_ck", 1562 .main_clk = "dpll_per_m2_div4_ck",
1564 .prcm = { 1563 .prcm = {
1565 .omap4 = { 1564 .omap4 = {
1566 .clkctrl_offs = AM33XX_CM_PER_SPI1_CLKCTRL_OFFSET, 1565 .clkctrl_offs = AM33XX_CM_PER_SPI1_CLKCTRL_OFFSET,
1567 .modulemode = MODULEMODE_SWCTRL, 1566 .modulemode = MODULEMODE_SWCTRL,
1568 }, 1567 },
1569 }, 1568 },
1570 .dev_attr = &mcspi_attrib, 1569 .dev_attr = &mcspi_attrib,
1571 }; 1570 };
1572 1571
1573 /* 1572 /*
1574 * 'spinlock' class 1573 * 'spinlock' class
1575 * spinlock provides hardware assistance for synchronizing the 1574 * spinlock provides hardware assistance for synchronizing the
1576 * processes running on multiple processors 1575 * processes running on multiple processors
1577 */ 1576 */
1578 static struct omap_hwmod_class am33xx_spinlock_hwmod_class = { 1577 static struct omap_hwmod_class am33xx_spinlock_hwmod_class = {
1579 .name = "spinlock", 1578 .name = "spinlock",
1580 }; 1579 };
1581 1580
1582 static struct omap_hwmod am33xx_spinlock_hwmod = { 1581 static struct omap_hwmod am33xx_spinlock_hwmod = {
1583 .name = "spinlock", 1582 .name = "spinlock",
1584 .class = &am33xx_spinlock_hwmod_class, 1583 .class = &am33xx_spinlock_hwmod_class,
1585 .clkdm_name = "l4ls_clkdm", 1584 .clkdm_name = "l4ls_clkdm",
1586 .main_clk = "l4ls_gclk", 1585 .main_clk = "l4ls_gclk",
1587 .prcm = { 1586 .prcm = {
1588 .omap4 = { 1587 .omap4 = {
1589 .clkctrl_offs = AM33XX_CM_PER_SPINLOCK_CLKCTRL_OFFSET, 1588 .clkctrl_offs = AM33XX_CM_PER_SPINLOCK_CLKCTRL_OFFSET,
1590 .modulemode = MODULEMODE_SWCTRL, 1589 .modulemode = MODULEMODE_SWCTRL,
1591 }, 1590 },
1592 }, 1591 },
1593 }; 1592 };
1594 1593
1595 /* 'timer 2-7' class */ 1594 /* 'timer 2-7' class */
1596 static struct omap_hwmod_class_sysconfig am33xx_timer_sysc = { 1595 static struct omap_hwmod_class_sysconfig am33xx_timer_sysc = {
1597 .rev_offs = 0x0000, 1596 .rev_offs = 0x0000,
1598 .sysc_offs = 0x0010, 1597 .sysc_offs = 0x0010,
1599 .syss_offs = 0x0014, 1598 .syss_offs = 0x0014,
1600 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET), 1599 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
1601 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1600 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1602 SIDLE_SMART_WKUP), 1601 SIDLE_SMART_WKUP),
1603 .sysc_fields = &omap_hwmod_sysc_type2, 1602 .sysc_fields = &omap_hwmod_sysc_type2,
1604 }; 1603 };
1605 1604
1606 static struct omap_hwmod_class am33xx_timer_hwmod_class = { 1605 static struct omap_hwmod_class am33xx_timer_hwmod_class = {
1607 .name = "timer", 1606 .name = "timer",
1608 .sysc = &am33xx_timer_sysc, 1607 .sysc = &am33xx_timer_sysc,
1609 }; 1608 };
1610 1609
1611 /* timer1 1ms */ 1610 /* timer1 1ms */
1612 static struct omap_hwmod_class_sysconfig am33xx_timer1ms_sysc = { 1611 static struct omap_hwmod_class_sysconfig am33xx_timer1ms_sysc = {
1613 .rev_offs = 0x0000, 1612 .rev_offs = 0x0000,
1614 .sysc_offs = 0x0010, 1613 .sysc_offs = 0x0010,
1615 .syss_offs = 0x0014, 1614 .syss_offs = 0x0014,
1616 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 1615 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
1617 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE | 1616 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE |
1618 SYSS_HAS_RESET_STATUS), 1617 SYSS_HAS_RESET_STATUS),
1619 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1618 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1620 .sysc_fields = &omap_hwmod_sysc_type1, 1619 .sysc_fields = &omap_hwmod_sysc_type1,
1621 }; 1620 };
1622 1621
1623 static struct omap_hwmod_class am33xx_timer1ms_hwmod_class = { 1622 static struct omap_hwmod_class am33xx_timer1ms_hwmod_class = {
1624 .name = "timer", 1623 .name = "timer",
1625 .sysc = &am33xx_timer1ms_sysc, 1624 .sysc = &am33xx_timer1ms_sysc,
1626 }; 1625 };
1627 1626
1628 static struct omap_hwmod_irq_info am33xx_timer1_irqs[] = { 1627 static struct omap_hwmod_irq_info am33xx_timer1_irqs[] = {
1629 { .irq = 67 + OMAP_INTC_START, }, 1628 { .irq = 67 + OMAP_INTC_START, },
1630 { .irq = -1 }, 1629 { .irq = -1 },
1631 }; 1630 };
1632 1631
1633 static struct omap_hwmod am33xx_timer1_hwmod = { 1632 static struct omap_hwmod am33xx_timer1_hwmod = {
1634 .name = "timer1", 1633 .name = "timer1",
1635 .class = &am33xx_timer1ms_hwmod_class, 1634 .class = &am33xx_timer1ms_hwmod_class,
1636 .clkdm_name = "l4_wkup_clkdm", 1635 .clkdm_name = "l4_wkup_clkdm",
1637 .mpu_irqs = am33xx_timer1_irqs, 1636 .mpu_irqs = am33xx_timer1_irqs,
1638 .main_clk = "timer1_fck", 1637 .main_clk = "timer1_fck",
1639 .prcm = { 1638 .prcm = {
1640 .omap4 = { 1639 .omap4 = {
1641 .clkctrl_offs = AM33XX_CM_WKUP_TIMER1_CLKCTRL_OFFSET, 1640 .clkctrl_offs = AM33XX_CM_WKUP_TIMER1_CLKCTRL_OFFSET,
1642 .modulemode = MODULEMODE_SWCTRL, 1641 .modulemode = MODULEMODE_SWCTRL,
1643 }, 1642 },
1644 }, 1643 },
1645 }; 1644 };
1646 1645
1647 static struct omap_hwmod_irq_info am33xx_timer2_irqs[] = { 1646 static struct omap_hwmod_irq_info am33xx_timer2_irqs[] = {
1648 { .irq = 68 + OMAP_INTC_START, }, 1647 { .irq = 68 + OMAP_INTC_START, },
1649 { .irq = -1 }, 1648 { .irq = -1 },
1650 }; 1649 };
1651 1650
1652 static struct omap_hwmod am33xx_timer2_hwmod = { 1651 static struct omap_hwmod am33xx_timer2_hwmod = {
1653 .name = "timer2", 1652 .name = "timer2",
1654 .class = &am33xx_timer_hwmod_class, 1653 .class = &am33xx_timer_hwmod_class,
1655 .clkdm_name = "l4ls_clkdm", 1654 .clkdm_name = "l4ls_clkdm",
1656 .mpu_irqs = am33xx_timer2_irqs, 1655 .mpu_irqs = am33xx_timer2_irqs,
1657 .main_clk = "timer2_fck", 1656 .main_clk = "timer2_fck",
1658 .prcm = { 1657 .prcm = {
1659 .omap4 = { 1658 .omap4 = {
1660 .clkctrl_offs = AM33XX_CM_PER_TIMER2_CLKCTRL_OFFSET, 1659 .clkctrl_offs = AM33XX_CM_PER_TIMER2_CLKCTRL_OFFSET,
1661 .modulemode = MODULEMODE_SWCTRL, 1660 .modulemode = MODULEMODE_SWCTRL,
1662 }, 1661 },
1663 }, 1662 },
1664 }; 1663 };
1665 1664
1666 static struct omap_hwmod_irq_info am33xx_timer3_irqs[] = { 1665 static struct omap_hwmod_irq_info am33xx_timer3_irqs[] = {
1667 { .irq = 69 + OMAP_INTC_START, }, 1666 { .irq = 69 + OMAP_INTC_START, },
1668 { .irq = -1 }, 1667 { .irq = -1 },
1669 }; 1668 };
1670 1669
1671 static struct omap_hwmod am33xx_timer3_hwmod = { 1670 static struct omap_hwmod am33xx_timer3_hwmod = {
1672 .name = "timer3", 1671 .name = "timer3",
1673 .class = &am33xx_timer_hwmod_class, 1672 .class = &am33xx_timer_hwmod_class,
1674 .clkdm_name = "l4ls_clkdm", 1673 .clkdm_name = "l4ls_clkdm",
1675 .mpu_irqs = am33xx_timer3_irqs, 1674 .mpu_irqs = am33xx_timer3_irqs,
1676 .main_clk = "timer3_fck", 1675 .main_clk = "timer3_fck",
1677 .prcm = { 1676 .prcm = {
1678 .omap4 = { 1677 .omap4 = {
1679 .clkctrl_offs = AM33XX_CM_PER_TIMER3_CLKCTRL_OFFSET, 1678 .clkctrl_offs = AM33XX_CM_PER_TIMER3_CLKCTRL_OFFSET,
1680 .modulemode = MODULEMODE_SWCTRL, 1679 .modulemode = MODULEMODE_SWCTRL,
1681 }, 1680 },
1682 }, 1681 },
1683 }; 1682 };
1684 1683
1685 static struct omap_hwmod_irq_info am33xx_timer4_irqs[] = { 1684 static struct omap_hwmod_irq_info am33xx_timer4_irqs[] = {
1686 { .irq = 92 + OMAP_INTC_START, }, 1685 { .irq = 92 + OMAP_INTC_START, },
1687 { .irq = -1 }, 1686 { .irq = -1 },
1688 }; 1687 };
1689 1688
1690 static struct omap_hwmod am33xx_timer4_hwmod = { 1689 static struct omap_hwmod am33xx_timer4_hwmod = {
1691 .name = "timer4", 1690 .name = "timer4",
1692 .class = &am33xx_timer_hwmod_class, 1691 .class = &am33xx_timer_hwmod_class,
1693 .clkdm_name = "l4ls_clkdm", 1692 .clkdm_name = "l4ls_clkdm",
1694 .mpu_irqs = am33xx_timer4_irqs, 1693 .mpu_irqs = am33xx_timer4_irqs,
1695 .main_clk = "timer4_fck", 1694 .main_clk = "timer4_fck",
1696 .prcm = { 1695 .prcm = {
1697 .omap4 = { 1696 .omap4 = {
1698 .clkctrl_offs = AM33XX_CM_PER_TIMER4_CLKCTRL_OFFSET, 1697 .clkctrl_offs = AM33XX_CM_PER_TIMER4_CLKCTRL_OFFSET,
1699 .modulemode = MODULEMODE_SWCTRL, 1698 .modulemode = MODULEMODE_SWCTRL,
1700 }, 1699 },
1701 }, 1700 },
1702 }; 1701 };
1703 1702
1704 static struct omap_hwmod_irq_info am33xx_timer5_irqs[] = { 1703 static struct omap_hwmod_irq_info am33xx_timer5_irqs[] = {
1705 { .irq = 93 + OMAP_INTC_START, }, 1704 { .irq = 93 + OMAP_INTC_START, },
1706 { .irq = -1 }, 1705 { .irq = -1 },
1707 }; 1706 };
1708 1707
1709 static struct omap_hwmod am33xx_timer5_hwmod = { 1708 static struct omap_hwmod am33xx_timer5_hwmod = {
1710 .name = "timer5", 1709 .name = "timer5",
1711 .class = &am33xx_timer_hwmod_class, 1710 .class = &am33xx_timer_hwmod_class,
1712 .clkdm_name = "l4ls_clkdm", 1711 .clkdm_name = "l4ls_clkdm",
1713 .mpu_irqs = am33xx_timer5_irqs, 1712 .mpu_irqs = am33xx_timer5_irqs,
1714 .main_clk = "timer5_fck", 1713 .main_clk = "timer5_fck",
1715 .prcm = { 1714 .prcm = {
1716 .omap4 = { 1715 .omap4 = {
1717 .clkctrl_offs = AM33XX_CM_PER_TIMER5_CLKCTRL_OFFSET, 1716 .clkctrl_offs = AM33XX_CM_PER_TIMER5_CLKCTRL_OFFSET,
1718 .modulemode = MODULEMODE_SWCTRL, 1717 .modulemode = MODULEMODE_SWCTRL,
1719 }, 1718 },
1720 }, 1719 },
1721 }; 1720 };
1722 1721
1723 static struct omap_hwmod_irq_info am33xx_timer6_irqs[] = { 1722 static struct omap_hwmod_irq_info am33xx_timer6_irqs[] = {
1724 { .irq = 94 + OMAP_INTC_START, }, 1723 { .irq = 94 + OMAP_INTC_START, },
1725 { .irq = -1 }, 1724 { .irq = -1 },
1726 }; 1725 };
1727 1726
1728 static struct omap_hwmod am33xx_timer6_hwmod = { 1727 static struct omap_hwmod am33xx_timer6_hwmod = {
1729 .name = "timer6", 1728 .name = "timer6",
1730 .class = &am33xx_timer_hwmod_class, 1729 .class = &am33xx_timer_hwmod_class,
1731 .clkdm_name = "l4ls_clkdm", 1730 .clkdm_name = "l4ls_clkdm",
1732 .mpu_irqs = am33xx_timer6_irqs, 1731 .mpu_irqs = am33xx_timer6_irqs,
1733 .main_clk = "timer6_fck", 1732 .main_clk = "timer6_fck",
1734 .prcm = { 1733 .prcm = {
1735 .omap4 = { 1734 .omap4 = {
1736 .clkctrl_offs = AM33XX_CM_PER_TIMER6_CLKCTRL_OFFSET, 1735 .clkctrl_offs = AM33XX_CM_PER_TIMER6_CLKCTRL_OFFSET,
1737 .modulemode = MODULEMODE_SWCTRL, 1736 .modulemode = MODULEMODE_SWCTRL,
1738 }, 1737 },
1739 }, 1738 },
1740 }; 1739 };
1741 1740
1742 static struct omap_hwmod_irq_info am33xx_timer7_irqs[] = { 1741 static struct omap_hwmod_irq_info am33xx_timer7_irqs[] = {
1743 { .irq = 95 + OMAP_INTC_START, }, 1742 { .irq = 95 + OMAP_INTC_START, },
1744 { .irq = -1 }, 1743 { .irq = -1 },
1745 }; 1744 };
1746 1745
1747 static struct omap_hwmod am33xx_timer7_hwmod = { 1746 static struct omap_hwmod am33xx_timer7_hwmod = {
1748 .name = "timer7", 1747 .name = "timer7",
1749 .class = &am33xx_timer_hwmod_class, 1748 .class = &am33xx_timer_hwmod_class,
1750 .clkdm_name = "l4ls_clkdm", 1749 .clkdm_name = "l4ls_clkdm",
1751 .mpu_irqs = am33xx_timer7_irqs, 1750 .mpu_irqs = am33xx_timer7_irqs,
1752 .main_clk = "timer7_fck", 1751 .main_clk = "timer7_fck",
1753 .prcm = { 1752 .prcm = {
1754 .omap4 = { 1753 .omap4 = {
1755 .clkctrl_offs = AM33XX_CM_PER_TIMER7_CLKCTRL_OFFSET, 1754 .clkctrl_offs = AM33XX_CM_PER_TIMER7_CLKCTRL_OFFSET,
1756 .modulemode = MODULEMODE_SWCTRL, 1755 .modulemode = MODULEMODE_SWCTRL,
1757 }, 1756 },
1758 }, 1757 },
1759 }; 1758 };
1760 1759
1761 /* tpcc */ 1760 /* tpcc */
1762 static struct omap_hwmod_class am33xx_tpcc_hwmod_class = { 1761 static struct omap_hwmod_class am33xx_tpcc_hwmod_class = {
1763 .name = "tpcc", 1762 .name = "tpcc",
1764 }; 1763 };
1765 1764
1766 static struct omap_hwmod_irq_info am33xx_tpcc_irqs[] = { 1765 static struct omap_hwmod_irq_info am33xx_tpcc_irqs[] = {
1767 { .name = "edma0", .irq = 12 + OMAP_INTC_START, }, 1766 { .name = "edma0", .irq = 12 + OMAP_INTC_START, },
1768 { .name = "edma0_mperr", .irq = 13 + OMAP_INTC_START, }, 1767 { .name = "edma0_mperr", .irq = 13 + OMAP_INTC_START, },
1769 { .name = "edma0_err", .irq = 14 + OMAP_INTC_START, }, 1768 { .name = "edma0_err", .irq = 14 + OMAP_INTC_START, },
1770 { .irq = -1 }, 1769 { .irq = -1 },
1771 }; 1770 };
1772 1771
1773 static struct omap_hwmod am33xx_tpcc_hwmod = { 1772 static struct omap_hwmod am33xx_tpcc_hwmod = {
1774 .name = "tpcc", 1773 .name = "tpcc",
1775 .class = &am33xx_tpcc_hwmod_class, 1774 .class = &am33xx_tpcc_hwmod_class,
1776 .clkdm_name = "l3_clkdm", 1775 .clkdm_name = "l3_clkdm",
1777 .mpu_irqs = am33xx_tpcc_irqs, 1776 .mpu_irqs = am33xx_tpcc_irqs,
1778 .main_clk = "l3_gclk", 1777 .main_clk = "l3_gclk",
1779 .prcm = { 1778 .prcm = {
1780 .omap4 = { 1779 .omap4 = {
1781 .clkctrl_offs = AM33XX_CM_PER_TPCC_CLKCTRL_OFFSET, 1780 .clkctrl_offs = AM33XX_CM_PER_TPCC_CLKCTRL_OFFSET,
1782 .modulemode = MODULEMODE_SWCTRL, 1781 .modulemode = MODULEMODE_SWCTRL,
1783 }, 1782 },
1784 }, 1783 },
1785 }; 1784 };
1786 1785
1787 static struct omap_hwmod_class_sysconfig am33xx_tptc_sysc = { 1786 static struct omap_hwmod_class_sysconfig am33xx_tptc_sysc = {
1788 .rev_offs = 0x0, 1787 .rev_offs = 0x0,
1789 .sysc_offs = 0x10, 1788 .sysc_offs = 0x10,
1790 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET | 1789 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
1791 SYSC_HAS_MIDLEMODE), 1790 SYSC_HAS_MIDLEMODE),
1792 .idlemodes = (SIDLE_FORCE | SIDLE_SMART | MSTANDBY_FORCE), 1791 .idlemodes = (SIDLE_FORCE | SIDLE_SMART | MSTANDBY_FORCE),
1793 .sysc_fields = &omap_hwmod_sysc_type2, 1792 .sysc_fields = &omap_hwmod_sysc_type2,
1794 }; 1793 };
1795 1794
1796 /* 'tptc' class */ 1795 /* 'tptc' class */
1797 static struct omap_hwmod_class am33xx_tptc_hwmod_class = { 1796 static struct omap_hwmod_class am33xx_tptc_hwmod_class = {
1798 .name = "tptc", 1797 .name = "tptc",
1799 .sysc = &am33xx_tptc_sysc, 1798 .sysc = &am33xx_tptc_sysc,
1800 }; 1799 };
1801 1800
1802 /* tptc0 */ 1801 /* tptc0 */
1803 static struct omap_hwmod_irq_info am33xx_tptc0_irqs[] = { 1802 static struct omap_hwmod_irq_info am33xx_tptc0_irqs[] = {
1804 { .irq = 112 + OMAP_INTC_START, }, 1803 { .irq = 112 + OMAP_INTC_START, },
1805 { .irq = -1 }, 1804 { .irq = -1 },
1806 }; 1805 };
1807 1806
1808 static struct omap_hwmod am33xx_tptc0_hwmod = { 1807 static struct omap_hwmod am33xx_tptc0_hwmod = {
1809 .name = "tptc0", 1808 .name = "tptc0",
1810 .class = &am33xx_tptc_hwmod_class, 1809 .class = &am33xx_tptc_hwmod_class,
1811 .clkdm_name = "l3_clkdm", 1810 .clkdm_name = "l3_clkdm",
1812 .mpu_irqs = am33xx_tptc0_irqs, 1811 .mpu_irqs = am33xx_tptc0_irqs,
1813 .main_clk = "l3_gclk", 1812 .main_clk = "l3_gclk",
1814 .prcm = { 1813 .prcm = {
1815 .omap4 = { 1814 .omap4 = {
1816 .clkctrl_offs = AM33XX_CM_PER_TPTC0_CLKCTRL_OFFSET, 1815 .clkctrl_offs = AM33XX_CM_PER_TPTC0_CLKCTRL_OFFSET,
1817 .modulemode = MODULEMODE_SWCTRL, 1816 .modulemode = MODULEMODE_SWCTRL,
1818 }, 1817 },
1819 }, 1818 },
1820 }; 1819 };
1821 1820
1822 /* tptc1 */ 1821 /* tptc1 */
1823 static struct omap_hwmod_irq_info am33xx_tptc1_irqs[] = { 1822 static struct omap_hwmod_irq_info am33xx_tptc1_irqs[] = {
1824 { .irq = 113 + OMAP_INTC_START, }, 1823 { .irq = 113 + OMAP_INTC_START, },
1825 { .irq = -1 }, 1824 { .irq = -1 },
1826 }; 1825 };
1827 1826
1828 static struct omap_hwmod am33xx_tptc1_hwmod = { 1827 static struct omap_hwmod am33xx_tptc1_hwmod = {
1829 .name = "tptc1", 1828 .name = "tptc1",
1830 .class = &am33xx_tptc_hwmod_class, 1829 .class = &am33xx_tptc_hwmod_class,
1831 .clkdm_name = "l3_clkdm", 1830 .clkdm_name = "l3_clkdm",
1832 .mpu_irqs = am33xx_tptc1_irqs, 1831 .mpu_irqs = am33xx_tptc1_irqs,
1833 .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY), 1832 .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
1834 .main_clk = "l3_gclk", 1833 .main_clk = "l3_gclk",
1835 .prcm = { 1834 .prcm = {
1836 .omap4 = { 1835 .omap4 = {
1837 .clkctrl_offs = AM33XX_CM_PER_TPTC1_CLKCTRL_OFFSET, 1836 .clkctrl_offs = AM33XX_CM_PER_TPTC1_CLKCTRL_OFFSET,
1838 .modulemode = MODULEMODE_SWCTRL, 1837 .modulemode = MODULEMODE_SWCTRL,
1839 }, 1838 },
1840 }, 1839 },
1841 }; 1840 };
1842 1841
1843 /* tptc2 */ 1842 /* tptc2 */
1844 static struct omap_hwmod_irq_info am33xx_tptc2_irqs[] = { 1843 static struct omap_hwmod_irq_info am33xx_tptc2_irqs[] = {
1845 { .irq = 114 + OMAP_INTC_START, }, 1844 { .irq = 114 + OMAP_INTC_START, },
1846 { .irq = -1 }, 1845 { .irq = -1 },
1847 }; 1846 };
1848 1847
1849 static struct omap_hwmod am33xx_tptc2_hwmod = { 1848 static struct omap_hwmod am33xx_tptc2_hwmod = {
1850 .name = "tptc2", 1849 .name = "tptc2",
1851 .class = &am33xx_tptc_hwmod_class, 1850 .class = &am33xx_tptc_hwmod_class,
1852 .clkdm_name = "l3_clkdm", 1851 .clkdm_name = "l3_clkdm",
1853 .mpu_irqs = am33xx_tptc2_irqs, 1852 .mpu_irqs = am33xx_tptc2_irqs,
1854 .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY), 1853 .flags = (HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY),
1855 .main_clk = "l3_gclk", 1854 .main_clk = "l3_gclk",
1856 .prcm = { 1855 .prcm = {
1857 .omap4 = { 1856 .omap4 = {
1858 .clkctrl_offs = AM33XX_CM_PER_TPTC2_CLKCTRL_OFFSET, 1857 .clkctrl_offs = AM33XX_CM_PER_TPTC2_CLKCTRL_OFFSET,
1859 .modulemode = MODULEMODE_SWCTRL, 1858 .modulemode = MODULEMODE_SWCTRL,
1860 }, 1859 },
1861 }, 1860 },
1862 }; 1861 };
1863 1862
1864 /* 'uart' class */ 1863 /* 'uart' class */
1865 static struct omap_hwmod_class_sysconfig uart_sysc = { 1864 static struct omap_hwmod_class_sysconfig uart_sysc = {
1866 .rev_offs = 0x50, 1865 .rev_offs = 0x50,
1867 .sysc_offs = 0x54, 1866 .sysc_offs = 0x54,
1868 .syss_offs = 0x58, 1867 .syss_offs = 0x58,
1869 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP | 1868 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP |
1870 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE), 1869 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
1871 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1870 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1872 SIDLE_SMART_WKUP), 1871 SIDLE_SMART_WKUP),
1873 .sysc_fields = &omap_hwmod_sysc_type1, 1872 .sysc_fields = &omap_hwmod_sysc_type1,
1874 }; 1873 };
1875 1874
1876 static struct omap_hwmod_class uart_class = { 1875 static struct omap_hwmod_class uart_class = {
1877 .name = "uart", 1876 .name = "uart",
1878 .sysc = &uart_sysc, 1877 .sysc = &uart_sysc,
1879 }; 1878 };
1880 1879
1881 /* uart1 */ 1880 /* uart1 */
1882 static struct omap_hwmod_dma_info uart1_edma_reqs[] = { 1881 static struct omap_hwmod_dma_info uart1_edma_reqs[] = {
1883 { .name = "tx", .dma_req = 26, }, 1882 { .name = "tx", .dma_req = 26, },
1884 { .name = "rx", .dma_req = 27, }, 1883 { .name = "rx", .dma_req = 27, },
1885 { .dma_req = -1 } 1884 { .dma_req = -1 }
1886 }; 1885 };
1887 1886
1888 static struct omap_hwmod_irq_info am33xx_uart1_irqs[] = { 1887 static struct omap_hwmod_irq_info am33xx_uart1_irqs[] = {
1889 { .irq = 72 + OMAP_INTC_START, }, 1888 { .irq = 72 + OMAP_INTC_START, },
1890 { .irq = -1 }, 1889 { .irq = -1 },
1891 }; 1890 };
1892 1891
1893 static struct omap_hwmod am33xx_uart1_hwmod = { 1892 static struct omap_hwmod am33xx_uart1_hwmod = {
1894 .name = "uart1", 1893 .name = "uart1",
1895 .class = &uart_class, 1894 .class = &uart_class,
1896 .clkdm_name = "l4_wkup_clkdm", 1895 .clkdm_name = "l4_wkup_clkdm",
1897 .mpu_irqs = am33xx_uart1_irqs, 1896 .mpu_irqs = am33xx_uart1_irqs,
1898 .sdma_reqs = uart1_edma_reqs, 1897 .sdma_reqs = uart1_edma_reqs,
1899 .main_clk = "dpll_per_m2_div4_wkupdm_ck", 1898 .main_clk = "dpll_per_m2_div4_wkupdm_ck",
1900 .prcm = { 1899 .prcm = {
1901 .omap4 = { 1900 .omap4 = {
1902 .clkctrl_offs = AM33XX_CM_WKUP_UART0_CLKCTRL_OFFSET, 1901 .clkctrl_offs = AM33XX_CM_WKUP_UART0_CLKCTRL_OFFSET,
1903 .modulemode = MODULEMODE_SWCTRL, 1902 .modulemode = MODULEMODE_SWCTRL,
1904 }, 1903 },
1905 }, 1904 },
1906 }; 1905 };
1907 1906
1908 static struct omap_hwmod_irq_info am33xx_uart2_irqs[] = { 1907 static struct omap_hwmod_irq_info am33xx_uart2_irqs[] = {
1909 { .irq = 73 + OMAP_INTC_START, }, 1908 { .irq = 73 + OMAP_INTC_START, },
1910 { .irq = -1 }, 1909 { .irq = -1 },
1911 }; 1910 };
1912 1911
1913 static struct omap_hwmod am33xx_uart2_hwmod = { 1912 static struct omap_hwmod am33xx_uart2_hwmod = {
1914 .name = "uart2", 1913 .name = "uart2",
1915 .class = &uart_class, 1914 .class = &uart_class,
1916 .clkdm_name = "l4ls_clkdm", 1915 .clkdm_name = "l4ls_clkdm",
1917 .mpu_irqs = am33xx_uart2_irqs, 1916 .mpu_irqs = am33xx_uart2_irqs,
1918 .sdma_reqs = uart1_edma_reqs, 1917 .sdma_reqs = uart1_edma_reqs,
1919 .main_clk = "dpll_per_m2_div4_ck", 1918 .main_clk = "dpll_per_m2_div4_ck",
1920 .prcm = { 1919 .prcm = {
1921 .omap4 = { 1920 .omap4 = {
1922 .clkctrl_offs = AM33XX_CM_PER_UART1_CLKCTRL_OFFSET, 1921 .clkctrl_offs = AM33XX_CM_PER_UART1_CLKCTRL_OFFSET,
1923 .modulemode = MODULEMODE_SWCTRL, 1922 .modulemode = MODULEMODE_SWCTRL,
1924 }, 1923 },
1925 }, 1924 },
1926 }; 1925 };
1927 1926
1928 /* uart3 */ 1927 /* uart3 */
1929 static struct omap_hwmod_dma_info uart3_edma_reqs[] = { 1928 static struct omap_hwmod_dma_info uart3_edma_reqs[] = {
1930 { .name = "tx", .dma_req = 30, }, 1929 { .name = "tx", .dma_req = 30, },
1931 { .name = "rx", .dma_req = 31, }, 1930 { .name = "rx", .dma_req = 31, },
1932 { .dma_req = -1 } 1931 { .dma_req = -1 }
1933 }; 1932 };
1934 1933
1935 static struct omap_hwmod_irq_info am33xx_uart3_irqs[] = { 1934 static struct omap_hwmod_irq_info am33xx_uart3_irqs[] = {
1936 { .irq = 74 + OMAP_INTC_START, }, 1935 { .irq = 74 + OMAP_INTC_START, },
1937 { .irq = -1 }, 1936 { .irq = -1 },
1938 }; 1937 };
1939 1938
1940 static struct omap_hwmod am33xx_uart3_hwmod = { 1939 static struct omap_hwmod am33xx_uart3_hwmod = {
1941 .name = "uart3", 1940 .name = "uart3",
1942 .class = &uart_class, 1941 .class = &uart_class,
1943 .clkdm_name = "l4ls_clkdm", 1942 .clkdm_name = "l4ls_clkdm",
1944 .mpu_irqs = am33xx_uart3_irqs, 1943 .mpu_irqs = am33xx_uart3_irqs,
1945 .sdma_reqs = uart3_edma_reqs, 1944 .sdma_reqs = uart3_edma_reqs,
1946 .main_clk = "dpll_per_m2_div4_ck", 1945 .main_clk = "dpll_per_m2_div4_ck",
1947 .prcm = { 1946 .prcm = {
1948 .omap4 = { 1947 .omap4 = {
1949 .clkctrl_offs = AM33XX_CM_PER_UART2_CLKCTRL_OFFSET, 1948 .clkctrl_offs = AM33XX_CM_PER_UART2_CLKCTRL_OFFSET,
1950 .modulemode = MODULEMODE_SWCTRL, 1949 .modulemode = MODULEMODE_SWCTRL,
1951 }, 1950 },
1952 }, 1951 },
1953 }; 1952 };
1954 1953
1955 static struct omap_hwmod_irq_info am33xx_uart4_irqs[] = { 1954 static struct omap_hwmod_irq_info am33xx_uart4_irqs[] = {
1956 { .irq = 44 + OMAP_INTC_START, }, 1955 { .irq = 44 + OMAP_INTC_START, },
1957 { .irq = -1 }, 1956 { .irq = -1 },
1958 }; 1957 };
1959 1958
1960 static struct omap_hwmod am33xx_uart4_hwmod = { 1959 static struct omap_hwmod am33xx_uart4_hwmod = {
1961 .name = "uart4", 1960 .name = "uart4",
1962 .class = &uart_class, 1961 .class = &uart_class,
1963 .clkdm_name = "l4ls_clkdm", 1962 .clkdm_name = "l4ls_clkdm",
1964 .mpu_irqs = am33xx_uart4_irqs, 1963 .mpu_irqs = am33xx_uart4_irqs,
1965 .sdma_reqs = uart1_edma_reqs, 1964 .sdma_reqs = uart1_edma_reqs,
1966 .main_clk = "dpll_per_m2_div4_ck", 1965 .main_clk = "dpll_per_m2_div4_ck",
1967 .prcm = { 1966 .prcm = {
1968 .omap4 = { 1967 .omap4 = {
1969 .clkctrl_offs = AM33XX_CM_PER_UART3_CLKCTRL_OFFSET, 1968 .clkctrl_offs = AM33XX_CM_PER_UART3_CLKCTRL_OFFSET,
1970 .modulemode = MODULEMODE_SWCTRL, 1969 .modulemode = MODULEMODE_SWCTRL,
1971 }, 1970 },
1972 }, 1971 },
1973 }; 1972 };
1974 1973
1975 static struct omap_hwmod_irq_info am33xx_uart5_irqs[] = { 1974 static struct omap_hwmod_irq_info am33xx_uart5_irqs[] = {
1976 { .irq = 45 + OMAP_INTC_START, }, 1975 { .irq = 45 + OMAP_INTC_START, },
1977 { .irq = -1 }, 1976 { .irq = -1 },
1978 }; 1977 };
1979 1978
1980 static struct omap_hwmod am33xx_uart5_hwmod = { 1979 static struct omap_hwmod am33xx_uart5_hwmod = {
1981 .name = "uart5", 1980 .name = "uart5",
1982 .class = &uart_class, 1981 .class = &uart_class,
1983 .clkdm_name = "l4ls_clkdm", 1982 .clkdm_name = "l4ls_clkdm",
1984 .mpu_irqs = am33xx_uart5_irqs, 1983 .mpu_irqs = am33xx_uart5_irqs,
1985 .sdma_reqs = uart1_edma_reqs, 1984 .sdma_reqs = uart1_edma_reqs,
1986 .main_clk = "dpll_per_m2_div4_ck", 1985 .main_clk = "dpll_per_m2_div4_ck",
1987 .prcm = { 1986 .prcm = {
1988 .omap4 = { 1987 .omap4 = {
1989 .clkctrl_offs = AM33XX_CM_PER_UART4_CLKCTRL_OFFSET, 1988 .clkctrl_offs = AM33XX_CM_PER_UART4_CLKCTRL_OFFSET,
1990 .modulemode = MODULEMODE_SWCTRL, 1989 .modulemode = MODULEMODE_SWCTRL,
1991 }, 1990 },
1992 }, 1991 },
1993 }; 1992 };
1994 1993
1995 static struct omap_hwmod_irq_info am33xx_uart6_irqs[] = { 1994 static struct omap_hwmod_irq_info am33xx_uart6_irqs[] = {
1996 { .irq = 46 + OMAP_INTC_START, }, 1995 { .irq = 46 + OMAP_INTC_START, },
1997 { .irq = -1 }, 1996 { .irq = -1 },
1998 }; 1997 };
1999 1998
2000 static struct omap_hwmod am33xx_uart6_hwmod = { 1999 static struct omap_hwmod am33xx_uart6_hwmod = {
2001 .name = "uart6", 2000 .name = "uart6",
2002 .class = &uart_class, 2001 .class = &uart_class,
2003 .clkdm_name = "l4ls_clkdm", 2002 .clkdm_name = "l4ls_clkdm",
2004 .mpu_irqs = am33xx_uart6_irqs, 2003 .mpu_irqs = am33xx_uart6_irqs,
2005 .sdma_reqs = uart1_edma_reqs, 2004 .sdma_reqs = uart1_edma_reqs,
2006 .main_clk = "dpll_per_m2_div4_ck", 2005 .main_clk = "dpll_per_m2_div4_ck",
2007 .prcm = { 2006 .prcm = {
2008 .omap4 = { 2007 .omap4 = {
2009 .clkctrl_offs = AM33XX_CM_PER_UART5_CLKCTRL_OFFSET, 2008 .clkctrl_offs = AM33XX_CM_PER_UART5_CLKCTRL_OFFSET,
2010 .modulemode = MODULEMODE_SWCTRL, 2009 .modulemode = MODULEMODE_SWCTRL,
2011 }, 2010 },
2012 }, 2011 },
2013 }; 2012 };
2014 2013
2015 /* 'wd_timer' class */ 2014 /* 'wd_timer' class */
2016 static struct omap_hwmod_class am33xx_wd_timer_hwmod_class = { 2015 static struct omap_hwmod_class am33xx_wd_timer_hwmod_class = {
2017 .name = "wd_timer", 2016 .name = "wd_timer",
2018 }; 2017 };
2019 2018
2020 /* 2019 /*
2021 * XXX: device.c file uses hardcoded name for watchdog timer 2020 * XXX: device.c file uses hardcoded name for watchdog timer
2022 * driver "wd_timer2, so we are also using same name as of now... 2021 * driver "wd_timer2, so we are also using same name as of now...
2023 */ 2022 */
2024 static struct omap_hwmod am33xx_wd_timer1_hwmod = { 2023 static struct omap_hwmod am33xx_wd_timer1_hwmod = {
2025 .name = "wd_timer2", 2024 .name = "wd_timer2",
2026 .class = &am33xx_wd_timer_hwmod_class, 2025 .class = &am33xx_wd_timer_hwmod_class,
2027 .clkdm_name = "l4_wkup_clkdm", 2026 .clkdm_name = "l4_wkup_clkdm",
2028 .main_clk = "wdt1_fck", 2027 .main_clk = "wdt1_fck",
2029 .prcm = { 2028 .prcm = {
2030 .omap4 = { 2029 .omap4 = {
2031 .clkctrl_offs = AM33XX_CM_WKUP_WDT1_CLKCTRL_OFFSET, 2030 .clkctrl_offs = AM33XX_CM_WKUP_WDT1_CLKCTRL_OFFSET,
2032 .modulemode = MODULEMODE_SWCTRL, 2031 .modulemode = MODULEMODE_SWCTRL,
2033 }, 2032 },
2034 }, 2033 },
2035 }; 2034 };
2036 2035
2037 /* 2036 /*
2038 * 'usb_otg' class 2037 * 'usb_otg' class
2039 * high-speed on-the-go universal serial bus (usb_otg) controller 2038 * high-speed on-the-go universal serial bus (usb_otg) controller
2040 */ 2039 */
2041 static struct omap_hwmod_class_sysconfig am33xx_usbhsotg_sysc = { 2040 static struct omap_hwmod_class_sysconfig am33xx_usbhsotg_sysc = {
2042 .rev_offs = 0x0, 2041 .rev_offs = 0x0,
2043 .sysc_offs = 0x10, 2042 .sysc_offs = 0x10,
2044 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE), 2043 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE),
2045 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 2044 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
2046 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART), 2045 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
2047 .sysc_fields = &omap_hwmod_sysc_type2, 2046 .sysc_fields = &omap_hwmod_sysc_type2,
2048 }; 2047 };
2049 2048
2050 static struct omap_hwmod_class am33xx_usbotg_class = { 2049 static struct omap_hwmod_class am33xx_usbotg_class = {
2051 .name = "usbotg", 2050 .name = "usbotg",
2052 .sysc = &am33xx_usbhsotg_sysc, 2051 .sysc = &am33xx_usbhsotg_sysc,
2053 }; 2052 };
2054 2053
2055 static struct omap_hwmod_irq_info am33xx_usbss_mpu_irqs[] = { 2054 static struct omap_hwmod_irq_info am33xx_usbss_mpu_irqs[] = {
2056 { .name = "usbss-irq", .irq = 17 + OMAP_INTC_START, }, 2055 { .name = "usbss-irq", .irq = 17 + OMAP_INTC_START, },
2057 { .name = "musb0-irq", .irq = 18 + OMAP_INTC_START, }, 2056 { .name = "musb0-irq", .irq = 18 + OMAP_INTC_START, },
2058 { .name = "musb1-irq", .irq = 19 + OMAP_INTC_START, }, 2057 { .name = "musb1-irq", .irq = 19 + OMAP_INTC_START, },
2059 { .irq = -1 + OMAP_INTC_START, }, 2058 { .irq = -1 + OMAP_INTC_START, },
2060 }; 2059 };
2061 2060
2062 static struct omap_hwmod am33xx_usbss_hwmod = { 2061 static struct omap_hwmod am33xx_usbss_hwmod = {
2063 .name = "usb_otg_hs", 2062 .name = "usb_otg_hs",
2064 .class = &am33xx_usbotg_class, 2063 .class = &am33xx_usbotg_class,
2065 .clkdm_name = "l3s_clkdm", 2064 .clkdm_name = "l3s_clkdm",
2066 .mpu_irqs = am33xx_usbss_mpu_irqs, 2065 .mpu_irqs = am33xx_usbss_mpu_irqs,
2067 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY, 2066 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
2068 .main_clk = "usbotg_fck", 2067 .main_clk = "usbotg_fck",
2069 .prcm = { 2068 .prcm = {
2070 .omap4 = { 2069 .omap4 = {
2071 .clkctrl_offs = AM33XX_CM_PER_USB0_CLKCTRL_OFFSET, 2070 .clkctrl_offs = AM33XX_CM_PER_USB0_CLKCTRL_OFFSET,
2072 .modulemode = MODULEMODE_SWCTRL, 2071 .modulemode = MODULEMODE_SWCTRL,
2073 }, 2072 },
2074 }, 2073 },
2075 }; 2074 };
2076 2075
2077 2076
2078 /* 2077 /*
2079 * Interfaces 2078 * Interfaces
2080 */ 2079 */
2081 2080
2082 /* l4 fw -> emif fw */ 2081 /* l4 fw -> emif fw */
2083 static struct omap_hwmod_ocp_if am33xx_l4_fw__emif_fw = { 2082 static struct omap_hwmod_ocp_if am33xx_l4_fw__emif_fw = {
2084 .master = &am33xx_l4_fw_hwmod, 2083 .master = &am33xx_l4_fw_hwmod,
2085 .slave = &am33xx_emif_fw_hwmod, 2084 .slave = &am33xx_emif_fw_hwmod,
2086 .clk = "l4fw_gclk", 2085 .clk = "l4fw_gclk",
2087 .user = OCP_USER_MPU, 2086 .user = OCP_USER_MPU,
2088 }; 2087 };
2089 2088
2090 static struct omap_hwmod_addr_space am33xx_emif_addrs[] = { 2089 static struct omap_hwmod_addr_space am33xx_emif_addrs[] = {
2091 { 2090 {
2092 .pa_start = 0x4c000000, 2091 .pa_start = 0x4c000000,
2093 .pa_end = 0x4c000fff, 2092 .pa_end = 0x4c000fff,
2094 .flags = ADDR_TYPE_RT 2093 .flags = ADDR_TYPE_RT
2095 }, 2094 },
2096 { } 2095 { }
2097 }; 2096 };
2098 /* l3 main -> emif */ 2097 /* l3 main -> emif */
2099 static struct omap_hwmod_ocp_if am33xx_l3_main__emif = { 2098 static struct omap_hwmod_ocp_if am33xx_l3_main__emif = {
2100 .master = &am33xx_l3_main_hwmod, 2099 .master = &am33xx_l3_main_hwmod,
2101 .slave = &am33xx_emif_hwmod, 2100 .slave = &am33xx_emif_hwmod,
2102 .clk = "dpll_core_m4_ck", 2101 .clk = "dpll_core_m4_ck",
2103 .addr = am33xx_emif_addrs, 2102 .addr = am33xx_emif_addrs,
2104 .user = OCP_USER_MPU | OCP_USER_SDMA, 2103 .user = OCP_USER_MPU | OCP_USER_SDMA,
2105 }; 2104 };
2106 2105
2107 /* mpu -> l3 main */ 2106 /* mpu -> l3 main */
2108 static struct omap_hwmod_ocp_if am33xx_mpu__l3_main = { 2107 static struct omap_hwmod_ocp_if am33xx_mpu__l3_main = {
2109 .master = &am33xx_mpu_hwmod, 2108 .master = &am33xx_mpu_hwmod,
2110 .slave = &am33xx_l3_main_hwmod, 2109 .slave = &am33xx_l3_main_hwmod,
2111 .clk = "dpll_mpu_m2_ck", 2110 .clk = "dpll_mpu_m2_ck",
2112 .user = OCP_USER_MPU, 2111 .user = OCP_USER_MPU,
2113 }; 2112 };
2114 2113
2115 /* l3 main -> l4 hs */ 2114 /* l3 main -> l4 hs */
2116 static struct omap_hwmod_ocp_if am33xx_l3_main__l4_hs = { 2115 static struct omap_hwmod_ocp_if am33xx_l3_main__l4_hs = {
2117 .master = &am33xx_l3_main_hwmod, 2116 .master = &am33xx_l3_main_hwmod,
2118 .slave = &am33xx_l4_hs_hwmod, 2117 .slave = &am33xx_l4_hs_hwmod,
2119 .clk = "l3s_gclk", 2118 .clk = "l3s_gclk",
2120 .user = OCP_USER_MPU | OCP_USER_SDMA, 2119 .user = OCP_USER_MPU | OCP_USER_SDMA,
2121 }; 2120 };
2122 2121
2123 /* l3 main -> l3 s */ 2122 /* l3 main -> l3 s */
2124 static struct omap_hwmod_ocp_if am33xx_l3_main__l3_s = { 2123 static struct omap_hwmod_ocp_if am33xx_l3_main__l3_s = {
2125 .master = &am33xx_l3_main_hwmod, 2124 .master = &am33xx_l3_main_hwmod,
2126 .slave = &am33xx_l3_s_hwmod, 2125 .slave = &am33xx_l3_s_hwmod,
2127 .clk = "l3s_gclk", 2126 .clk = "l3s_gclk",
2128 .user = OCP_USER_MPU | OCP_USER_SDMA, 2127 .user = OCP_USER_MPU | OCP_USER_SDMA,
2129 }; 2128 };
2130 2129
2131 /* l3 s -> l4 per/ls */ 2130 /* l3 s -> l4 per/ls */
2132 static struct omap_hwmod_ocp_if am33xx_l3_s__l4_ls = { 2131 static struct omap_hwmod_ocp_if am33xx_l3_s__l4_ls = {
2133 .master = &am33xx_l3_s_hwmod, 2132 .master = &am33xx_l3_s_hwmod,
2134 .slave = &am33xx_l4_ls_hwmod, 2133 .slave = &am33xx_l4_ls_hwmod,
2135 .clk = "l3s_gclk", 2134 .clk = "l3s_gclk",
2136 .user = OCP_USER_MPU | OCP_USER_SDMA, 2135 .user = OCP_USER_MPU | OCP_USER_SDMA,
2137 }; 2136 };
2138 2137
2139 /* l3 s -> l4 wkup */ 2138 /* l3 s -> l4 wkup */
2140 static struct omap_hwmod_ocp_if am33xx_l3_s__l4_wkup = { 2139 static struct omap_hwmod_ocp_if am33xx_l3_s__l4_wkup = {
2141 .master = &am33xx_l3_s_hwmod, 2140 .master = &am33xx_l3_s_hwmod,
2142 .slave = &am33xx_l4_wkup_hwmod, 2141 .slave = &am33xx_l4_wkup_hwmod,
2143 .clk = "l3s_gclk", 2142 .clk = "l3s_gclk",
2144 .user = OCP_USER_MPU | OCP_USER_SDMA, 2143 .user = OCP_USER_MPU | OCP_USER_SDMA,
2145 }; 2144 };
2146 2145
2147 /* l3 s -> l4 fw */ 2146 /* l3 s -> l4 fw */
2148 static struct omap_hwmod_ocp_if am33xx_l3_s__l4_fw = { 2147 static struct omap_hwmod_ocp_if am33xx_l3_s__l4_fw = {
2149 .master = &am33xx_l3_s_hwmod, 2148 .master = &am33xx_l3_s_hwmod,
2150 .slave = &am33xx_l4_fw_hwmod, 2149 .slave = &am33xx_l4_fw_hwmod,
2151 .clk = "l3s_gclk", 2150 .clk = "l3s_gclk",
2152 .user = OCP_USER_MPU | OCP_USER_SDMA, 2151 .user = OCP_USER_MPU | OCP_USER_SDMA,
2153 }; 2152 };
2154 2153
2155 /* l3 main -> l3 instr */ 2154 /* l3 main -> l3 instr */
2156 static struct omap_hwmod_ocp_if am33xx_l3_main__l3_instr = { 2155 static struct omap_hwmod_ocp_if am33xx_l3_main__l3_instr = {
2157 .master = &am33xx_l3_main_hwmod, 2156 .master = &am33xx_l3_main_hwmod,
2158 .slave = &am33xx_l3_instr_hwmod, 2157 .slave = &am33xx_l3_instr_hwmod,
2159 .clk = "l3s_gclk", 2158 .clk = "l3s_gclk",
2160 .user = OCP_USER_MPU | OCP_USER_SDMA, 2159 .user = OCP_USER_MPU | OCP_USER_SDMA,
2161 }; 2160 };
2162 2161
2163 /* mpu -> prcm */ 2162 /* mpu -> prcm */
2164 static struct omap_hwmod_ocp_if am33xx_mpu__prcm = { 2163 static struct omap_hwmod_ocp_if am33xx_mpu__prcm = {
2165 .master = &am33xx_mpu_hwmod, 2164 .master = &am33xx_mpu_hwmod,
2166 .slave = &am33xx_prcm_hwmod, 2165 .slave = &am33xx_prcm_hwmod,
2167 .clk = "dpll_mpu_m2_ck", 2166 .clk = "dpll_mpu_m2_ck",
2168 .user = OCP_USER_MPU | OCP_USER_SDMA, 2167 .user = OCP_USER_MPU | OCP_USER_SDMA,
2169 }; 2168 };
2170 2169
2171 /* l3 s -> l3 main*/ 2170 /* l3 s -> l3 main*/
2172 static struct omap_hwmod_ocp_if am33xx_l3_s__l3_main = { 2171 static struct omap_hwmod_ocp_if am33xx_l3_s__l3_main = {
2173 .master = &am33xx_l3_s_hwmod, 2172 .master = &am33xx_l3_s_hwmod,
2174 .slave = &am33xx_l3_main_hwmod, 2173 .slave = &am33xx_l3_main_hwmod,
2175 .clk = "l3s_gclk", 2174 .clk = "l3s_gclk",
2176 .user = OCP_USER_MPU | OCP_USER_SDMA, 2175 .user = OCP_USER_MPU | OCP_USER_SDMA,
2177 }; 2176 };
2178 2177
2179 /* pru-icss -> l3 main */ 2178 /* pru-icss -> l3 main */
2180 static struct omap_hwmod_ocp_if am33xx_pruss__l3_main = { 2179 static struct omap_hwmod_ocp_if am33xx_pruss__l3_main = {
2181 .master = &am33xx_pruss_hwmod, 2180 .master = &am33xx_pruss_hwmod,
2182 .slave = &am33xx_l3_main_hwmod, 2181 .slave = &am33xx_l3_main_hwmod,
2183 .clk = "l3_gclk", 2182 .clk = "l3_gclk",
2184 .user = OCP_USER_MPU | OCP_USER_SDMA, 2183 .user = OCP_USER_MPU | OCP_USER_SDMA,
2185 }; 2184 };
2186 2185
2187 /* wkup m3 -> l4 wkup */ 2186 /* wkup m3 -> l4 wkup */
2188 static struct omap_hwmod_ocp_if am33xx_wkup_m3__l4_wkup = { 2187 static struct omap_hwmod_ocp_if am33xx_wkup_m3__l4_wkup = {
2189 .master = &am33xx_wkup_m3_hwmod, 2188 .master = &am33xx_wkup_m3_hwmod,
2190 .slave = &am33xx_l4_wkup_hwmod, 2189 .slave = &am33xx_l4_wkup_hwmod,
2191 .clk = "dpll_core_m4_div2_ck", 2190 .clk = "dpll_core_m4_div2_ck",
2192 .user = OCP_USER_MPU | OCP_USER_SDMA, 2191 .user = OCP_USER_MPU | OCP_USER_SDMA,
2193 }; 2192 };
2194 2193
2195 /* gfx -> l3 main */ 2194 /* gfx -> l3 main */
2196 static struct omap_hwmod_ocp_if am33xx_gfx__l3_main = { 2195 static struct omap_hwmod_ocp_if am33xx_gfx__l3_main = {
2197 .master = &am33xx_gfx_hwmod, 2196 .master = &am33xx_gfx_hwmod,
2198 .slave = &am33xx_l3_main_hwmod, 2197 .slave = &am33xx_l3_main_hwmod,
2199 .clk = "dpll_core_m4_ck", 2198 .clk = "dpll_core_m4_ck",
2200 .user = OCP_USER_MPU | OCP_USER_SDMA, 2199 .user = OCP_USER_MPU | OCP_USER_SDMA,
2201 }; 2200 };
2202 2201
2203 /* l4 wkup -> wkup m3 */ 2202 /* l4 wkup -> wkup m3 */
2204 static struct omap_hwmod_addr_space am33xx_wkup_m3_addrs[] = { 2203 static struct omap_hwmod_addr_space am33xx_wkup_m3_addrs[] = {
2205 { 2204 {
2206 .name = "umem", 2205 .name = "umem",
2207 .pa_start = 0x44d00000, 2206 .pa_start = 0x44d00000,
2208 .pa_end = 0x44d00000 + SZ_16K - 1, 2207 .pa_end = 0x44d00000 + SZ_16K - 1,
2209 .flags = ADDR_TYPE_RT 2208 .flags = ADDR_TYPE_RT
2210 }, 2209 },
2211 { 2210 {
2212 .name = "dmem", 2211 .name = "dmem",
2213 .pa_start = 0x44d80000, 2212 .pa_start = 0x44d80000,
2214 .pa_end = 0x44d80000 + SZ_8K - 1, 2213 .pa_end = 0x44d80000 + SZ_8K - 1,
2215 .flags = ADDR_TYPE_RT 2214 .flags = ADDR_TYPE_RT
2216 }, 2215 },
2217 { } 2216 { }
2218 }; 2217 };
2219 2218
2220 static struct omap_hwmod_ocp_if am33xx_l4_wkup__wkup_m3 = { 2219 static struct omap_hwmod_ocp_if am33xx_l4_wkup__wkup_m3 = {
2221 .master = &am33xx_l4_wkup_hwmod, 2220 .master = &am33xx_l4_wkup_hwmod,
2222 .slave = &am33xx_wkup_m3_hwmod, 2221 .slave = &am33xx_wkup_m3_hwmod,
2223 .clk = "dpll_core_m4_div2_ck", 2222 .clk = "dpll_core_m4_div2_ck",
2224 .addr = am33xx_wkup_m3_addrs, 2223 .addr = am33xx_wkup_m3_addrs,
2225 .user = OCP_USER_MPU | OCP_USER_SDMA, 2224 .user = OCP_USER_MPU | OCP_USER_SDMA,
2226 }; 2225 };
2227 2226
2228 /* l4 hs -> pru-icss */ 2227 /* l4 hs -> pru-icss */
2229 static struct omap_hwmod_addr_space am33xx_pruss_addrs[] = { 2228 static struct omap_hwmod_addr_space am33xx_pruss_addrs[] = {
2230 { 2229 {
2231 .pa_start = 0x4a300000, 2230 .pa_start = 0x4a300000,
2232 .pa_end = 0x4a300000 + SZ_512K - 1, 2231 .pa_end = 0x4a300000 + SZ_512K - 1,
2233 .flags = ADDR_TYPE_RT 2232 .flags = ADDR_TYPE_RT
2234 }, 2233 },
2235 { } 2234 { }
2236 }; 2235 };
2237 2236
2238 static struct omap_hwmod_ocp_if am33xx_l4_hs__pruss = { 2237 static struct omap_hwmod_ocp_if am33xx_l4_hs__pruss = {
2239 .master = &am33xx_l4_hs_hwmod, 2238 .master = &am33xx_l4_hs_hwmod,
2240 .slave = &am33xx_pruss_hwmod, 2239 .slave = &am33xx_pruss_hwmod,
2241 .clk = "dpll_core_m4_ck", 2240 .clk = "dpll_core_m4_ck",
2242 .addr = am33xx_pruss_addrs, 2241 .addr = am33xx_pruss_addrs,
2243 .user = OCP_USER_MPU | OCP_USER_SDMA, 2242 .user = OCP_USER_MPU | OCP_USER_SDMA,
2244 }; 2243 };
2245 2244
2246 /* l3 main -> gfx */ 2245 /* l3 main -> gfx */
2247 static struct omap_hwmod_addr_space am33xx_gfx_addrs[] = { 2246 static struct omap_hwmod_addr_space am33xx_gfx_addrs[] = {
2248 { 2247 {
2249 .pa_start = 0x56000000, 2248 .pa_start = 0x56000000,
2250 .pa_end = 0x56000000 + SZ_16M - 1, 2249 .pa_end = 0x56000000 + SZ_16M - 1,
2251 .flags = ADDR_TYPE_RT 2250 .flags = ADDR_TYPE_RT
2252 }, 2251 },
2253 { } 2252 { }
2254 }; 2253 };
2255 2254
2256 static struct omap_hwmod_ocp_if am33xx_l3_main__gfx = { 2255 static struct omap_hwmod_ocp_if am33xx_l3_main__gfx = {
2257 .master = &am33xx_l3_main_hwmod, 2256 .master = &am33xx_l3_main_hwmod,
2258 .slave = &am33xx_gfx_hwmod, 2257 .slave = &am33xx_gfx_hwmod,
2259 .clk = "dpll_core_m4_ck", 2258 .clk = "dpll_core_m4_ck",
2260 .addr = am33xx_gfx_addrs, 2259 .addr = am33xx_gfx_addrs,
2261 .user = OCP_USER_MPU | OCP_USER_SDMA, 2260 .user = OCP_USER_MPU | OCP_USER_SDMA,
2262 }; 2261 };
2263 2262
2264 /* l4 wkup -> smartreflex0 */ 2263 /* l4 wkup -> smartreflex0 */
2265 static struct omap_hwmod_addr_space am33xx_smartreflex0_addrs[] = { 2264 static struct omap_hwmod_addr_space am33xx_smartreflex0_addrs[] = {
2266 { 2265 {
2267 .pa_start = 0x44e37000, 2266 .pa_start = 0x44e37000,
2268 .pa_end = 0x44e37000 + SZ_4K - 1, 2267 .pa_end = 0x44e37000 + SZ_4K - 1,
2269 .flags = ADDR_TYPE_RT 2268 .flags = ADDR_TYPE_RT
2270 }, 2269 },
2271 { } 2270 { }
2272 }; 2271 };
2273 2272
2274 static struct omap_hwmod_ocp_if am33xx_l4_wkup__smartreflex0 = { 2273 static struct omap_hwmod_ocp_if am33xx_l4_wkup__smartreflex0 = {
2275 .master = &am33xx_l4_wkup_hwmod, 2274 .master = &am33xx_l4_wkup_hwmod,
2276 .slave = &am33xx_smartreflex0_hwmod, 2275 .slave = &am33xx_smartreflex0_hwmod,
2277 .clk = "dpll_core_m4_div2_ck", 2276 .clk = "dpll_core_m4_div2_ck",
2278 .addr = am33xx_smartreflex0_addrs, 2277 .addr = am33xx_smartreflex0_addrs,
2279 .user = OCP_USER_MPU, 2278 .user = OCP_USER_MPU,
2280 }; 2279 };
2281 2280
2282 /* l4 wkup -> smartreflex1 */ 2281 /* l4 wkup -> smartreflex1 */
2283 static struct omap_hwmod_addr_space am33xx_smartreflex1_addrs[] = { 2282 static struct omap_hwmod_addr_space am33xx_smartreflex1_addrs[] = {
2284 { 2283 {
2285 .pa_start = 0x44e39000, 2284 .pa_start = 0x44e39000,
2286 .pa_end = 0x44e39000 + SZ_4K - 1, 2285 .pa_end = 0x44e39000 + SZ_4K - 1,
2287 .flags = ADDR_TYPE_RT 2286 .flags = ADDR_TYPE_RT
2288 }, 2287 },
2289 { } 2288 { }
2290 }; 2289 };
2291 2290
2292 static struct omap_hwmod_ocp_if am33xx_l4_wkup__smartreflex1 = { 2291 static struct omap_hwmod_ocp_if am33xx_l4_wkup__smartreflex1 = {
2293 .master = &am33xx_l4_wkup_hwmod, 2292 .master = &am33xx_l4_wkup_hwmod,
2294 .slave = &am33xx_smartreflex1_hwmod, 2293 .slave = &am33xx_smartreflex1_hwmod,
2295 .clk = "dpll_core_m4_div2_ck", 2294 .clk = "dpll_core_m4_div2_ck",
2296 .addr = am33xx_smartreflex1_addrs, 2295 .addr = am33xx_smartreflex1_addrs,
2297 .user = OCP_USER_MPU, 2296 .user = OCP_USER_MPU,
2298 }; 2297 };
2299 2298
2300 /* l4 wkup -> control */ 2299 /* l4 wkup -> control */
2301 static struct omap_hwmod_addr_space am33xx_control_addrs[] = { 2300 static struct omap_hwmod_addr_space am33xx_control_addrs[] = {
2302 { 2301 {
2303 .pa_start = 0x44e10000, 2302 .pa_start = 0x44e10000,
2304 .pa_end = 0x44e10000 + SZ_8K - 1, 2303 .pa_end = 0x44e10000 + SZ_8K - 1,
2305 .flags = ADDR_TYPE_RT 2304 .flags = ADDR_TYPE_RT
2306 }, 2305 },
2307 { } 2306 { }
2308 }; 2307 };
2309 2308
2310 static struct omap_hwmod_ocp_if am33xx_l4_wkup__control = { 2309 static struct omap_hwmod_ocp_if am33xx_l4_wkup__control = {
2311 .master = &am33xx_l4_wkup_hwmod, 2310 .master = &am33xx_l4_wkup_hwmod,
2312 .slave = &am33xx_control_hwmod, 2311 .slave = &am33xx_control_hwmod,
2313 .clk = "dpll_core_m4_div2_ck", 2312 .clk = "dpll_core_m4_div2_ck",
2314 .addr = am33xx_control_addrs, 2313 .addr = am33xx_control_addrs,
2315 .user = OCP_USER_MPU, 2314 .user = OCP_USER_MPU,
2316 }; 2315 };
2317 2316
2318 /* l4 wkup -> rtc */ 2317 /* l4 wkup -> rtc */
2319 static struct omap_hwmod_addr_space am33xx_rtc_addrs[] = { 2318 static struct omap_hwmod_addr_space am33xx_rtc_addrs[] = {
2320 { 2319 {
2321 .pa_start = 0x44e3e000, 2320 .pa_start = 0x44e3e000,
2322 .pa_end = 0x44e3e000 + SZ_4K - 1, 2321 .pa_end = 0x44e3e000 + SZ_4K - 1,
2323 .flags = ADDR_TYPE_RT 2322 .flags = ADDR_TYPE_RT
2324 }, 2323 },
2325 { } 2324 { }
2326 }; 2325 };
2327 2326
2328 static struct omap_hwmod_ocp_if am33xx_l4_wkup__rtc = { 2327 static struct omap_hwmod_ocp_if am33xx_l4_wkup__rtc = {
2329 .master = &am33xx_l4_wkup_hwmod, 2328 .master = &am33xx_l4_wkup_hwmod,
2330 .slave = &am33xx_rtc_hwmod, 2329 .slave = &am33xx_rtc_hwmod,
2331 .clk = "clkdiv32k_ick", 2330 .clk = "clkdiv32k_ick",
2332 .addr = am33xx_rtc_addrs, 2331 .addr = am33xx_rtc_addrs,
2333 .user = OCP_USER_MPU, 2332 .user = OCP_USER_MPU,
2334 }; 2333 };
2335 2334
2336 /* l4 per/ls -> DCAN0 */ 2335 /* l4 per/ls -> DCAN0 */
2337 static struct omap_hwmod_addr_space am33xx_dcan0_addrs[] = { 2336 static struct omap_hwmod_addr_space am33xx_dcan0_addrs[] = {
2338 { 2337 {
2339 .pa_start = 0x481CC000, 2338 .pa_start = 0x481CC000,
2340 .pa_end = 0x481CC000 + SZ_4K - 1, 2339 .pa_end = 0x481CC000 + SZ_4K - 1,
2341 .flags = ADDR_TYPE_RT 2340 .flags = ADDR_TYPE_RT
2342 }, 2341 },
2343 { } 2342 { }
2344 }; 2343 };
2345 2344
2346 static struct omap_hwmod_ocp_if am33xx_l4_per__dcan0 = { 2345 static struct omap_hwmod_ocp_if am33xx_l4_per__dcan0 = {
2347 .master = &am33xx_l4_ls_hwmod, 2346 .master = &am33xx_l4_ls_hwmod,
2348 .slave = &am33xx_dcan0_hwmod, 2347 .slave = &am33xx_dcan0_hwmod,
2349 .clk = "l4ls_gclk", 2348 .clk = "l4ls_gclk",
2350 .addr = am33xx_dcan0_addrs, 2349 .addr = am33xx_dcan0_addrs,
2351 .user = OCP_USER_MPU | OCP_USER_SDMA, 2350 .user = OCP_USER_MPU | OCP_USER_SDMA,
2352 }; 2351 };
2353 2352
2354 /* l4 per/ls -> DCAN1 */ 2353 /* l4 per/ls -> DCAN1 */
2355 static struct omap_hwmod_addr_space am33xx_dcan1_addrs[] = { 2354 static struct omap_hwmod_addr_space am33xx_dcan1_addrs[] = {
2356 { 2355 {
2357 .pa_start = 0x481D0000, 2356 .pa_start = 0x481D0000,
2358 .pa_end = 0x481D0000 + SZ_4K - 1, 2357 .pa_end = 0x481D0000 + SZ_4K - 1,
2359 .flags = ADDR_TYPE_RT 2358 .flags = ADDR_TYPE_RT
2360 }, 2359 },
2361 { } 2360 { }
2362 }; 2361 };
2363 2362
2364 static struct omap_hwmod_ocp_if am33xx_l4_per__dcan1 = { 2363 static struct omap_hwmod_ocp_if am33xx_l4_per__dcan1 = {
2365 .master = &am33xx_l4_ls_hwmod, 2364 .master = &am33xx_l4_ls_hwmod,
2366 .slave = &am33xx_dcan1_hwmod, 2365 .slave = &am33xx_dcan1_hwmod,
2367 .clk = "l4ls_gclk", 2366 .clk = "l4ls_gclk",
2368 .addr = am33xx_dcan1_addrs, 2367 .addr = am33xx_dcan1_addrs,
2369 .user = OCP_USER_MPU | OCP_USER_SDMA, 2368 .user = OCP_USER_MPU | OCP_USER_SDMA,
2370 }; 2369 };
2371 2370
2372 /* l4 per/ls -> GPIO2 */ 2371 /* l4 per/ls -> GPIO2 */
2373 static struct omap_hwmod_addr_space am33xx_gpio1_addrs[] = { 2372 static struct omap_hwmod_addr_space am33xx_gpio1_addrs[] = {
2374 { 2373 {
2375 .pa_start = 0x4804C000, 2374 .pa_start = 0x4804C000,
2376 .pa_end = 0x4804C000 + SZ_4K - 1, 2375 .pa_end = 0x4804C000 + SZ_4K - 1,
2377 .flags = ADDR_TYPE_RT, 2376 .flags = ADDR_TYPE_RT,
2378 }, 2377 },
2379 { } 2378 { }
2380 }; 2379 };
2381 2380
2382 static struct omap_hwmod_ocp_if am33xx_l4_per__gpio1 = { 2381 static struct omap_hwmod_ocp_if am33xx_l4_per__gpio1 = {
2383 .master = &am33xx_l4_ls_hwmod, 2382 .master = &am33xx_l4_ls_hwmod,
2384 .slave = &am33xx_gpio1_hwmod, 2383 .slave = &am33xx_gpio1_hwmod,
2385 .clk = "l4ls_gclk", 2384 .clk = "l4ls_gclk",
2386 .addr = am33xx_gpio1_addrs, 2385 .addr = am33xx_gpio1_addrs,
2387 .user = OCP_USER_MPU | OCP_USER_SDMA, 2386 .user = OCP_USER_MPU | OCP_USER_SDMA,
2388 }; 2387 };
2389 2388
2390 /* l4 per/ls -> gpio3 */ 2389 /* l4 per/ls -> gpio3 */
2391 static struct omap_hwmod_addr_space am33xx_gpio2_addrs[] = { 2390 static struct omap_hwmod_addr_space am33xx_gpio2_addrs[] = {
2392 { 2391 {
2393 .pa_start = 0x481AC000, 2392 .pa_start = 0x481AC000,
2394 .pa_end = 0x481AC000 + SZ_4K - 1, 2393 .pa_end = 0x481AC000 + SZ_4K - 1,
2395 .flags = ADDR_TYPE_RT, 2394 .flags = ADDR_TYPE_RT,
2396 }, 2395 },
2397 { } 2396 { }
2398 }; 2397 };
2399 2398
2400 static struct omap_hwmod_ocp_if am33xx_l4_per__gpio2 = { 2399 static struct omap_hwmod_ocp_if am33xx_l4_per__gpio2 = {
2401 .master = &am33xx_l4_ls_hwmod, 2400 .master = &am33xx_l4_ls_hwmod,
2402 .slave = &am33xx_gpio2_hwmod, 2401 .slave = &am33xx_gpio2_hwmod,
2403 .clk = "l4ls_gclk", 2402 .clk = "l4ls_gclk",
2404 .addr = am33xx_gpio2_addrs, 2403 .addr = am33xx_gpio2_addrs,
2405 .user = OCP_USER_MPU | OCP_USER_SDMA, 2404 .user = OCP_USER_MPU | OCP_USER_SDMA,
2406 }; 2405 };
2407 2406
2408 /* l4 per/ls -> gpio4 */ 2407 /* l4 per/ls -> gpio4 */
2409 static struct omap_hwmod_addr_space am33xx_gpio3_addrs[] = { 2408 static struct omap_hwmod_addr_space am33xx_gpio3_addrs[] = {
2410 { 2409 {
2411 .pa_start = 0x481AE000, 2410 .pa_start = 0x481AE000,
2412 .pa_end = 0x481AE000 + SZ_4K - 1, 2411 .pa_end = 0x481AE000 + SZ_4K - 1,
2413 .flags = ADDR_TYPE_RT, 2412 .flags = ADDR_TYPE_RT,
2414 }, 2413 },
2415 { } 2414 { }
2416 }; 2415 };
2417 2416
2418 static struct omap_hwmod_ocp_if am33xx_l4_per__gpio3 = { 2417 static struct omap_hwmod_ocp_if am33xx_l4_per__gpio3 = {
2419 .master = &am33xx_l4_ls_hwmod, 2418 .master = &am33xx_l4_ls_hwmod,
2420 .slave = &am33xx_gpio3_hwmod, 2419 .slave = &am33xx_gpio3_hwmod,
2421 .clk = "l4ls_gclk", 2420 .clk = "l4ls_gclk",
2422 .addr = am33xx_gpio3_addrs, 2421 .addr = am33xx_gpio3_addrs,
2423 .user = OCP_USER_MPU | OCP_USER_SDMA, 2422 .user = OCP_USER_MPU | OCP_USER_SDMA,
2424 }; 2423 };
2425 2424
2426 /* L4 WKUP -> I2C1 */ 2425 /* L4 WKUP -> I2C1 */
2427 static struct omap_hwmod_addr_space am33xx_i2c1_addr_space[] = { 2426 static struct omap_hwmod_addr_space am33xx_i2c1_addr_space[] = {
2428 { 2427 {
2429 .pa_start = 0x44E0B000, 2428 .pa_start = 0x44E0B000,
2430 .pa_end = 0x44E0B000 + SZ_4K - 1, 2429 .pa_end = 0x44E0B000 + SZ_4K - 1,
2431 .flags = ADDR_TYPE_RT, 2430 .flags = ADDR_TYPE_RT,
2432 }, 2431 },
2433 { } 2432 { }
2434 }; 2433 };
2435 2434
2436 static struct omap_hwmod_ocp_if am33xx_l4_wkup__i2c1 = { 2435 static struct omap_hwmod_ocp_if am33xx_l4_wkup__i2c1 = {
2437 .master = &am33xx_l4_wkup_hwmod, 2436 .master = &am33xx_l4_wkup_hwmod,
2438 .slave = &am33xx_i2c1_hwmod, 2437 .slave = &am33xx_i2c1_hwmod,
2439 .clk = "dpll_core_m4_div2_ck", 2438 .clk = "dpll_core_m4_div2_ck",
2440 .addr = am33xx_i2c1_addr_space, 2439 .addr = am33xx_i2c1_addr_space,
2441 .user = OCP_USER_MPU, 2440 .user = OCP_USER_MPU,
2442 }; 2441 };
2443 2442
2444 /* L4 WKUP -> GPIO1 */ 2443 /* L4 WKUP -> GPIO1 */
2445 static struct omap_hwmod_addr_space am33xx_gpio0_addrs[] = { 2444 static struct omap_hwmod_addr_space am33xx_gpio0_addrs[] = {
2446 { 2445 {
2447 .pa_start = 0x44E07000, 2446 .pa_start = 0x44E07000,
2448 .pa_end = 0x44E07000 + SZ_4K - 1, 2447 .pa_end = 0x44E07000 + SZ_4K - 1,
2449 .flags = ADDR_TYPE_RT, 2448 .flags = ADDR_TYPE_RT,
2450 }, 2449 },
2451 { } 2450 { }
2452 }; 2451 };
2453 2452
2454 static struct omap_hwmod_ocp_if am33xx_l4_wkup__gpio0 = { 2453 static struct omap_hwmod_ocp_if am33xx_l4_wkup__gpio0 = {
2455 .master = &am33xx_l4_wkup_hwmod, 2454 .master = &am33xx_l4_wkup_hwmod,
2456 .slave = &am33xx_gpio0_hwmod, 2455 .slave = &am33xx_gpio0_hwmod,
2457 .clk = "dpll_core_m4_div2_ck", 2456 .clk = "dpll_core_m4_div2_ck",
2458 .addr = am33xx_gpio0_addrs, 2457 .addr = am33xx_gpio0_addrs,
2459 .user = OCP_USER_MPU | OCP_USER_SDMA, 2458 .user = OCP_USER_MPU | OCP_USER_SDMA,
2460 }; 2459 };
2461 2460
2462 /* L4 WKUP -> ADC_TSC */ 2461 /* L4 WKUP -> ADC_TSC */
2463 static struct omap_hwmod_addr_space am33xx_adc_tsc_addrs[] = { 2462 static struct omap_hwmod_addr_space am33xx_adc_tsc_addrs[] = {
2464 { 2463 {
2465 .pa_start = 0x44E0D000, 2464 .pa_start = 0x44E0D000,
2466 .pa_end = 0x44E0D000 + SZ_8K - 1, 2465 .pa_end = 0x44E0D000 + SZ_8K - 1,
2467 .flags = ADDR_TYPE_RT 2466 .flags = ADDR_TYPE_RT
2468 }, 2467 },
2469 { } 2468 { }
2470 }; 2469 };
2471 2470
2472 static struct omap_hwmod_ocp_if am33xx_l4_wkup__adc_tsc = { 2471 static struct omap_hwmod_ocp_if am33xx_l4_wkup__adc_tsc = {
2473 .master = &am33xx_l4_wkup_hwmod, 2472 .master = &am33xx_l4_wkup_hwmod,
2474 .slave = &am33xx_adc_tsc_hwmod, 2473 .slave = &am33xx_adc_tsc_hwmod,
2475 .clk = "dpll_core_m4_div2_ck", 2474 .clk = "dpll_core_m4_div2_ck",
2476 .addr = am33xx_adc_tsc_addrs, 2475 .addr = am33xx_adc_tsc_addrs,
2477 .user = OCP_USER_MPU, 2476 .user = OCP_USER_MPU,
2478 }; 2477 };
2479 2478
2480 static struct omap_hwmod_addr_space am33xx_cpgmac0_addr_space[] = { 2479 static struct omap_hwmod_addr_space am33xx_cpgmac0_addr_space[] = {
2481 /* cpsw ss */ 2480 /* cpsw ss */
2482 { 2481 {
2483 .pa_start = 0x4a100000, 2482 .pa_start = 0x4a100000,
2484 .pa_end = 0x4a100000 + SZ_2K - 1, 2483 .pa_end = 0x4a100000 + SZ_2K - 1,
2485 .flags = ADDR_TYPE_RT, 2484 .flags = ADDR_TYPE_RT,
2486 }, 2485 },
2487 /* cpsw wr */ 2486 /* cpsw wr */
2488 { 2487 {
2489 .pa_start = 0x4a101200, 2488 .pa_start = 0x4a101200,
2490 .pa_end = 0x4a101200 + SZ_256 - 1, 2489 .pa_end = 0x4a101200 + SZ_256 - 1,
2491 .flags = ADDR_TYPE_RT, 2490 .flags = ADDR_TYPE_RT,
2492 }, 2491 },
2493 { } 2492 { }
2494 }; 2493 };
2495 2494
2496 static struct omap_hwmod_ocp_if am33xx_l4_hs__cpgmac0 = { 2495 static struct omap_hwmod_ocp_if am33xx_l4_hs__cpgmac0 = {
2497 .master = &am33xx_l4_hs_hwmod, 2496 .master = &am33xx_l4_hs_hwmod,
2498 .slave = &am33xx_cpgmac0_hwmod, 2497 .slave = &am33xx_cpgmac0_hwmod,
2499 .clk = "cpsw_125mhz_gclk", 2498 .clk = "cpsw_125mhz_gclk",
2500 .addr = am33xx_cpgmac0_addr_space, 2499 .addr = am33xx_cpgmac0_addr_space,
2501 .user = OCP_USER_MPU, 2500 .user = OCP_USER_MPU,
2502 }; 2501 };
2503 2502
2504 static struct omap_hwmod_addr_space am33xx_elm_addr_space[] = { 2503 static struct omap_hwmod_addr_space am33xx_elm_addr_space[] = {
2505 { 2504 {
2506 .pa_start = 0x48080000, 2505 .pa_start = 0x48080000,
2507 .pa_end = 0x48080000 + SZ_8K - 1, 2506 .pa_end = 0x48080000 + SZ_8K - 1,
2508 .flags = ADDR_TYPE_RT 2507 .flags = ADDR_TYPE_RT
2509 }, 2508 },
2510 { } 2509 { }
2511 }; 2510 };
2512 2511
2513 static struct omap_hwmod_ocp_if am33xx_l4_ls__elm = { 2512 static struct omap_hwmod_ocp_if am33xx_l4_ls__elm = {
2514 .master = &am33xx_l4_ls_hwmod, 2513 .master = &am33xx_l4_ls_hwmod,
2515 .slave = &am33xx_elm_hwmod, 2514 .slave = &am33xx_elm_hwmod,
2516 .clk = "l4ls_gclk", 2515 .clk = "l4ls_gclk",
2517 .addr = am33xx_elm_addr_space, 2516 .addr = am33xx_elm_addr_space,
2518 .user = OCP_USER_MPU, 2517 .user = OCP_USER_MPU,
2519 }; 2518 };
2520 2519
2521 /* 2520 /*
2522 * Splitting the resources to handle access of PWMSS config space 2521 * Splitting the resources to handle access of PWMSS config space
2523 * and module specific part independently 2522 * and module specific part independently
2524 */ 2523 */
2525 static struct omap_hwmod_addr_space am33xx_ehrpwm0_addr_space[] = { 2524 static struct omap_hwmod_addr_space am33xx_ehrpwm0_addr_space[] = {
2526 { 2525 {
2527 .pa_start = 0x48300000, 2526 .pa_start = 0x48300000,
2528 .pa_end = 0x48300000 + SZ_16 - 1, 2527 .pa_end = 0x48300000 + SZ_16 - 1,
2529 .flags = ADDR_TYPE_RT 2528 .flags = ADDR_TYPE_RT
2530 }, 2529 },
2531 { 2530 {
2532 .pa_start = 0x48300200, 2531 .pa_start = 0x48300200,
2533 .pa_end = 0x48300200 + SZ_256 - 1, 2532 .pa_end = 0x48300200 + SZ_256 - 1,
2534 .flags = ADDR_TYPE_RT 2533 .flags = ADDR_TYPE_RT
2535 }, 2534 },
2536 { } 2535 { }
2537 }; 2536 };
2538 2537
2539 static struct omap_hwmod_ocp_if am33xx_l4_ls__ehrpwm0 = { 2538 static struct omap_hwmod_ocp_if am33xx_l4_ls__ehrpwm0 = {
2540 .master = &am33xx_l4_ls_hwmod, 2539 .master = &am33xx_l4_ls_hwmod,
2541 .slave = &am33xx_ehrpwm0_hwmod, 2540 .slave = &am33xx_ehrpwm0_hwmod,
2542 .clk = "l4ls_gclk", 2541 .clk = "l4ls_gclk",
2543 .addr = am33xx_ehrpwm0_addr_space, 2542 .addr = am33xx_ehrpwm0_addr_space,
2544 .user = OCP_USER_MPU, 2543 .user = OCP_USER_MPU,
2545 }; 2544 };
2546 2545
2547 /* 2546 /*
2548 * Splitting the resources to handle access of PWMSS config space 2547 * Splitting the resources to handle access of PWMSS config space
2549 * and module specific part independently 2548 * and module specific part independently
2550 */ 2549 */
2551 static struct omap_hwmod_addr_space am33xx_ehrpwm1_addr_space[] = { 2550 static struct omap_hwmod_addr_space am33xx_ehrpwm1_addr_space[] = {
2552 { 2551 {
2553 .pa_start = 0x48302000, 2552 .pa_start = 0x48302000,
2554 .pa_end = 0x48302000 + SZ_16 - 1, 2553 .pa_end = 0x48302000 + SZ_16 - 1,
2555 .flags = ADDR_TYPE_RT 2554 .flags = ADDR_TYPE_RT
2556 }, 2555 },
2557 { 2556 {
2558 .pa_start = 0x48302200, 2557 .pa_start = 0x48302200,
2559 .pa_end = 0x48302200 + SZ_256 - 1, 2558 .pa_end = 0x48302200 + SZ_256 - 1,
2560 .flags = ADDR_TYPE_RT 2559 .flags = ADDR_TYPE_RT
2561 }, 2560 },
2562 { } 2561 { }
2563 }; 2562 };
2564 2563
2565 static struct omap_hwmod_ocp_if am33xx_l4_ls__ehrpwm1 = { 2564 static struct omap_hwmod_ocp_if am33xx_l4_ls__ehrpwm1 = {
2566 .master = &am33xx_l4_ls_hwmod, 2565 .master = &am33xx_l4_ls_hwmod,
2567 .slave = &am33xx_ehrpwm1_hwmod, 2566 .slave = &am33xx_ehrpwm1_hwmod,
2568 .clk = "l4ls_gclk", 2567 .clk = "l4ls_gclk",
2569 .addr = am33xx_ehrpwm1_addr_space, 2568 .addr = am33xx_ehrpwm1_addr_space,
2570 .user = OCP_USER_MPU, 2569 .user = OCP_USER_MPU,
2571 }; 2570 };
2572 2571
2573 /* 2572 /*
2574 * Splitting the resources to handle access of PWMSS config space 2573 * Splitting the resources to handle access of PWMSS config space
2575 * and module specific part independently 2574 * and module specific part independently
2576 */ 2575 */
2577 static struct omap_hwmod_addr_space am33xx_ehrpwm2_addr_space[] = { 2576 static struct omap_hwmod_addr_space am33xx_ehrpwm2_addr_space[] = {
2578 { 2577 {
2579 .pa_start = 0x48304000, 2578 .pa_start = 0x48304000,
2580 .pa_end = 0x48304000 + SZ_16 - 1, 2579 .pa_end = 0x48304000 + SZ_16 - 1,
2581 .flags = ADDR_TYPE_RT 2580 .flags = ADDR_TYPE_RT
2582 }, 2581 },
2583 { 2582 {
2584 .pa_start = 0x48304200, 2583 .pa_start = 0x48304200,
2585 .pa_end = 0x48304200 + SZ_256 - 1, 2584 .pa_end = 0x48304200 + SZ_256 - 1,
2586 .flags = ADDR_TYPE_RT 2585 .flags = ADDR_TYPE_RT
2587 }, 2586 },
2588 { } 2587 { }
2589 }; 2588 };
2590 2589
2591 static struct omap_hwmod_ocp_if am33xx_l4_ls__ehrpwm2 = { 2590 static struct omap_hwmod_ocp_if am33xx_l4_ls__ehrpwm2 = {
2592 .master = &am33xx_l4_ls_hwmod, 2591 .master = &am33xx_l4_ls_hwmod,
2593 .slave = &am33xx_ehrpwm2_hwmod, 2592 .slave = &am33xx_ehrpwm2_hwmod,
2594 .clk = "l4ls_gclk", 2593 .clk = "l4ls_gclk",
2595 .addr = am33xx_ehrpwm2_addr_space, 2594 .addr = am33xx_ehrpwm2_addr_space,
2596 .user = OCP_USER_MPU, 2595 .user = OCP_USER_MPU,
2597 }; 2596 };
2598 2597
2599 /* 2598 /*
2600 * Splitting the resources to handle access of PWMSS config space 2599 * Splitting the resources to handle access of PWMSS config space
2601 * and module specific part independently 2600 * and module specific part independently
2602 */ 2601 */
2603 static struct omap_hwmod_addr_space am33xx_ecap0_addr_space[] = { 2602 static struct omap_hwmod_addr_space am33xx_ecap0_addr_space[] = {
2604 { 2603 {
2605 .pa_start = 0x48300000, 2604 .pa_start = 0x48300000,
2606 .pa_end = 0x48300000 + SZ_16 - 1, 2605 .pa_end = 0x48300000 + SZ_16 - 1,
2607 .flags = ADDR_TYPE_RT 2606 .flags = ADDR_TYPE_RT
2608 }, 2607 },
2609 { 2608 {
2610 .pa_start = 0x48300100, 2609 .pa_start = 0x48300100,
2611 .pa_end = 0x48300100 + SZ_256 - 1, 2610 .pa_end = 0x48300100 + SZ_256 - 1,
2612 .flags = ADDR_TYPE_RT 2611 .flags = ADDR_TYPE_RT
2613 }, 2612 },
2614 { } 2613 { }
2615 }; 2614 };
2616 2615
2617 static struct omap_hwmod_ocp_if am33xx_l4_ls__ecap0 = { 2616 static struct omap_hwmod_ocp_if am33xx_l4_ls__ecap0 = {
2618 .master = &am33xx_l4_ls_hwmod, 2617 .master = &am33xx_l4_ls_hwmod,
2619 .slave = &am33xx_ecap0_hwmod, 2618 .slave = &am33xx_ecap0_hwmod,
2620 .clk = "l4ls_gclk", 2619 .clk = "l4ls_gclk",
2621 .addr = am33xx_ecap0_addr_space, 2620 .addr = am33xx_ecap0_addr_space,
2622 .user = OCP_USER_MPU, 2621 .user = OCP_USER_MPU,
2623 }; 2622 };
2624 2623
2625 /* 2624 /*
2626 * Splitting the resources to handle access of PWMSS config space 2625 * Splitting the resources to handle access of PWMSS config space
2627 * and module specific part independently 2626 * and module specific part independently
2628 */ 2627 */
2629 static struct omap_hwmod_addr_space am33xx_ecap1_addr_space[] = { 2628 static struct omap_hwmod_addr_space am33xx_ecap1_addr_space[] = {
2630 { 2629 {
2631 .pa_start = 0x48302000, 2630 .pa_start = 0x48302000,
2632 .pa_end = 0x48302000 + SZ_16 - 1, 2631 .pa_end = 0x48302000 + SZ_16 - 1,
2633 .flags = ADDR_TYPE_RT 2632 .flags = ADDR_TYPE_RT
2634 }, 2633 },
2635 { 2634 {
2636 .pa_start = 0x48302100, 2635 .pa_start = 0x48302100,
2637 .pa_end = 0x48302100 + SZ_256 - 1, 2636 .pa_end = 0x48302100 + SZ_256 - 1,
2638 .flags = ADDR_TYPE_RT 2637 .flags = ADDR_TYPE_RT
2639 }, 2638 },
2640 { } 2639 { }
2641 }; 2640 };
2642 2641
2643 static struct omap_hwmod_ocp_if am33xx_l4_ls__ecap1 = { 2642 static struct omap_hwmod_ocp_if am33xx_l4_ls__ecap1 = {
2644 .master = &am33xx_l4_ls_hwmod, 2643 .master = &am33xx_l4_ls_hwmod,
2645 .slave = &am33xx_ecap1_hwmod, 2644 .slave = &am33xx_ecap1_hwmod,
2646 .clk = "l4ls_gclk", 2645 .clk = "l4ls_gclk",
2647 .addr = am33xx_ecap1_addr_space, 2646 .addr = am33xx_ecap1_addr_space,
2648 .user = OCP_USER_MPU, 2647 .user = OCP_USER_MPU,
2649 }; 2648 };
2650 2649
2651 /* 2650 /*
2652 * Splitting the resources to handle access of PWMSS config space 2651 * Splitting the resources to handle access of PWMSS config space
2653 * and module specific part independently 2652 * and module specific part independently
2654 */ 2653 */
2655 static struct omap_hwmod_addr_space am33xx_ecap2_addr_space[] = { 2654 static struct omap_hwmod_addr_space am33xx_ecap2_addr_space[] = {
2656 { 2655 {
2657 .pa_start = 0x48304000, 2656 .pa_start = 0x48304000,
2658 .pa_end = 0x48304000 + SZ_16 - 1, 2657 .pa_end = 0x48304000 + SZ_16 - 1,
2659 .flags = ADDR_TYPE_RT 2658 .flags = ADDR_TYPE_RT
2660 }, 2659 },
2661 { 2660 {
2662 .pa_start = 0x48304100, 2661 .pa_start = 0x48304100,
2663 .pa_end = 0x48304100 + SZ_256 - 1, 2662 .pa_end = 0x48304100 + SZ_256 - 1,
2664 .flags = ADDR_TYPE_RT 2663 .flags = ADDR_TYPE_RT
2665 }, 2664 },
2666 { } 2665 { }
2667 }; 2666 };
2668 2667
2669 static struct omap_hwmod_ocp_if am33xx_l4_ls__ecap2 = { 2668 static struct omap_hwmod_ocp_if am33xx_l4_ls__ecap2 = {
2670 .master = &am33xx_l4_ls_hwmod, 2669 .master = &am33xx_l4_ls_hwmod,
2671 .slave = &am33xx_ecap2_hwmod, 2670 .slave = &am33xx_ecap2_hwmod,
2672 .clk = "l4ls_gclk", 2671 .clk = "l4ls_gclk",
2673 .addr = am33xx_ecap2_addr_space, 2672 .addr = am33xx_ecap2_addr_space,
2674 .user = OCP_USER_MPU, 2673 .user = OCP_USER_MPU,
2675 }; 2674 };
2676 2675
2677 /* l3s cfg -> gpmc */ 2676 /* l3s cfg -> gpmc */
2678 static struct omap_hwmod_addr_space am33xx_gpmc_addr_space[] = { 2677 static struct omap_hwmod_addr_space am33xx_gpmc_addr_space[] = {
2679 { 2678 {
2680 .pa_start = 0x50000000, 2679 .pa_start = 0x50000000,
2681 .pa_end = 0x50000000 + SZ_8K - 1, 2680 .pa_end = 0x50000000 + SZ_8K - 1,
2682 .flags = ADDR_TYPE_RT, 2681 .flags = ADDR_TYPE_RT,
2683 }, 2682 },
2684 { } 2683 { }
2685 }; 2684 };
2686 2685
2687 static struct omap_hwmod_ocp_if am33xx_l3_s__gpmc = { 2686 static struct omap_hwmod_ocp_if am33xx_l3_s__gpmc = {
2688 .master = &am33xx_l3_s_hwmod, 2687 .master = &am33xx_l3_s_hwmod,
2689 .slave = &am33xx_gpmc_hwmod, 2688 .slave = &am33xx_gpmc_hwmod,
2690 .clk = "l3s_gclk", 2689 .clk = "l3s_gclk",
2691 .addr = am33xx_gpmc_addr_space, 2690 .addr = am33xx_gpmc_addr_space,
2692 .user = OCP_USER_MPU, 2691 .user = OCP_USER_MPU,
2693 }; 2692 };
2694 2693
2695 /* i2c2 */ 2694 /* i2c2 */
2696 static struct omap_hwmod_addr_space am33xx_i2c2_addr_space[] = { 2695 static struct omap_hwmod_addr_space am33xx_i2c2_addr_space[] = {
2697 { 2696 {
2698 .pa_start = 0x4802A000, 2697 .pa_start = 0x4802A000,
2699 .pa_end = 0x4802A000 + SZ_4K - 1, 2698 .pa_end = 0x4802A000 + SZ_4K - 1,
2700 .flags = ADDR_TYPE_RT, 2699 .flags = ADDR_TYPE_RT,
2701 }, 2700 },
2702 { } 2701 { }
2703 }; 2702 };
2704 2703
2705 static struct omap_hwmod_ocp_if am33xx_l4_per__i2c2 = { 2704 static struct omap_hwmod_ocp_if am33xx_l4_per__i2c2 = {
2706 .master = &am33xx_l4_ls_hwmod, 2705 .master = &am33xx_l4_ls_hwmod,
2707 .slave = &am33xx_i2c2_hwmod, 2706 .slave = &am33xx_i2c2_hwmod,
2708 .clk = "l4ls_gclk", 2707 .clk = "l4ls_gclk",
2709 .addr = am33xx_i2c2_addr_space, 2708 .addr = am33xx_i2c2_addr_space,
2710 .user = OCP_USER_MPU, 2709 .user = OCP_USER_MPU,
2711 }; 2710 };
2712 2711
2713 static struct omap_hwmod_addr_space am33xx_i2c3_addr_space[] = { 2712 static struct omap_hwmod_addr_space am33xx_i2c3_addr_space[] = {
2714 { 2713 {
2715 .pa_start = 0x4819C000, 2714 .pa_start = 0x4819C000,
2716 .pa_end = 0x4819C000 + SZ_4K - 1, 2715 .pa_end = 0x4819C000 + SZ_4K - 1,
2717 .flags = ADDR_TYPE_RT 2716 .flags = ADDR_TYPE_RT
2718 }, 2717 },
2719 { } 2718 { }
2720 }; 2719 };
2721 2720
2722 static struct omap_hwmod_ocp_if am33xx_l4_per__i2c3 = { 2721 static struct omap_hwmod_ocp_if am33xx_l4_per__i2c3 = {
2723 .master = &am33xx_l4_ls_hwmod, 2722 .master = &am33xx_l4_ls_hwmod,
2724 .slave = &am33xx_i2c3_hwmod, 2723 .slave = &am33xx_i2c3_hwmod,
2725 .clk = "l4ls_gclk", 2724 .clk = "l4ls_gclk",
2726 .addr = am33xx_i2c3_addr_space, 2725 .addr = am33xx_i2c3_addr_space,
2727 .user = OCP_USER_MPU, 2726 .user = OCP_USER_MPU,
2728 }; 2727 };
2729 2728
2730 static struct omap_hwmod_addr_space am33xx_lcdc_addr_space[] = { 2729 static struct omap_hwmod_addr_space am33xx_lcdc_addr_space[] = {
2731 { 2730 {
2732 .pa_start = 0x4830E000, 2731 .pa_start = 0x4830E000,
2733 .pa_end = 0x4830E000 + SZ_8K - 1, 2732 .pa_end = 0x4830E000 + SZ_8K - 1,
2734 .flags = ADDR_TYPE_RT, 2733 .flags = ADDR_TYPE_RT,
2735 }, 2734 },
2736 { } 2735 { }
2737 }; 2736 };
2738 2737
2739 static struct omap_hwmod_ocp_if am33xx_l3_main__lcdc = { 2738 static struct omap_hwmod_ocp_if am33xx_l3_main__lcdc = {
2740 .master = &am33xx_l3_main_hwmod, 2739 .master = &am33xx_l3_main_hwmod,
2741 .slave = &am33xx_lcdc_hwmod, 2740 .slave = &am33xx_lcdc_hwmod,
2742 .clk = "dpll_core_m4_ck", 2741 .clk = "dpll_core_m4_ck",
2743 .addr = am33xx_lcdc_addr_space, 2742 .addr = am33xx_lcdc_addr_space,
2744 .user = OCP_USER_MPU, 2743 .user = OCP_USER_MPU,
2745 }; 2744 };
2746 2745
2747 static struct omap_hwmod_addr_space am33xx_mailbox_addrs[] = { 2746 static struct omap_hwmod_addr_space am33xx_mailbox_addrs[] = {
2748 { 2747 {
2749 .pa_start = 0x480C8000, 2748 .pa_start = 0x480C8000,
2750 .pa_end = 0x480C8000 + (SZ_4K - 1), 2749 .pa_end = 0x480C8000 + (SZ_4K - 1),
2751 .flags = ADDR_TYPE_RT 2750 .flags = ADDR_TYPE_RT
2752 }, 2751 },
2753 { } 2752 { }
2754 }; 2753 };
2755 2754
2756 /* l4 ls -> mailbox */ 2755 /* l4 ls -> mailbox */
2757 static struct omap_hwmod_ocp_if am33xx_l4_per__mailbox = { 2756 static struct omap_hwmod_ocp_if am33xx_l4_per__mailbox = {
2758 .master = &am33xx_l4_ls_hwmod, 2757 .master = &am33xx_l4_ls_hwmod,
2759 .slave = &am33xx_mailbox_hwmod, 2758 .slave = &am33xx_mailbox_hwmod,
2760 .clk = "l4ls_gclk", 2759 .clk = "l4ls_gclk",
2761 .addr = am33xx_mailbox_addrs, 2760 .addr = am33xx_mailbox_addrs,
2762 .user = OCP_USER_MPU, 2761 .user = OCP_USER_MPU,
2763 }; 2762 };
2764 2763
2765 /* l4 ls -> spinlock */ 2764 /* l4 ls -> spinlock */
2766 static struct omap_hwmod_addr_space am33xx_spinlock_addrs[] = { 2765 static struct omap_hwmod_addr_space am33xx_spinlock_addrs[] = {
2767 { 2766 {
2768 .pa_start = 0x480Ca000, 2767 .pa_start = 0x480Ca000,
2769 .pa_end = 0x480Ca000 + SZ_4K - 1, 2768 .pa_end = 0x480Ca000 + SZ_4K - 1,
2770 .flags = ADDR_TYPE_RT 2769 .flags = ADDR_TYPE_RT
2771 }, 2770 },
2772 { } 2771 { }
2773 }; 2772 };
2774 2773
2775 static struct omap_hwmod_ocp_if am33xx_l4_ls__spinlock = { 2774 static struct omap_hwmod_ocp_if am33xx_l4_ls__spinlock = {
2776 .master = &am33xx_l4_ls_hwmod, 2775 .master = &am33xx_l4_ls_hwmod,
2777 .slave = &am33xx_spinlock_hwmod, 2776 .slave = &am33xx_spinlock_hwmod,
2778 .clk = "l4ls_gclk", 2777 .clk = "l4ls_gclk",
2779 .addr = am33xx_spinlock_addrs, 2778 .addr = am33xx_spinlock_addrs,
2780 .user = OCP_USER_MPU, 2779 .user = OCP_USER_MPU,
2781 }; 2780 };
2782 2781
2783 /* l4 ls -> mcasp0 */ 2782 /* l4 ls -> mcasp0 */
2784 static struct omap_hwmod_addr_space am33xx_mcasp0_addr_space[] = { 2783 static struct omap_hwmod_addr_space am33xx_mcasp0_addr_space[] = {
2785 { 2784 {
2786 .pa_start = 0x48038000, 2785 .pa_start = 0x48038000,
2787 .pa_end = 0x48038000 + SZ_8K - 1, 2786 .pa_end = 0x48038000 + SZ_8K - 1,
2788 .flags = ADDR_TYPE_RT 2787 .flags = ADDR_TYPE_RT
2789 }, 2788 },
2790 { } 2789 { }
2791 }; 2790 };
2792 2791
2793 static struct omap_hwmod_ocp_if am33xx_l4_ls__mcasp0 = { 2792 static struct omap_hwmod_ocp_if am33xx_l4_ls__mcasp0 = {
2794 .master = &am33xx_l4_ls_hwmod, 2793 .master = &am33xx_l4_ls_hwmod,
2795 .slave = &am33xx_mcasp0_hwmod, 2794 .slave = &am33xx_mcasp0_hwmod,
2796 .clk = "l4ls_gclk", 2795 .clk = "l4ls_gclk",
2797 .addr = am33xx_mcasp0_addr_space, 2796 .addr = am33xx_mcasp0_addr_space,
2798 .user = OCP_USER_MPU, 2797 .user = OCP_USER_MPU,
2799 }; 2798 };
2800 2799
2801 /* l3 s -> mcasp0 data */ 2800 /* l3 s -> mcasp0 data */
2802 static struct omap_hwmod_addr_space am33xx_mcasp0_data_addr_space[] = { 2801 static struct omap_hwmod_addr_space am33xx_mcasp0_data_addr_space[] = {
2803 { 2802 {
2804 .pa_start = 0x46000000, 2803 .pa_start = 0x46000000,
2805 .pa_end = 0x46000000 + SZ_4M - 1, 2804 .pa_end = 0x46000000 + SZ_4M - 1,
2806 .flags = ADDR_TYPE_RT 2805 .flags = ADDR_TYPE_RT
2807 }, 2806 },
2808 { } 2807 { }
2809 }; 2808 };
2810 2809
2811 static struct omap_hwmod_ocp_if am33xx_l3_s__mcasp0_data = { 2810 static struct omap_hwmod_ocp_if am33xx_l3_s__mcasp0_data = {
2812 .master = &am33xx_l3_s_hwmod, 2811 .master = &am33xx_l3_s_hwmod,
2813 .slave = &am33xx_mcasp0_hwmod, 2812 .slave = &am33xx_mcasp0_hwmod,
2814 .clk = "l3s_gclk", 2813 .clk = "l3s_gclk",
2815 .addr = am33xx_mcasp0_data_addr_space, 2814 .addr = am33xx_mcasp0_data_addr_space,
2816 .user = OCP_USER_SDMA, 2815 .user = OCP_USER_SDMA,
2817 }; 2816 };
2818 2817
2819 /* l4 ls -> mcasp1 */ 2818 /* l4 ls -> mcasp1 */
2820 static struct omap_hwmod_addr_space am33xx_mcasp1_addr_space[] = { 2819 static struct omap_hwmod_addr_space am33xx_mcasp1_addr_space[] = {
2821 { 2820 {
2822 .pa_start = 0x4803C000, 2821 .pa_start = 0x4803C000,
2823 .pa_end = 0x4803C000 + SZ_8K - 1, 2822 .pa_end = 0x4803C000 + SZ_8K - 1,
2824 .flags = ADDR_TYPE_RT 2823 .flags = ADDR_TYPE_RT
2825 }, 2824 },
2826 { } 2825 { }
2827 }; 2826 };
2828 2827
2829 static struct omap_hwmod_ocp_if am33xx_l4_ls__mcasp1 = { 2828 static struct omap_hwmod_ocp_if am33xx_l4_ls__mcasp1 = {
2830 .master = &am33xx_l4_ls_hwmod, 2829 .master = &am33xx_l4_ls_hwmod,
2831 .slave = &am33xx_mcasp1_hwmod, 2830 .slave = &am33xx_mcasp1_hwmod,
2832 .clk = "l4ls_gclk", 2831 .clk = "l4ls_gclk",
2833 .addr = am33xx_mcasp1_addr_space, 2832 .addr = am33xx_mcasp1_addr_space,
2834 .user = OCP_USER_MPU, 2833 .user = OCP_USER_MPU,
2835 }; 2834 };
2836 2835
2837 /* l3 s -> mcasp1 data */ 2836 /* l3 s -> mcasp1 data */
2838 static struct omap_hwmod_addr_space am33xx_mcasp1_data_addr_space[] = { 2837 static struct omap_hwmod_addr_space am33xx_mcasp1_data_addr_space[] = {
2839 { 2838 {
2840 .pa_start = 0x46400000, 2839 .pa_start = 0x46400000,
2841 .pa_end = 0x46400000 + SZ_4M - 1, 2840 .pa_end = 0x46400000 + SZ_4M - 1,
2842 .flags = ADDR_TYPE_RT 2841 .flags = ADDR_TYPE_RT
2843 }, 2842 },
2844 { } 2843 { }
2845 }; 2844 };
2846 2845
2847 static struct omap_hwmod_ocp_if am33xx_l3_s__mcasp1_data = { 2846 static struct omap_hwmod_ocp_if am33xx_l3_s__mcasp1_data = {
2848 .master = &am33xx_l3_s_hwmod, 2847 .master = &am33xx_l3_s_hwmod,
2849 .slave = &am33xx_mcasp1_hwmod, 2848 .slave = &am33xx_mcasp1_hwmod,
2850 .clk = "l3s_gclk", 2849 .clk = "l3s_gclk",
2851 .addr = am33xx_mcasp1_data_addr_space, 2850 .addr = am33xx_mcasp1_data_addr_space,
2852 .user = OCP_USER_SDMA, 2851 .user = OCP_USER_SDMA,
2853 }; 2852 };
2854 2853
2855 /* l4 ls -> mmc0 */ 2854 /* l4 ls -> mmc0 */
2856 static struct omap_hwmod_addr_space am33xx_mmc0_addr_space[] = { 2855 static struct omap_hwmod_addr_space am33xx_mmc0_addr_space[] = {
2857 { 2856 {
2858 .pa_start = 0x48060100, 2857 .pa_start = 0x48060100,
2859 .pa_end = 0x48060100 + SZ_4K - 1, 2858 .pa_end = 0x48060100 + SZ_4K - 1,
2860 .flags = ADDR_TYPE_RT, 2859 .flags = ADDR_TYPE_RT,
2861 }, 2860 },
2862 { } 2861 { }
2863 }; 2862 };
2864 2863
2865 static struct omap_hwmod_ocp_if am33xx_l4_ls__mmc0 = { 2864 static struct omap_hwmod_ocp_if am33xx_l4_ls__mmc0 = {
2866 .master = &am33xx_l4_ls_hwmod, 2865 .master = &am33xx_l4_ls_hwmod,
2867 .slave = &am33xx_mmc0_hwmod, 2866 .slave = &am33xx_mmc0_hwmod,
2868 .clk = "l4ls_gclk", 2867 .clk = "l4ls_gclk",
2869 .addr = am33xx_mmc0_addr_space, 2868 .addr = am33xx_mmc0_addr_space,
2870 .user = OCP_USER_MPU, 2869 .user = OCP_USER_MPU,
2871 }; 2870 };
2872 2871
2873 /* l4 ls -> mmc1 */ 2872 /* l4 ls -> mmc1 */
2874 static struct omap_hwmod_addr_space am33xx_mmc1_addr_space[] = { 2873 static struct omap_hwmod_addr_space am33xx_mmc1_addr_space[] = {
2875 { 2874 {
2876 .pa_start = 0x481d8100, 2875 .pa_start = 0x481d8100,
2877 .pa_end = 0x481d8100 + SZ_4K - 1, 2876 .pa_end = 0x481d8100 + SZ_4K - 1,
2878 .flags = ADDR_TYPE_RT, 2877 .flags = ADDR_TYPE_RT,
2879 }, 2878 },
2880 { } 2879 { }
2881 }; 2880 };
2882 2881
2883 static struct omap_hwmod_ocp_if am33xx_l4_ls__mmc1 = { 2882 static struct omap_hwmod_ocp_if am33xx_l4_ls__mmc1 = {
2884 .master = &am33xx_l4_ls_hwmod, 2883 .master = &am33xx_l4_ls_hwmod,
2885 .slave = &am33xx_mmc1_hwmod, 2884 .slave = &am33xx_mmc1_hwmod,
2886 .clk = "l4ls_gclk", 2885 .clk = "l4ls_gclk",
2887 .addr = am33xx_mmc1_addr_space, 2886 .addr = am33xx_mmc1_addr_space,
2888 .user = OCP_USER_MPU, 2887 .user = OCP_USER_MPU,
2889 }; 2888 };
2890 2889
2891 /* l3 s -> mmc2 */ 2890 /* l3 s -> mmc2 */
2892 static struct omap_hwmod_addr_space am33xx_mmc2_addr_space[] = { 2891 static struct omap_hwmod_addr_space am33xx_mmc2_addr_space[] = {
2893 { 2892 {
2894 .pa_start = 0x47810100, 2893 .pa_start = 0x47810100,
2895 .pa_end = 0x47810100 + SZ_64K - 1, 2894 .pa_end = 0x47810100 + SZ_64K - 1,
2896 .flags = ADDR_TYPE_RT, 2895 .flags = ADDR_TYPE_RT,
2897 }, 2896 },
2898 { } 2897 { }
2899 }; 2898 };
2900 2899
2901 static struct omap_hwmod_ocp_if am33xx_l3_s__mmc2 = { 2900 static struct omap_hwmod_ocp_if am33xx_l3_s__mmc2 = {
2902 .master = &am33xx_l3_s_hwmod, 2901 .master = &am33xx_l3_s_hwmod,
2903 .slave = &am33xx_mmc2_hwmod, 2902 .slave = &am33xx_mmc2_hwmod,
2904 .clk = "l3s_gclk", 2903 .clk = "l3s_gclk",
2905 .addr = am33xx_mmc2_addr_space, 2904 .addr = am33xx_mmc2_addr_space,
2906 .user = OCP_USER_MPU, 2905 .user = OCP_USER_MPU,
2907 }; 2906 };
2908 2907
2909 /* l4 ls -> mcspi0 */ 2908 /* l4 ls -> mcspi0 */
2910 static struct omap_hwmod_addr_space am33xx_mcspi0_addr_space[] = { 2909 static struct omap_hwmod_addr_space am33xx_mcspi0_addr_space[] = {
2911 { 2910 {
2912 .pa_start = 0x48030000, 2911 .pa_start = 0x48030000,
2913 .pa_end = 0x48030000 + SZ_1K - 1, 2912 .pa_end = 0x48030000 + SZ_1K - 1,
2914 .flags = ADDR_TYPE_RT, 2913 .flags = ADDR_TYPE_RT,
2915 }, 2914 },
2916 { } 2915 { }
2917 }; 2916 };
2918 2917
2919 static struct omap_hwmod_ocp_if am33xx_l4_ls__mcspi0 = { 2918 static struct omap_hwmod_ocp_if am33xx_l4_ls__mcspi0 = {
2920 .master = &am33xx_l4_ls_hwmod, 2919 .master = &am33xx_l4_ls_hwmod,
2921 .slave = &am33xx_spi0_hwmod, 2920 .slave = &am33xx_spi0_hwmod,
2922 .clk = "l4ls_gclk", 2921 .clk = "l4ls_gclk",
2923 .addr = am33xx_mcspi0_addr_space, 2922 .addr = am33xx_mcspi0_addr_space,
2924 .user = OCP_USER_MPU, 2923 .user = OCP_USER_MPU,
2925 }; 2924 };
2926 2925
2927 /* l4 ls -> mcspi1 */ 2926 /* l4 ls -> mcspi1 */
2928 static struct omap_hwmod_addr_space am33xx_mcspi1_addr_space[] = { 2927 static struct omap_hwmod_addr_space am33xx_mcspi1_addr_space[] = {
2929 { 2928 {
2930 .pa_start = 0x481A0000, 2929 .pa_start = 0x481A0000,
2931 .pa_end = 0x481A0000 + SZ_1K - 1, 2930 .pa_end = 0x481A0000 + SZ_1K - 1,
2932 .flags = ADDR_TYPE_RT, 2931 .flags = ADDR_TYPE_RT,
2933 }, 2932 },
2934 { } 2933 { }
2935 }; 2934 };
2936 2935
2937 static struct omap_hwmod_ocp_if am33xx_l4_ls__mcspi1 = { 2936 static struct omap_hwmod_ocp_if am33xx_l4_ls__mcspi1 = {
2938 .master = &am33xx_l4_ls_hwmod, 2937 .master = &am33xx_l4_ls_hwmod,
2939 .slave = &am33xx_spi1_hwmod, 2938 .slave = &am33xx_spi1_hwmod,
2940 .clk = "l4ls_gclk", 2939 .clk = "l4ls_gclk",
2941 .addr = am33xx_mcspi1_addr_space, 2940 .addr = am33xx_mcspi1_addr_space,
2942 .user = OCP_USER_MPU, 2941 .user = OCP_USER_MPU,
2943 }; 2942 };
2944 2943
2945 /* l4 wkup -> timer1 */ 2944 /* l4 wkup -> timer1 */
2946 static struct omap_hwmod_addr_space am33xx_timer1_addr_space[] = { 2945 static struct omap_hwmod_addr_space am33xx_timer1_addr_space[] = {
2947 { 2946 {
2948 .pa_start = 0x44E31000, 2947 .pa_start = 0x44E31000,
2949 .pa_end = 0x44E31000 + SZ_1K - 1, 2948 .pa_end = 0x44E31000 + SZ_1K - 1,
2950 .flags = ADDR_TYPE_RT 2949 .flags = ADDR_TYPE_RT
2951 }, 2950 },
2952 { } 2951 { }
2953 }; 2952 };
2954 2953
2955 static struct omap_hwmod_ocp_if am33xx_l4_wkup__timer1 = { 2954 static struct omap_hwmod_ocp_if am33xx_l4_wkup__timer1 = {
2956 .master = &am33xx_l4_wkup_hwmod, 2955 .master = &am33xx_l4_wkup_hwmod,
2957 .slave = &am33xx_timer1_hwmod, 2956 .slave = &am33xx_timer1_hwmod,
2958 .clk = "dpll_core_m4_div2_ck", 2957 .clk = "dpll_core_m4_div2_ck",
2959 .addr = am33xx_timer1_addr_space, 2958 .addr = am33xx_timer1_addr_space,
2960 .user = OCP_USER_MPU, 2959 .user = OCP_USER_MPU,
2961 }; 2960 };
2962 2961
2963 /* l4 per -> timer2 */ 2962 /* l4 per -> timer2 */
2964 static struct omap_hwmod_addr_space am33xx_timer2_addr_space[] = { 2963 static struct omap_hwmod_addr_space am33xx_timer2_addr_space[] = {
2965 { 2964 {
2966 .pa_start = 0x48040000, 2965 .pa_start = 0x48040000,
2967 .pa_end = 0x48040000 + SZ_1K - 1, 2966 .pa_end = 0x48040000 + SZ_1K - 1,
2968 .flags = ADDR_TYPE_RT 2967 .flags = ADDR_TYPE_RT
2969 }, 2968 },
2970 { } 2969 { }
2971 }; 2970 };
2972 2971
2973 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer2 = { 2972 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer2 = {
2974 .master = &am33xx_l4_ls_hwmod, 2973 .master = &am33xx_l4_ls_hwmod,
2975 .slave = &am33xx_timer2_hwmod, 2974 .slave = &am33xx_timer2_hwmod,
2976 .clk = "l4ls_gclk", 2975 .clk = "l4ls_gclk",
2977 .addr = am33xx_timer2_addr_space, 2976 .addr = am33xx_timer2_addr_space,
2978 .user = OCP_USER_MPU, 2977 .user = OCP_USER_MPU,
2979 }; 2978 };
2980 2979
2981 /* l4 per -> timer3 */ 2980 /* l4 per -> timer3 */
2982 static struct omap_hwmod_addr_space am33xx_timer3_addr_space[] = { 2981 static struct omap_hwmod_addr_space am33xx_timer3_addr_space[] = {
2983 { 2982 {
2984 .pa_start = 0x48042000, 2983 .pa_start = 0x48042000,
2985 .pa_end = 0x48042000 + SZ_1K - 1, 2984 .pa_end = 0x48042000 + SZ_1K - 1,
2986 .flags = ADDR_TYPE_RT 2985 .flags = ADDR_TYPE_RT
2987 }, 2986 },
2988 { } 2987 { }
2989 }; 2988 };
2990 2989
2991 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer3 = { 2990 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer3 = {
2992 .master = &am33xx_l4_ls_hwmod, 2991 .master = &am33xx_l4_ls_hwmod,
2993 .slave = &am33xx_timer3_hwmod, 2992 .slave = &am33xx_timer3_hwmod,
2994 .clk = "l4ls_gclk", 2993 .clk = "l4ls_gclk",
2995 .addr = am33xx_timer3_addr_space, 2994 .addr = am33xx_timer3_addr_space,
2996 .user = OCP_USER_MPU, 2995 .user = OCP_USER_MPU,
2997 }; 2996 };
2998 2997
2999 /* l4 per -> timer4 */ 2998 /* l4 per -> timer4 */
3000 static struct omap_hwmod_addr_space am33xx_timer4_addr_space[] = { 2999 static struct omap_hwmod_addr_space am33xx_timer4_addr_space[] = {
3001 { 3000 {
3002 .pa_start = 0x48044000, 3001 .pa_start = 0x48044000,
3003 .pa_end = 0x48044000 + SZ_1K - 1, 3002 .pa_end = 0x48044000 + SZ_1K - 1,
3004 .flags = ADDR_TYPE_RT 3003 .flags = ADDR_TYPE_RT
3005 }, 3004 },
3006 { } 3005 { }
3007 }; 3006 };
3008 3007
3009 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer4 = { 3008 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer4 = {
3010 .master = &am33xx_l4_ls_hwmod, 3009 .master = &am33xx_l4_ls_hwmod,
3011 .slave = &am33xx_timer4_hwmod, 3010 .slave = &am33xx_timer4_hwmod,
3012 .clk = "l4ls_gclk", 3011 .clk = "l4ls_gclk",
3013 .addr = am33xx_timer4_addr_space, 3012 .addr = am33xx_timer4_addr_space,
3014 .user = OCP_USER_MPU, 3013 .user = OCP_USER_MPU,
3015 }; 3014 };
3016 3015
3017 /* l4 per -> timer5 */ 3016 /* l4 per -> timer5 */
3018 static struct omap_hwmod_addr_space am33xx_timer5_addr_space[] = { 3017 static struct omap_hwmod_addr_space am33xx_timer5_addr_space[] = {
3019 { 3018 {
3020 .pa_start = 0x48046000, 3019 .pa_start = 0x48046000,
3021 .pa_end = 0x48046000 + SZ_1K - 1, 3020 .pa_end = 0x48046000 + SZ_1K - 1,
3022 .flags = ADDR_TYPE_RT 3021 .flags = ADDR_TYPE_RT
3023 }, 3022 },
3024 { } 3023 { }
3025 }; 3024 };
3026 3025
3027 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer5 = { 3026 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer5 = {
3028 .master = &am33xx_l4_ls_hwmod, 3027 .master = &am33xx_l4_ls_hwmod,
3029 .slave = &am33xx_timer5_hwmod, 3028 .slave = &am33xx_timer5_hwmod,
3030 .clk = "l4ls_gclk", 3029 .clk = "l4ls_gclk",
3031 .addr = am33xx_timer5_addr_space, 3030 .addr = am33xx_timer5_addr_space,
3032 .user = OCP_USER_MPU, 3031 .user = OCP_USER_MPU,
3033 }; 3032 };
3034 3033
3035 /* l4 per -> timer6 */ 3034 /* l4 per -> timer6 */
3036 static struct omap_hwmod_addr_space am33xx_timer6_addr_space[] = { 3035 static struct omap_hwmod_addr_space am33xx_timer6_addr_space[] = {
3037 { 3036 {
3038 .pa_start = 0x48048000, 3037 .pa_start = 0x48048000,
3039 .pa_end = 0x48048000 + SZ_1K - 1, 3038 .pa_end = 0x48048000 + SZ_1K - 1,
3040 .flags = ADDR_TYPE_RT 3039 .flags = ADDR_TYPE_RT
3041 }, 3040 },
3042 { } 3041 { }
3043 }; 3042 };
3044 3043
3045 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer6 = { 3044 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer6 = {
3046 .master = &am33xx_l4_ls_hwmod, 3045 .master = &am33xx_l4_ls_hwmod,
3047 .slave = &am33xx_timer6_hwmod, 3046 .slave = &am33xx_timer6_hwmod,
3048 .clk = "l4ls_gclk", 3047 .clk = "l4ls_gclk",
3049 .addr = am33xx_timer6_addr_space, 3048 .addr = am33xx_timer6_addr_space,
3050 .user = OCP_USER_MPU, 3049 .user = OCP_USER_MPU,
3051 }; 3050 };
3052 3051
3053 /* l4 per -> timer7 */ 3052 /* l4 per -> timer7 */
3054 static struct omap_hwmod_addr_space am33xx_timer7_addr_space[] = { 3053 static struct omap_hwmod_addr_space am33xx_timer7_addr_space[] = {
3055 { 3054 {
3056 .pa_start = 0x4804A000, 3055 .pa_start = 0x4804A000,
3057 .pa_end = 0x4804A000 + SZ_1K - 1, 3056 .pa_end = 0x4804A000 + SZ_1K - 1,
3058 .flags = ADDR_TYPE_RT 3057 .flags = ADDR_TYPE_RT
3059 }, 3058 },
3060 { } 3059 { }
3061 }; 3060 };
3062 3061
3063 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer7 = { 3062 static struct omap_hwmod_ocp_if am33xx_l4_ls__timer7 = {
3064 .master = &am33xx_l4_ls_hwmod, 3063 .master = &am33xx_l4_ls_hwmod,
3065 .slave = &am33xx_timer7_hwmod, 3064 .slave = &am33xx_timer7_hwmod,
3066 .clk = "l4ls_gclk", 3065 .clk = "l4ls_gclk",
3067 .addr = am33xx_timer7_addr_space, 3066 .addr = am33xx_timer7_addr_space,
3068 .user = OCP_USER_MPU, 3067 .user = OCP_USER_MPU,
3069 }; 3068 };
3070 3069
3071 /* l3 main -> tpcc */ 3070 /* l3 main -> tpcc */
3072 static struct omap_hwmod_addr_space am33xx_tpcc_addr_space[] = { 3071 static struct omap_hwmod_addr_space am33xx_tpcc_addr_space[] = {
3073 { 3072 {
3074 .pa_start = 0x49000000, 3073 .pa_start = 0x49000000,
3075 .pa_end = 0x49000000 + SZ_32K - 1, 3074 .pa_end = 0x49000000 + SZ_32K - 1,
3076 .flags = ADDR_TYPE_RT 3075 .flags = ADDR_TYPE_RT
3077 }, 3076 },
3078 { } 3077 { }
3079 }; 3078 };
3080 3079
3081 static struct omap_hwmod_ocp_if am33xx_l3_main__tpcc = { 3080 static struct omap_hwmod_ocp_if am33xx_l3_main__tpcc = {
3082 .master = &am33xx_l3_main_hwmod, 3081 .master = &am33xx_l3_main_hwmod,
3083 .slave = &am33xx_tpcc_hwmod, 3082 .slave = &am33xx_tpcc_hwmod,
3084 .clk = "l3_gclk", 3083 .clk = "l3_gclk",
3085 .addr = am33xx_tpcc_addr_space, 3084 .addr = am33xx_tpcc_addr_space,
3086 .user = OCP_USER_MPU, 3085 .user = OCP_USER_MPU,
3087 }; 3086 };
3088 3087
3089 /* l3 main -> tpcc0 */ 3088 /* l3 main -> tpcc0 */
3090 static struct omap_hwmod_addr_space am33xx_tptc0_addr_space[] = { 3089 static struct omap_hwmod_addr_space am33xx_tptc0_addr_space[] = {
3091 { 3090 {
3092 .pa_start = 0x49800000, 3091 .pa_start = 0x49800000,
3093 .pa_end = 0x49800000 + SZ_8K - 1, 3092 .pa_end = 0x49800000 + SZ_8K - 1,
3094 .flags = ADDR_TYPE_RT, 3093 .flags = ADDR_TYPE_RT,
3095 }, 3094 },
3096 { } 3095 { }
3097 }; 3096 };
3098 3097
3099 static struct omap_hwmod_ocp_if am33xx_l3_main__tptc0 = { 3098 static struct omap_hwmod_ocp_if am33xx_l3_main__tptc0 = {
3100 .master = &am33xx_l3_main_hwmod, 3099 .master = &am33xx_l3_main_hwmod,
3101 .slave = &am33xx_tptc0_hwmod, 3100 .slave = &am33xx_tptc0_hwmod,
3102 .clk = "l3_gclk", 3101 .clk = "l3_gclk",
3103 .addr = am33xx_tptc0_addr_space, 3102 .addr = am33xx_tptc0_addr_space,
3104 .user = OCP_USER_MPU, 3103 .user = OCP_USER_MPU,
3105 }; 3104 };
3106 3105
3107 /* l3 main -> tpcc1 */ 3106 /* l3 main -> tpcc1 */
3108 static struct omap_hwmod_addr_space am33xx_tptc1_addr_space[] = { 3107 static struct omap_hwmod_addr_space am33xx_tptc1_addr_space[] = {
3109 { 3108 {
3110 .pa_start = 0x49900000, 3109 .pa_start = 0x49900000,
3111 .pa_end = 0x49900000 + SZ_8K - 1, 3110 .pa_end = 0x49900000 + SZ_8K - 1,
3112 .flags = ADDR_TYPE_RT, 3111 .flags = ADDR_TYPE_RT,
3113 }, 3112 },
3114 { } 3113 { }
3115 }; 3114 };
3116 3115
3117 static struct omap_hwmod_ocp_if am33xx_l3_main__tptc1 = { 3116 static struct omap_hwmod_ocp_if am33xx_l3_main__tptc1 = {
3118 .master = &am33xx_l3_main_hwmod, 3117 .master = &am33xx_l3_main_hwmod,
3119 .slave = &am33xx_tptc1_hwmod, 3118 .slave = &am33xx_tptc1_hwmod,
3120 .clk = "l3_gclk", 3119 .clk = "l3_gclk",
3121 .addr = am33xx_tptc1_addr_space, 3120 .addr = am33xx_tptc1_addr_space,
3122 .user = OCP_USER_MPU, 3121 .user = OCP_USER_MPU,
3123 }; 3122 };
3124 3123
3125 /* l3 main -> tpcc2 */ 3124 /* l3 main -> tpcc2 */
3126 static struct omap_hwmod_addr_space am33xx_tptc2_addr_space[] = { 3125 static struct omap_hwmod_addr_space am33xx_tptc2_addr_space[] = {
3127 { 3126 {
3128 .pa_start = 0x49a00000, 3127 .pa_start = 0x49a00000,
3129 .pa_end = 0x49a00000 + SZ_8K - 1, 3128 .pa_end = 0x49a00000 + SZ_8K - 1,
3130 .flags = ADDR_TYPE_RT, 3129 .flags = ADDR_TYPE_RT,
3131 }, 3130 },
3132 { } 3131 { }
3133 }; 3132 };
3134 3133
3135 static struct omap_hwmod_ocp_if am33xx_l3_main__tptc2 = { 3134 static struct omap_hwmod_ocp_if am33xx_l3_main__tptc2 = {
3136 .master = &am33xx_l3_main_hwmod, 3135 .master = &am33xx_l3_main_hwmod,
3137 .slave = &am33xx_tptc2_hwmod, 3136 .slave = &am33xx_tptc2_hwmod,
3138 .clk = "l3_gclk", 3137 .clk = "l3_gclk",
3139 .addr = am33xx_tptc2_addr_space, 3138 .addr = am33xx_tptc2_addr_space,
3140 .user = OCP_USER_MPU, 3139 .user = OCP_USER_MPU,
3141 }; 3140 };
3142 3141
3143 /* l4 wkup -> uart1 */ 3142 /* l4 wkup -> uart1 */
3144 static struct omap_hwmod_addr_space am33xx_uart1_addr_space[] = { 3143 static struct omap_hwmod_addr_space am33xx_uart1_addr_space[] = {
3145 { 3144 {
3146 .pa_start = 0x44E09000, 3145 .pa_start = 0x44E09000,
3147 .pa_end = 0x44E09000 + SZ_8K - 1, 3146 .pa_end = 0x44E09000 + SZ_8K - 1,
3148 .flags = ADDR_TYPE_RT, 3147 .flags = ADDR_TYPE_RT,
3149 }, 3148 },
3150 { } 3149 { }
3151 }; 3150 };
3152 3151
3153 static struct omap_hwmod_ocp_if am33xx_l4_wkup__uart1 = { 3152 static struct omap_hwmod_ocp_if am33xx_l4_wkup__uart1 = {
3154 .master = &am33xx_l4_wkup_hwmod, 3153 .master = &am33xx_l4_wkup_hwmod,
3155 .slave = &am33xx_uart1_hwmod, 3154 .slave = &am33xx_uart1_hwmod,
3156 .clk = "dpll_core_m4_div2_ck", 3155 .clk = "dpll_core_m4_div2_ck",
3157 .addr = am33xx_uart1_addr_space, 3156 .addr = am33xx_uart1_addr_space,
3158 .user = OCP_USER_MPU, 3157 .user = OCP_USER_MPU,
3159 }; 3158 };
3160 3159
3161 /* l4 ls -> uart2 */ 3160 /* l4 ls -> uart2 */
3162 static struct omap_hwmod_addr_space am33xx_uart2_addr_space[] = { 3161 static struct omap_hwmod_addr_space am33xx_uart2_addr_space[] = {
3163 { 3162 {
3164 .pa_start = 0x48022000, 3163 .pa_start = 0x48022000,
3165 .pa_end = 0x48022000 + SZ_8K - 1, 3164 .pa_end = 0x48022000 + SZ_8K - 1,
3166 .flags = ADDR_TYPE_RT, 3165 .flags = ADDR_TYPE_RT,
3167 }, 3166 },
3168 { } 3167 { }
3169 }; 3168 };
3170 3169
3171 static struct omap_hwmod_ocp_if am33xx_l4_ls__uart2 = { 3170 static struct omap_hwmod_ocp_if am33xx_l4_ls__uart2 = {
3172 .master = &am33xx_l4_ls_hwmod, 3171 .master = &am33xx_l4_ls_hwmod,
3173 .slave = &am33xx_uart2_hwmod, 3172 .slave = &am33xx_uart2_hwmod,
3174 .clk = "l4ls_gclk", 3173 .clk = "l4ls_gclk",
3175 .addr = am33xx_uart2_addr_space, 3174 .addr = am33xx_uart2_addr_space,
3176 .user = OCP_USER_MPU, 3175 .user = OCP_USER_MPU,
3177 }; 3176 };
3178 3177
3179 /* l4 ls -> uart3 */ 3178 /* l4 ls -> uart3 */
3180 static struct omap_hwmod_addr_space am33xx_uart3_addr_space[] = { 3179 static struct omap_hwmod_addr_space am33xx_uart3_addr_space[] = {
3181 { 3180 {
3182 .pa_start = 0x48024000, 3181 .pa_start = 0x48024000,
3183 .pa_end = 0x48024000 + SZ_8K - 1, 3182 .pa_end = 0x48024000 + SZ_8K - 1,
3184 .flags = ADDR_TYPE_RT, 3183 .flags = ADDR_TYPE_RT,
3185 }, 3184 },
3186 { } 3185 { }
3187 }; 3186 };
3188 3187
3189 static struct omap_hwmod_ocp_if am33xx_l4_ls__uart3 = { 3188 static struct omap_hwmod_ocp_if am33xx_l4_ls__uart3 = {
3190 .master = &am33xx_l4_ls_hwmod, 3189 .master = &am33xx_l4_ls_hwmod,
3191 .slave = &am33xx_uart3_hwmod, 3190 .slave = &am33xx_uart3_hwmod,
3192 .clk = "l4ls_gclk", 3191 .clk = "l4ls_gclk",
3193 .addr = am33xx_uart3_addr_space, 3192 .addr = am33xx_uart3_addr_space,
3194 .user = OCP_USER_MPU, 3193 .user = OCP_USER_MPU,
3195 }; 3194 };
3196 3195
3197 /* l4 ls -> uart4 */ 3196 /* l4 ls -> uart4 */
3198 static struct omap_hwmod_addr_space am33xx_uart4_addr_space[] = { 3197 static struct omap_hwmod_addr_space am33xx_uart4_addr_space[] = {
3199 { 3198 {
3200 .pa_start = 0x481A6000, 3199 .pa_start = 0x481A6000,
3201 .pa_end = 0x481A6000 + SZ_8K - 1, 3200 .pa_end = 0x481A6000 + SZ_8K - 1,
3202 .flags = ADDR_TYPE_RT, 3201 .flags = ADDR_TYPE_RT,
3203 }, 3202 },
3204 { } 3203 { }
3205 }; 3204 };
3206 3205
3207 static struct omap_hwmod_ocp_if am33xx_l4_ls__uart4 = { 3206 static struct omap_hwmod_ocp_if am33xx_l4_ls__uart4 = {
3208 .master = &am33xx_l4_ls_hwmod, 3207 .master = &am33xx_l4_ls_hwmod,
3209 .slave = &am33xx_uart4_hwmod, 3208 .slave = &am33xx_uart4_hwmod,
3210 .clk = "l4ls_gclk", 3209 .clk = "l4ls_gclk",
3211 .addr = am33xx_uart4_addr_space, 3210 .addr = am33xx_uart4_addr_space,
3212 .user = OCP_USER_MPU, 3211 .user = OCP_USER_MPU,
3213 }; 3212 };
3214 3213
3215 /* l4 ls -> uart5 */ 3214 /* l4 ls -> uart5 */
3216 static struct omap_hwmod_addr_space am33xx_uart5_addr_space[] = { 3215 static struct omap_hwmod_addr_space am33xx_uart5_addr_space[] = {
3217 { 3216 {
3218 .pa_start = 0x481A8000, 3217 .pa_start = 0x481A8000,
3219 .pa_end = 0x481A8000 + SZ_8K - 1, 3218 .pa_end = 0x481A8000 + SZ_8K - 1,
3220 .flags = ADDR_TYPE_RT, 3219 .flags = ADDR_TYPE_RT,
3221 }, 3220 },
3222 { } 3221 { }
3223 }; 3222 };
3224 3223
3225 static struct omap_hwmod_ocp_if am33xx_l4_ls__uart5 = { 3224 static struct omap_hwmod_ocp_if am33xx_l4_ls__uart5 = {
3226 .master = &am33xx_l4_ls_hwmod, 3225 .master = &am33xx_l4_ls_hwmod,
3227 .slave = &am33xx_uart5_hwmod, 3226 .slave = &am33xx_uart5_hwmod,
3228 .clk = "l4ls_gclk", 3227 .clk = "l4ls_gclk",
3229 .addr = am33xx_uart5_addr_space, 3228 .addr = am33xx_uart5_addr_space,
3230 .user = OCP_USER_MPU, 3229 .user = OCP_USER_MPU,
3231 }; 3230 };
3232 3231
3233 /* l4 ls -> uart6 */ 3232 /* l4 ls -> uart6 */
3234 static struct omap_hwmod_addr_space am33xx_uart6_addr_space[] = { 3233 static struct omap_hwmod_addr_space am33xx_uart6_addr_space[] = {
3235 { 3234 {
3236 .pa_start = 0x481aa000, 3235 .pa_start = 0x481aa000,
3237 .pa_end = 0x481aa000 + SZ_8K - 1, 3236 .pa_end = 0x481aa000 + SZ_8K - 1,
3238 .flags = ADDR_TYPE_RT, 3237 .flags = ADDR_TYPE_RT,
3239 }, 3238 },
3240 { } 3239 { }
3241 }; 3240 };
3242 3241
3243 static struct omap_hwmod_ocp_if am33xx_l4_ls__uart6 = { 3242 static struct omap_hwmod_ocp_if am33xx_l4_ls__uart6 = {
3244 .master = &am33xx_l4_ls_hwmod, 3243 .master = &am33xx_l4_ls_hwmod,
3245 .slave = &am33xx_uart6_hwmod, 3244 .slave = &am33xx_uart6_hwmod,
3246 .clk = "l4ls_gclk", 3245 .clk = "l4ls_gclk",
3247 .addr = am33xx_uart6_addr_space, 3246 .addr = am33xx_uart6_addr_space,
3248 .user = OCP_USER_MPU, 3247 .user = OCP_USER_MPU,
3249 }; 3248 };
3250 3249
3251 /* l4 wkup -> wd_timer1 */ 3250 /* l4 wkup -> wd_timer1 */
3252 static struct omap_hwmod_addr_space am33xx_wd_timer1_addrs[] = { 3251 static struct omap_hwmod_addr_space am33xx_wd_timer1_addrs[] = {
3253 { 3252 {
3254 .pa_start = 0x44e35000, 3253 .pa_start = 0x44e35000,
3255 .pa_end = 0x44e35000 + SZ_4K - 1, 3254 .pa_end = 0x44e35000 + SZ_4K - 1,
3256 .flags = ADDR_TYPE_RT 3255 .flags = ADDR_TYPE_RT
3257 }, 3256 },
3258 { } 3257 { }
3259 }; 3258 };
3260 3259
3261 static struct omap_hwmod_ocp_if am33xx_l4_wkup__wd_timer1 = { 3260 static struct omap_hwmod_ocp_if am33xx_l4_wkup__wd_timer1 = {
3262 .master = &am33xx_l4_wkup_hwmod, 3261 .master = &am33xx_l4_wkup_hwmod,
3263 .slave = &am33xx_wd_timer1_hwmod, 3262 .slave = &am33xx_wd_timer1_hwmod,
3264 .clk = "dpll_core_m4_div2_ck", 3263 .clk = "dpll_core_m4_div2_ck",
3265 .addr = am33xx_wd_timer1_addrs, 3264 .addr = am33xx_wd_timer1_addrs,
3266 .user = OCP_USER_MPU, 3265 .user = OCP_USER_MPU,
3267 }; 3266 };
3268 3267
3269 /* usbss */ 3268 /* usbss */
3270 /* l3 s -> USBSS interface */ 3269 /* l3 s -> USBSS interface */
3271 static struct omap_hwmod_addr_space am33xx_usbss_addr_space[] = { 3270 static struct omap_hwmod_addr_space am33xx_usbss_addr_space[] = {
3272 { 3271 {
3273 .name = "usbss", 3272 .name = "usbss",
3274 .pa_start = 0x47400000, 3273 .pa_start = 0x47400000,
3275 .pa_end = 0x47400000 + SZ_4K - 1, 3274 .pa_end = 0x47400000 + SZ_4K - 1,
3276 .flags = ADDR_TYPE_RT 3275 .flags = ADDR_TYPE_RT
3277 }, 3276 },
3278 { 3277 {
3279 .name = "musb0", 3278 .name = "musb0",
3280 .pa_start = 0x47401000, 3279 .pa_start = 0x47401000,
3281 .pa_end = 0x47401000 + SZ_2K - 1, 3280 .pa_end = 0x47401000 + SZ_2K - 1,
3282 .flags = ADDR_TYPE_RT 3281 .flags = ADDR_TYPE_RT
3283 }, 3282 },
3284 { 3283 {
3285 .name = "musb1", 3284 .name = "musb1",
3286 .pa_start = 0x47401800, 3285 .pa_start = 0x47401800,
3287 .pa_end = 0x47401800 + SZ_2K - 1, 3286 .pa_end = 0x47401800 + SZ_2K - 1,
3288 .flags = ADDR_TYPE_RT 3287 .flags = ADDR_TYPE_RT
3289 }, 3288 },
3290 { } 3289 { }
3291 }; 3290 };
3292 3291
3293 static struct omap_hwmod_ocp_if am33xx_l3_s__usbss = { 3292 static struct omap_hwmod_ocp_if am33xx_l3_s__usbss = {
3294 .master = &am33xx_l3_s_hwmod, 3293 .master = &am33xx_l3_s_hwmod,
3295 .slave = &am33xx_usbss_hwmod, 3294 .slave = &am33xx_usbss_hwmod,
3296 .clk = "l3s_gclk", 3295 .clk = "l3s_gclk",
3297 .addr = am33xx_usbss_addr_space, 3296 .addr = am33xx_usbss_addr_space,
3298 .user = OCP_USER_MPU, 3297 .user = OCP_USER_MPU,
3299 .flags = OCPIF_SWSUP_IDLE, 3298 .flags = OCPIF_SWSUP_IDLE,
3300 }; 3299 };
3301 3300
3302 static struct omap_hwmod_ocp_if *am33xx_hwmod_ocp_ifs[] __initdata = { 3301 static struct omap_hwmod_ocp_if *am33xx_hwmod_ocp_ifs[] __initdata = {
3303 &am33xx_l4_fw__emif_fw, 3302 &am33xx_l4_fw__emif_fw,
3304 &am33xx_l3_main__emif, 3303 &am33xx_l3_main__emif,
3305 &am33xx_mpu__l3_main, 3304 &am33xx_mpu__l3_main,
3306 &am33xx_mpu__prcm, 3305 &am33xx_mpu__prcm,
3307 &am33xx_l3_s__l4_ls, 3306 &am33xx_l3_s__l4_ls,
3308 &am33xx_l3_s__l4_wkup, 3307 &am33xx_l3_s__l4_wkup,
3309 &am33xx_l3_s__l4_fw, 3308 &am33xx_l3_s__l4_fw,
3310 &am33xx_l3_main__l4_hs, 3309 &am33xx_l3_main__l4_hs,
3311 &am33xx_l3_main__l3_s, 3310 &am33xx_l3_main__l3_s,
3312 &am33xx_l3_main__l3_instr, 3311 &am33xx_l3_main__l3_instr,
3313 &am33xx_l3_main__gfx, 3312 &am33xx_l3_main__gfx,
3314 &am33xx_l3_s__l3_main, 3313 &am33xx_l3_s__l3_main,
3315 &am33xx_pruss__l3_main, 3314 &am33xx_pruss__l3_main,
3316 &am33xx_wkup_m3__l4_wkup, 3315 &am33xx_wkup_m3__l4_wkup,
3317 &am33xx_gfx__l3_main, 3316 &am33xx_gfx__l3_main,
3318 &am33xx_l4_wkup__wkup_m3, 3317 &am33xx_l4_wkup__wkup_m3,
3319 &am33xx_l4_wkup__control, 3318 &am33xx_l4_wkup__control,
3320 &am33xx_l4_wkup__smartreflex0, 3319 &am33xx_l4_wkup__smartreflex0,
3321 &am33xx_l4_wkup__smartreflex1, 3320 &am33xx_l4_wkup__smartreflex1,
3322 &am33xx_l4_wkup__uart1, 3321 &am33xx_l4_wkup__uart1,
3323 &am33xx_l4_wkup__timer1, 3322 &am33xx_l4_wkup__timer1,
3324 &am33xx_l4_wkup__rtc, 3323 &am33xx_l4_wkup__rtc,
3325 &am33xx_l4_wkup__i2c1, 3324 &am33xx_l4_wkup__i2c1,
3326 &am33xx_l4_wkup__gpio0, 3325 &am33xx_l4_wkup__gpio0,
3327 &am33xx_l4_wkup__adc_tsc, 3326 &am33xx_l4_wkup__adc_tsc,
3328 &am33xx_l4_wkup__wd_timer1, 3327 &am33xx_l4_wkup__wd_timer1,
3329 &am33xx_l4_hs__pruss, 3328 &am33xx_l4_hs__pruss,
3330 &am33xx_l4_per__dcan0, 3329 &am33xx_l4_per__dcan0,
3331 &am33xx_l4_per__dcan1, 3330 &am33xx_l4_per__dcan1,
3332 &am33xx_l4_per__gpio1, 3331 &am33xx_l4_per__gpio1,
3333 &am33xx_l4_per__gpio2, 3332 &am33xx_l4_per__gpio2,
3334 &am33xx_l4_per__gpio3, 3333 &am33xx_l4_per__gpio3,
3335 &am33xx_l4_per__i2c2, 3334 &am33xx_l4_per__i2c2,
3336 &am33xx_l4_per__i2c3, 3335 &am33xx_l4_per__i2c3,
3337 &am33xx_l4_per__mailbox, 3336 &am33xx_l4_per__mailbox,
3338 &am33xx_l4_ls__mcasp0, 3337 &am33xx_l4_ls__mcasp0,
3339 &am33xx_l3_s__mcasp0_data, 3338 &am33xx_l3_s__mcasp0_data,
3340 &am33xx_l4_ls__mcasp1, 3339 &am33xx_l4_ls__mcasp1,
3341 &am33xx_l3_s__mcasp1_data, 3340 &am33xx_l3_s__mcasp1_data,
3342 &am33xx_l4_ls__mmc0, 3341 &am33xx_l4_ls__mmc0,
3343 &am33xx_l4_ls__mmc1, 3342 &am33xx_l4_ls__mmc1,
3344 &am33xx_l3_s__mmc2, 3343 &am33xx_l3_s__mmc2,
3345 &am33xx_l4_ls__timer2, 3344 &am33xx_l4_ls__timer2,
3346 &am33xx_l4_ls__timer3, 3345 &am33xx_l4_ls__timer3,
3347 &am33xx_l4_ls__timer4, 3346 &am33xx_l4_ls__timer4,
3348 &am33xx_l4_ls__timer5, 3347 &am33xx_l4_ls__timer5,
3349 &am33xx_l4_ls__timer6, 3348 &am33xx_l4_ls__timer6,
3350 &am33xx_l4_ls__timer7, 3349 &am33xx_l4_ls__timer7,
3351 &am33xx_l3_main__tpcc, 3350 &am33xx_l3_main__tpcc,
3352 &am33xx_l4_ls__uart2, 3351 &am33xx_l4_ls__uart2,
3353 &am33xx_l4_ls__uart3, 3352 &am33xx_l4_ls__uart3,
3354 &am33xx_l4_ls__uart4, 3353 &am33xx_l4_ls__uart4,
3355 &am33xx_l4_ls__uart5, 3354 &am33xx_l4_ls__uart5,
3356 &am33xx_l4_ls__uart6, 3355 &am33xx_l4_ls__uart6,
3357 &am33xx_l4_ls__spinlock, 3356 &am33xx_l4_ls__spinlock,
3358 &am33xx_l4_ls__elm, 3357 &am33xx_l4_ls__elm,
3359 &am33xx_l4_ls__ehrpwm0, 3358 &am33xx_l4_ls__ehrpwm0,
3360 &am33xx_l4_ls__ehrpwm1, 3359 &am33xx_l4_ls__ehrpwm1,
3361 &am33xx_l4_ls__ehrpwm2, 3360 &am33xx_l4_ls__ehrpwm2,
3362 &am33xx_l4_ls__ecap0, 3361 &am33xx_l4_ls__ecap0,
3363 &am33xx_l4_ls__ecap1, 3362 &am33xx_l4_ls__ecap1,
3364 &am33xx_l4_ls__ecap2, 3363 &am33xx_l4_ls__ecap2,
3365 &am33xx_l3_s__gpmc, 3364 &am33xx_l3_s__gpmc,
3366 &am33xx_l3_main__lcdc, 3365 &am33xx_l3_main__lcdc,
3367 &am33xx_l4_ls__mcspi0, 3366 &am33xx_l4_ls__mcspi0,
3368 &am33xx_l4_ls__mcspi1, 3367 &am33xx_l4_ls__mcspi1,
3369 &am33xx_l3_main__tptc0, 3368 &am33xx_l3_main__tptc0,
3370 &am33xx_l3_main__tptc1, 3369 &am33xx_l3_main__tptc1,
3371 &am33xx_l3_main__tptc2, 3370 &am33xx_l3_main__tptc2,
3372 &am33xx_l3_s__usbss, 3371 &am33xx_l3_s__usbss,
3373 &am33xx_l4_hs__cpgmac0, 3372 &am33xx_l4_hs__cpgmac0,
3374 NULL, 3373 NULL,
3375 }; 3374 };
3376 3375
3377 int __init am33xx_hwmod_init(void) 3376 int __init am33xx_hwmod_init(void)
3378 { 3377 {
3379 omap_hwmod_init(); 3378 omap_hwmod_init();
3380 return omap_hwmod_register_links(am33xx_hwmod_ocp_ifs); 3379 return omap_hwmod_register_links(am33xx_hwmod_ocp_ifs);
3381 } 3380 }
3382 3381
arch/arm/mach-omap2/omap_hwmod_3xxx_data.c
1 /* 1 /*
2 * omap_hwmod_3xxx_data.c - hardware modules present on the OMAP3xxx chips 2 * omap_hwmod_3xxx_data.c - hardware modules present on the OMAP3xxx chips
3 * 3 *
4 * Copyright (C) 2009-2011 Nokia Corporation 4 * Copyright (C) 2009-2011 Nokia Corporation
5 * Copyright (C) 2012 Texas Instruments, Inc. 5 * Copyright (C) 2012 Texas Instruments, Inc.
6 * Paul Walmsley 6 * Paul Walmsley
7 * 7 *
8 * This program is free software; you can redistribute it and/or modify 8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License version 2 as 9 * it under the terms of the GNU General Public License version 2 as
10 * published by the Free Software Foundation. 10 * published by the Free Software Foundation.
11 * 11 *
12 * The data in this file should be completely autogeneratable from 12 * The data in this file should be completely autogeneratable from
13 * the TI hardware database or other technical documentation. 13 * the TI hardware database or other technical documentation.
14 * 14 *
15 * XXX these should be marked initdata for multi-OMAP kernels 15 * XXX these should be marked initdata for multi-OMAP kernels
16 */ 16 */
17 #include <linux/power/smartreflex.h> 17 #include <linux/power/smartreflex.h>
18 #include <linux/platform_data/gpio-omap.h> 18 #include <linux/platform_data/gpio-omap.h>
19 19
20 #include <plat/omap_hwmod.h> 20 #include <plat/omap_hwmod.h>
21 #include <plat/dma.h> 21 #include <plat/dma.h>
22 #include <plat/serial.h> 22 #include <plat/serial.h>
23 #include "l3_3xxx.h" 23 #include "l3_3xxx.h"
24 #include "l4_3xxx.h" 24 #include "l4_3xxx.h"
25 #include <plat/i2c.h> 25 #include <plat/i2c.h>
26 #include <plat/mmc.h> 26 #include <plat/mmc.h>
27 #include <linux/platform_data/asoc-ti-mcbsp.h> 27 #include <linux/platform_data/asoc-ti-mcbsp.h>
28 #include <linux/platform_data/spi-omap2-mcspi.h> 28 #include <linux/platform_data/spi-omap2-mcspi.h>
29 #include <plat/dmtimer.h> 29 #include <plat/dmtimer.h>
30 #include <plat/iommu.h> 30 #include <plat/iommu.h>
31 31
32 #include "am35xx.h" 32 #include "am35xx.h"
33 33
34 #include "soc.h" 34 #include "soc.h"
35 #include "omap_hwmod_common_data.h" 35 #include "omap_hwmod_common_data.h"
36 #include "prm-regbits-34xx.h" 36 #include "prm-regbits-34xx.h"
37 #include "cm-regbits-34xx.h" 37 #include "cm-regbits-34xx.h"
38 #include "wd_timer.h" 38 #include "wd_timer.h"
39 39
40 /* 40 /*
41 * OMAP3xxx hardware module integration data 41 * OMAP3xxx hardware module integration data
42 * 42 *
43 * All of the data in this section should be autogeneratable from the 43 * All of the data in this section should be autogeneratable from the
44 * TI hardware database or other technical documentation. Data that 44 * TI hardware database or other technical documentation. Data that
45 * is driver-specific or driver-kernel integration-specific belongs 45 * is driver-specific or driver-kernel integration-specific belongs
46 * elsewhere. 46 * elsewhere.
47 */ 47 */
48 48
49 /* 49 /*
50 * IP blocks 50 * IP blocks
51 */ 51 */
52 52
53 /* L3 */ 53 /* L3 */
54 static struct omap_hwmod_irq_info omap3xxx_l3_main_irqs[] = { 54 static struct omap_hwmod_irq_info omap3xxx_l3_main_irqs[] = {
55 { .irq = 9 + OMAP_INTC_START, }, 55 { .irq = 9 + OMAP_INTC_START, },
56 { .irq = 10 + OMAP_INTC_START, }, 56 { .irq = 10 + OMAP_INTC_START, },
57 { .irq = -1 }, 57 { .irq = -1 },
58 }; 58 };
59 59
60 static struct omap_hwmod omap3xxx_l3_main_hwmod = { 60 static struct omap_hwmod omap3xxx_l3_main_hwmod = {
61 .name = "l3_main", 61 .name = "l3_main",
62 .class = &l3_hwmod_class, 62 .class = &l3_hwmod_class,
63 .mpu_irqs = omap3xxx_l3_main_irqs, 63 .mpu_irqs = omap3xxx_l3_main_irqs,
64 .flags = HWMOD_NO_IDLEST, 64 .flags = HWMOD_NO_IDLEST,
65 }; 65 };
66 66
67 /* L4 CORE */ 67 /* L4 CORE */
68 static struct omap_hwmod omap3xxx_l4_core_hwmod = { 68 static struct omap_hwmod omap3xxx_l4_core_hwmod = {
69 .name = "l4_core", 69 .name = "l4_core",
70 .class = &l4_hwmod_class, 70 .class = &l4_hwmod_class,
71 .flags = HWMOD_NO_IDLEST, 71 .flags = HWMOD_NO_IDLEST,
72 }; 72 };
73 73
74 /* L4 PER */ 74 /* L4 PER */
75 static struct omap_hwmod omap3xxx_l4_per_hwmod = { 75 static struct omap_hwmod omap3xxx_l4_per_hwmod = {
76 .name = "l4_per", 76 .name = "l4_per",
77 .class = &l4_hwmod_class, 77 .class = &l4_hwmod_class,
78 .flags = HWMOD_NO_IDLEST, 78 .flags = HWMOD_NO_IDLEST,
79 }; 79 };
80 80
81 /* L4 WKUP */ 81 /* L4 WKUP */
82 static struct omap_hwmod omap3xxx_l4_wkup_hwmod = { 82 static struct omap_hwmod omap3xxx_l4_wkup_hwmod = {
83 .name = "l4_wkup", 83 .name = "l4_wkup",
84 .class = &l4_hwmod_class, 84 .class = &l4_hwmod_class,
85 .flags = HWMOD_NO_IDLEST, 85 .flags = HWMOD_NO_IDLEST,
86 }; 86 };
87 87
88 /* L4 SEC */ 88 /* L4 SEC */
89 static struct omap_hwmod omap3xxx_l4_sec_hwmod = { 89 static struct omap_hwmod omap3xxx_l4_sec_hwmod = {
90 .name = "l4_sec", 90 .name = "l4_sec",
91 .class = &l4_hwmod_class, 91 .class = &l4_hwmod_class,
92 .flags = HWMOD_NO_IDLEST, 92 .flags = HWMOD_NO_IDLEST,
93 }; 93 };
94 94
95 /* MPU */ 95 /* MPU */
96 static struct omap_hwmod_irq_info omap3xxx_mpu_irqs[] = { 96 static struct omap_hwmod_irq_info omap3xxx_mpu_irqs[] = {
97 { .name = "pmu", .irq = 3 + OMAP_INTC_START }, 97 { .name = "pmu", .irq = 3 + OMAP_INTC_START },
98 { .irq = -1 } 98 { .irq = -1 }
99 }; 99 };
100 100
101 static struct omap_hwmod omap3xxx_mpu_hwmod = { 101 static struct omap_hwmod omap3xxx_mpu_hwmod = {
102 .name = "mpu", 102 .name = "mpu",
103 .mpu_irqs = omap3xxx_mpu_irqs, 103 .mpu_irqs = omap3xxx_mpu_irqs,
104 .class = &mpu_hwmod_class, 104 .class = &mpu_hwmod_class,
105 .main_clk = "arm_fck", 105 .main_clk = "arm_fck",
106 }; 106 };
107 107
108 /* IVA2 (IVA2) */ 108 /* IVA2 (IVA2) */
109 static struct omap_hwmod_rst_info omap3xxx_iva_resets[] = { 109 static struct omap_hwmod_rst_info omap3xxx_iva_resets[] = {
110 { .name = "logic", .rst_shift = 0, .st_shift = 8 }, 110 { .name = "logic", .rst_shift = 0, .st_shift = 8 },
111 { .name = "seq0", .rst_shift = 1, .st_shift = 9 }, 111 { .name = "seq0", .rst_shift = 1, .st_shift = 9 },
112 { .name = "seq1", .rst_shift = 2, .st_shift = 10 }, 112 { .name = "seq1", .rst_shift = 2, .st_shift = 10 },
113 }; 113 };
114 114
115 static struct omap_hwmod omap3xxx_iva_hwmod = { 115 static struct omap_hwmod omap3xxx_iva_hwmod = {
116 .name = "iva", 116 .name = "iva",
117 .class = &iva_hwmod_class, 117 .class = &iva_hwmod_class,
118 .clkdm_name = "iva2_clkdm", 118 .clkdm_name = "iva2_clkdm",
119 .rst_lines = omap3xxx_iva_resets, 119 .rst_lines = omap3xxx_iva_resets,
120 .rst_lines_cnt = ARRAY_SIZE(omap3xxx_iva_resets), 120 .rst_lines_cnt = ARRAY_SIZE(omap3xxx_iva_resets),
121 .main_clk = "iva2_ck", 121 .main_clk = "iva2_ck",
122 .prcm = { 122 .prcm = {
123 .omap2 = { 123 .omap2 = {
124 .module_offs = OMAP3430_IVA2_MOD, 124 .module_offs = OMAP3430_IVA2_MOD,
125 .prcm_reg_id = 1, 125 .prcm_reg_id = 1,
126 .module_bit = OMAP3430_CM_FCLKEN_IVA2_EN_IVA2_SHIFT, 126 .module_bit = OMAP3430_CM_FCLKEN_IVA2_EN_IVA2_SHIFT,
127 .idlest_reg_id = 1, 127 .idlest_reg_id = 1,
128 .idlest_idle_bit = OMAP3430_ST_IVA2_SHIFT, 128 .idlest_idle_bit = OMAP3430_ST_IVA2_SHIFT,
129 } 129 }
130 }, 130 },
131 }; 131 };
132 132
133 /* 133 /*
134 * 'debugss' class 134 * 'debugss' class
135 * debug and emulation sub system 135 * debug and emulation sub system
136 */ 136 */
137 137
138 static struct omap_hwmod_class omap3xxx_debugss_hwmod_class = { 138 static struct omap_hwmod_class omap3xxx_debugss_hwmod_class = {
139 .name = "debugss", 139 .name = "debugss",
140 }; 140 };
141 141
142 /* debugss */ 142 /* debugss */
143 static struct omap_hwmod omap3xxx_debugss_hwmod = { 143 static struct omap_hwmod omap3xxx_debugss_hwmod = {
144 .name = "debugss", 144 .name = "debugss",
145 .class = &omap3xxx_debugss_hwmod_class, 145 .class = &omap3xxx_debugss_hwmod_class,
146 .clkdm_name = "emu_clkdm", 146 .clkdm_name = "emu_clkdm",
147 .main_clk = "emu_src_ck", 147 .main_clk = "emu_src_ck",
148 .flags = HWMOD_NO_IDLEST, 148 .flags = HWMOD_NO_IDLEST,
149 }; 149 };
150 150
151 /* timer class */ 151 /* timer class */
152 static struct omap_hwmod_class_sysconfig omap3xxx_timer_1ms_sysc = { 152 static struct omap_hwmod_class_sysconfig omap3xxx_timer_1ms_sysc = {
153 .rev_offs = 0x0000, 153 .rev_offs = 0x0000,
154 .sysc_offs = 0x0010, 154 .sysc_offs = 0x0010,
155 .syss_offs = 0x0014, 155 .syss_offs = 0x0014,
156 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_CLOCKACTIVITY | 156 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_CLOCKACTIVITY |
157 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET | 157 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
158 SYSC_HAS_EMUFREE | SYSC_HAS_AUTOIDLE), 158 SYSC_HAS_EMUFREE | SYSC_HAS_AUTOIDLE),
159 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 159 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
160 .sysc_fields = &omap_hwmod_sysc_type1, 160 .sysc_fields = &omap_hwmod_sysc_type1,
161 }; 161 };
162 162
163 static struct omap_hwmod_class omap3xxx_timer_1ms_hwmod_class = { 163 static struct omap_hwmod_class omap3xxx_timer_1ms_hwmod_class = {
164 .name = "timer", 164 .name = "timer",
165 .sysc = &omap3xxx_timer_1ms_sysc, 165 .sysc = &omap3xxx_timer_1ms_sysc,
166 }; 166 };
167 167
168 static struct omap_hwmod_class_sysconfig omap3xxx_timer_sysc = { 168 static struct omap_hwmod_class_sysconfig omap3xxx_timer_sysc = {
169 .rev_offs = 0x0000, 169 .rev_offs = 0x0000,
170 .sysc_offs = 0x0010, 170 .sysc_offs = 0x0010,
171 .syss_offs = 0x0014, 171 .syss_offs = 0x0014,
172 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP | 172 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP |
173 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE), 173 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
174 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 174 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
175 .sysc_fields = &omap_hwmod_sysc_type1, 175 .sysc_fields = &omap_hwmod_sysc_type1,
176 }; 176 };
177 177
178 static struct omap_hwmod_class omap3xxx_timer_hwmod_class = { 178 static struct omap_hwmod_class omap3xxx_timer_hwmod_class = {
179 .name = "timer", 179 .name = "timer",
180 .sysc = &omap3xxx_timer_sysc, 180 .sysc = &omap3xxx_timer_sysc,
181 }; 181 };
182 182
183 /* secure timers dev attribute */ 183 /* secure timers dev attribute */
184 static struct omap_timer_capability_dev_attr capability_secure_dev_attr = { 184 static struct omap_timer_capability_dev_attr capability_secure_dev_attr = {
185 .timer_capability = OMAP_TIMER_ALWON | OMAP_TIMER_SECURE, 185 .timer_capability = OMAP_TIMER_ALWON | OMAP_TIMER_SECURE,
186 }; 186 };
187 187
188 /* always-on timers dev attribute */ 188 /* always-on timers dev attribute */
189 static struct omap_timer_capability_dev_attr capability_alwon_dev_attr = { 189 static struct omap_timer_capability_dev_attr capability_alwon_dev_attr = {
190 .timer_capability = OMAP_TIMER_ALWON, 190 .timer_capability = OMAP_TIMER_ALWON,
191 }; 191 };
192 192
193 /* pwm timers dev attribute */ 193 /* pwm timers dev attribute */
194 static struct omap_timer_capability_dev_attr capability_pwm_dev_attr = { 194 static struct omap_timer_capability_dev_attr capability_pwm_dev_attr = {
195 .timer_capability = OMAP_TIMER_HAS_PWM, 195 .timer_capability = OMAP_TIMER_HAS_PWM,
196 }; 196 };
197 197
198 /* timers with DSP interrupt dev attribute */ 198 /* timers with DSP interrupt dev attribute */
199 static struct omap_timer_capability_dev_attr capability_dsp_dev_attr = { 199 static struct omap_timer_capability_dev_attr capability_dsp_dev_attr = {
200 .timer_capability = OMAP_TIMER_HAS_DSP_IRQ, 200 .timer_capability = OMAP_TIMER_HAS_DSP_IRQ,
201 }; 201 };
202 202
203 /* pwm timers with DSP interrupt dev attribute */ 203 /* pwm timers with DSP interrupt dev attribute */
204 static struct omap_timer_capability_dev_attr capability_dsp_pwm_dev_attr = { 204 static struct omap_timer_capability_dev_attr capability_dsp_pwm_dev_attr = {
205 .timer_capability = OMAP_TIMER_HAS_DSP_IRQ | OMAP_TIMER_HAS_PWM, 205 .timer_capability = OMAP_TIMER_HAS_DSP_IRQ | OMAP_TIMER_HAS_PWM,
206 }; 206 };
207 207
208 /* timer1 */ 208 /* timer1 */
209 static struct omap_hwmod omap3xxx_timer1_hwmod = { 209 static struct omap_hwmod omap3xxx_timer1_hwmod = {
210 .name = "timer1", 210 .name = "timer1",
211 .mpu_irqs = omap2_timer1_mpu_irqs, 211 .mpu_irqs = omap2_timer1_mpu_irqs,
212 .main_clk = "gpt1_fck", 212 .main_clk = "gpt1_fck",
213 .prcm = { 213 .prcm = {
214 .omap2 = { 214 .omap2 = {
215 .prcm_reg_id = 1, 215 .prcm_reg_id = 1,
216 .module_bit = OMAP3430_EN_GPT1_SHIFT, 216 .module_bit = OMAP3430_EN_GPT1_SHIFT,
217 .module_offs = WKUP_MOD, 217 .module_offs = WKUP_MOD,
218 .idlest_reg_id = 1, 218 .idlest_reg_id = 1,
219 .idlest_idle_bit = OMAP3430_ST_GPT1_SHIFT, 219 .idlest_idle_bit = OMAP3430_ST_GPT1_SHIFT,
220 }, 220 },
221 }, 221 },
222 .dev_attr = &capability_alwon_dev_attr, 222 .dev_attr = &capability_alwon_dev_attr,
223 .class = &omap3xxx_timer_1ms_hwmod_class, 223 .class = &omap3xxx_timer_1ms_hwmod_class,
224 }; 224 };
225 225
226 /* timer2 */ 226 /* timer2 */
227 static struct omap_hwmod omap3xxx_timer2_hwmod = { 227 static struct omap_hwmod omap3xxx_timer2_hwmod = {
228 .name = "timer2", 228 .name = "timer2",
229 .mpu_irqs = omap2_timer2_mpu_irqs, 229 .mpu_irqs = omap2_timer2_mpu_irqs,
230 .main_clk = "gpt2_fck", 230 .main_clk = "gpt2_fck",
231 .prcm = { 231 .prcm = {
232 .omap2 = { 232 .omap2 = {
233 .prcm_reg_id = 1, 233 .prcm_reg_id = 1,
234 .module_bit = OMAP3430_EN_GPT2_SHIFT, 234 .module_bit = OMAP3430_EN_GPT2_SHIFT,
235 .module_offs = OMAP3430_PER_MOD, 235 .module_offs = OMAP3430_PER_MOD,
236 .idlest_reg_id = 1, 236 .idlest_reg_id = 1,
237 .idlest_idle_bit = OMAP3430_ST_GPT2_SHIFT, 237 .idlest_idle_bit = OMAP3430_ST_GPT2_SHIFT,
238 }, 238 },
239 }, 239 },
240 .class = &omap3xxx_timer_1ms_hwmod_class, 240 .class = &omap3xxx_timer_1ms_hwmod_class,
241 }; 241 };
242 242
243 /* timer3 */ 243 /* timer3 */
244 static struct omap_hwmod omap3xxx_timer3_hwmod = { 244 static struct omap_hwmod omap3xxx_timer3_hwmod = {
245 .name = "timer3", 245 .name = "timer3",
246 .mpu_irqs = omap2_timer3_mpu_irqs, 246 .mpu_irqs = omap2_timer3_mpu_irqs,
247 .main_clk = "gpt3_fck", 247 .main_clk = "gpt3_fck",
248 .prcm = { 248 .prcm = {
249 .omap2 = { 249 .omap2 = {
250 .prcm_reg_id = 1, 250 .prcm_reg_id = 1,
251 .module_bit = OMAP3430_EN_GPT3_SHIFT, 251 .module_bit = OMAP3430_EN_GPT3_SHIFT,
252 .module_offs = OMAP3430_PER_MOD, 252 .module_offs = OMAP3430_PER_MOD,
253 .idlest_reg_id = 1, 253 .idlest_reg_id = 1,
254 .idlest_idle_bit = OMAP3430_ST_GPT3_SHIFT, 254 .idlest_idle_bit = OMAP3430_ST_GPT3_SHIFT,
255 }, 255 },
256 }, 256 },
257 .class = &omap3xxx_timer_hwmod_class, 257 .class = &omap3xxx_timer_hwmod_class,
258 }; 258 };
259 259
260 /* timer4 */ 260 /* timer4 */
261 static struct omap_hwmod omap3xxx_timer4_hwmod = { 261 static struct omap_hwmod omap3xxx_timer4_hwmod = {
262 .name = "timer4", 262 .name = "timer4",
263 .mpu_irqs = omap2_timer4_mpu_irqs, 263 .mpu_irqs = omap2_timer4_mpu_irqs,
264 .main_clk = "gpt4_fck", 264 .main_clk = "gpt4_fck",
265 .prcm = { 265 .prcm = {
266 .omap2 = { 266 .omap2 = {
267 .prcm_reg_id = 1, 267 .prcm_reg_id = 1,
268 .module_bit = OMAP3430_EN_GPT4_SHIFT, 268 .module_bit = OMAP3430_EN_GPT4_SHIFT,
269 .module_offs = OMAP3430_PER_MOD, 269 .module_offs = OMAP3430_PER_MOD,
270 .idlest_reg_id = 1, 270 .idlest_reg_id = 1,
271 .idlest_idle_bit = OMAP3430_ST_GPT4_SHIFT, 271 .idlest_idle_bit = OMAP3430_ST_GPT4_SHIFT,
272 }, 272 },
273 }, 273 },
274 .class = &omap3xxx_timer_hwmod_class, 274 .class = &omap3xxx_timer_hwmod_class,
275 }; 275 };
276 276
277 /* timer5 */ 277 /* timer5 */
278 static struct omap_hwmod omap3xxx_timer5_hwmod = { 278 static struct omap_hwmod omap3xxx_timer5_hwmod = {
279 .name = "timer5", 279 .name = "timer5",
280 .mpu_irqs = omap2_timer5_mpu_irqs, 280 .mpu_irqs = omap2_timer5_mpu_irqs,
281 .main_clk = "gpt5_fck", 281 .main_clk = "gpt5_fck",
282 .prcm = { 282 .prcm = {
283 .omap2 = { 283 .omap2 = {
284 .prcm_reg_id = 1, 284 .prcm_reg_id = 1,
285 .module_bit = OMAP3430_EN_GPT5_SHIFT, 285 .module_bit = OMAP3430_EN_GPT5_SHIFT,
286 .module_offs = OMAP3430_PER_MOD, 286 .module_offs = OMAP3430_PER_MOD,
287 .idlest_reg_id = 1, 287 .idlest_reg_id = 1,
288 .idlest_idle_bit = OMAP3430_ST_GPT5_SHIFT, 288 .idlest_idle_bit = OMAP3430_ST_GPT5_SHIFT,
289 }, 289 },
290 }, 290 },
291 .dev_attr = &capability_dsp_dev_attr, 291 .dev_attr = &capability_dsp_dev_attr,
292 .class = &omap3xxx_timer_hwmod_class, 292 .class = &omap3xxx_timer_hwmod_class,
293 }; 293 };
294 294
295 /* timer6 */ 295 /* timer6 */
296 static struct omap_hwmod omap3xxx_timer6_hwmod = { 296 static struct omap_hwmod omap3xxx_timer6_hwmod = {
297 .name = "timer6", 297 .name = "timer6",
298 .mpu_irqs = omap2_timer6_mpu_irqs, 298 .mpu_irqs = omap2_timer6_mpu_irqs,
299 .main_clk = "gpt6_fck", 299 .main_clk = "gpt6_fck",
300 .prcm = { 300 .prcm = {
301 .omap2 = { 301 .omap2 = {
302 .prcm_reg_id = 1, 302 .prcm_reg_id = 1,
303 .module_bit = OMAP3430_EN_GPT6_SHIFT, 303 .module_bit = OMAP3430_EN_GPT6_SHIFT,
304 .module_offs = OMAP3430_PER_MOD, 304 .module_offs = OMAP3430_PER_MOD,
305 .idlest_reg_id = 1, 305 .idlest_reg_id = 1,
306 .idlest_idle_bit = OMAP3430_ST_GPT6_SHIFT, 306 .idlest_idle_bit = OMAP3430_ST_GPT6_SHIFT,
307 }, 307 },
308 }, 308 },
309 .dev_attr = &capability_dsp_dev_attr, 309 .dev_attr = &capability_dsp_dev_attr,
310 .class = &omap3xxx_timer_hwmod_class, 310 .class = &omap3xxx_timer_hwmod_class,
311 }; 311 };
312 312
313 /* timer7 */ 313 /* timer7 */
314 static struct omap_hwmod omap3xxx_timer7_hwmod = { 314 static struct omap_hwmod omap3xxx_timer7_hwmod = {
315 .name = "timer7", 315 .name = "timer7",
316 .mpu_irqs = omap2_timer7_mpu_irqs, 316 .mpu_irqs = omap2_timer7_mpu_irqs,
317 .main_clk = "gpt7_fck", 317 .main_clk = "gpt7_fck",
318 .prcm = { 318 .prcm = {
319 .omap2 = { 319 .omap2 = {
320 .prcm_reg_id = 1, 320 .prcm_reg_id = 1,
321 .module_bit = OMAP3430_EN_GPT7_SHIFT, 321 .module_bit = OMAP3430_EN_GPT7_SHIFT,
322 .module_offs = OMAP3430_PER_MOD, 322 .module_offs = OMAP3430_PER_MOD,
323 .idlest_reg_id = 1, 323 .idlest_reg_id = 1,
324 .idlest_idle_bit = OMAP3430_ST_GPT7_SHIFT, 324 .idlest_idle_bit = OMAP3430_ST_GPT7_SHIFT,
325 }, 325 },
326 }, 326 },
327 .dev_attr = &capability_dsp_dev_attr, 327 .dev_attr = &capability_dsp_dev_attr,
328 .class = &omap3xxx_timer_hwmod_class, 328 .class = &omap3xxx_timer_hwmod_class,
329 }; 329 };
330 330
331 /* timer8 */ 331 /* timer8 */
332 static struct omap_hwmod omap3xxx_timer8_hwmod = { 332 static struct omap_hwmod omap3xxx_timer8_hwmod = {
333 .name = "timer8", 333 .name = "timer8",
334 .mpu_irqs = omap2_timer8_mpu_irqs, 334 .mpu_irqs = omap2_timer8_mpu_irqs,
335 .main_clk = "gpt8_fck", 335 .main_clk = "gpt8_fck",
336 .prcm = { 336 .prcm = {
337 .omap2 = { 337 .omap2 = {
338 .prcm_reg_id = 1, 338 .prcm_reg_id = 1,
339 .module_bit = OMAP3430_EN_GPT8_SHIFT, 339 .module_bit = OMAP3430_EN_GPT8_SHIFT,
340 .module_offs = OMAP3430_PER_MOD, 340 .module_offs = OMAP3430_PER_MOD,
341 .idlest_reg_id = 1, 341 .idlest_reg_id = 1,
342 .idlest_idle_bit = OMAP3430_ST_GPT8_SHIFT, 342 .idlest_idle_bit = OMAP3430_ST_GPT8_SHIFT,
343 }, 343 },
344 }, 344 },
345 .dev_attr = &capability_dsp_pwm_dev_attr, 345 .dev_attr = &capability_dsp_pwm_dev_attr,
346 .class = &omap3xxx_timer_hwmod_class, 346 .class = &omap3xxx_timer_hwmod_class,
347 }; 347 };
348 348
349 /* timer9 */ 349 /* timer9 */
350 static struct omap_hwmod omap3xxx_timer9_hwmod = { 350 static struct omap_hwmod omap3xxx_timer9_hwmod = {
351 .name = "timer9", 351 .name = "timer9",
352 .mpu_irqs = omap2_timer9_mpu_irqs, 352 .mpu_irqs = omap2_timer9_mpu_irqs,
353 .main_clk = "gpt9_fck", 353 .main_clk = "gpt9_fck",
354 .prcm = { 354 .prcm = {
355 .omap2 = { 355 .omap2 = {
356 .prcm_reg_id = 1, 356 .prcm_reg_id = 1,
357 .module_bit = OMAP3430_EN_GPT9_SHIFT, 357 .module_bit = OMAP3430_EN_GPT9_SHIFT,
358 .module_offs = OMAP3430_PER_MOD, 358 .module_offs = OMAP3430_PER_MOD,
359 .idlest_reg_id = 1, 359 .idlest_reg_id = 1,
360 .idlest_idle_bit = OMAP3430_ST_GPT9_SHIFT, 360 .idlest_idle_bit = OMAP3430_ST_GPT9_SHIFT,
361 }, 361 },
362 }, 362 },
363 .dev_attr = &capability_pwm_dev_attr, 363 .dev_attr = &capability_pwm_dev_attr,
364 .class = &omap3xxx_timer_hwmod_class, 364 .class = &omap3xxx_timer_hwmod_class,
365 }; 365 };
366 366
367 /* timer10 */ 367 /* timer10 */
368 static struct omap_hwmod omap3xxx_timer10_hwmod = { 368 static struct omap_hwmod omap3xxx_timer10_hwmod = {
369 .name = "timer10", 369 .name = "timer10",
370 .mpu_irqs = omap2_timer10_mpu_irqs, 370 .mpu_irqs = omap2_timer10_mpu_irqs,
371 .main_clk = "gpt10_fck", 371 .main_clk = "gpt10_fck",
372 .prcm = { 372 .prcm = {
373 .omap2 = { 373 .omap2 = {
374 .prcm_reg_id = 1, 374 .prcm_reg_id = 1,
375 .module_bit = OMAP3430_EN_GPT10_SHIFT, 375 .module_bit = OMAP3430_EN_GPT10_SHIFT,
376 .module_offs = CORE_MOD, 376 .module_offs = CORE_MOD,
377 .idlest_reg_id = 1, 377 .idlest_reg_id = 1,
378 .idlest_idle_bit = OMAP3430_ST_GPT10_SHIFT, 378 .idlest_idle_bit = OMAP3430_ST_GPT10_SHIFT,
379 }, 379 },
380 }, 380 },
381 .dev_attr = &capability_pwm_dev_attr, 381 .dev_attr = &capability_pwm_dev_attr,
382 .class = &omap3xxx_timer_1ms_hwmod_class, 382 .class = &omap3xxx_timer_1ms_hwmod_class,
383 }; 383 };
384 384
385 /* timer11 */ 385 /* timer11 */
386 static struct omap_hwmod omap3xxx_timer11_hwmod = { 386 static struct omap_hwmod omap3xxx_timer11_hwmod = {
387 .name = "timer11", 387 .name = "timer11",
388 .mpu_irqs = omap2_timer11_mpu_irqs, 388 .mpu_irqs = omap2_timer11_mpu_irqs,
389 .main_clk = "gpt11_fck", 389 .main_clk = "gpt11_fck",
390 .prcm = { 390 .prcm = {
391 .omap2 = { 391 .omap2 = {
392 .prcm_reg_id = 1, 392 .prcm_reg_id = 1,
393 .module_bit = OMAP3430_EN_GPT11_SHIFT, 393 .module_bit = OMAP3430_EN_GPT11_SHIFT,
394 .module_offs = CORE_MOD, 394 .module_offs = CORE_MOD,
395 .idlest_reg_id = 1, 395 .idlest_reg_id = 1,
396 .idlest_idle_bit = OMAP3430_ST_GPT11_SHIFT, 396 .idlest_idle_bit = OMAP3430_ST_GPT11_SHIFT,
397 }, 397 },
398 }, 398 },
399 .dev_attr = &capability_pwm_dev_attr, 399 .dev_attr = &capability_pwm_dev_attr,
400 .class = &omap3xxx_timer_hwmod_class, 400 .class = &omap3xxx_timer_hwmod_class,
401 }; 401 };
402 402
403 /* timer12 */ 403 /* timer12 */
404 static struct omap_hwmod_irq_info omap3xxx_timer12_mpu_irqs[] = { 404 static struct omap_hwmod_irq_info omap3xxx_timer12_mpu_irqs[] = {
405 { .irq = 95 + OMAP_INTC_START, }, 405 { .irq = 95 + OMAP_INTC_START, },
406 { .irq = -1 }, 406 { .irq = -1 },
407 }; 407 };
408 408
409 static struct omap_hwmod omap3xxx_timer12_hwmod = { 409 static struct omap_hwmod omap3xxx_timer12_hwmod = {
410 .name = "timer12", 410 .name = "timer12",
411 .mpu_irqs = omap3xxx_timer12_mpu_irqs, 411 .mpu_irqs = omap3xxx_timer12_mpu_irqs,
412 .main_clk = "gpt12_fck", 412 .main_clk = "gpt12_fck",
413 .prcm = { 413 .prcm = {
414 .omap2 = { 414 .omap2 = {
415 .prcm_reg_id = 1, 415 .prcm_reg_id = 1,
416 .module_bit = OMAP3430_EN_GPT12_SHIFT, 416 .module_bit = OMAP3430_EN_GPT12_SHIFT,
417 .module_offs = WKUP_MOD, 417 .module_offs = WKUP_MOD,
418 .idlest_reg_id = 1, 418 .idlest_reg_id = 1,
419 .idlest_idle_bit = OMAP3430_ST_GPT12_SHIFT, 419 .idlest_idle_bit = OMAP3430_ST_GPT12_SHIFT,
420 }, 420 },
421 }, 421 },
422 .dev_attr = &capability_secure_dev_attr, 422 .dev_attr = &capability_secure_dev_attr,
423 .class = &omap3xxx_timer_hwmod_class, 423 .class = &omap3xxx_timer_hwmod_class,
424 }; 424 };
425 425
426 /* 426 /*
427 * 'wd_timer' class 427 * 'wd_timer' class
428 * 32-bit watchdog upward counter that generates a pulse on the reset pin on 428 * 32-bit watchdog upward counter that generates a pulse on the reset pin on
429 * overflow condition 429 * overflow condition
430 */ 430 */
431 431
432 static struct omap_hwmod_class_sysconfig omap3xxx_wd_timer_sysc = { 432 static struct omap_hwmod_class_sysconfig omap3xxx_wd_timer_sysc = {
433 .rev_offs = 0x0000, 433 .rev_offs = 0x0000,
434 .sysc_offs = 0x0010, 434 .sysc_offs = 0x0010,
435 .syss_offs = 0x0014, 435 .syss_offs = 0x0014,
436 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_EMUFREE | 436 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_EMUFREE |
437 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET | 437 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
438 SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY | 438 SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
439 SYSS_HAS_RESET_STATUS), 439 SYSS_HAS_RESET_STATUS),
440 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 440 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
441 .sysc_fields = &omap_hwmod_sysc_type1, 441 .sysc_fields = &omap_hwmod_sysc_type1,
442 }; 442 };
443 443
444 /* I2C common */ 444 /* I2C common */
445 static struct omap_hwmod_class_sysconfig i2c_sysc = { 445 static struct omap_hwmod_class_sysconfig i2c_sysc = {
446 .rev_offs = 0x00, 446 .rev_offs = 0x00,
447 .sysc_offs = 0x20, 447 .sysc_offs = 0x20,
448 .syss_offs = 0x10, 448 .syss_offs = 0x10,
449 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 449 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
450 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET | 450 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
451 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS), 451 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS),
452 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 452 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
453 .clockact = CLOCKACT_TEST_ICLK, 453 .clockact = CLOCKACT_TEST_ICLK,
454 .sysc_fields = &omap_hwmod_sysc_type1, 454 .sysc_fields = &omap_hwmod_sysc_type1,
455 }; 455 };
456 456
457 static struct omap_hwmod_class omap3xxx_wd_timer_hwmod_class = { 457 static struct omap_hwmod_class omap3xxx_wd_timer_hwmod_class = {
458 .name = "wd_timer", 458 .name = "wd_timer",
459 .sysc = &omap3xxx_wd_timer_sysc, 459 .sysc = &omap3xxx_wd_timer_sysc,
460 .pre_shutdown = &omap2_wd_timer_disable, 460 .pre_shutdown = &omap2_wd_timer_disable,
461 .reset = &omap2_wd_timer_reset, 461 .reset = &omap2_wd_timer_reset,
462 }; 462 };
463 463
464 static struct omap_hwmod omap3xxx_wd_timer2_hwmod = { 464 static struct omap_hwmod omap3xxx_wd_timer2_hwmod = {
465 .name = "wd_timer2", 465 .name = "wd_timer2",
466 .class = &omap3xxx_wd_timer_hwmod_class, 466 .class = &omap3xxx_wd_timer_hwmod_class,
467 .main_clk = "wdt2_fck", 467 .main_clk = "wdt2_fck",
468 .prcm = { 468 .prcm = {
469 .omap2 = { 469 .omap2 = {
470 .prcm_reg_id = 1, 470 .prcm_reg_id = 1,
471 .module_bit = OMAP3430_EN_WDT2_SHIFT, 471 .module_bit = OMAP3430_EN_WDT2_SHIFT,
472 .module_offs = WKUP_MOD, 472 .module_offs = WKUP_MOD,
473 .idlest_reg_id = 1, 473 .idlest_reg_id = 1,
474 .idlest_idle_bit = OMAP3430_ST_WDT2_SHIFT, 474 .idlest_idle_bit = OMAP3430_ST_WDT2_SHIFT,
475 }, 475 },
476 }, 476 },
477 /* 477 /*
478 * XXX: Use software supervised mode, HW supervised smartidle seems to 478 * XXX: Use software supervised mode, HW supervised smartidle seems to
479 * block CORE power domain idle transitions. Maybe a HW bug in wdt2? 479 * block CORE power domain idle transitions. Maybe a HW bug in wdt2?
480 */ 480 */
481 .flags = HWMOD_SWSUP_SIDLE, 481 .flags = HWMOD_SWSUP_SIDLE,
482 }; 482 };
483 483
484 /* UART1 */ 484 /* UART1 */
485 static struct omap_hwmod omap3xxx_uart1_hwmod = { 485 static struct omap_hwmod omap3xxx_uart1_hwmod = {
486 .name = "uart1", 486 .name = "uart1",
487 .mpu_irqs = omap2_uart1_mpu_irqs, 487 .mpu_irqs = omap2_uart1_mpu_irqs,
488 .sdma_reqs = omap2_uart1_sdma_reqs, 488 .sdma_reqs = omap2_uart1_sdma_reqs,
489 .main_clk = "uart1_fck", 489 .main_clk = "uart1_fck",
490 .prcm = { 490 .prcm = {
491 .omap2 = { 491 .omap2 = {
492 .module_offs = CORE_MOD, 492 .module_offs = CORE_MOD,
493 .prcm_reg_id = 1, 493 .prcm_reg_id = 1,
494 .module_bit = OMAP3430_EN_UART1_SHIFT, 494 .module_bit = OMAP3430_EN_UART1_SHIFT,
495 .idlest_reg_id = 1, 495 .idlest_reg_id = 1,
496 .idlest_idle_bit = OMAP3430_EN_UART1_SHIFT, 496 .idlest_idle_bit = OMAP3430_EN_UART1_SHIFT,
497 }, 497 },
498 }, 498 },
499 .class = &omap2_uart_class, 499 .class = &omap2_uart_class,
500 }; 500 };
501 501
502 /* UART2 */ 502 /* UART2 */
503 static struct omap_hwmod omap3xxx_uart2_hwmod = { 503 static struct omap_hwmod omap3xxx_uart2_hwmod = {
504 .name = "uart2", 504 .name = "uart2",
505 .mpu_irqs = omap2_uart2_mpu_irqs, 505 .mpu_irqs = omap2_uart2_mpu_irqs,
506 .sdma_reqs = omap2_uart2_sdma_reqs, 506 .sdma_reqs = omap2_uart2_sdma_reqs,
507 .main_clk = "uart2_fck", 507 .main_clk = "uart2_fck",
508 .prcm = { 508 .prcm = {
509 .omap2 = { 509 .omap2 = {
510 .module_offs = CORE_MOD, 510 .module_offs = CORE_MOD,
511 .prcm_reg_id = 1, 511 .prcm_reg_id = 1,
512 .module_bit = OMAP3430_EN_UART2_SHIFT, 512 .module_bit = OMAP3430_EN_UART2_SHIFT,
513 .idlest_reg_id = 1, 513 .idlest_reg_id = 1,
514 .idlest_idle_bit = OMAP3430_EN_UART2_SHIFT, 514 .idlest_idle_bit = OMAP3430_EN_UART2_SHIFT,
515 }, 515 },
516 }, 516 },
517 .class = &omap2_uart_class, 517 .class = &omap2_uart_class,
518 }; 518 };
519 519
520 /* UART3 */ 520 /* UART3 */
521 static struct omap_hwmod omap3xxx_uart3_hwmod = { 521 static struct omap_hwmod omap3xxx_uart3_hwmod = {
522 .name = "uart3", 522 .name = "uart3",
523 .mpu_irqs = omap2_uart3_mpu_irqs, 523 .mpu_irqs = omap2_uart3_mpu_irqs,
524 .sdma_reqs = omap2_uart3_sdma_reqs, 524 .sdma_reqs = omap2_uart3_sdma_reqs,
525 .main_clk = "uart3_fck", 525 .main_clk = "uart3_fck",
526 .prcm = { 526 .prcm = {
527 .omap2 = { 527 .omap2 = {
528 .module_offs = OMAP3430_PER_MOD, 528 .module_offs = OMAP3430_PER_MOD,
529 .prcm_reg_id = 1, 529 .prcm_reg_id = 1,
530 .module_bit = OMAP3430_EN_UART3_SHIFT, 530 .module_bit = OMAP3430_EN_UART3_SHIFT,
531 .idlest_reg_id = 1, 531 .idlest_reg_id = 1,
532 .idlest_idle_bit = OMAP3430_EN_UART3_SHIFT, 532 .idlest_idle_bit = OMAP3430_EN_UART3_SHIFT,
533 }, 533 },
534 }, 534 },
535 .class = &omap2_uart_class, 535 .class = &omap2_uart_class,
536 }; 536 };
537 537
538 /* UART4 */ 538 /* UART4 */
539 static struct omap_hwmod_irq_info uart4_mpu_irqs[] = { 539 static struct omap_hwmod_irq_info uart4_mpu_irqs[] = {
540 { .irq = 80 + OMAP_INTC_START, }, 540 { .irq = 80 + OMAP_INTC_START, },
541 { .irq = -1 }, 541 { .irq = -1 },
542 }; 542 };
543 543
544 static struct omap_hwmod_dma_info uart4_sdma_reqs[] = { 544 static struct omap_hwmod_dma_info uart4_sdma_reqs[] = {
545 { .name = "rx", .dma_req = OMAP36XX_DMA_UART4_RX, }, 545 { .name = "rx", .dma_req = OMAP36XX_DMA_UART4_RX, },
546 { .name = "tx", .dma_req = OMAP36XX_DMA_UART4_TX, }, 546 { .name = "tx", .dma_req = OMAP36XX_DMA_UART4_TX, },
547 { .dma_req = -1 } 547 { .dma_req = -1 }
548 }; 548 };
549 549
550 static struct omap_hwmod omap36xx_uart4_hwmod = { 550 static struct omap_hwmod omap36xx_uart4_hwmod = {
551 .name = "uart4", 551 .name = "uart4",
552 .mpu_irqs = uart4_mpu_irqs, 552 .mpu_irqs = uart4_mpu_irqs,
553 .sdma_reqs = uart4_sdma_reqs, 553 .sdma_reqs = uart4_sdma_reqs,
554 .main_clk = "uart4_fck", 554 .main_clk = "uart4_fck",
555 .prcm = { 555 .prcm = {
556 .omap2 = { 556 .omap2 = {
557 .module_offs = OMAP3430_PER_MOD, 557 .module_offs = OMAP3430_PER_MOD,
558 .prcm_reg_id = 1, 558 .prcm_reg_id = 1,
559 .module_bit = OMAP3630_EN_UART4_SHIFT, 559 .module_bit = OMAP3630_EN_UART4_SHIFT,
560 .idlest_reg_id = 1, 560 .idlest_reg_id = 1,
561 .idlest_idle_bit = OMAP3630_EN_UART4_SHIFT, 561 .idlest_idle_bit = OMAP3630_EN_UART4_SHIFT,
562 }, 562 },
563 }, 563 },
564 .class = &omap2_uart_class, 564 .class = &omap2_uart_class,
565 }; 565 };
566 566
567 static struct omap_hwmod_irq_info am35xx_uart4_mpu_irqs[] = { 567 static struct omap_hwmod_irq_info am35xx_uart4_mpu_irqs[] = {
568 { .irq = 84 + OMAP_INTC_START, }, 568 { .irq = 84 + OMAP_INTC_START, },
569 { .irq = -1 }, 569 { .irq = -1 },
570 }; 570 };
571 571
572 static struct omap_hwmod_dma_info am35xx_uart4_sdma_reqs[] = { 572 static struct omap_hwmod_dma_info am35xx_uart4_sdma_reqs[] = {
573 { .name = "rx", .dma_req = AM35XX_DMA_UART4_RX, }, 573 { .name = "rx", .dma_req = AM35XX_DMA_UART4_RX, },
574 { .name = "tx", .dma_req = AM35XX_DMA_UART4_TX, }, 574 { .name = "tx", .dma_req = AM35XX_DMA_UART4_TX, },
575 { .dma_req = -1 } 575 { .dma_req = -1 }
576 }; 576 };
577 577
578 /* 578 /*
579 * XXX AM35xx UART4 cannot complete its softreset without uart1_fck or 579 * XXX AM35xx UART4 cannot complete its softreset without uart1_fck or
580 * uart2_fck being enabled. So we add uart1_fck as an optional clock, 580 * uart2_fck being enabled. So we add uart1_fck as an optional clock,
581 * below, and set the HWMOD_CONTROL_OPT_CLKS_IN_RESET. This really 581 * below, and set the HWMOD_CONTROL_OPT_CLKS_IN_RESET. This really
582 * should not be needed. The functional clock structure of the AM35xx 582 * should not be needed. The functional clock structure of the AM35xx
583 * UART4 is extremely unclear and opaque; it is unclear what the role 583 * UART4 is extremely unclear and opaque; it is unclear what the role
584 * of uart1/2_fck is for the UART4. Any clarification from either 584 * of uart1/2_fck is for the UART4. Any clarification from either
585 * empirical testing or the AM3505/3517 hardware designers would be 585 * empirical testing or the AM3505/3517 hardware designers would be
586 * most welcome. 586 * most welcome.
587 */ 587 */
588 static struct omap_hwmod_opt_clk am35xx_uart4_opt_clks[] = { 588 static struct omap_hwmod_opt_clk am35xx_uart4_opt_clks[] = {
589 { .role = "softreset_uart1_fck", .clk = "uart1_fck" }, 589 { .role = "softreset_uart1_fck", .clk = "uart1_fck" },
590 }; 590 };
591 591
592 static struct omap_hwmod am35xx_uart4_hwmod = { 592 static struct omap_hwmod am35xx_uart4_hwmod = {
593 .name = "uart4", 593 .name = "uart4",
594 .mpu_irqs = am35xx_uart4_mpu_irqs, 594 .mpu_irqs = am35xx_uart4_mpu_irqs,
595 .sdma_reqs = am35xx_uart4_sdma_reqs, 595 .sdma_reqs = am35xx_uart4_sdma_reqs,
596 .main_clk = "uart4_fck", 596 .main_clk = "uart4_fck",
597 .prcm = { 597 .prcm = {
598 .omap2 = { 598 .omap2 = {
599 .module_offs = CORE_MOD, 599 .module_offs = CORE_MOD,
600 .prcm_reg_id = 1, 600 .prcm_reg_id = 1,
601 .module_bit = AM35XX_EN_UART4_SHIFT, 601 .module_bit = AM35XX_EN_UART4_SHIFT,
602 .idlest_reg_id = 1, 602 .idlest_reg_id = 1,
603 .idlest_idle_bit = AM35XX_ST_UART4_SHIFT, 603 .idlest_idle_bit = AM35XX_ST_UART4_SHIFT,
604 }, 604 },
605 }, 605 },
606 .opt_clks = am35xx_uart4_opt_clks, 606 .opt_clks = am35xx_uart4_opt_clks,
607 .opt_clks_cnt = ARRAY_SIZE(am35xx_uart4_opt_clks), 607 .opt_clks_cnt = ARRAY_SIZE(am35xx_uart4_opt_clks),
608 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 608 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
609 .class = &omap2_uart_class, 609 .class = &omap2_uart_class,
610 }; 610 };
611 611
612 static struct omap_hwmod_class i2c_class = { 612 static struct omap_hwmod_class i2c_class = {
613 .name = "i2c", 613 .name = "i2c",
614 .sysc = &i2c_sysc, 614 .sysc = &i2c_sysc,
615 .rev = OMAP_I2C_IP_VERSION_1, 615 .rev = OMAP_I2C_IP_VERSION_1,
616 .reset = &omap_i2c_reset, 616 .reset = &omap_i2c_reset,
617 }; 617 };
618 618
619 static struct omap_hwmod_dma_info omap3xxx_dss_sdma_chs[] = { 619 static struct omap_hwmod_dma_info omap3xxx_dss_sdma_chs[] = {
620 { .name = "dispc", .dma_req = 5 }, 620 { .name = "dispc", .dma_req = 5 },
621 { .name = "dsi1", .dma_req = 74 }, 621 { .name = "dsi1", .dma_req = 74 },
622 { .dma_req = -1 } 622 { .dma_req = -1 }
623 }; 623 };
624 624
625 /* dss */ 625 /* dss */
626 static struct omap_hwmod_opt_clk dss_opt_clks[] = { 626 static struct omap_hwmod_opt_clk dss_opt_clks[] = {
627 /* 627 /*
628 * The DSS HW needs all DSS clocks enabled during reset. The dss_core 628 * The DSS HW needs all DSS clocks enabled during reset. The dss_core
629 * driver does not use these clocks. 629 * driver does not use these clocks.
630 */ 630 */
631 { .role = "sys_clk", .clk = "dss2_alwon_fck" }, 631 { .role = "sys_clk", .clk = "dss2_alwon_fck" },
632 { .role = "tv_clk", .clk = "dss_tv_fck" }, 632 { .role = "tv_clk", .clk = "dss_tv_fck" },
633 /* required only on OMAP3430 */ 633 /* required only on OMAP3430 */
634 { .role = "tv_dac_clk", .clk = "dss_96m_fck" }, 634 { .role = "tv_dac_clk", .clk = "dss_96m_fck" },
635 }; 635 };
636 636
637 static struct omap_hwmod omap3430es1_dss_core_hwmod = { 637 static struct omap_hwmod omap3430es1_dss_core_hwmod = {
638 .name = "dss_core", 638 .name = "dss_core",
639 .class = &omap2_dss_hwmod_class, 639 .class = &omap2_dss_hwmod_class,
640 .main_clk = "dss1_alwon_fck", /* instead of dss_fck */ 640 .main_clk = "dss1_alwon_fck", /* instead of dss_fck */
641 .sdma_reqs = omap3xxx_dss_sdma_chs, 641 .sdma_reqs = omap3xxx_dss_sdma_chs,
642 .prcm = { 642 .prcm = {
643 .omap2 = { 643 .omap2 = {
644 .prcm_reg_id = 1, 644 .prcm_reg_id = 1,
645 .module_bit = OMAP3430_EN_DSS1_SHIFT, 645 .module_bit = OMAP3430_EN_DSS1_SHIFT,
646 .module_offs = OMAP3430_DSS_MOD, 646 .module_offs = OMAP3430_DSS_MOD,
647 .idlest_reg_id = 1, 647 .idlest_reg_id = 1,
648 .idlest_stdby_bit = OMAP3430ES1_ST_DSS_SHIFT, 648 .idlest_stdby_bit = OMAP3430ES1_ST_DSS_SHIFT,
649 }, 649 },
650 }, 650 },
651 .opt_clks = dss_opt_clks, 651 .opt_clks = dss_opt_clks,
652 .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks), 652 .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks),
653 .flags = HWMOD_NO_IDLEST | HWMOD_CONTROL_OPT_CLKS_IN_RESET, 653 .flags = HWMOD_NO_IDLEST | HWMOD_CONTROL_OPT_CLKS_IN_RESET,
654 }; 654 };
655 655
656 static struct omap_hwmod omap3xxx_dss_core_hwmod = { 656 static struct omap_hwmod omap3xxx_dss_core_hwmod = {
657 .name = "dss_core", 657 .name = "dss_core",
658 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 658 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
659 .class = &omap2_dss_hwmod_class, 659 .class = &omap2_dss_hwmod_class,
660 .main_clk = "dss1_alwon_fck", /* instead of dss_fck */ 660 .main_clk = "dss1_alwon_fck", /* instead of dss_fck */
661 .sdma_reqs = omap3xxx_dss_sdma_chs, 661 .sdma_reqs = omap3xxx_dss_sdma_chs,
662 .prcm = { 662 .prcm = {
663 .omap2 = { 663 .omap2 = {
664 .prcm_reg_id = 1, 664 .prcm_reg_id = 1,
665 .module_bit = OMAP3430_EN_DSS1_SHIFT, 665 .module_bit = OMAP3430_EN_DSS1_SHIFT,
666 .module_offs = OMAP3430_DSS_MOD, 666 .module_offs = OMAP3430_DSS_MOD,
667 .idlest_reg_id = 1, 667 .idlest_reg_id = 1,
668 .idlest_idle_bit = OMAP3430ES2_ST_DSS_IDLE_SHIFT, 668 .idlest_idle_bit = OMAP3430ES2_ST_DSS_IDLE_SHIFT,
669 .idlest_stdby_bit = OMAP3430ES2_ST_DSS_STDBY_SHIFT, 669 .idlest_stdby_bit = OMAP3430ES2_ST_DSS_STDBY_SHIFT,
670 }, 670 },
671 }, 671 },
672 .opt_clks = dss_opt_clks, 672 .opt_clks = dss_opt_clks,
673 .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks), 673 .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks),
674 }; 674 };
675 675
676 /* 676 /*
677 * 'dispc' class 677 * 'dispc' class
678 * display controller 678 * display controller
679 */ 679 */
680 680
681 static struct omap_hwmod_class_sysconfig omap3_dispc_sysc = { 681 static struct omap_hwmod_class_sysconfig omap3_dispc_sysc = {
682 .rev_offs = 0x0000, 682 .rev_offs = 0x0000,
683 .sysc_offs = 0x0010, 683 .sysc_offs = 0x0010,
684 .syss_offs = 0x0014, 684 .syss_offs = 0x0014,
685 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE | 685 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE |
686 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE | 686 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE |
687 SYSC_HAS_ENAWAKEUP), 687 SYSC_HAS_ENAWAKEUP),
688 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 688 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
689 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART), 689 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
690 .sysc_fields = &omap_hwmod_sysc_type1, 690 .sysc_fields = &omap_hwmod_sysc_type1,
691 }; 691 };
692 692
693 static struct omap_hwmod_class omap3_dispc_hwmod_class = { 693 static struct omap_hwmod_class omap3_dispc_hwmod_class = {
694 .name = "dispc", 694 .name = "dispc",
695 .sysc = &omap3_dispc_sysc, 695 .sysc = &omap3_dispc_sysc,
696 }; 696 };
697 697
698 static struct omap_hwmod omap3xxx_dss_dispc_hwmod = { 698 static struct omap_hwmod omap3xxx_dss_dispc_hwmod = {
699 .name = "dss_dispc", 699 .name = "dss_dispc",
700 .class = &omap3_dispc_hwmod_class, 700 .class = &omap3_dispc_hwmod_class,
701 .mpu_irqs = omap2_dispc_irqs, 701 .mpu_irqs = omap2_dispc_irqs,
702 .main_clk = "dss1_alwon_fck", 702 .main_clk = "dss1_alwon_fck",
703 .prcm = { 703 .prcm = {
704 .omap2 = { 704 .omap2 = {
705 .prcm_reg_id = 1, 705 .prcm_reg_id = 1,
706 .module_bit = OMAP3430_EN_DSS1_SHIFT, 706 .module_bit = OMAP3430_EN_DSS1_SHIFT,
707 .module_offs = OMAP3430_DSS_MOD, 707 .module_offs = OMAP3430_DSS_MOD,
708 }, 708 },
709 }, 709 },
710 .flags = HWMOD_NO_IDLEST, 710 .flags = HWMOD_NO_IDLEST,
711 .dev_attr = &omap2_3_dss_dispc_dev_attr 711 .dev_attr = &omap2_3_dss_dispc_dev_attr
712 }; 712 };
713 713
714 /* 714 /*
715 * 'dsi' class 715 * 'dsi' class
716 * display serial interface controller 716 * display serial interface controller
717 */ 717 */
718 718
719 static struct omap_hwmod_class omap3xxx_dsi_hwmod_class = { 719 static struct omap_hwmod_class omap3xxx_dsi_hwmod_class = {
720 .name = "dsi", 720 .name = "dsi",
721 }; 721 };
722 722
723 static struct omap_hwmod_irq_info omap3xxx_dsi1_irqs[] = { 723 static struct omap_hwmod_irq_info omap3xxx_dsi1_irqs[] = {
724 { .irq = 25 + OMAP_INTC_START, }, 724 { .irq = 25 + OMAP_INTC_START, },
725 { .irq = -1 }, 725 { .irq = -1 },
726 }; 726 };
727 727
728 /* dss_dsi1 */ 728 /* dss_dsi1 */
729 static struct omap_hwmod_opt_clk dss_dsi1_opt_clks[] = { 729 static struct omap_hwmod_opt_clk dss_dsi1_opt_clks[] = {
730 { .role = "sys_clk", .clk = "dss2_alwon_fck" }, 730 { .role = "sys_clk", .clk = "dss2_alwon_fck" },
731 }; 731 };
732 732
733 static struct omap_hwmod omap3xxx_dss_dsi1_hwmod = { 733 static struct omap_hwmod omap3xxx_dss_dsi1_hwmod = {
734 .name = "dss_dsi1", 734 .name = "dss_dsi1",
735 .class = &omap3xxx_dsi_hwmod_class, 735 .class = &omap3xxx_dsi_hwmod_class,
736 .mpu_irqs = omap3xxx_dsi1_irqs, 736 .mpu_irqs = omap3xxx_dsi1_irqs,
737 .main_clk = "dss1_alwon_fck", 737 .main_clk = "dss1_alwon_fck",
738 .prcm = { 738 .prcm = {
739 .omap2 = { 739 .omap2 = {
740 .prcm_reg_id = 1, 740 .prcm_reg_id = 1,
741 .module_bit = OMAP3430_EN_DSS1_SHIFT, 741 .module_bit = OMAP3430_EN_DSS1_SHIFT,
742 .module_offs = OMAP3430_DSS_MOD, 742 .module_offs = OMAP3430_DSS_MOD,
743 }, 743 },
744 }, 744 },
745 .opt_clks = dss_dsi1_opt_clks, 745 .opt_clks = dss_dsi1_opt_clks,
746 .opt_clks_cnt = ARRAY_SIZE(dss_dsi1_opt_clks), 746 .opt_clks_cnt = ARRAY_SIZE(dss_dsi1_opt_clks),
747 .flags = HWMOD_NO_IDLEST, 747 .flags = HWMOD_NO_IDLEST,
748 }; 748 };
749 749
750 static struct omap_hwmod_opt_clk dss_rfbi_opt_clks[] = { 750 static struct omap_hwmod_opt_clk dss_rfbi_opt_clks[] = {
751 { .role = "ick", .clk = "dss_ick" }, 751 { .role = "ick", .clk = "dss_ick" },
752 }; 752 };
753 753
754 static struct omap_hwmod omap3xxx_dss_rfbi_hwmod = { 754 static struct omap_hwmod omap3xxx_dss_rfbi_hwmod = {
755 .name = "dss_rfbi", 755 .name = "dss_rfbi",
756 .class = &omap2_rfbi_hwmod_class, 756 .class = &omap2_rfbi_hwmod_class,
757 .main_clk = "dss1_alwon_fck", 757 .main_clk = "dss1_alwon_fck",
758 .prcm = { 758 .prcm = {
759 .omap2 = { 759 .omap2 = {
760 .prcm_reg_id = 1, 760 .prcm_reg_id = 1,
761 .module_bit = OMAP3430_EN_DSS1_SHIFT, 761 .module_bit = OMAP3430_EN_DSS1_SHIFT,
762 .module_offs = OMAP3430_DSS_MOD, 762 .module_offs = OMAP3430_DSS_MOD,
763 }, 763 },
764 }, 764 },
765 .opt_clks = dss_rfbi_opt_clks, 765 .opt_clks = dss_rfbi_opt_clks,
766 .opt_clks_cnt = ARRAY_SIZE(dss_rfbi_opt_clks), 766 .opt_clks_cnt = ARRAY_SIZE(dss_rfbi_opt_clks),
767 .flags = HWMOD_NO_IDLEST, 767 .flags = HWMOD_NO_IDLEST,
768 }; 768 };
769 769
770 static struct omap_hwmod_opt_clk dss_venc_opt_clks[] = { 770 static struct omap_hwmod_opt_clk dss_venc_opt_clks[] = {
771 /* required only on OMAP3430 */ 771 /* required only on OMAP3430 */
772 { .role = "tv_dac_clk", .clk = "dss_96m_fck" }, 772 { .role = "tv_dac_clk", .clk = "dss_96m_fck" },
773 }; 773 };
774 774
775 static struct omap_hwmod omap3xxx_dss_venc_hwmod = { 775 static struct omap_hwmod omap3xxx_dss_venc_hwmod = {
776 .name = "dss_venc", 776 .name = "dss_venc",
777 .class = &omap2_venc_hwmod_class, 777 .class = &omap2_venc_hwmod_class,
778 .main_clk = "dss_tv_fck", 778 .main_clk = "dss_tv_fck",
779 .prcm = { 779 .prcm = {
780 .omap2 = { 780 .omap2 = {
781 .prcm_reg_id = 1, 781 .prcm_reg_id = 1,
782 .module_bit = OMAP3430_EN_DSS1_SHIFT, 782 .module_bit = OMAP3430_EN_DSS1_SHIFT,
783 .module_offs = OMAP3430_DSS_MOD, 783 .module_offs = OMAP3430_DSS_MOD,
784 }, 784 },
785 }, 785 },
786 .opt_clks = dss_venc_opt_clks, 786 .opt_clks = dss_venc_opt_clks,
787 .opt_clks_cnt = ARRAY_SIZE(dss_venc_opt_clks), 787 .opt_clks_cnt = ARRAY_SIZE(dss_venc_opt_clks),
788 .flags = HWMOD_NO_IDLEST, 788 .flags = HWMOD_NO_IDLEST,
789 }; 789 };
790 790
791 /* I2C1 */ 791 /* I2C1 */
792 static struct omap_i2c_dev_attr i2c1_dev_attr = { 792 static struct omap_i2c_dev_attr i2c1_dev_attr = {
793 .fifo_depth = 8, /* bytes */ 793 .fifo_depth = 8, /* bytes */
794 .flags = OMAP_I2C_FLAG_RESET_REGS_POSTIDLE | 794 .flags = OMAP_I2C_FLAG_BUS_SHIFT_2,
795 OMAP_I2C_FLAG_BUS_SHIFT_2,
796 }; 795 };
797 796
798 static struct omap_hwmod omap3xxx_i2c1_hwmod = { 797 static struct omap_hwmod omap3xxx_i2c1_hwmod = {
799 .name = "i2c1", 798 .name = "i2c1",
800 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT, 799 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
801 .mpu_irqs = omap2_i2c1_mpu_irqs, 800 .mpu_irqs = omap2_i2c1_mpu_irqs,
802 .sdma_reqs = omap2_i2c1_sdma_reqs, 801 .sdma_reqs = omap2_i2c1_sdma_reqs,
803 .main_clk = "i2c1_fck", 802 .main_clk = "i2c1_fck",
804 .prcm = { 803 .prcm = {
805 .omap2 = { 804 .omap2 = {
806 .module_offs = CORE_MOD, 805 .module_offs = CORE_MOD,
807 .prcm_reg_id = 1, 806 .prcm_reg_id = 1,
808 .module_bit = OMAP3430_EN_I2C1_SHIFT, 807 .module_bit = OMAP3430_EN_I2C1_SHIFT,
809 .idlest_reg_id = 1, 808 .idlest_reg_id = 1,
810 .idlest_idle_bit = OMAP3430_ST_I2C1_SHIFT, 809 .idlest_idle_bit = OMAP3430_ST_I2C1_SHIFT,
811 }, 810 },
812 }, 811 },
813 .class = &i2c_class, 812 .class = &i2c_class,
814 .dev_attr = &i2c1_dev_attr, 813 .dev_attr = &i2c1_dev_attr,
815 }; 814 };
816 815
817 /* I2C2 */ 816 /* I2C2 */
818 static struct omap_i2c_dev_attr i2c2_dev_attr = { 817 static struct omap_i2c_dev_attr i2c2_dev_attr = {
819 .fifo_depth = 8, /* bytes */ 818 .fifo_depth = 8, /* bytes */
820 .flags = OMAP_I2C_FLAG_RESET_REGS_POSTIDLE | 819 .flags = OMAP_I2C_FLAG_BUS_SHIFT_2,
821 OMAP_I2C_FLAG_BUS_SHIFT_2,
822 }; 820 };
823 821
824 static struct omap_hwmod omap3xxx_i2c2_hwmod = { 822 static struct omap_hwmod omap3xxx_i2c2_hwmod = {
825 .name = "i2c2", 823 .name = "i2c2",
826 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT, 824 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
827 .mpu_irqs = omap2_i2c2_mpu_irqs, 825 .mpu_irqs = omap2_i2c2_mpu_irqs,
828 .sdma_reqs = omap2_i2c2_sdma_reqs, 826 .sdma_reqs = omap2_i2c2_sdma_reqs,
829 .main_clk = "i2c2_fck", 827 .main_clk = "i2c2_fck",
830 .prcm = { 828 .prcm = {
831 .omap2 = { 829 .omap2 = {
832 .module_offs = CORE_MOD, 830 .module_offs = CORE_MOD,
833 .prcm_reg_id = 1, 831 .prcm_reg_id = 1,
834 .module_bit = OMAP3430_EN_I2C2_SHIFT, 832 .module_bit = OMAP3430_EN_I2C2_SHIFT,
835 .idlest_reg_id = 1, 833 .idlest_reg_id = 1,
836 .idlest_idle_bit = OMAP3430_ST_I2C2_SHIFT, 834 .idlest_idle_bit = OMAP3430_ST_I2C2_SHIFT,
837 }, 835 },
838 }, 836 },
839 .class = &i2c_class, 837 .class = &i2c_class,
840 .dev_attr = &i2c2_dev_attr, 838 .dev_attr = &i2c2_dev_attr,
841 }; 839 };
842 840
843 /* I2C3 */ 841 /* I2C3 */
844 static struct omap_i2c_dev_attr i2c3_dev_attr = { 842 static struct omap_i2c_dev_attr i2c3_dev_attr = {
845 .fifo_depth = 64, /* bytes */ 843 .fifo_depth = 64, /* bytes */
846 .flags = OMAP_I2C_FLAG_RESET_REGS_POSTIDLE | 844 .flags = OMAP_I2C_FLAG_BUS_SHIFT_2,
847 OMAP_I2C_FLAG_BUS_SHIFT_2,
848 }; 845 };
849 846
850 static struct omap_hwmod_irq_info i2c3_mpu_irqs[] = { 847 static struct omap_hwmod_irq_info i2c3_mpu_irqs[] = {
851 { .irq = 61 + OMAP_INTC_START, }, 848 { .irq = 61 + OMAP_INTC_START, },
852 { .irq = -1 }, 849 { .irq = -1 },
853 }; 850 };
854 851
855 static struct omap_hwmod_dma_info i2c3_sdma_reqs[] = { 852 static struct omap_hwmod_dma_info i2c3_sdma_reqs[] = {
856 { .name = "tx", .dma_req = OMAP34XX_DMA_I2C3_TX }, 853 { .name = "tx", .dma_req = OMAP34XX_DMA_I2C3_TX },
857 { .name = "rx", .dma_req = OMAP34XX_DMA_I2C3_RX }, 854 { .name = "rx", .dma_req = OMAP34XX_DMA_I2C3_RX },
858 { .dma_req = -1 } 855 { .dma_req = -1 }
859 }; 856 };
860 857
861 static struct omap_hwmod omap3xxx_i2c3_hwmod = { 858 static struct omap_hwmod omap3xxx_i2c3_hwmod = {
862 .name = "i2c3", 859 .name = "i2c3",
863 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT, 860 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
864 .mpu_irqs = i2c3_mpu_irqs, 861 .mpu_irqs = i2c3_mpu_irqs,
865 .sdma_reqs = i2c3_sdma_reqs, 862 .sdma_reqs = i2c3_sdma_reqs,
866 .main_clk = "i2c3_fck", 863 .main_clk = "i2c3_fck",
867 .prcm = { 864 .prcm = {
868 .omap2 = { 865 .omap2 = {
869 .module_offs = CORE_MOD, 866 .module_offs = CORE_MOD,
870 .prcm_reg_id = 1, 867 .prcm_reg_id = 1,
871 .module_bit = OMAP3430_EN_I2C3_SHIFT, 868 .module_bit = OMAP3430_EN_I2C3_SHIFT,
872 .idlest_reg_id = 1, 869 .idlest_reg_id = 1,
873 .idlest_idle_bit = OMAP3430_ST_I2C3_SHIFT, 870 .idlest_idle_bit = OMAP3430_ST_I2C3_SHIFT,
874 }, 871 },
875 }, 872 },
876 .class = &i2c_class, 873 .class = &i2c_class,
877 .dev_attr = &i2c3_dev_attr, 874 .dev_attr = &i2c3_dev_attr,
878 }; 875 };
879 876
880 /* 877 /*
881 * 'gpio' class 878 * 'gpio' class
882 * general purpose io module 879 * general purpose io module
883 */ 880 */
884 881
885 static struct omap_hwmod_class_sysconfig omap3xxx_gpio_sysc = { 882 static struct omap_hwmod_class_sysconfig omap3xxx_gpio_sysc = {
886 .rev_offs = 0x0000, 883 .rev_offs = 0x0000,
887 .sysc_offs = 0x0010, 884 .sysc_offs = 0x0010,
888 .syss_offs = 0x0014, 885 .syss_offs = 0x0014,
889 .sysc_flags = (SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE | 886 .sysc_flags = (SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
890 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE | 887 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE |
891 SYSS_HAS_RESET_STATUS), 888 SYSS_HAS_RESET_STATUS),
892 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 889 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
893 .sysc_fields = &omap_hwmod_sysc_type1, 890 .sysc_fields = &omap_hwmod_sysc_type1,
894 }; 891 };
895 892
896 static struct omap_hwmod_class omap3xxx_gpio_hwmod_class = { 893 static struct omap_hwmod_class omap3xxx_gpio_hwmod_class = {
897 .name = "gpio", 894 .name = "gpio",
898 .sysc = &omap3xxx_gpio_sysc, 895 .sysc = &omap3xxx_gpio_sysc,
899 .rev = 1, 896 .rev = 1,
900 }; 897 };
901 898
902 /* gpio_dev_attr */ 899 /* gpio_dev_attr */
903 static struct omap_gpio_dev_attr gpio_dev_attr = { 900 static struct omap_gpio_dev_attr gpio_dev_attr = {
904 .bank_width = 32, 901 .bank_width = 32,
905 .dbck_flag = true, 902 .dbck_flag = true,
906 }; 903 };
907 904
908 /* gpio1 */ 905 /* gpio1 */
909 static struct omap_hwmod_opt_clk gpio1_opt_clks[] = { 906 static struct omap_hwmod_opt_clk gpio1_opt_clks[] = {
910 { .role = "dbclk", .clk = "gpio1_dbck", }, 907 { .role = "dbclk", .clk = "gpio1_dbck", },
911 }; 908 };
912 909
913 static struct omap_hwmod omap3xxx_gpio1_hwmod = { 910 static struct omap_hwmod omap3xxx_gpio1_hwmod = {
914 .name = "gpio1", 911 .name = "gpio1",
915 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 912 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
916 .mpu_irqs = omap2_gpio1_irqs, 913 .mpu_irqs = omap2_gpio1_irqs,
917 .main_clk = "gpio1_ick", 914 .main_clk = "gpio1_ick",
918 .opt_clks = gpio1_opt_clks, 915 .opt_clks = gpio1_opt_clks,
919 .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks), 916 .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks),
920 .prcm = { 917 .prcm = {
921 .omap2 = { 918 .omap2 = {
922 .prcm_reg_id = 1, 919 .prcm_reg_id = 1,
923 .module_bit = OMAP3430_EN_GPIO1_SHIFT, 920 .module_bit = OMAP3430_EN_GPIO1_SHIFT,
924 .module_offs = WKUP_MOD, 921 .module_offs = WKUP_MOD,
925 .idlest_reg_id = 1, 922 .idlest_reg_id = 1,
926 .idlest_idle_bit = OMAP3430_ST_GPIO1_SHIFT, 923 .idlest_idle_bit = OMAP3430_ST_GPIO1_SHIFT,
927 }, 924 },
928 }, 925 },
929 .class = &omap3xxx_gpio_hwmod_class, 926 .class = &omap3xxx_gpio_hwmod_class,
930 .dev_attr = &gpio_dev_attr, 927 .dev_attr = &gpio_dev_attr,
931 }; 928 };
932 929
933 /* gpio2 */ 930 /* gpio2 */
934 static struct omap_hwmod_opt_clk gpio2_opt_clks[] = { 931 static struct omap_hwmod_opt_clk gpio2_opt_clks[] = {
935 { .role = "dbclk", .clk = "gpio2_dbck", }, 932 { .role = "dbclk", .clk = "gpio2_dbck", },
936 }; 933 };
937 934
938 static struct omap_hwmod omap3xxx_gpio2_hwmod = { 935 static struct omap_hwmod omap3xxx_gpio2_hwmod = {
939 .name = "gpio2", 936 .name = "gpio2",
940 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 937 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
941 .mpu_irqs = omap2_gpio2_irqs, 938 .mpu_irqs = omap2_gpio2_irqs,
942 .main_clk = "gpio2_ick", 939 .main_clk = "gpio2_ick",
943 .opt_clks = gpio2_opt_clks, 940 .opt_clks = gpio2_opt_clks,
944 .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks), 941 .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks),
945 .prcm = { 942 .prcm = {
946 .omap2 = { 943 .omap2 = {
947 .prcm_reg_id = 1, 944 .prcm_reg_id = 1,
948 .module_bit = OMAP3430_EN_GPIO2_SHIFT, 945 .module_bit = OMAP3430_EN_GPIO2_SHIFT,
949 .module_offs = OMAP3430_PER_MOD, 946 .module_offs = OMAP3430_PER_MOD,
950 .idlest_reg_id = 1, 947 .idlest_reg_id = 1,
951 .idlest_idle_bit = OMAP3430_ST_GPIO2_SHIFT, 948 .idlest_idle_bit = OMAP3430_ST_GPIO2_SHIFT,
952 }, 949 },
953 }, 950 },
954 .class = &omap3xxx_gpio_hwmod_class, 951 .class = &omap3xxx_gpio_hwmod_class,
955 .dev_attr = &gpio_dev_attr, 952 .dev_attr = &gpio_dev_attr,
956 }; 953 };
957 954
958 /* gpio3 */ 955 /* gpio3 */
959 static struct omap_hwmod_opt_clk gpio3_opt_clks[] = { 956 static struct omap_hwmod_opt_clk gpio3_opt_clks[] = {
960 { .role = "dbclk", .clk = "gpio3_dbck", }, 957 { .role = "dbclk", .clk = "gpio3_dbck", },
961 }; 958 };
962 959
963 static struct omap_hwmod omap3xxx_gpio3_hwmod = { 960 static struct omap_hwmod omap3xxx_gpio3_hwmod = {
964 .name = "gpio3", 961 .name = "gpio3",
965 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 962 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
966 .mpu_irqs = omap2_gpio3_irqs, 963 .mpu_irqs = omap2_gpio3_irqs,
967 .main_clk = "gpio3_ick", 964 .main_clk = "gpio3_ick",
968 .opt_clks = gpio3_opt_clks, 965 .opt_clks = gpio3_opt_clks,
969 .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks), 966 .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks),
970 .prcm = { 967 .prcm = {
971 .omap2 = { 968 .omap2 = {
972 .prcm_reg_id = 1, 969 .prcm_reg_id = 1,
973 .module_bit = OMAP3430_EN_GPIO3_SHIFT, 970 .module_bit = OMAP3430_EN_GPIO3_SHIFT,
974 .module_offs = OMAP3430_PER_MOD, 971 .module_offs = OMAP3430_PER_MOD,
975 .idlest_reg_id = 1, 972 .idlest_reg_id = 1,
976 .idlest_idle_bit = OMAP3430_ST_GPIO3_SHIFT, 973 .idlest_idle_bit = OMAP3430_ST_GPIO3_SHIFT,
977 }, 974 },
978 }, 975 },
979 .class = &omap3xxx_gpio_hwmod_class, 976 .class = &omap3xxx_gpio_hwmod_class,
980 .dev_attr = &gpio_dev_attr, 977 .dev_attr = &gpio_dev_attr,
981 }; 978 };
982 979
983 /* gpio4 */ 980 /* gpio4 */
984 static struct omap_hwmod_opt_clk gpio4_opt_clks[] = { 981 static struct omap_hwmod_opt_clk gpio4_opt_clks[] = {
985 { .role = "dbclk", .clk = "gpio4_dbck", }, 982 { .role = "dbclk", .clk = "gpio4_dbck", },
986 }; 983 };
987 984
988 static struct omap_hwmod omap3xxx_gpio4_hwmod = { 985 static struct omap_hwmod omap3xxx_gpio4_hwmod = {
989 .name = "gpio4", 986 .name = "gpio4",
990 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 987 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
991 .mpu_irqs = omap2_gpio4_irqs, 988 .mpu_irqs = omap2_gpio4_irqs,
992 .main_clk = "gpio4_ick", 989 .main_clk = "gpio4_ick",
993 .opt_clks = gpio4_opt_clks, 990 .opt_clks = gpio4_opt_clks,
994 .opt_clks_cnt = ARRAY_SIZE(gpio4_opt_clks), 991 .opt_clks_cnt = ARRAY_SIZE(gpio4_opt_clks),
995 .prcm = { 992 .prcm = {
996 .omap2 = { 993 .omap2 = {
997 .prcm_reg_id = 1, 994 .prcm_reg_id = 1,
998 .module_bit = OMAP3430_EN_GPIO4_SHIFT, 995 .module_bit = OMAP3430_EN_GPIO4_SHIFT,
999 .module_offs = OMAP3430_PER_MOD, 996 .module_offs = OMAP3430_PER_MOD,
1000 .idlest_reg_id = 1, 997 .idlest_reg_id = 1,
1001 .idlest_idle_bit = OMAP3430_ST_GPIO4_SHIFT, 998 .idlest_idle_bit = OMAP3430_ST_GPIO4_SHIFT,
1002 }, 999 },
1003 }, 1000 },
1004 .class = &omap3xxx_gpio_hwmod_class, 1001 .class = &omap3xxx_gpio_hwmod_class,
1005 .dev_attr = &gpio_dev_attr, 1002 .dev_attr = &gpio_dev_attr,
1006 }; 1003 };
1007 1004
1008 /* gpio5 */ 1005 /* gpio5 */
1009 static struct omap_hwmod_irq_info omap3xxx_gpio5_irqs[] = { 1006 static struct omap_hwmod_irq_info omap3xxx_gpio5_irqs[] = {
1010 { .irq = 33 + OMAP_INTC_START, }, /* INT_34XX_GPIO_BANK5 */ 1007 { .irq = 33 + OMAP_INTC_START, }, /* INT_34XX_GPIO_BANK5 */
1011 { .irq = -1 }, 1008 { .irq = -1 },
1012 }; 1009 };
1013 1010
1014 static struct omap_hwmod_opt_clk gpio5_opt_clks[] = { 1011 static struct omap_hwmod_opt_clk gpio5_opt_clks[] = {
1015 { .role = "dbclk", .clk = "gpio5_dbck", }, 1012 { .role = "dbclk", .clk = "gpio5_dbck", },
1016 }; 1013 };
1017 1014
1018 static struct omap_hwmod omap3xxx_gpio5_hwmod = { 1015 static struct omap_hwmod omap3xxx_gpio5_hwmod = {
1019 .name = "gpio5", 1016 .name = "gpio5",
1020 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 1017 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
1021 .mpu_irqs = omap3xxx_gpio5_irqs, 1018 .mpu_irqs = omap3xxx_gpio5_irqs,
1022 .main_clk = "gpio5_ick", 1019 .main_clk = "gpio5_ick",
1023 .opt_clks = gpio5_opt_clks, 1020 .opt_clks = gpio5_opt_clks,
1024 .opt_clks_cnt = ARRAY_SIZE(gpio5_opt_clks), 1021 .opt_clks_cnt = ARRAY_SIZE(gpio5_opt_clks),
1025 .prcm = { 1022 .prcm = {
1026 .omap2 = { 1023 .omap2 = {
1027 .prcm_reg_id = 1, 1024 .prcm_reg_id = 1,
1028 .module_bit = OMAP3430_EN_GPIO5_SHIFT, 1025 .module_bit = OMAP3430_EN_GPIO5_SHIFT,
1029 .module_offs = OMAP3430_PER_MOD, 1026 .module_offs = OMAP3430_PER_MOD,
1030 .idlest_reg_id = 1, 1027 .idlest_reg_id = 1,
1031 .idlest_idle_bit = OMAP3430_ST_GPIO5_SHIFT, 1028 .idlest_idle_bit = OMAP3430_ST_GPIO5_SHIFT,
1032 }, 1029 },
1033 }, 1030 },
1034 .class = &omap3xxx_gpio_hwmod_class, 1031 .class = &omap3xxx_gpio_hwmod_class,
1035 .dev_attr = &gpio_dev_attr, 1032 .dev_attr = &gpio_dev_attr,
1036 }; 1033 };
1037 1034
1038 /* gpio6 */ 1035 /* gpio6 */
1039 static struct omap_hwmod_irq_info omap3xxx_gpio6_irqs[] = { 1036 static struct omap_hwmod_irq_info omap3xxx_gpio6_irqs[] = {
1040 { .irq = 34 + OMAP_INTC_START, }, /* INT_34XX_GPIO_BANK6 */ 1037 { .irq = 34 + OMAP_INTC_START, }, /* INT_34XX_GPIO_BANK6 */
1041 { .irq = -1 }, 1038 { .irq = -1 },
1042 }; 1039 };
1043 1040
1044 static struct omap_hwmod_opt_clk gpio6_opt_clks[] = { 1041 static struct omap_hwmod_opt_clk gpio6_opt_clks[] = {
1045 { .role = "dbclk", .clk = "gpio6_dbck", }, 1042 { .role = "dbclk", .clk = "gpio6_dbck", },
1046 }; 1043 };
1047 1044
1048 static struct omap_hwmod omap3xxx_gpio6_hwmod = { 1045 static struct omap_hwmod omap3xxx_gpio6_hwmod = {
1049 .name = "gpio6", 1046 .name = "gpio6",
1050 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 1047 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
1051 .mpu_irqs = omap3xxx_gpio6_irqs, 1048 .mpu_irqs = omap3xxx_gpio6_irqs,
1052 .main_clk = "gpio6_ick", 1049 .main_clk = "gpio6_ick",
1053 .opt_clks = gpio6_opt_clks, 1050 .opt_clks = gpio6_opt_clks,
1054 .opt_clks_cnt = ARRAY_SIZE(gpio6_opt_clks), 1051 .opt_clks_cnt = ARRAY_SIZE(gpio6_opt_clks),
1055 .prcm = { 1052 .prcm = {
1056 .omap2 = { 1053 .omap2 = {
1057 .prcm_reg_id = 1, 1054 .prcm_reg_id = 1,
1058 .module_bit = OMAP3430_EN_GPIO6_SHIFT, 1055 .module_bit = OMAP3430_EN_GPIO6_SHIFT,
1059 .module_offs = OMAP3430_PER_MOD, 1056 .module_offs = OMAP3430_PER_MOD,
1060 .idlest_reg_id = 1, 1057 .idlest_reg_id = 1,
1061 .idlest_idle_bit = OMAP3430_ST_GPIO6_SHIFT, 1058 .idlest_idle_bit = OMAP3430_ST_GPIO6_SHIFT,
1062 }, 1059 },
1063 }, 1060 },
1064 .class = &omap3xxx_gpio_hwmod_class, 1061 .class = &omap3xxx_gpio_hwmod_class,
1065 .dev_attr = &gpio_dev_attr, 1062 .dev_attr = &gpio_dev_attr,
1066 }; 1063 };
1067 1064
1068 /* dma attributes */ 1065 /* dma attributes */
1069 static struct omap_dma_dev_attr dma_dev_attr = { 1066 static struct omap_dma_dev_attr dma_dev_attr = {
1070 .dev_caps = RESERVE_CHANNEL | DMA_LINKED_LCH | GLOBAL_PRIORITY | 1067 .dev_caps = RESERVE_CHANNEL | DMA_LINKED_LCH | GLOBAL_PRIORITY |
1071 IS_CSSA_32 | IS_CDSA_32 | IS_RW_PRIORITY, 1068 IS_CSSA_32 | IS_CDSA_32 | IS_RW_PRIORITY,
1072 .lch_count = 32, 1069 .lch_count = 32,
1073 }; 1070 };
1074 1071
1075 static struct omap_hwmod_class_sysconfig omap3xxx_dma_sysc = { 1072 static struct omap_hwmod_class_sysconfig omap3xxx_dma_sysc = {
1076 .rev_offs = 0x0000, 1073 .rev_offs = 0x0000,
1077 .sysc_offs = 0x002c, 1074 .sysc_offs = 0x002c,
1078 .syss_offs = 0x0028, 1075 .syss_offs = 0x0028,
1079 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET | 1076 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
1080 SYSC_HAS_MIDLEMODE | SYSC_HAS_CLOCKACTIVITY | 1077 SYSC_HAS_MIDLEMODE | SYSC_HAS_CLOCKACTIVITY |
1081 SYSC_HAS_EMUFREE | SYSC_HAS_AUTOIDLE | 1078 SYSC_HAS_EMUFREE | SYSC_HAS_AUTOIDLE |
1082 SYSS_HAS_RESET_STATUS), 1079 SYSS_HAS_RESET_STATUS),
1083 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1080 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1084 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART), 1081 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
1085 .sysc_fields = &omap_hwmod_sysc_type1, 1082 .sysc_fields = &omap_hwmod_sysc_type1,
1086 }; 1083 };
1087 1084
1088 static struct omap_hwmod_class omap3xxx_dma_hwmod_class = { 1085 static struct omap_hwmod_class omap3xxx_dma_hwmod_class = {
1089 .name = "dma", 1086 .name = "dma",
1090 .sysc = &omap3xxx_dma_sysc, 1087 .sysc = &omap3xxx_dma_sysc,
1091 }; 1088 };
1092 1089
1093 /* dma_system */ 1090 /* dma_system */
1094 static struct omap_hwmod omap3xxx_dma_system_hwmod = { 1091 static struct omap_hwmod omap3xxx_dma_system_hwmod = {
1095 .name = "dma", 1092 .name = "dma",
1096 .class = &omap3xxx_dma_hwmod_class, 1093 .class = &omap3xxx_dma_hwmod_class,
1097 .mpu_irqs = omap2_dma_system_irqs, 1094 .mpu_irqs = omap2_dma_system_irqs,
1098 .main_clk = "core_l3_ick", 1095 .main_clk = "core_l3_ick",
1099 .prcm = { 1096 .prcm = {
1100 .omap2 = { 1097 .omap2 = {
1101 .module_offs = CORE_MOD, 1098 .module_offs = CORE_MOD,
1102 .prcm_reg_id = 1, 1099 .prcm_reg_id = 1,
1103 .module_bit = OMAP3430_ST_SDMA_SHIFT, 1100 .module_bit = OMAP3430_ST_SDMA_SHIFT,
1104 .idlest_reg_id = 1, 1101 .idlest_reg_id = 1,
1105 .idlest_idle_bit = OMAP3430_ST_SDMA_SHIFT, 1102 .idlest_idle_bit = OMAP3430_ST_SDMA_SHIFT,
1106 }, 1103 },
1107 }, 1104 },
1108 .dev_attr = &dma_dev_attr, 1105 .dev_attr = &dma_dev_attr,
1109 .flags = HWMOD_NO_IDLEST, 1106 .flags = HWMOD_NO_IDLEST,
1110 }; 1107 };
1111 1108
1112 /* 1109 /*
1113 * 'mcbsp' class 1110 * 'mcbsp' class
1114 * multi channel buffered serial port controller 1111 * multi channel buffered serial port controller
1115 */ 1112 */
1116 1113
1117 static struct omap_hwmod_class_sysconfig omap3xxx_mcbsp_sysc = { 1114 static struct omap_hwmod_class_sysconfig omap3xxx_mcbsp_sysc = {
1118 .sysc_offs = 0x008c, 1115 .sysc_offs = 0x008c,
1119 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_ENAWAKEUP | 1116 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_ENAWAKEUP |
1120 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET), 1117 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
1121 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1118 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1122 .sysc_fields = &omap_hwmod_sysc_type1, 1119 .sysc_fields = &omap_hwmod_sysc_type1,
1123 .clockact = 0x2, 1120 .clockact = 0x2,
1124 }; 1121 };
1125 1122
1126 static struct omap_hwmod_class omap3xxx_mcbsp_hwmod_class = { 1123 static struct omap_hwmod_class omap3xxx_mcbsp_hwmod_class = {
1127 .name = "mcbsp", 1124 .name = "mcbsp",
1128 .sysc = &omap3xxx_mcbsp_sysc, 1125 .sysc = &omap3xxx_mcbsp_sysc,
1129 .rev = MCBSP_CONFIG_TYPE3, 1126 .rev = MCBSP_CONFIG_TYPE3,
1130 }; 1127 };
1131 1128
1132 /* McBSP functional clock mapping */ 1129 /* McBSP functional clock mapping */
1133 static struct omap_hwmod_opt_clk mcbsp15_opt_clks[] = { 1130 static struct omap_hwmod_opt_clk mcbsp15_opt_clks[] = {
1134 { .role = "pad_fck", .clk = "mcbsp_clks" }, 1131 { .role = "pad_fck", .clk = "mcbsp_clks" },
1135 { .role = "prcm_fck", .clk = "core_96m_fck" }, 1132 { .role = "prcm_fck", .clk = "core_96m_fck" },
1136 }; 1133 };
1137 1134
1138 static struct omap_hwmod_opt_clk mcbsp234_opt_clks[] = { 1135 static struct omap_hwmod_opt_clk mcbsp234_opt_clks[] = {
1139 { .role = "pad_fck", .clk = "mcbsp_clks" }, 1136 { .role = "pad_fck", .clk = "mcbsp_clks" },
1140 { .role = "prcm_fck", .clk = "per_96m_fck" }, 1137 { .role = "prcm_fck", .clk = "per_96m_fck" },
1141 }; 1138 };
1142 1139
1143 /* mcbsp1 */ 1140 /* mcbsp1 */
1144 static struct omap_hwmod_irq_info omap3xxx_mcbsp1_irqs[] = { 1141 static struct omap_hwmod_irq_info omap3xxx_mcbsp1_irqs[] = {
1145 { .name = "common", .irq = 16 + OMAP_INTC_START, }, 1142 { .name = "common", .irq = 16 + OMAP_INTC_START, },
1146 { .name = "tx", .irq = 59 + OMAP_INTC_START, }, 1143 { .name = "tx", .irq = 59 + OMAP_INTC_START, },
1147 { .name = "rx", .irq = 60 + OMAP_INTC_START, }, 1144 { .name = "rx", .irq = 60 + OMAP_INTC_START, },
1148 { .irq = -1 }, 1145 { .irq = -1 },
1149 }; 1146 };
1150 1147
1151 static struct omap_hwmod omap3xxx_mcbsp1_hwmod = { 1148 static struct omap_hwmod omap3xxx_mcbsp1_hwmod = {
1152 .name = "mcbsp1", 1149 .name = "mcbsp1",
1153 .class = &omap3xxx_mcbsp_hwmod_class, 1150 .class = &omap3xxx_mcbsp_hwmod_class,
1154 .mpu_irqs = omap3xxx_mcbsp1_irqs, 1151 .mpu_irqs = omap3xxx_mcbsp1_irqs,
1155 .sdma_reqs = omap2_mcbsp1_sdma_reqs, 1152 .sdma_reqs = omap2_mcbsp1_sdma_reqs,
1156 .main_clk = "mcbsp1_fck", 1153 .main_clk = "mcbsp1_fck",
1157 .prcm = { 1154 .prcm = {
1158 .omap2 = { 1155 .omap2 = {
1159 .prcm_reg_id = 1, 1156 .prcm_reg_id = 1,
1160 .module_bit = OMAP3430_EN_MCBSP1_SHIFT, 1157 .module_bit = OMAP3430_EN_MCBSP1_SHIFT,
1161 .module_offs = CORE_MOD, 1158 .module_offs = CORE_MOD,
1162 .idlest_reg_id = 1, 1159 .idlest_reg_id = 1,
1163 .idlest_idle_bit = OMAP3430_ST_MCBSP1_SHIFT, 1160 .idlest_idle_bit = OMAP3430_ST_MCBSP1_SHIFT,
1164 }, 1161 },
1165 }, 1162 },
1166 .opt_clks = mcbsp15_opt_clks, 1163 .opt_clks = mcbsp15_opt_clks,
1167 .opt_clks_cnt = ARRAY_SIZE(mcbsp15_opt_clks), 1164 .opt_clks_cnt = ARRAY_SIZE(mcbsp15_opt_clks),
1168 }; 1165 };
1169 1166
1170 /* mcbsp2 */ 1167 /* mcbsp2 */
1171 static struct omap_hwmod_irq_info omap3xxx_mcbsp2_irqs[] = { 1168 static struct omap_hwmod_irq_info omap3xxx_mcbsp2_irqs[] = {
1172 { .name = "common", .irq = 17 + OMAP_INTC_START, }, 1169 { .name = "common", .irq = 17 + OMAP_INTC_START, },
1173 { .name = "tx", .irq = 62 + OMAP_INTC_START, }, 1170 { .name = "tx", .irq = 62 + OMAP_INTC_START, },
1174 { .name = "rx", .irq = 63 + OMAP_INTC_START, }, 1171 { .name = "rx", .irq = 63 + OMAP_INTC_START, },
1175 { .irq = -1 }, 1172 { .irq = -1 },
1176 }; 1173 };
1177 1174
1178 static struct omap_mcbsp_dev_attr omap34xx_mcbsp2_dev_attr = { 1175 static struct omap_mcbsp_dev_attr omap34xx_mcbsp2_dev_attr = {
1179 .sidetone = "mcbsp2_sidetone", 1176 .sidetone = "mcbsp2_sidetone",
1180 }; 1177 };
1181 1178
1182 static struct omap_hwmod omap3xxx_mcbsp2_hwmod = { 1179 static struct omap_hwmod omap3xxx_mcbsp2_hwmod = {
1183 .name = "mcbsp2", 1180 .name = "mcbsp2",
1184 .class = &omap3xxx_mcbsp_hwmod_class, 1181 .class = &omap3xxx_mcbsp_hwmod_class,
1185 .mpu_irqs = omap3xxx_mcbsp2_irqs, 1182 .mpu_irqs = omap3xxx_mcbsp2_irqs,
1186 .sdma_reqs = omap2_mcbsp2_sdma_reqs, 1183 .sdma_reqs = omap2_mcbsp2_sdma_reqs,
1187 .main_clk = "mcbsp2_fck", 1184 .main_clk = "mcbsp2_fck",
1188 .prcm = { 1185 .prcm = {
1189 .omap2 = { 1186 .omap2 = {
1190 .prcm_reg_id = 1, 1187 .prcm_reg_id = 1,
1191 .module_bit = OMAP3430_EN_MCBSP2_SHIFT, 1188 .module_bit = OMAP3430_EN_MCBSP2_SHIFT,
1192 .module_offs = OMAP3430_PER_MOD, 1189 .module_offs = OMAP3430_PER_MOD,
1193 .idlest_reg_id = 1, 1190 .idlest_reg_id = 1,
1194 .idlest_idle_bit = OMAP3430_ST_MCBSP2_SHIFT, 1191 .idlest_idle_bit = OMAP3430_ST_MCBSP2_SHIFT,
1195 }, 1192 },
1196 }, 1193 },
1197 .opt_clks = mcbsp234_opt_clks, 1194 .opt_clks = mcbsp234_opt_clks,
1198 .opt_clks_cnt = ARRAY_SIZE(mcbsp234_opt_clks), 1195 .opt_clks_cnt = ARRAY_SIZE(mcbsp234_opt_clks),
1199 .dev_attr = &omap34xx_mcbsp2_dev_attr, 1196 .dev_attr = &omap34xx_mcbsp2_dev_attr,
1200 }; 1197 };
1201 1198
1202 /* mcbsp3 */ 1199 /* mcbsp3 */
1203 static struct omap_hwmod_irq_info omap3xxx_mcbsp3_irqs[] = { 1200 static struct omap_hwmod_irq_info omap3xxx_mcbsp3_irqs[] = {
1204 { .name = "common", .irq = 22 + OMAP_INTC_START, }, 1201 { .name = "common", .irq = 22 + OMAP_INTC_START, },
1205 { .name = "tx", .irq = 89 + OMAP_INTC_START, }, 1202 { .name = "tx", .irq = 89 + OMAP_INTC_START, },
1206 { .name = "rx", .irq = 90 + OMAP_INTC_START, }, 1203 { .name = "rx", .irq = 90 + OMAP_INTC_START, },
1207 { .irq = -1 }, 1204 { .irq = -1 },
1208 }; 1205 };
1209 1206
1210 static struct omap_mcbsp_dev_attr omap34xx_mcbsp3_dev_attr = { 1207 static struct omap_mcbsp_dev_attr omap34xx_mcbsp3_dev_attr = {
1211 .sidetone = "mcbsp3_sidetone", 1208 .sidetone = "mcbsp3_sidetone",
1212 }; 1209 };
1213 1210
1214 static struct omap_hwmod omap3xxx_mcbsp3_hwmod = { 1211 static struct omap_hwmod omap3xxx_mcbsp3_hwmod = {
1215 .name = "mcbsp3", 1212 .name = "mcbsp3",
1216 .class = &omap3xxx_mcbsp_hwmod_class, 1213 .class = &omap3xxx_mcbsp_hwmod_class,
1217 .mpu_irqs = omap3xxx_mcbsp3_irqs, 1214 .mpu_irqs = omap3xxx_mcbsp3_irqs,
1218 .sdma_reqs = omap2_mcbsp3_sdma_reqs, 1215 .sdma_reqs = omap2_mcbsp3_sdma_reqs,
1219 .main_clk = "mcbsp3_fck", 1216 .main_clk = "mcbsp3_fck",
1220 .prcm = { 1217 .prcm = {
1221 .omap2 = { 1218 .omap2 = {
1222 .prcm_reg_id = 1, 1219 .prcm_reg_id = 1,
1223 .module_bit = OMAP3430_EN_MCBSP3_SHIFT, 1220 .module_bit = OMAP3430_EN_MCBSP3_SHIFT,
1224 .module_offs = OMAP3430_PER_MOD, 1221 .module_offs = OMAP3430_PER_MOD,
1225 .idlest_reg_id = 1, 1222 .idlest_reg_id = 1,
1226 .idlest_idle_bit = OMAP3430_ST_MCBSP3_SHIFT, 1223 .idlest_idle_bit = OMAP3430_ST_MCBSP3_SHIFT,
1227 }, 1224 },
1228 }, 1225 },
1229 .opt_clks = mcbsp234_opt_clks, 1226 .opt_clks = mcbsp234_opt_clks,
1230 .opt_clks_cnt = ARRAY_SIZE(mcbsp234_opt_clks), 1227 .opt_clks_cnt = ARRAY_SIZE(mcbsp234_opt_clks),
1231 .dev_attr = &omap34xx_mcbsp3_dev_attr, 1228 .dev_attr = &omap34xx_mcbsp3_dev_attr,
1232 }; 1229 };
1233 1230
1234 /* mcbsp4 */ 1231 /* mcbsp4 */
1235 static struct omap_hwmod_irq_info omap3xxx_mcbsp4_irqs[] = { 1232 static struct omap_hwmod_irq_info omap3xxx_mcbsp4_irqs[] = {
1236 { .name = "common", .irq = 23 + OMAP_INTC_START, }, 1233 { .name = "common", .irq = 23 + OMAP_INTC_START, },
1237 { .name = "tx", .irq = 54 + OMAP_INTC_START, }, 1234 { .name = "tx", .irq = 54 + OMAP_INTC_START, },
1238 { .name = "rx", .irq = 55 + OMAP_INTC_START, }, 1235 { .name = "rx", .irq = 55 + OMAP_INTC_START, },
1239 { .irq = -1 }, 1236 { .irq = -1 },
1240 }; 1237 };
1241 1238
1242 static struct omap_hwmod_dma_info omap3xxx_mcbsp4_sdma_chs[] = { 1239 static struct omap_hwmod_dma_info omap3xxx_mcbsp4_sdma_chs[] = {
1243 { .name = "rx", .dma_req = 20 }, 1240 { .name = "rx", .dma_req = 20 },
1244 { .name = "tx", .dma_req = 19 }, 1241 { .name = "tx", .dma_req = 19 },
1245 { .dma_req = -1 } 1242 { .dma_req = -1 }
1246 }; 1243 };
1247 1244
1248 static struct omap_hwmod omap3xxx_mcbsp4_hwmod = { 1245 static struct omap_hwmod omap3xxx_mcbsp4_hwmod = {
1249 .name = "mcbsp4", 1246 .name = "mcbsp4",
1250 .class = &omap3xxx_mcbsp_hwmod_class, 1247 .class = &omap3xxx_mcbsp_hwmod_class,
1251 .mpu_irqs = omap3xxx_mcbsp4_irqs, 1248 .mpu_irqs = omap3xxx_mcbsp4_irqs,
1252 .sdma_reqs = omap3xxx_mcbsp4_sdma_chs, 1249 .sdma_reqs = omap3xxx_mcbsp4_sdma_chs,
1253 .main_clk = "mcbsp4_fck", 1250 .main_clk = "mcbsp4_fck",
1254 .prcm = { 1251 .prcm = {
1255 .omap2 = { 1252 .omap2 = {
1256 .prcm_reg_id = 1, 1253 .prcm_reg_id = 1,
1257 .module_bit = OMAP3430_EN_MCBSP4_SHIFT, 1254 .module_bit = OMAP3430_EN_MCBSP4_SHIFT,
1258 .module_offs = OMAP3430_PER_MOD, 1255 .module_offs = OMAP3430_PER_MOD,
1259 .idlest_reg_id = 1, 1256 .idlest_reg_id = 1,
1260 .idlest_idle_bit = OMAP3430_ST_MCBSP4_SHIFT, 1257 .idlest_idle_bit = OMAP3430_ST_MCBSP4_SHIFT,
1261 }, 1258 },
1262 }, 1259 },
1263 .opt_clks = mcbsp234_opt_clks, 1260 .opt_clks = mcbsp234_opt_clks,
1264 .opt_clks_cnt = ARRAY_SIZE(mcbsp234_opt_clks), 1261 .opt_clks_cnt = ARRAY_SIZE(mcbsp234_opt_clks),
1265 }; 1262 };
1266 1263
1267 /* mcbsp5 */ 1264 /* mcbsp5 */
1268 static struct omap_hwmod_irq_info omap3xxx_mcbsp5_irqs[] = { 1265 static struct omap_hwmod_irq_info omap3xxx_mcbsp5_irqs[] = {
1269 { .name = "common", .irq = 27 + OMAP_INTC_START, }, 1266 { .name = "common", .irq = 27 + OMAP_INTC_START, },
1270 { .name = "tx", .irq = 81 + OMAP_INTC_START, }, 1267 { .name = "tx", .irq = 81 + OMAP_INTC_START, },
1271 { .name = "rx", .irq = 82 + OMAP_INTC_START, }, 1268 { .name = "rx", .irq = 82 + OMAP_INTC_START, },
1272 { .irq = -1 }, 1269 { .irq = -1 },
1273 }; 1270 };
1274 1271
1275 static struct omap_hwmod_dma_info omap3xxx_mcbsp5_sdma_chs[] = { 1272 static struct omap_hwmod_dma_info omap3xxx_mcbsp5_sdma_chs[] = {
1276 { .name = "rx", .dma_req = 22 }, 1273 { .name = "rx", .dma_req = 22 },
1277 { .name = "tx", .dma_req = 21 }, 1274 { .name = "tx", .dma_req = 21 },
1278 { .dma_req = -1 } 1275 { .dma_req = -1 }
1279 }; 1276 };
1280 1277
1281 static struct omap_hwmod omap3xxx_mcbsp5_hwmod = { 1278 static struct omap_hwmod omap3xxx_mcbsp5_hwmod = {
1282 .name = "mcbsp5", 1279 .name = "mcbsp5",
1283 .class = &omap3xxx_mcbsp_hwmod_class, 1280 .class = &omap3xxx_mcbsp_hwmod_class,
1284 .mpu_irqs = omap3xxx_mcbsp5_irqs, 1281 .mpu_irqs = omap3xxx_mcbsp5_irqs,
1285 .sdma_reqs = omap3xxx_mcbsp5_sdma_chs, 1282 .sdma_reqs = omap3xxx_mcbsp5_sdma_chs,
1286 .main_clk = "mcbsp5_fck", 1283 .main_clk = "mcbsp5_fck",
1287 .prcm = { 1284 .prcm = {
1288 .omap2 = { 1285 .omap2 = {
1289 .prcm_reg_id = 1, 1286 .prcm_reg_id = 1,
1290 .module_bit = OMAP3430_EN_MCBSP5_SHIFT, 1287 .module_bit = OMAP3430_EN_MCBSP5_SHIFT,
1291 .module_offs = CORE_MOD, 1288 .module_offs = CORE_MOD,
1292 .idlest_reg_id = 1, 1289 .idlest_reg_id = 1,
1293 .idlest_idle_bit = OMAP3430_ST_MCBSP5_SHIFT, 1290 .idlest_idle_bit = OMAP3430_ST_MCBSP5_SHIFT,
1294 }, 1291 },
1295 }, 1292 },
1296 .opt_clks = mcbsp15_opt_clks, 1293 .opt_clks = mcbsp15_opt_clks,
1297 .opt_clks_cnt = ARRAY_SIZE(mcbsp15_opt_clks), 1294 .opt_clks_cnt = ARRAY_SIZE(mcbsp15_opt_clks),
1298 }; 1295 };
1299 1296
1300 /* 'mcbsp sidetone' class */ 1297 /* 'mcbsp sidetone' class */
1301 static struct omap_hwmod_class_sysconfig omap3xxx_mcbsp_sidetone_sysc = { 1298 static struct omap_hwmod_class_sysconfig omap3xxx_mcbsp_sidetone_sysc = {
1302 .sysc_offs = 0x0010, 1299 .sysc_offs = 0x0010,
1303 .sysc_flags = SYSC_HAS_AUTOIDLE, 1300 .sysc_flags = SYSC_HAS_AUTOIDLE,
1304 .sysc_fields = &omap_hwmod_sysc_type1, 1301 .sysc_fields = &omap_hwmod_sysc_type1,
1305 }; 1302 };
1306 1303
1307 static struct omap_hwmod_class omap3xxx_mcbsp_sidetone_hwmod_class = { 1304 static struct omap_hwmod_class omap3xxx_mcbsp_sidetone_hwmod_class = {
1308 .name = "mcbsp_sidetone", 1305 .name = "mcbsp_sidetone",
1309 .sysc = &omap3xxx_mcbsp_sidetone_sysc, 1306 .sysc = &omap3xxx_mcbsp_sidetone_sysc,
1310 }; 1307 };
1311 1308
1312 /* mcbsp2_sidetone */ 1309 /* mcbsp2_sidetone */
1313 static struct omap_hwmod_irq_info omap3xxx_mcbsp2_sidetone_irqs[] = { 1310 static struct omap_hwmod_irq_info omap3xxx_mcbsp2_sidetone_irqs[] = {
1314 { .name = "irq", .irq = 4 + OMAP_INTC_START, }, 1311 { .name = "irq", .irq = 4 + OMAP_INTC_START, },
1315 { .irq = -1 }, 1312 { .irq = -1 },
1316 }; 1313 };
1317 1314
1318 static struct omap_hwmod omap3xxx_mcbsp2_sidetone_hwmod = { 1315 static struct omap_hwmod omap3xxx_mcbsp2_sidetone_hwmod = {
1319 .name = "mcbsp2_sidetone", 1316 .name = "mcbsp2_sidetone",
1320 .class = &omap3xxx_mcbsp_sidetone_hwmod_class, 1317 .class = &omap3xxx_mcbsp_sidetone_hwmod_class,
1321 .mpu_irqs = omap3xxx_mcbsp2_sidetone_irqs, 1318 .mpu_irqs = omap3xxx_mcbsp2_sidetone_irqs,
1322 .main_clk = "mcbsp2_fck", 1319 .main_clk = "mcbsp2_fck",
1323 .prcm = { 1320 .prcm = {
1324 .omap2 = { 1321 .omap2 = {
1325 .prcm_reg_id = 1, 1322 .prcm_reg_id = 1,
1326 .module_bit = OMAP3430_EN_MCBSP2_SHIFT, 1323 .module_bit = OMAP3430_EN_MCBSP2_SHIFT,
1327 .module_offs = OMAP3430_PER_MOD, 1324 .module_offs = OMAP3430_PER_MOD,
1328 .idlest_reg_id = 1, 1325 .idlest_reg_id = 1,
1329 .idlest_idle_bit = OMAP3430_ST_MCBSP2_SHIFT, 1326 .idlest_idle_bit = OMAP3430_ST_MCBSP2_SHIFT,
1330 }, 1327 },
1331 }, 1328 },
1332 }; 1329 };
1333 1330
1334 /* mcbsp3_sidetone */ 1331 /* mcbsp3_sidetone */
1335 static struct omap_hwmod_irq_info omap3xxx_mcbsp3_sidetone_irqs[] = { 1332 static struct omap_hwmod_irq_info omap3xxx_mcbsp3_sidetone_irqs[] = {
1336 { .name = "irq", .irq = 5 + OMAP_INTC_START, }, 1333 { .name = "irq", .irq = 5 + OMAP_INTC_START, },
1337 { .irq = -1 }, 1334 { .irq = -1 },
1338 }; 1335 };
1339 1336
1340 static struct omap_hwmod omap3xxx_mcbsp3_sidetone_hwmod = { 1337 static struct omap_hwmod omap3xxx_mcbsp3_sidetone_hwmod = {
1341 .name = "mcbsp3_sidetone", 1338 .name = "mcbsp3_sidetone",
1342 .class = &omap3xxx_mcbsp_sidetone_hwmod_class, 1339 .class = &omap3xxx_mcbsp_sidetone_hwmod_class,
1343 .mpu_irqs = omap3xxx_mcbsp3_sidetone_irqs, 1340 .mpu_irqs = omap3xxx_mcbsp3_sidetone_irqs,
1344 .main_clk = "mcbsp3_fck", 1341 .main_clk = "mcbsp3_fck",
1345 .prcm = { 1342 .prcm = {
1346 .omap2 = { 1343 .omap2 = {
1347 .prcm_reg_id = 1, 1344 .prcm_reg_id = 1,
1348 .module_bit = OMAP3430_EN_MCBSP3_SHIFT, 1345 .module_bit = OMAP3430_EN_MCBSP3_SHIFT,
1349 .module_offs = OMAP3430_PER_MOD, 1346 .module_offs = OMAP3430_PER_MOD,
1350 .idlest_reg_id = 1, 1347 .idlest_reg_id = 1,
1351 .idlest_idle_bit = OMAP3430_ST_MCBSP3_SHIFT, 1348 .idlest_idle_bit = OMAP3430_ST_MCBSP3_SHIFT,
1352 }, 1349 },
1353 }, 1350 },
1354 }; 1351 };
1355 1352
1356 /* SR common */ 1353 /* SR common */
1357 static struct omap_hwmod_sysc_fields omap34xx_sr_sysc_fields = { 1354 static struct omap_hwmod_sysc_fields omap34xx_sr_sysc_fields = {
1358 .clkact_shift = 20, 1355 .clkact_shift = 20,
1359 }; 1356 };
1360 1357
1361 static struct omap_hwmod_class_sysconfig omap34xx_sr_sysc = { 1358 static struct omap_hwmod_class_sysconfig omap34xx_sr_sysc = {
1362 .sysc_offs = 0x24, 1359 .sysc_offs = 0x24,
1363 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_NO_CACHE), 1360 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_NO_CACHE),
1364 .clockact = CLOCKACT_TEST_ICLK, 1361 .clockact = CLOCKACT_TEST_ICLK,
1365 .sysc_fields = &omap34xx_sr_sysc_fields, 1362 .sysc_fields = &omap34xx_sr_sysc_fields,
1366 }; 1363 };
1367 1364
1368 static struct omap_hwmod_class omap34xx_smartreflex_hwmod_class = { 1365 static struct omap_hwmod_class omap34xx_smartreflex_hwmod_class = {
1369 .name = "smartreflex", 1366 .name = "smartreflex",
1370 .sysc = &omap34xx_sr_sysc, 1367 .sysc = &omap34xx_sr_sysc,
1371 .rev = 1, 1368 .rev = 1,
1372 }; 1369 };
1373 1370
1374 static struct omap_hwmod_sysc_fields omap36xx_sr_sysc_fields = { 1371 static struct omap_hwmod_sysc_fields omap36xx_sr_sysc_fields = {
1375 .sidle_shift = 24, 1372 .sidle_shift = 24,
1376 .enwkup_shift = 26, 1373 .enwkup_shift = 26,
1377 }; 1374 };
1378 1375
1379 static struct omap_hwmod_class_sysconfig omap36xx_sr_sysc = { 1376 static struct omap_hwmod_class_sysconfig omap36xx_sr_sysc = {
1380 .sysc_offs = 0x38, 1377 .sysc_offs = 0x38,
1381 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1378 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1382 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP | 1379 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP |
1383 SYSC_NO_CACHE), 1380 SYSC_NO_CACHE),
1384 .sysc_fields = &omap36xx_sr_sysc_fields, 1381 .sysc_fields = &omap36xx_sr_sysc_fields,
1385 }; 1382 };
1386 1383
1387 static struct omap_hwmod_class omap36xx_smartreflex_hwmod_class = { 1384 static struct omap_hwmod_class omap36xx_smartreflex_hwmod_class = {
1388 .name = "smartreflex", 1385 .name = "smartreflex",
1389 .sysc = &omap36xx_sr_sysc, 1386 .sysc = &omap36xx_sr_sysc,
1390 .rev = 2, 1387 .rev = 2,
1391 }; 1388 };
1392 1389
1393 /* SR1 */ 1390 /* SR1 */
1394 static struct omap_smartreflex_dev_attr sr1_dev_attr = { 1391 static struct omap_smartreflex_dev_attr sr1_dev_attr = {
1395 .sensor_voltdm_name = "mpu_iva", 1392 .sensor_voltdm_name = "mpu_iva",
1396 }; 1393 };
1397 1394
1398 static struct omap_hwmod_irq_info omap3_smartreflex_mpu_irqs[] = { 1395 static struct omap_hwmod_irq_info omap3_smartreflex_mpu_irqs[] = {
1399 { .irq = 18 + OMAP_INTC_START, }, 1396 { .irq = 18 + OMAP_INTC_START, },
1400 { .irq = -1 }, 1397 { .irq = -1 },
1401 }; 1398 };
1402 1399
1403 static struct omap_hwmod omap34xx_sr1_hwmod = { 1400 static struct omap_hwmod omap34xx_sr1_hwmod = {
1404 .name = "smartreflex_mpu_iva", 1401 .name = "smartreflex_mpu_iva",
1405 .class = &omap34xx_smartreflex_hwmod_class, 1402 .class = &omap34xx_smartreflex_hwmod_class,
1406 .main_clk = "sr1_fck", 1403 .main_clk = "sr1_fck",
1407 .prcm = { 1404 .prcm = {
1408 .omap2 = { 1405 .omap2 = {
1409 .prcm_reg_id = 1, 1406 .prcm_reg_id = 1,
1410 .module_bit = OMAP3430_EN_SR1_SHIFT, 1407 .module_bit = OMAP3430_EN_SR1_SHIFT,
1411 .module_offs = WKUP_MOD, 1408 .module_offs = WKUP_MOD,
1412 .idlest_reg_id = 1, 1409 .idlest_reg_id = 1,
1413 .idlest_idle_bit = OMAP3430_EN_SR1_SHIFT, 1410 .idlest_idle_bit = OMAP3430_EN_SR1_SHIFT,
1414 }, 1411 },
1415 }, 1412 },
1416 .dev_attr = &sr1_dev_attr, 1413 .dev_attr = &sr1_dev_attr,
1417 .mpu_irqs = omap3_smartreflex_mpu_irqs, 1414 .mpu_irqs = omap3_smartreflex_mpu_irqs,
1418 .flags = HWMOD_SET_DEFAULT_CLOCKACT, 1415 .flags = HWMOD_SET_DEFAULT_CLOCKACT,
1419 }; 1416 };
1420 1417
1421 static struct omap_hwmod omap36xx_sr1_hwmod = { 1418 static struct omap_hwmod omap36xx_sr1_hwmod = {
1422 .name = "smartreflex_mpu_iva", 1419 .name = "smartreflex_mpu_iva",
1423 .class = &omap36xx_smartreflex_hwmod_class, 1420 .class = &omap36xx_smartreflex_hwmod_class,
1424 .main_clk = "sr1_fck", 1421 .main_clk = "sr1_fck",
1425 .prcm = { 1422 .prcm = {
1426 .omap2 = { 1423 .omap2 = {
1427 .prcm_reg_id = 1, 1424 .prcm_reg_id = 1,
1428 .module_bit = OMAP3430_EN_SR1_SHIFT, 1425 .module_bit = OMAP3430_EN_SR1_SHIFT,
1429 .module_offs = WKUP_MOD, 1426 .module_offs = WKUP_MOD,
1430 .idlest_reg_id = 1, 1427 .idlest_reg_id = 1,
1431 .idlest_idle_bit = OMAP3430_EN_SR1_SHIFT, 1428 .idlest_idle_bit = OMAP3430_EN_SR1_SHIFT,
1432 }, 1429 },
1433 }, 1430 },
1434 .dev_attr = &sr1_dev_attr, 1431 .dev_attr = &sr1_dev_attr,
1435 .mpu_irqs = omap3_smartreflex_mpu_irqs, 1432 .mpu_irqs = omap3_smartreflex_mpu_irqs,
1436 }; 1433 };
1437 1434
1438 /* SR2 */ 1435 /* SR2 */
1439 static struct omap_smartreflex_dev_attr sr2_dev_attr = { 1436 static struct omap_smartreflex_dev_attr sr2_dev_attr = {
1440 .sensor_voltdm_name = "core", 1437 .sensor_voltdm_name = "core",
1441 }; 1438 };
1442 1439
1443 static struct omap_hwmod_irq_info omap3_smartreflex_core_irqs[] = { 1440 static struct omap_hwmod_irq_info omap3_smartreflex_core_irqs[] = {
1444 { .irq = 19 + OMAP_INTC_START, }, 1441 { .irq = 19 + OMAP_INTC_START, },
1445 { .irq = -1 }, 1442 { .irq = -1 },
1446 }; 1443 };
1447 1444
1448 static struct omap_hwmod omap34xx_sr2_hwmod = { 1445 static struct omap_hwmod omap34xx_sr2_hwmod = {
1449 .name = "smartreflex_core", 1446 .name = "smartreflex_core",
1450 .class = &omap34xx_smartreflex_hwmod_class, 1447 .class = &omap34xx_smartreflex_hwmod_class,
1451 .main_clk = "sr2_fck", 1448 .main_clk = "sr2_fck",
1452 .prcm = { 1449 .prcm = {
1453 .omap2 = { 1450 .omap2 = {
1454 .prcm_reg_id = 1, 1451 .prcm_reg_id = 1,
1455 .module_bit = OMAP3430_EN_SR2_SHIFT, 1452 .module_bit = OMAP3430_EN_SR2_SHIFT,
1456 .module_offs = WKUP_MOD, 1453 .module_offs = WKUP_MOD,
1457 .idlest_reg_id = 1, 1454 .idlest_reg_id = 1,
1458 .idlest_idle_bit = OMAP3430_EN_SR2_SHIFT, 1455 .idlest_idle_bit = OMAP3430_EN_SR2_SHIFT,
1459 }, 1456 },
1460 }, 1457 },
1461 .dev_attr = &sr2_dev_attr, 1458 .dev_attr = &sr2_dev_attr,
1462 .mpu_irqs = omap3_smartreflex_core_irqs, 1459 .mpu_irqs = omap3_smartreflex_core_irqs,
1463 .flags = HWMOD_SET_DEFAULT_CLOCKACT, 1460 .flags = HWMOD_SET_DEFAULT_CLOCKACT,
1464 }; 1461 };
1465 1462
1466 static struct omap_hwmod omap36xx_sr2_hwmod = { 1463 static struct omap_hwmod omap36xx_sr2_hwmod = {
1467 .name = "smartreflex_core", 1464 .name = "smartreflex_core",
1468 .class = &omap36xx_smartreflex_hwmod_class, 1465 .class = &omap36xx_smartreflex_hwmod_class,
1469 .main_clk = "sr2_fck", 1466 .main_clk = "sr2_fck",
1470 .prcm = { 1467 .prcm = {
1471 .omap2 = { 1468 .omap2 = {
1472 .prcm_reg_id = 1, 1469 .prcm_reg_id = 1,
1473 .module_bit = OMAP3430_EN_SR2_SHIFT, 1470 .module_bit = OMAP3430_EN_SR2_SHIFT,
1474 .module_offs = WKUP_MOD, 1471 .module_offs = WKUP_MOD,
1475 .idlest_reg_id = 1, 1472 .idlest_reg_id = 1,
1476 .idlest_idle_bit = OMAP3430_EN_SR2_SHIFT, 1473 .idlest_idle_bit = OMAP3430_EN_SR2_SHIFT,
1477 }, 1474 },
1478 }, 1475 },
1479 .dev_attr = &sr2_dev_attr, 1476 .dev_attr = &sr2_dev_attr,
1480 .mpu_irqs = omap3_smartreflex_core_irqs, 1477 .mpu_irqs = omap3_smartreflex_core_irqs,
1481 }; 1478 };
1482 1479
1483 /* 1480 /*
1484 * 'mailbox' class 1481 * 'mailbox' class
1485 * mailbox module allowing communication between the on-chip processors 1482 * mailbox module allowing communication between the on-chip processors
1486 * using a queued mailbox-interrupt mechanism. 1483 * using a queued mailbox-interrupt mechanism.
1487 */ 1484 */
1488 1485
1489 static struct omap_hwmod_class_sysconfig omap3xxx_mailbox_sysc = { 1486 static struct omap_hwmod_class_sysconfig omap3xxx_mailbox_sysc = {
1490 .rev_offs = 0x000, 1487 .rev_offs = 0x000,
1491 .sysc_offs = 0x010, 1488 .sysc_offs = 0x010,
1492 .syss_offs = 0x014, 1489 .syss_offs = 0x014,
1493 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 1490 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
1494 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE), 1491 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
1495 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1492 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1496 .sysc_fields = &omap_hwmod_sysc_type1, 1493 .sysc_fields = &omap_hwmod_sysc_type1,
1497 }; 1494 };
1498 1495
1499 static struct omap_hwmod_class omap3xxx_mailbox_hwmod_class = { 1496 static struct omap_hwmod_class omap3xxx_mailbox_hwmod_class = {
1500 .name = "mailbox", 1497 .name = "mailbox",
1501 .sysc = &omap3xxx_mailbox_sysc, 1498 .sysc = &omap3xxx_mailbox_sysc,
1502 }; 1499 };
1503 1500
1504 static struct omap_hwmod_irq_info omap3xxx_mailbox_irqs[] = { 1501 static struct omap_hwmod_irq_info omap3xxx_mailbox_irqs[] = {
1505 { .irq = 26 + OMAP_INTC_START, }, 1502 { .irq = 26 + OMAP_INTC_START, },
1506 { .irq = -1 }, 1503 { .irq = -1 },
1507 }; 1504 };
1508 1505
1509 static struct omap_hwmod omap3xxx_mailbox_hwmod = { 1506 static struct omap_hwmod omap3xxx_mailbox_hwmod = {
1510 .name = "mailbox", 1507 .name = "mailbox",
1511 .class = &omap3xxx_mailbox_hwmod_class, 1508 .class = &omap3xxx_mailbox_hwmod_class,
1512 .mpu_irqs = omap3xxx_mailbox_irqs, 1509 .mpu_irqs = omap3xxx_mailbox_irqs,
1513 .main_clk = "mailboxes_ick", 1510 .main_clk = "mailboxes_ick",
1514 .prcm = { 1511 .prcm = {
1515 .omap2 = { 1512 .omap2 = {
1516 .prcm_reg_id = 1, 1513 .prcm_reg_id = 1,
1517 .module_bit = OMAP3430_EN_MAILBOXES_SHIFT, 1514 .module_bit = OMAP3430_EN_MAILBOXES_SHIFT,
1518 .module_offs = CORE_MOD, 1515 .module_offs = CORE_MOD,
1519 .idlest_reg_id = 1, 1516 .idlest_reg_id = 1,
1520 .idlest_idle_bit = OMAP3430_ST_MAILBOXES_SHIFT, 1517 .idlest_idle_bit = OMAP3430_ST_MAILBOXES_SHIFT,
1521 }, 1518 },
1522 }, 1519 },
1523 }; 1520 };
1524 1521
1525 /* 1522 /*
1526 * 'mcspi' class 1523 * 'mcspi' class
1527 * multichannel serial port interface (mcspi) / master/slave synchronous serial 1524 * multichannel serial port interface (mcspi) / master/slave synchronous serial
1528 * bus 1525 * bus
1529 */ 1526 */
1530 1527
1531 static struct omap_hwmod_class_sysconfig omap34xx_mcspi_sysc = { 1528 static struct omap_hwmod_class_sysconfig omap34xx_mcspi_sysc = {
1532 .rev_offs = 0x0000, 1529 .rev_offs = 0x0000,
1533 .sysc_offs = 0x0010, 1530 .sysc_offs = 0x0010,
1534 .syss_offs = 0x0014, 1531 .syss_offs = 0x0014,
1535 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 1532 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
1536 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET | 1533 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
1537 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS), 1534 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS),
1538 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1535 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1539 .sysc_fields = &omap_hwmod_sysc_type1, 1536 .sysc_fields = &omap_hwmod_sysc_type1,
1540 }; 1537 };
1541 1538
1542 static struct omap_hwmod_class omap34xx_mcspi_class = { 1539 static struct omap_hwmod_class omap34xx_mcspi_class = {
1543 .name = "mcspi", 1540 .name = "mcspi",
1544 .sysc = &omap34xx_mcspi_sysc, 1541 .sysc = &omap34xx_mcspi_sysc,
1545 .rev = OMAP3_MCSPI_REV, 1542 .rev = OMAP3_MCSPI_REV,
1546 }; 1543 };
1547 1544
1548 /* mcspi1 */ 1545 /* mcspi1 */
1549 static struct omap2_mcspi_dev_attr omap_mcspi1_dev_attr = { 1546 static struct omap2_mcspi_dev_attr omap_mcspi1_dev_attr = {
1550 .num_chipselect = 4, 1547 .num_chipselect = 4,
1551 }; 1548 };
1552 1549
1553 static struct omap_hwmod omap34xx_mcspi1 = { 1550 static struct omap_hwmod omap34xx_mcspi1 = {
1554 .name = "mcspi1", 1551 .name = "mcspi1",
1555 .mpu_irqs = omap2_mcspi1_mpu_irqs, 1552 .mpu_irqs = omap2_mcspi1_mpu_irqs,
1556 .sdma_reqs = omap2_mcspi1_sdma_reqs, 1553 .sdma_reqs = omap2_mcspi1_sdma_reqs,
1557 .main_clk = "mcspi1_fck", 1554 .main_clk = "mcspi1_fck",
1558 .prcm = { 1555 .prcm = {
1559 .omap2 = { 1556 .omap2 = {
1560 .module_offs = CORE_MOD, 1557 .module_offs = CORE_MOD,
1561 .prcm_reg_id = 1, 1558 .prcm_reg_id = 1,
1562 .module_bit = OMAP3430_EN_MCSPI1_SHIFT, 1559 .module_bit = OMAP3430_EN_MCSPI1_SHIFT,
1563 .idlest_reg_id = 1, 1560 .idlest_reg_id = 1,
1564 .idlest_idle_bit = OMAP3430_ST_MCSPI1_SHIFT, 1561 .idlest_idle_bit = OMAP3430_ST_MCSPI1_SHIFT,
1565 }, 1562 },
1566 }, 1563 },
1567 .class = &omap34xx_mcspi_class, 1564 .class = &omap34xx_mcspi_class,
1568 .dev_attr = &omap_mcspi1_dev_attr, 1565 .dev_attr = &omap_mcspi1_dev_attr,
1569 }; 1566 };
1570 1567
1571 /* mcspi2 */ 1568 /* mcspi2 */
1572 static struct omap2_mcspi_dev_attr omap_mcspi2_dev_attr = { 1569 static struct omap2_mcspi_dev_attr omap_mcspi2_dev_attr = {
1573 .num_chipselect = 2, 1570 .num_chipselect = 2,
1574 }; 1571 };
1575 1572
1576 static struct omap_hwmod omap34xx_mcspi2 = { 1573 static struct omap_hwmod omap34xx_mcspi2 = {
1577 .name = "mcspi2", 1574 .name = "mcspi2",
1578 .mpu_irqs = omap2_mcspi2_mpu_irqs, 1575 .mpu_irqs = omap2_mcspi2_mpu_irqs,
1579 .sdma_reqs = omap2_mcspi2_sdma_reqs, 1576 .sdma_reqs = omap2_mcspi2_sdma_reqs,
1580 .main_clk = "mcspi2_fck", 1577 .main_clk = "mcspi2_fck",
1581 .prcm = { 1578 .prcm = {
1582 .omap2 = { 1579 .omap2 = {
1583 .module_offs = CORE_MOD, 1580 .module_offs = CORE_MOD,
1584 .prcm_reg_id = 1, 1581 .prcm_reg_id = 1,
1585 .module_bit = OMAP3430_EN_MCSPI2_SHIFT, 1582 .module_bit = OMAP3430_EN_MCSPI2_SHIFT,
1586 .idlest_reg_id = 1, 1583 .idlest_reg_id = 1,
1587 .idlest_idle_bit = OMAP3430_ST_MCSPI2_SHIFT, 1584 .idlest_idle_bit = OMAP3430_ST_MCSPI2_SHIFT,
1588 }, 1585 },
1589 }, 1586 },
1590 .class = &omap34xx_mcspi_class, 1587 .class = &omap34xx_mcspi_class,
1591 .dev_attr = &omap_mcspi2_dev_attr, 1588 .dev_attr = &omap_mcspi2_dev_attr,
1592 }; 1589 };
1593 1590
1594 /* mcspi3 */ 1591 /* mcspi3 */
1595 static struct omap_hwmod_irq_info omap34xx_mcspi3_mpu_irqs[] = { 1592 static struct omap_hwmod_irq_info omap34xx_mcspi3_mpu_irqs[] = {
1596 { .name = "irq", .irq = 91 + OMAP_INTC_START, }, /* 91 */ 1593 { .name = "irq", .irq = 91 + OMAP_INTC_START, }, /* 91 */
1597 { .irq = -1 }, 1594 { .irq = -1 },
1598 }; 1595 };
1599 1596
1600 static struct omap_hwmod_dma_info omap34xx_mcspi3_sdma_reqs[] = { 1597 static struct omap_hwmod_dma_info omap34xx_mcspi3_sdma_reqs[] = {
1601 { .name = "tx0", .dma_req = 15 }, 1598 { .name = "tx0", .dma_req = 15 },
1602 { .name = "rx0", .dma_req = 16 }, 1599 { .name = "rx0", .dma_req = 16 },
1603 { .name = "tx1", .dma_req = 23 }, 1600 { .name = "tx1", .dma_req = 23 },
1604 { .name = "rx1", .dma_req = 24 }, 1601 { .name = "rx1", .dma_req = 24 },
1605 { .dma_req = -1 } 1602 { .dma_req = -1 }
1606 }; 1603 };
1607 1604
1608 static struct omap2_mcspi_dev_attr omap_mcspi3_dev_attr = { 1605 static struct omap2_mcspi_dev_attr omap_mcspi3_dev_attr = {
1609 .num_chipselect = 2, 1606 .num_chipselect = 2,
1610 }; 1607 };
1611 1608
1612 static struct omap_hwmod omap34xx_mcspi3 = { 1609 static struct omap_hwmod omap34xx_mcspi3 = {
1613 .name = "mcspi3", 1610 .name = "mcspi3",
1614 .mpu_irqs = omap34xx_mcspi3_mpu_irqs, 1611 .mpu_irqs = omap34xx_mcspi3_mpu_irqs,
1615 .sdma_reqs = omap34xx_mcspi3_sdma_reqs, 1612 .sdma_reqs = omap34xx_mcspi3_sdma_reqs,
1616 .main_clk = "mcspi3_fck", 1613 .main_clk = "mcspi3_fck",
1617 .prcm = { 1614 .prcm = {
1618 .omap2 = { 1615 .omap2 = {
1619 .module_offs = CORE_MOD, 1616 .module_offs = CORE_MOD,
1620 .prcm_reg_id = 1, 1617 .prcm_reg_id = 1,
1621 .module_bit = OMAP3430_EN_MCSPI3_SHIFT, 1618 .module_bit = OMAP3430_EN_MCSPI3_SHIFT,
1622 .idlest_reg_id = 1, 1619 .idlest_reg_id = 1,
1623 .idlest_idle_bit = OMAP3430_ST_MCSPI3_SHIFT, 1620 .idlest_idle_bit = OMAP3430_ST_MCSPI3_SHIFT,
1624 }, 1621 },
1625 }, 1622 },
1626 .class = &omap34xx_mcspi_class, 1623 .class = &omap34xx_mcspi_class,
1627 .dev_attr = &omap_mcspi3_dev_attr, 1624 .dev_attr = &omap_mcspi3_dev_attr,
1628 }; 1625 };
1629 1626
1630 /* mcspi4 */ 1627 /* mcspi4 */
1631 static struct omap_hwmod_irq_info omap34xx_mcspi4_mpu_irqs[] = { 1628 static struct omap_hwmod_irq_info omap34xx_mcspi4_mpu_irqs[] = {
1632 { .name = "irq", .irq = 48 + OMAP_INTC_START, }, 1629 { .name = "irq", .irq = 48 + OMAP_INTC_START, },
1633 { .irq = -1 }, 1630 { .irq = -1 },
1634 }; 1631 };
1635 1632
1636 static struct omap_hwmod_dma_info omap34xx_mcspi4_sdma_reqs[] = { 1633 static struct omap_hwmod_dma_info omap34xx_mcspi4_sdma_reqs[] = {
1637 { .name = "tx0", .dma_req = 70 }, /* DMA_SPI4_TX0 */ 1634 { .name = "tx0", .dma_req = 70 }, /* DMA_SPI4_TX0 */
1638 { .name = "rx0", .dma_req = 71 }, /* DMA_SPI4_RX0 */ 1635 { .name = "rx0", .dma_req = 71 }, /* DMA_SPI4_RX0 */
1639 { .dma_req = -1 } 1636 { .dma_req = -1 }
1640 }; 1637 };
1641 1638
1642 static struct omap2_mcspi_dev_attr omap_mcspi4_dev_attr = { 1639 static struct omap2_mcspi_dev_attr omap_mcspi4_dev_attr = {
1643 .num_chipselect = 1, 1640 .num_chipselect = 1,
1644 }; 1641 };
1645 1642
1646 static struct omap_hwmod omap34xx_mcspi4 = { 1643 static struct omap_hwmod omap34xx_mcspi4 = {
1647 .name = "mcspi4", 1644 .name = "mcspi4",
1648 .mpu_irqs = omap34xx_mcspi4_mpu_irqs, 1645 .mpu_irqs = omap34xx_mcspi4_mpu_irqs,
1649 .sdma_reqs = omap34xx_mcspi4_sdma_reqs, 1646 .sdma_reqs = omap34xx_mcspi4_sdma_reqs,
1650 .main_clk = "mcspi4_fck", 1647 .main_clk = "mcspi4_fck",
1651 .prcm = { 1648 .prcm = {
1652 .omap2 = { 1649 .omap2 = {
1653 .module_offs = CORE_MOD, 1650 .module_offs = CORE_MOD,
1654 .prcm_reg_id = 1, 1651 .prcm_reg_id = 1,
1655 .module_bit = OMAP3430_EN_MCSPI4_SHIFT, 1652 .module_bit = OMAP3430_EN_MCSPI4_SHIFT,
1656 .idlest_reg_id = 1, 1653 .idlest_reg_id = 1,
1657 .idlest_idle_bit = OMAP3430_ST_MCSPI4_SHIFT, 1654 .idlest_idle_bit = OMAP3430_ST_MCSPI4_SHIFT,
1658 }, 1655 },
1659 }, 1656 },
1660 .class = &omap34xx_mcspi_class, 1657 .class = &omap34xx_mcspi_class,
1661 .dev_attr = &omap_mcspi4_dev_attr, 1658 .dev_attr = &omap_mcspi4_dev_attr,
1662 }; 1659 };
1663 1660
1664 /* usbhsotg */ 1661 /* usbhsotg */
1665 static struct omap_hwmod_class_sysconfig omap3xxx_usbhsotg_sysc = { 1662 static struct omap_hwmod_class_sysconfig omap3xxx_usbhsotg_sysc = {
1666 .rev_offs = 0x0400, 1663 .rev_offs = 0x0400,
1667 .sysc_offs = 0x0404, 1664 .sysc_offs = 0x0404,
1668 .syss_offs = 0x0408, 1665 .syss_offs = 0x0408,
1669 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE| 1666 .sysc_flags = (SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE|
1670 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET | 1667 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
1671 SYSC_HAS_AUTOIDLE), 1668 SYSC_HAS_AUTOIDLE),
1672 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1669 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1673 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART), 1670 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
1674 .sysc_fields = &omap_hwmod_sysc_type1, 1671 .sysc_fields = &omap_hwmod_sysc_type1,
1675 }; 1672 };
1676 1673
1677 static struct omap_hwmod_class usbotg_class = { 1674 static struct omap_hwmod_class usbotg_class = {
1678 .name = "usbotg", 1675 .name = "usbotg",
1679 .sysc = &omap3xxx_usbhsotg_sysc, 1676 .sysc = &omap3xxx_usbhsotg_sysc,
1680 }; 1677 };
1681 1678
1682 /* usb_otg_hs */ 1679 /* usb_otg_hs */
1683 static struct omap_hwmod_irq_info omap3xxx_usbhsotg_mpu_irqs[] = { 1680 static struct omap_hwmod_irq_info omap3xxx_usbhsotg_mpu_irqs[] = {
1684 1681
1685 { .name = "mc", .irq = 92 + OMAP_INTC_START, }, 1682 { .name = "mc", .irq = 92 + OMAP_INTC_START, },
1686 { .name = "dma", .irq = 93 + OMAP_INTC_START, }, 1683 { .name = "dma", .irq = 93 + OMAP_INTC_START, },
1687 { .irq = -1 }, 1684 { .irq = -1 },
1688 }; 1685 };
1689 1686
1690 static struct omap_hwmod omap3xxx_usbhsotg_hwmod = { 1687 static struct omap_hwmod omap3xxx_usbhsotg_hwmod = {
1691 .name = "usb_otg_hs", 1688 .name = "usb_otg_hs",
1692 .mpu_irqs = omap3xxx_usbhsotg_mpu_irqs, 1689 .mpu_irqs = omap3xxx_usbhsotg_mpu_irqs,
1693 .main_clk = "hsotgusb_ick", 1690 .main_clk = "hsotgusb_ick",
1694 .prcm = { 1691 .prcm = {
1695 .omap2 = { 1692 .omap2 = {
1696 .prcm_reg_id = 1, 1693 .prcm_reg_id = 1,
1697 .module_bit = OMAP3430_EN_HSOTGUSB_SHIFT, 1694 .module_bit = OMAP3430_EN_HSOTGUSB_SHIFT,
1698 .module_offs = CORE_MOD, 1695 .module_offs = CORE_MOD,
1699 .idlest_reg_id = 1, 1696 .idlest_reg_id = 1,
1700 .idlest_idle_bit = OMAP3430ES2_ST_HSOTGUSB_IDLE_SHIFT, 1697 .idlest_idle_bit = OMAP3430ES2_ST_HSOTGUSB_IDLE_SHIFT,
1701 .idlest_stdby_bit = OMAP3430ES2_ST_HSOTGUSB_STDBY_SHIFT 1698 .idlest_stdby_bit = OMAP3430ES2_ST_HSOTGUSB_STDBY_SHIFT
1702 }, 1699 },
1703 }, 1700 },
1704 .class = &usbotg_class, 1701 .class = &usbotg_class,
1705 1702
1706 /* 1703 /*
1707 * Erratum ID: i479 idle_req / idle_ack mechanism potentially 1704 * Erratum ID: i479 idle_req / idle_ack mechanism potentially
1708 * broken when autoidle is enabled 1705 * broken when autoidle is enabled
1709 * workaround is to disable the autoidle bit at module level. 1706 * workaround is to disable the autoidle bit at module level.
1710 */ 1707 */
1711 .flags = HWMOD_NO_OCP_AUTOIDLE | HWMOD_SWSUP_SIDLE 1708 .flags = HWMOD_NO_OCP_AUTOIDLE | HWMOD_SWSUP_SIDLE
1712 | HWMOD_SWSUP_MSTANDBY, 1709 | HWMOD_SWSUP_MSTANDBY,
1713 }; 1710 };
1714 1711
1715 /* usb_otg_hs */ 1712 /* usb_otg_hs */
1716 static struct omap_hwmod_irq_info am35xx_usbhsotg_mpu_irqs[] = { 1713 static struct omap_hwmod_irq_info am35xx_usbhsotg_mpu_irqs[] = {
1717 { .name = "mc", .irq = 71 + OMAP_INTC_START, }, 1714 { .name = "mc", .irq = 71 + OMAP_INTC_START, },
1718 { .irq = -1 }, 1715 { .irq = -1 },
1719 }; 1716 };
1720 1717
1721 static struct omap_hwmod_class am35xx_usbotg_class = { 1718 static struct omap_hwmod_class am35xx_usbotg_class = {
1722 .name = "am35xx_usbotg", 1719 .name = "am35xx_usbotg",
1723 }; 1720 };
1724 1721
1725 static struct omap_hwmod am35xx_usbhsotg_hwmod = { 1722 static struct omap_hwmod am35xx_usbhsotg_hwmod = {
1726 .name = "am35x_otg_hs", 1723 .name = "am35x_otg_hs",
1727 .mpu_irqs = am35xx_usbhsotg_mpu_irqs, 1724 .mpu_irqs = am35xx_usbhsotg_mpu_irqs,
1728 .main_clk = "hsotgusb_fck", 1725 .main_clk = "hsotgusb_fck",
1729 .class = &am35xx_usbotg_class, 1726 .class = &am35xx_usbotg_class,
1730 .flags = HWMOD_NO_IDLEST, 1727 .flags = HWMOD_NO_IDLEST,
1731 }; 1728 };
1732 1729
1733 /* MMC/SD/SDIO common */ 1730 /* MMC/SD/SDIO common */
1734 static struct omap_hwmod_class_sysconfig omap34xx_mmc_sysc = { 1731 static struct omap_hwmod_class_sysconfig omap34xx_mmc_sysc = {
1735 .rev_offs = 0x1fc, 1732 .rev_offs = 0x1fc,
1736 .sysc_offs = 0x10, 1733 .sysc_offs = 0x10,
1737 .syss_offs = 0x14, 1734 .syss_offs = 0x14,
1738 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 1735 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
1739 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET | 1736 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
1740 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS), 1737 SYSC_HAS_AUTOIDLE | SYSS_HAS_RESET_STATUS),
1741 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1738 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1742 .sysc_fields = &omap_hwmod_sysc_type1, 1739 .sysc_fields = &omap_hwmod_sysc_type1,
1743 }; 1740 };
1744 1741
1745 static struct omap_hwmod_class omap34xx_mmc_class = { 1742 static struct omap_hwmod_class omap34xx_mmc_class = {
1746 .name = "mmc", 1743 .name = "mmc",
1747 .sysc = &omap34xx_mmc_sysc, 1744 .sysc = &omap34xx_mmc_sysc,
1748 }; 1745 };
1749 1746
1750 /* MMC/SD/SDIO1 */ 1747 /* MMC/SD/SDIO1 */
1751 1748
1752 static struct omap_hwmod_irq_info omap34xx_mmc1_mpu_irqs[] = { 1749 static struct omap_hwmod_irq_info omap34xx_mmc1_mpu_irqs[] = {
1753 { .irq = 83 + OMAP_INTC_START, }, 1750 { .irq = 83 + OMAP_INTC_START, },
1754 { .irq = -1 }, 1751 { .irq = -1 },
1755 }; 1752 };
1756 1753
1757 static struct omap_hwmod_dma_info omap34xx_mmc1_sdma_reqs[] = { 1754 static struct omap_hwmod_dma_info omap34xx_mmc1_sdma_reqs[] = {
1758 { .name = "tx", .dma_req = 61, }, 1755 { .name = "tx", .dma_req = 61, },
1759 { .name = "rx", .dma_req = 62, }, 1756 { .name = "rx", .dma_req = 62, },
1760 { .dma_req = -1 } 1757 { .dma_req = -1 }
1761 }; 1758 };
1762 1759
1763 static struct omap_hwmod_opt_clk omap34xx_mmc1_opt_clks[] = { 1760 static struct omap_hwmod_opt_clk omap34xx_mmc1_opt_clks[] = {
1764 { .role = "dbck", .clk = "omap_32k_fck", }, 1761 { .role = "dbck", .clk = "omap_32k_fck", },
1765 }; 1762 };
1766 1763
1767 static struct omap_mmc_dev_attr mmc1_dev_attr = { 1764 static struct omap_mmc_dev_attr mmc1_dev_attr = {
1768 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT, 1765 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
1769 }; 1766 };
1770 1767
1771 /* See 35xx errata 2.1.1.128 in SPRZ278F */ 1768 /* See 35xx errata 2.1.1.128 in SPRZ278F */
1772 static struct omap_mmc_dev_attr mmc1_pre_es3_dev_attr = { 1769 static struct omap_mmc_dev_attr mmc1_pre_es3_dev_attr = {
1773 .flags = (OMAP_HSMMC_SUPPORTS_DUAL_VOLT | 1770 .flags = (OMAP_HSMMC_SUPPORTS_DUAL_VOLT |
1774 OMAP_HSMMC_BROKEN_MULTIBLOCK_READ), 1771 OMAP_HSMMC_BROKEN_MULTIBLOCK_READ),
1775 }; 1772 };
1776 1773
1777 static struct omap_hwmod omap3xxx_pre_es3_mmc1_hwmod = { 1774 static struct omap_hwmod omap3xxx_pre_es3_mmc1_hwmod = {
1778 .name = "mmc1", 1775 .name = "mmc1",
1779 .mpu_irqs = omap34xx_mmc1_mpu_irqs, 1776 .mpu_irqs = omap34xx_mmc1_mpu_irqs,
1780 .sdma_reqs = omap34xx_mmc1_sdma_reqs, 1777 .sdma_reqs = omap34xx_mmc1_sdma_reqs,
1781 .opt_clks = omap34xx_mmc1_opt_clks, 1778 .opt_clks = omap34xx_mmc1_opt_clks,
1782 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc1_opt_clks), 1779 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc1_opt_clks),
1783 .main_clk = "mmchs1_fck", 1780 .main_clk = "mmchs1_fck",
1784 .prcm = { 1781 .prcm = {
1785 .omap2 = { 1782 .omap2 = {
1786 .module_offs = CORE_MOD, 1783 .module_offs = CORE_MOD,
1787 .prcm_reg_id = 1, 1784 .prcm_reg_id = 1,
1788 .module_bit = OMAP3430_EN_MMC1_SHIFT, 1785 .module_bit = OMAP3430_EN_MMC1_SHIFT,
1789 .idlest_reg_id = 1, 1786 .idlest_reg_id = 1,
1790 .idlest_idle_bit = OMAP3430_ST_MMC1_SHIFT, 1787 .idlest_idle_bit = OMAP3430_ST_MMC1_SHIFT,
1791 }, 1788 },
1792 }, 1789 },
1793 .dev_attr = &mmc1_pre_es3_dev_attr, 1790 .dev_attr = &mmc1_pre_es3_dev_attr,
1794 .class = &omap34xx_mmc_class, 1791 .class = &omap34xx_mmc_class,
1795 }; 1792 };
1796 1793
1797 static struct omap_hwmod omap3xxx_es3plus_mmc1_hwmod = { 1794 static struct omap_hwmod omap3xxx_es3plus_mmc1_hwmod = {
1798 .name = "mmc1", 1795 .name = "mmc1",
1799 .mpu_irqs = omap34xx_mmc1_mpu_irqs, 1796 .mpu_irqs = omap34xx_mmc1_mpu_irqs,
1800 .sdma_reqs = omap34xx_mmc1_sdma_reqs, 1797 .sdma_reqs = omap34xx_mmc1_sdma_reqs,
1801 .opt_clks = omap34xx_mmc1_opt_clks, 1798 .opt_clks = omap34xx_mmc1_opt_clks,
1802 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc1_opt_clks), 1799 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc1_opt_clks),
1803 .main_clk = "mmchs1_fck", 1800 .main_clk = "mmchs1_fck",
1804 .prcm = { 1801 .prcm = {
1805 .omap2 = { 1802 .omap2 = {
1806 .module_offs = CORE_MOD, 1803 .module_offs = CORE_MOD,
1807 .prcm_reg_id = 1, 1804 .prcm_reg_id = 1,
1808 .module_bit = OMAP3430_EN_MMC1_SHIFT, 1805 .module_bit = OMAP3430_EN_MMC1_SHIFT,
1809 .idlest_reg_id = 1, 1806 .idlest_reg_id = 1,
1810 .idlest_idle_bit = OMAP3430_ST_MMC1_SHIFT, 1807 .idlest_idle_bit = OMAP3430_ST_MMC1_SHIFT,
1811 }, 1808 },
1812 }, 1809 },
1813 .dev_attr = &mmc1_dev_attr, 1810 .dev_attr = &mmc1_dev_attr,
1814 .class = &omap34xx_mmc_class, 1811 .class = &omap34xx_mmc_class,
1815 }; 1812 };
1816 1813
1817 /* MMC/SD/SDIO2 */ 1814 /* MMC/SD/SDIO2 */
1818 1815
1819 static struct omap_hwmod_irq_info omap34xx_mmc2_mpu_irqs[] = { 1816 static struct omap_hwmod_irq_info omap34xx_mmc2_mpu_irqs[] = {
1820 { .irq = 86 + OMAP_INTC_START, }, 1817 { .irq = 86 + OMAP_INTC_START, },
1821 { .irq = -1 }, 1818 { .irq = -1 },
1822 }; 1819 };
1823 1820
1824 static struct omap_hwmod_dma_info omap34xx_mmc2_sdma_reqs[] = { 1821 static struct omap_hwmod_dma_info omap34xx_mmc2_sdma_reqs[] = {
1825 { .name = "tx", .dma_req = 47, }, 1822 { .name = "tx", .dma_req = 47, },
1826 { .name = "rx", .dma_req = 48, }, 1823 { .name = "rx", .dma_req = 48, },
1827 { .dma_req = -1 } 1824 { .dma_req = -1 }
1828 }; 1825 };
1829 1826
1830 static struct omap_hwmod_opt_clk omap34xx_mmc2_opt_clks[] = { 1827 static struct omap_hwmod_opt_clk omap34xx_mmc2_opt_clks[] = {
1831 { .role = "dbck", .clk = "omap_32k_fck", }, 1828 { .role = "dbck", .clk = "omap_32k_fck", },
1832 }; 1829 };
1833 1830
1834 /* See 35xx errata 2.1.1.128 in SPRZ278F */ 1831 /* See 35xx errata 2.1.1.128 in SPRZ278F */
1835 static struct omap_mmc_dev_attr mmc2_pre_es3_dev_attr = { 1832 static struct omap_mmc_dev_attr mmc2_pre_es3_dev_attr = {
1836 .flags = OMAP_HSMMC_BROKEN_MULTIBLOCK_READ, 1833 .flags = OMAP_HSMMC_BROKEN_MULTIBLOCK_READ,
1837 }; 1834 };
1838 1835
1839 static struct omap_hwmod omap3xxx_pre_es3_mmc2_hwmod = { 1836 static struct omap_hwmod omap3xxx_pre_es3_mmc2_hwmod = {
1840 .name = "mmc2", 1837 .name = "mmc2",
1841 .mpu_irqs = omap34xx_mmc2_mpu_irqs, 1838 .mpu_irqs = omap34xx_mmc2_mpu_irqs,
1842 .sdma_reqs = omap34xx_mmc2_sdma_reqs, 1839 .sdma_reqs = omap34xx_mmc2_sdma_reqs,
1843 .opt_clks = omap34xx_mmc2_opt_clks, 1840 .opt_clks = omap34xx_mmc2_opt_clks,
1844 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc2_opt_clks), 1841 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc2_opt_clks),
1845 .main_clk = "mmchs2_fck", 1842 .main_clk = "mmchs2_fck",
1846 .prcm = { 1843 .prcm = {
1847 .omap2 = { 1844 .omap2 = {
1848 .module_offs = CORE_MOD, 1845 .module_offs = CORE_MOD,
1849 .prcm_reg_id = 1, 1846 .prcm_reg_id = 1,
1850 .module_bit = OMAP3430_EN_MMC2_SHIFT, 1847 .module_bit = OMAP3430_EN_MMC2_SHIFT,
1851 .idlest_reg_id = 1, 1848 .idlest_reg_id = 1,
1852 .idlest_idle_bit = OMAP3430_ST_MMC2_SHIFT, 1849 .idlest_idle_bit = OMAP3430_ST_MMC2_SHIFT,
1853 }, 1850 },
1854 }, 1851 },
1855 .dev_attr = &mmc2_pre_es3_dev_attr, 1852 .dev_attr = &mmc2_pre_es3_dev_attr,
1856 .class = &omap34xx_mmc_class, 1853 .class = &omap34xx_mmc_class,
1857 }; 1854 };
1858 1855
1859 static struct omap_hwmod omap3xxx_es3plus_mmc2_hwmod = { 1856 static struct omap_hwmod omap3xxx_es3plus_mmc2_hwmod = {
1860 .name = "mmc2", 1857 .name = "mmc2",
1861 .mpu_irqs = omap34xx_mmc2_mpu_irqs, 1858 .mpu_irqs = omap34xx_mmc2_mpu_irqs,
1862 .sdma_reqs = omap34xx_mmc2_sdma_reqs, 1859 .sdma_reqs = omap34xx_mmc2_sdma_reqs,
1863 .opt_clks = omap34xx_mmc2_opt_clks, 1860 .opt_clks = omap34xx_mmc2_opt_clks,
1864 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc2_opt_clks), 1861 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc2_opt_clks),
1865 .main_clk = "mmchs2_fck", 1862 .main_clk = "mmchs2_fck",
1866 .prcm = { 1863 .prcm = {
1867 .omap2 = { 1864 .omap2 = {
1868 .module_offs = CORE_MOD, 1865 .module_offs = CORE_MOD,
1869 .prcm_reg_id = 1, 1866 .prcm_reg_id = 1,
1870 .module_bit = OMAP3430_EN_MMC2_SHIFT, 1867 .module_bit = OMAP3430_EN_MMC2_SHIFT,
1871 .idlest_reg_id = 1, 1868 .idlest_reg_id = 1,
1872 .idlest_idle_bit = OMAP3430_ST_MMC2_SHIFT, 1869 .idlest_idle_bit = OMAP3430_ST_MMC2_SHIFT,
1873 }, 1870 },
1874 }, 1871 },
1875 .class = &omap34xx_mmc_class, 1872 .class = &omap34xx_mmc_class,
1876 }; 1873 };
1877 1874
1878 /* MMC/SD/SDIO3 */ 1875 /* MMC/SD/SDIO3 */
1879 1876
1880 static struct omap_hwmod_irq_info omap34xx_mmc3_mpu_irqs[] = { 1877 static struct omap_hwmod_irq_info omap34xx_mmc3_mpu_irqs[] = {
1881 { .irq = 94 + OMAP_INTC_START, }, 1878 { .irq = 94 + OMAP_INTC_START, },
1882 { .irq = -1 }, 1879 { .irq = -1 },
1883 }; 1880 };
1884 1881
1885 static struct omap_hwmod_dma_info omap34xx_mmc3_sdma_reqs[] = { 1882 static struct omap_hwmod_dma_info omap34xx_mmc3_sdma_reqs[] = {
1886 { .name = "tx", .dma_req = 77, }, 1883 { .name = "tx", .dma_req = 77, },
1887 { .name = "rx", .dma_req = 78, }, 1884 { .name = "rx", .dma_req = 78, },
1888 { .dma_req = -1 } 1885 { .dma_req = -1 }
1889 }; 1886 };
1890 1887
1891 static struct omap_hwmod_opt_clk omap34xx_mmc3_opt_clks[] = { 1888 static struct omap_hwmod_opt_clk omap34xx_mmc3_opt_clks[] = {
1892 { .role = "dbck", .clk = "omap_32k_fck", }, 1889 { .role = "dbck", .clk = "omap_32k_fck", },
1893 }; 1890 };
1894 1891
1895 static struct omap_hwmod omap3xxx_mmc3_hwmod = { 1892 static struct omap_hwmod omap3xxx_mmc3_hwmod = {
1896 .name = "mmc3", 1893 .name = "mmc3",
1897 .mpu_irqs = omap34xx_mmc3_mpu_irqs, 1894 .mpu_irqs = omap34xx_mmc3_mpu_irqs,
1898 .sdma_reqs = omap34xx_mmc3_sdma_reqs, 1895 .sdma_reqs = omap34xx_mmc3_sdma_reqs,
1899 .opt_clks = omap34xx_mmc3_opt_clks, 1896 .opt_clks = omap34xx_mmc3_opt_clks,
1900 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc3_opt_clks), 1897 .opt_clks_cnt = ARRAY_SIZE(omap34xx_mmc3_opt_clks),
1901 .main_clk = "mmchs3_fck", 1898 .main_clk = "mmchs3_fck",
1902 .prcm = { 1899 .prcm = {
1903 .omap2 = { 1900 .omap2 = {
1904 .prcm_reg_id = 1, 1901 .prcm_reg_id = 1,
1905 .module_bit = OMAP3430_EN_MMC3_SHIFT, 1902 .module_bit = OMAP3430_EN_MMC3_SHIFT,
1906 .idlest_reg_id = 1, 1903 .idlest_reg_id = 1,
1907 .idlest_idle_bit = OMAP3430_ST_MMC3_SHIFT, 1904 .idlest_idle_bit = OMAP3430_ST_MMC3_SHIFT,
1908 }, 1905 },
1909 }, 1906 },
1910 .class = &omap34xx_mmc_class, 1907 .class = &omap34xx_mmc_class,
1911 }; 1908 };
1912 1909
1913 /* 1910 /*
1914 * 'usb_host_hs' class 1911 * 'usb_host_hs' class
1915 * high-speed multi-port usb host controller 1912 * high-speed multi-port usb host controller
1916 */ 1913 */
1917 1914
1918 static struct omap_hwmod_class_sysconfig omap3xxx_usb_host_hs_sysc = { 1915 static struct omap_hwmod_class_sysconfig omap3xxx_usb_host_hs_sysc = {
1919 .rev_offs = 0x0000, 1916 .rev_offs = 0x0000,
1920 .sysc_offs = 0x0010, 1917 .sysc_offs = 0x0010,
1921 .syss_offs = 0x0014, 1918 .syss_offs = 0x0014,
1922 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_CLOCKACTIVITY | 1919 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_CLOCKACTIVITY |
1923 SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP | 1920 SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP |
1924 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE), 1921 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
1925 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1922 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1926 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART), 1923 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
1927 .sysc_fields = &omap_hwmod_sysc_type1, 1924 .sysc_fields = &omap_hwmod_sysc_type1,
1928 }; 1925 };
1929 1926
1930 static struct omap_hwmod_class omap3xxx_usb_host_hs_hwmod_class = { 1927 static struct omap_hwmod_class omap3xxx_usb_host_hs_hwmod_class = {
1931 .name = "usb_host_hs", 1928 .name = "usb_host_hs",
1932 .sysc = &omap3xxx_usb_host_hs_sysc, 1929 .sysc = &omap3xxx_usb_host_hs_sysc,
1933 }; 1930 };
1934 1931
1935 static struct omap_hwmod_opt_clk omap3xxx_usb_host_hs_opt_clks[] = { 1932 static struct omap_hwmod_opt_clk omap3xxx_usb_host_hs_opt_clks[] = {
1936 { .role = "ehci_logic_fck", .clk = "usbhost_120m_fck", }, 1933 { .role = "ehci_logic_fck", .clk = "usbhost_120m_fck", },
1937 }; 1934 };
1938 1935
1939 static struct omap_hwmod_irq_info omap3xxx_usb_host_hs_irqs[] = { 1936 static struct omap_hwmod_irq_info omap3xxx_usb_host_hs_irqs[] = {
1940 { .name = "ohci-irq", .irq = 76 + OMAP_INTC_START, }, 1937 { .name = "ohci-irq", .irq = 76 + OMAP_INTC_START, },
1941 { .name = "ehci-irq", .irq = 77 + OMAP_INTC_START, }, 1938 { .name = "ehci-irq", .irq = 77 + OMAP_INTC_START, },
1942 { .irq = -1 }, 1939 { .irq = -1 },
1943 }; 1940 };
1944 1941
1945 static struct omap_hwmod omap3xxx_usb_host_hs_hwmod = { 1942 static struct omap_hwmod omap3xxx_usb_host_hs_hwmod = {
1946 .name = "usb_host_hs", 1943 .name = "usb_host_hs",
1947 .class = &omap3xxx_usb_host_hs_hwmod_class, 1944 .class = &omap3xxx_usb_host_hs_hwmod_class,
1948 .clkdm_name = "l3_init_clkdm", 1945 .clkdm_name = "l3_init_clkdm",
1949 .mpu_irqs = omap3xxx_usb_host_hs_irqs, 1946 .mpu_irqs = omap3xxx_usb_host_hs_irqs,
1950 .main_clk = "usbhost_48m_fck", 1947 .main_clk = "usbhost_48m_fck",
1951 .prcm = { 1948 .prcm = {
1952 .omap2 = { 1949 .omap2 = {
1953 .module_offs = OMAP3430ES2_USBHOST_MOD, 1950 .module_offs = OMAP3430ES2_USBHOST_MOD,
1954 .prcm_reg_id = 1, 1951 .prcm_reg_id = 1,
1955 .module_bit = OMAP3430ES2_EN_USBHOST1_SHIFT, 1952 .module_bit = OMAP3430ES2_EN_USBHOST1_SHIFT,
1956 .idlest_reg_id = 1, 1953 .idlest_reg_id = 1,
1957 .idlest_idle_bit = OMAP3430ES2_ST_USBHOST_IDLE_SHIFT, 1954 .idlest_idle_bit = OMAP3430ES2_ST_USBHOST_IDLE_SHIFT,
1958 .idlest_stdby_bit = OMAP3430ES2_ST_USBHOST_STDBY_SHIFT, 1955 .idlest_stdby_bit = OMAP3430ES2_ST_USBHOST_STDBY_SHIFT,
1959 }, 1956 },
1960 }, 1957 },
1961 .opt_clks = omap3xxx_usb_host_hs_opt_clks, 1958 .opt_clks = omap3xxx_usb_host_hs_opt_clks,
1962 .opt_clks_cnt = ARRAY_SIZE(omap3xxx_usb_host_hs_opt_clks), 1959 .opt_clks_cnt = ARRAY_SIZE(omap3xxx_usb_host_hs_opt_clks),
1963 1960
1964 /* 1961 /*
1965 * Errata: USBHOST Configured In Smart-Idle Can Lead To a Deadlock 1962 * Errata: USBHOST Configured In Smart-Idle Can Lead To a Deadlock
1966 * id: i660 1963 * id: i660
1967 * 1964 *
1968 * Description: 1965 * Description:
1969 * In the following configuration : 1966 * In the following configuration :
1970 * - USBHOST module is set to smart-idle mode 1967 * - USBHOST module is set to smart-idle mode
1971 * - PRCM asserts idle_req to the USBHOST module ( This typically 1968 * - PRCM asserts idle_req to the USBHOST module ( This typically
1972 * happens when the system is going to a low power mode : all ports 1969 * happens when the system is going to a low power mode : all ports
1973 * have been suspended, the master part of the USBHOST module has 1970 * have been suspended, the master part of the USBHOST module has
1974 * entered the standby state, and SW has cut the functional clocks) 1971 * entered the standby state, and SW has cut the functional clocks)
1975 * - an USBHOST interrupt occurs before the module is able to answer 1972 * - an USBHOST interrupt occurs before the module is able to answer
1976 * idle_ack, typically a remote wakeup IRQ. 1973 * idle_ack, typically a remote wakeup IRQ.
1977 * Then the USB HOST module will enter a deadlock situation where it 1974 * Then the USB HOST module will enter a deadlock situation where it
1978 * is no more accessible nor functional. 1975 * is no more accessible nor functional.
1979 * 1976 *
1980 * Workaround: 1977 * Workaround:
1981 * Don't use smart idle; use only force idle, hence HWMOD_SWSUP_SIDLE 1978 * Don't use smart idle; use only force idle, hence HWMOD_SWSUP_SIDLE
1982 */ 1979 */
1983 1980
1984 /* 1981 /*
1985 * Errata: USB host EHCI may stall when entering smart-standby mode 1982 * Errata: USB host EHCI may stall when entering smart-standby mode
1986 * Id: i571 1983 * Id: i571
1987 * 1984 *
1988 * Description: 1985 * Description:
1989 * When the USBHOST module is set to smart-standby mode, and when it is 1986 * When the USBHOST module is set to smart-standby mode, and when it is
1990 * ready to enter the standby state (i.e. all ports are suspended and 1987 * ready to enter the standby state (i.e. all ports are suspended and
1991 * all attached devices are in suspend mode), then it can wrongly assert 1988 * all attached devices are in suspend mode), then it can wrongly assert
1992 * the Mstandby signal too early while there are still some residual OCP 1989 * the Mstandby signal too early while there are still some residual OCP
1993 * transactions ongoing. If this condition occurs, the internal state 1990 * transactions ongoing. If this condition occurs, the internal state
1994 * machine may go to an undefined state and the USB link may be stuck 1991 * machine may go to an undefined state and the USB link may be stuck
1995 * upon the next resume. 1992 * upon the next resume.
1996 * 1993 *
1997 * Workaround: 1994 * Workaround:
1998 * Don't use smart standby; use only force standby, 1995 * Don't use smart standby; use only force standby,
1999 * hence HWMOD_SWSUP_MSTANDBY 1996 * hence HWMOD_SWSUP_MSTANDBY
2000 */ 1997 */
2001 1998
2002 /* 1999 /*
2003 * During system boot; If the hwmod framework resets the module 2000 * During system boot; If the hwmod framework resets the module
2004 * the module will have smart idle settings; which can lead to deadlock 2001 * the module will have smart idle settings; which can lead to deadlock
2005 * (above Errata Id:i660); so, dont reset the module during boot; 2002 * (above Errata Id:i660); so, dont reset the module during boot;
2006 * Use HWMOD_INIT_NO_RESET. 2003 * Use HWMOD_INIT_NO_RESET.
2007 */ 2004 */
2008 2005
2009 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY | 2006 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
2010 HWMOD_INIT_NO_RESET, 2007 HWMOD_INIT_NO_RESET,
2011 }; 2008 };
2012 2009
2013 /* 2010 /*
2014 * 'usb_tll_hs' class 2011 * 'usb_tll_hs' class
2015 * usb_tll_hs module is the adapter on the usb_host_hs ports 2012 * usb_tll_hs module is the adapter on the usb_host_hs ports
2016 */ 2013 */
2017 static struct omap_hwmod_class_sysconfig omap3xxx_usb_tll_hs_sysc = { 2014 static struct omap_hwmod_class_sysconfig omap3xxx_usb_tll_hs_sysc = {
2018 .rev_offs = 0x0000, 2015 .rev_offs = 0x0000,
2019 .sysc_offs = 0x0010, 2016 .sysc_offs = 0x0010,
2020 .syss_offs = 0x0014, 2017 .syss_offs = 0x0014,
2021 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 2018 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
2022 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET | 2019 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
2023 SYSC_HAS_AUTOIDLE), 2020 SYSC_HAS_AUTOIDLE),
2024 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 2021 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2025 .sysc_fields = &omap_hwmod_sysc_type1, 2022 .sysc_fields = &omap_hwmod_sysc_type1,
2026 }; 2023 };
2027 2024
2028 static struct omap_hwmod_class omap3xxx_usb_tll_hs_hwmod_class = { 2025 static struct omap_hwmod_class omap3xxx_usb_tll_hs_hwmod_class = {
2029 .name = "usb_tll_hs", 2026 .name = "usb_tll_hs",
2030 .sysc = &omap3xxx_usb_tll_hs_sysc, 2027 .sysc = &omap3xxx_usb_tll_hs_sysc,
2031 }; 2028 };
2032 2029
2033 static struct omap_hwmod_irq_info omap3xxx_usb_tll_hs_irqs[] = { 2030 static struct omap_hwmod_irq_info omap3xxx_usb_tll_hs_irqs[] = {
2034 { .name = "tll-irq", .irq = 78 + OMAP_INTC_START, }, 2031 { .name = "tll-irq", .irq = 78 + OMAP_INTC_START, },
2035 { .irq = -1 }, 2032 { .irq = -1 },
2036 }; 2033 };
2037 2034
2038 static struct omap_hwmod omap3xxx_usb_tll_hs_hwmod = { 2035 static struct omap_hwmod omap3xxx_usb_tll_hs_hwmod = {
2039 .name = "usb_tll_hs", 2036 .name = "usb_tll_hs",
2040 .class = &omap3xxx_usb_tll_hs_hwmod_class, 2037 .class = &omap3xxx_usb_tll_hs_hwmod_class,
2041 .clkdm_name = "l3_init_clkdm", 2038 .clkdm_name = "l3_init_clkdm",
2042 .mpu_irqs = omap3xxx_usb_tll_hs_irqs, 2039 .mpu_irqs = omap3xxx_usb_tll_hs_irqs,
2043 .main_clk = "usbtll_fck", 2040 .main_clk = "usbtll_fck",
2044 .prcm = { 2041 .prcm = {
2045 .omap2 = { 2042 .omap2 = {
2046 .module_offs = CORE_MOD, 2043 .module_offs = CORE_MOD,
2047 .prcm_reg_id = 3, 2044 .prcm_reg_id = 3,
2048 .module_bit = OMAP3430ES2_EN_USBTLL_SHIFT, 2045 .module_bit = OMAP3430ES2_EN_USBTLL_SHIFT,
2049 .idlest_reg_id = 3, 2046 .idlest_reg_id = 3,
2050 .idlest_idle_bit = OMAP3430ES2_ST_USBTLL_SHIFT, 2047 .idlest_idle_bit = OMAP3430ES2_ST_USBTLL_SHIFT,
2051 }, 2048 },
2052 }, 2049 },
2053 }; 2050 };
2054 2051
2055 static struct omap_hwmod omap3xxx_hdq1w_hwmod = { 2052 static struct omap_hwmod omap3xxx_hdq1w_hwmod = {
2056 .name = "hdq1w", 2053 .name = "hdq1w",
2057 .mpu_irqs = omap2_hdq1w_mpu_irqs, 2054 .mpu_irqs = omap2_hdq1w_mpu_irqs,
2058 .main_clk = "hdq_fck", 2055 .main_clk = "hdq_fck",
2059 .prcm = { 2056 .prcm = {
2060 .omap2 = { 2057 .omap2 = {
2061 .module_offs = CORE_MOD, 2058 .module_offs = CORE_MOD,
2062 .prcm_reg_id = 1, 2059 .prcm_reg_id = 1,
2063 .module_bit = OMAP3430_EN_HDQ_SHIFT, 2060 .module_bit = OMAP3430_EN_HDQ_SHIFT,
2064 .idlest_reg_id = 1, 2061 .idlest_reg_id = 1,
2065 .idlest_idle_bit = OMAP3430_ST_HDQ_SHIFT, 2062 .idlest_idle_bit = OMAP3430_ST_HDQ_SHIFT,
2066 }, 2063 },
2067 }, 2064 },
2068 .class = &omap2_hdq1w_class, 2065 .class = &omap2_hdq1w_class,
2069 }; 2066 };
2070 2067
2071 /* SAD2D */ 2068 /* SAD2D */
2072 static struct omap_hwmod_rst_info omap3xxx_sad2d_resets[] = { 2069 static struct omap_hwmod_rst_info omap3xxx_sad2d_resets[] = {
2073 { .name = "rst_modem_pwron_sw", .rst_shift = 0 }, 2070 { .name = "rst_modem_pwron_sw", .rst_shift = 0 },
2074 { .name = "rst_modem_sw", .rst_shift = 1 }, 2071 { .name = "rst_modem_sw", .rst_shift = 1 },
2075 }; 2072 };
2076 2073
2077 static struct omap_hwmod_class omap3xxx_sad2d_class = { 2074 static struct omap_hwmod_class omap3xxx_sad2d_class = {
2078 .name = "sad2d", 2075 .name = "sad2d",
2079 }; 2076 };
2080 2077
2081 static struct omap_hwmod omap3xxx_sad2d_hwmod = { 2078 static struct omap_hwmod omap3xxx_sad2d_hwmod = {
2082 .name = "sad2d", 2079 .name = "sad2d",
2083 .rst_lines = omap3xxx_sad2d_resets, 2080 .rst_lines = omap3xxx_sad2d_resets,
2084 .rst_lines_cnt = ARRAY_SIZE(omap3xxx_sad2d_resets), 2081 .rst_lines_cnt = ARRAY_SIZE(omap3xxx_sad2d_resets),
2085 .main_clk = "sad2d_ick", 2082 .main_clk = "sad2d_ick",
2086 .prcm = { 2083 .prcm = {
2087 .omap2 = { 2084 .omap2 = {
2088 .module_offs = CORE_MOD, 2085 .module_offs = CORE_MOD,
2089 .prcm_reg_id = 1, 2086 .prcm_reg_id = 1,
2090 .module_bit = OMAP3430_EN_SAD2D_SHIFT, 2087 .module_bit = OMAP3430_EN_SAD2D_SHIFT,
2091 .idlest_reg_id = 1, 2088 .idlest_reg_id = 1,
2092 .idlest_idle_bit = OMAP3430_ST_SAD2D_SHIFT, 2089 .idlest_idle_bit = OMAP3430_ST_SAD2D_SHIFT,
2093 }, 2090 },
2094 }, 2091 },
2095 .class = &omap3xxx_sad2d_class, 2092 .class = &omap3xxx_sad2d_class,
2096 }; 2093 };
2097 2094
2098 /* 2095 /*
2099 * '32K sync counter' class 2096 * '32K sync counter' class
2100 * 32-bit ordinary counter, clocked by the falling edge of the 32 khz clock 2097 * 32-bit ordinary counter, clocked by the falling edge of the 32 khz clock
2101 */ 2098 */
2102 static struct omap_hwmod_class_sysconfig omap3xxx_counter_sysc = { 2099 static struct omap_hwmod_class_sysconfig omap3xxx_counter_sysc = {
2103 .rev_offs = 0x0000, 2100 .rev_offs = 0x0000,
2104 .sysc_offs = 0x0004, 2101 .sysc_offs = 0x0004,
2105 .sysc_flags = SYSC_HAS_SIDLEMODE, 2102 .sysc_flags = SYSC_HAS_SIDLEMODE,
2106 .idlemodes = (SIDLE_FORCE | SIDLE_NO), 2103 .idlemodes = (SIDLE_FORCE | SIDLE_NO),
2107 .sysc_fields = &omap_hwmod_sysc_type1, 2104 .sysc_fields = &omap_hwmod_sysc_type1,
2108 }; 2105 };
2109 2106
2110 static struct omap_hwmod_class omap3xxx_counter_hwmod_class = { 2107 static struct omap_hwmod_class omap3xxx_counter_hwmod_class = {
2111 .name = "counter", 2108 .name = "counter",
2112 .sysc = &omap3xxx_counter_sysc, 2109 .sysc = &omap3xxx_counter_sysc,
2113 }; 2110 };
2114 2111
2115 static struct omap_hwmod omap3xxx_counter_32k_hwmod = { 2112 static struct omap_hwmod omap3xxx_counter_32k_hwmod = {
2116 .name = "counter_32k", 2113 .name = "counter_32k",
2117 .class = &omap3xxx_counter_hwmod_class, 2114 .class = &omap3xxx_counter_hwmod_class,
2118 .clkdm_name = "wkup_clkdm", 2115 .clkdm_name = "wkup_clkdm",
2119 .flags = HWMOD_SWSUP_SIDLE, 2116 .flags = HWMOD_SWSUP_SIDLE,
2120 .main_clk = "wkup_32k_fck", 2117 .main_clk = "wkup_32k_fck",
2121 .prcm = { 2118 .prcm = {
2122 .omap2 = { 2119 .omap2 = {
2123 .module_offs = WKUP_MOD, 2120 .module_offs = WKUP_MOD,
2124 .prcm_reg_id = 1, 2121 .prcm_reg_id = 1,
2125 .module_bit = OMAP3430_ST_32KSYNC_SHIFT, 2122 .module_bit = OMAP3430_ST_32KSYNC_SHIFT,
2126 .idlest_reg_id = 1, 2123 .idlest_reg_id = 1,
2127 .idlest_idle_bit = OMAP3430_ST_32KSYNC_SHIFT, 2124 .idlest_idle_bit = OMAP3430_ST_32KSYNC_SHIFT,
2128 }, 2125 },
2129 }, 2126 },
2130 }; 2127 };
2131 2128
2132 /* 2129 /*
2133 * 'gpmc' class 2130 * 'gpmc' class
2134 * general purpose memory controller 2131 * general purpose memory controller
2135 */ 2132 */
2136 2133
2137 static struct omap_hwmod_class_sysconfig omap3xxx_gpmc_sysc = { 2134 static struct omap_hwmod_class_sysconfig omap3xxx_gpmc_sysc = {
2138 .rev_offs = 0x0000, 2135 .rev_offs = 0x0000,
2139 .sysc_offs = 0x0010, 2136 .sysc_offs = 0x0010,
2140 .syss_offs = 0x0014, 2137 .syss_offs = 0x0014,
2141 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE | 2138 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
2142 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 2139 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
2143 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 2140 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2144 .sysc_fields = &omap_hwmod_sysc_type1, 2141 .sysc_fields = &omap_hwmod_sysc_type1,
2145 }; 2142 };
2146 2143
2147 static struct omap_hwmod_class omap3xxx_gpmc_hwmod_class = { 2144 static struct omap_hwmod_class omap3xxx_gpmc_hwmod_class = {
2148 .name = "gpmc", 2145 .name = "gpmc",
2149 .sysc = &omap3xxx_gpmc_sysc, 2146 .sysc = &omap3xxx_gpmc_sysc,
2150 }; 2147 };
2151 2148
2152 static struct omap_hwmod_irq_info omap3xxx_gpmc_irqs[] = { 2149 static struct omap_hwmod_irq_info omap3xxx_gpmc_irqs[] = {
2153 { .irq = 20 }, 2150 { .irq = 20 },
2154 { .irq = -1 } 2151 { .irq = -1 }
2155 }; 2152 };
2156 2153
2157 static struct omap_hwmod omap3xxx_gpmc_hwmod = { 2154 static struct omap_hwmod omap3xxx_gpmc_hwmod = {
2158 .name = "gpmc", 2155 .name = "gpmc",
2159 .class = &omap3xxx_gpmc_hwmod_class, 2156 .class = &omap3xxx_gpmc_hwmod_class,
2160 .clkdm_name = "core_l3_clkdm", 2157 .clkdm_name = "core_l3_clkdm",
2161 .mpu_irqs = omap3xxx_gpmc_irqs, 2158 .mpu_irqs = omap3xxx_gpmc_irqs,
2162 .main_clk = "gpmc_fck", 2159 .main_clk = "gpmc_fck",
2163 /* 2160 /*
2164 * XXX HWMOD_INIT_NO_RESET should not be needed for this IP 2161 * XXX HWMOD_INIT_NO_RESET should not be needed for this IP
2165 * block. It is not being added due to any known bugs with 2162 * block. It is not being added due to any known bugs with
2166 * resetting the GPMC IP block, but rather because any timings 2163 * resetting the GPMC IP block, but rather because any timings
2167 * set by the bootloader are not being correctly programmed by 2164 * set by the bootloader are not being correctly programmed by
2168 * the kernel from the board file or DT data. 2165 * the kernel from the board file or DT data.
2169 * HWMOD_INIT_NO_RESET should be removed ASAP. 2166 * HWMOD_INIT_NO_RESET should be removed ASAP.
2170 */ 2167 */
2171 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET | 2168 .flags = (HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET |
2172 HWMOD_NO_IDLEST), 2169 HWMOD_NO_IDLEST),
2173 }; 2170 };
2174 2171
2175 /* 2172 /*
2176 * interfaces 2173 * interfaces
2177 */ 2174 */
2178 2175
2179 /* L3 -> L4_CORE interface */ 2176 /* L3 -> L4_CORE interface */
2180 static struct omap_hwmod_ocp_if omap3xxx_l3_main__l4_core = { 2177 static struct omap_hwmod_ocp_if omap3xxx_l3_main__l4_core = {
2181 .master = &omap3xxx_l3_main_hwmod, 2178 .master = &omap3xxx_l3_main_hwmod,
2182 .slave = &omap3xxx_l4_core_hwmod, 2179 .slave = &omap3xxx_l4_core_hwmod,
2183 .user = OCP_USER_MPU | OCP_USER_SDMA, 2180 .user = OCP_USER_MPU | OCP_USER_SDMA,
2184 }; 2181 };
2185 2182
2186 /* L3 -> L4_PER interface */ 2183 /* L3 -> L4_PER interface */
2187 static struct omap_hwmod_ocp_if omap3xxx_l3_main__l4_per = { 2184 static struct omap_hwmod_ocp_if omap3xxx_l3_main__l4_per = {
2188 .master = &omap3xxx_l3_main_hwmod, 2185 .master = &omap3xxx_l3_main_hwmod,
2189 .slave = &omap3xxx_l4_per_hwmod, 2186 .slave = &omap3xxx_l4_per_hwmod,
2190 .user = OCP_USER_MPU | OCP_USER_SDMA, 2187 .user = OCP_USER_MPU | OCP_USER_SDMA,
2191 }; 2188 };
2192 2189
2193 static struct omap_hwmod_addr_space omap3xxx_l3_main_addrs[] = { 2190 static struct omap_hwmod_addr_space omap3xxx_l3_main_addrs[] = {
2194 { 2191 {
2195 .pa_start = 0x68000000, 2192 .pa_start = 0x68000000,
2196 .pa_end = 0x6800ffff, 2193 .pa_end = 0x6800ffff,
2197 .flags = ADDR_TYPE_RT, 2194 .flags = ADDR_TYPE_RT,
2198 }, 2195 },
2199 { } 2196 { }
2200 }; 2197 };
2201 2198
2202 /* MPU -> L3 interface */ 2199 /* MPU -> L3 interface */
2203 static struct omap_hwmod_ocp_if omap3xxx_mpu__l3_main = { 2200 static struct omap_hwmod_ocp_if omap3xxx_mpu__l3_main = {
2204 .master = &omap3xxx_mpu_hwmod, 2201 .master = &omap3xxx_mpu_hwmod,
2205 .slave = &omap3xxx_l3_main_hwmod, 2202 .slave = &omap3xxx_l3_main_hwmod,
2206 .addr = omap3xxx_l3_main_addrs, 2203 .addr = omap3xxx_l3_main_addrs,
2207 .user = OCP_USER_MPU, 2204 .user = OCP_USER_MPU,
2208 }; 2205 };
2209 2206
2210 static struct omap_hwmod_addr_space omap3xxx_l4_emu_addrs[] = { 2207 static struct omap_hwmod_addr_space omap3xxx_l4_emu_addrs[] = {
2211 { 2208 {
2212 .pa_start = 0x54000000, 2209 .pa_start = 0x54000000,
2213 .pa_end = 0x547fffff, 2210 .pa_end = 0x547fffff,
2214 .flags = ADDR_TYPE_RT, 2211 .flags = ADDR_TYPE_RT,
2215 }, 2212 },
2216 { } 2213 { }
2217 }; 2214 };
2218 2215
2219 /* l3 -> debugss */ 2216 /* l3 -> debugss */
2220 static struct omap_hwmod_ocp_if omap3xxx_l3_main__l4_debugss = { 2217 static struct omap_hwmod_ocp_if omap3xxx_l3_main__l4_debugss = {
2221 .master = &omap3xxx_l3_main_hwmod, 2218 .master = &omap3xxx_l3_main_hwmod,
2222 .slave = &omap3xxx_debugss_hwmod, 2219 .slave = &omap3xxx_debugss_hwmod,
2223 .addr = omap3xxx_l4_emu_addrs, 2220 .addr = omap3xxx_l4_emu_addrs,
2224 .user = OCP_USER_MPU, 2221 .user = OCP_USER_MPU,
2225 }; 2222 };
2226 2223
2227 /* DSS -> l3 */ 2224 /* DSS -> l3 */
2228 static struct omap_hwmod_ocp_if omap3430es1_dss__l3 = { 2225 static struct omap_hwmod_ocp_if omap3430es1_dss__l3 = {
2229 .master = &omap3430es1_dss_core_hwmod, 2226 .master = &omap3430es1_dss_core_hwmod,
2230 .slave = &omap3xxx_l3_main_hwmod, 2227 .slave = &omap3xxx_l3_main_hwmod,
2231 .user = OCP_USER_MPU | OCP_USER_SDMA, 2228 .user = OCP_USER_MPU | OCP_USER_SDMA,
2232 }; 2229 };
2233 2230
2234 static struct omap_hwmod_ocp_if omap3xxx_dss__l3 = { 2231 static struct omap_hwmod_ocp_if omap3xxx_dss__l3 = {
2235 .master = &omap3xxx_dss_core_hwmod, 2232 .master = &omap3xxx_dss_core_hwmod,
2236 .slave = &omap3xxx_l3_main_hwmod, 2233 .slave = &omap3xxx_l3_main_hwmod,
2237 .fw = { 2234 .fw = {
2238 .omap2 = { 2235 .omap2 = {
2239 .l3_perm_bit = OMAP3_L3_CORE_FW_INIT_ID_DSS, 2236 .l3_perm_bit = OMAP3_L3_CORE_FW_INIT_ID_DSS,
2240 .flags = OMAP_FIREWALL_L3, 2237 .flags = OMAP_FIREWALL_L3,
2241 } 2238 }
2242 }, 2239 },
2243 .user = OCP_USER_MPU | OCP_USER_SDMA, 2240 .user = OCP_USER_MPU | OCP_USER_SDMA,
2244 }; 2241 };
2245 2242
2246 /* l3_core -> usbhsotg interface */ 2243 /* l3_core -> usbhsotg interface */
2247 static struct omap_hwmod_ocp_if omap3xxx_usbhsotg__l3 = { 2244 static struct omap_hwmod_ocp_if omap3xxx_usbhsotg__l3 = {
2248 .master = &omap3xxx_usbhsotg_hwmod, 2245 .master = &omap3xxx_usbhsotg_hwmod,
2249 .slave = &omap3xxx_l3_main_hwmod, 2246 .slave = &omap3xxx_l3_main_hwmod,
2250 .clk = "core_l3_ick", 2247 .clk = "core_l3_ick",
2251 .user = OCP_USER_MPU, 2248 .user = OCP_USER_MPU,
2252 }; 2249 };
2253 2250
2254 /* l3_core -> am35xx_usbhsotg interface */ 2251 /* l3_core -> am35xx_usbhsotg interface */
2255 static struct omap_hwmod_ocp_if am35xx_usbhsotg__l3 = { 2252 static struct omap_hwmod_ocp_if am35xx_usbhsotg__l3 = {
2256 .master = &am35xx_usbhsotg_hwmod, 2253 .master = &am35xx_usbhsotg_hwmod,
2257 .slave = &omap3xxx_l3_main_hwmod, 2254 .slave = &omap3xxx_l3_main_hwmod,
2258 .clk = "hsotgusb_ick", 2255 .clk = "hsotgusb_ick",
2259 .user = OCP_USER_MPU, 2256 .user = OCP_USER_MPU,
2260 }; 2257 };
2261 2258
2262 /* l3_core -> sad2d interface */ 2259 /* l3_core -> sad2d interface */
2263 static struct omap_hwmod_ocp_if omap3xxx_sad2d__l3 = { 2260 static struct omap_hwmod_ocp_if omap3xxx_sad2d__l3 = {
2264 .master = &omap3xxx_sad2d_hwmod, 2261 .master = &omap3xxx_sad2d_hwmod,
2265 .slave = &omap3xxx_l3_main_hwmod, 2262 .slave = &omap3xxx_l3_main_hwmod,
2266 .clk = "core_l3_ick", 2263 .clk = "core_l3_ick",
2267 .user = OCP_USER_MPU, 2264 .user = OCP_USER_MPU,
2268 }; 2265 };
2269 2266
2270 /* L4_CORE -> L4_WKUP interface */ 2267 /* L4_CORE -> L4_WKUP interface */
2271 static struct omap_hwmod_ocp_if omap3xxx_l4_core__l4_wkup = { 2268 static struct omap_hwmod_ocp_if omap3xxx_l4_core__l4_wkup = {
2272 .master = &omap3xxx_l4_core_hwmod, 2269 .master = &omap3xxx_l4_core_hwmod,
2273 .slave = &omap3xxx_l4_wkup_hwmod, 2270 .slave = &omap3xxx_l4_wkup_hwmod,
2274 .user = OCP_USER_MPU | OCP_USER_SDMA, 2271 .user = OCP_USER_MPU | OCP_USER_SDMA,
2275 }; 2272 };
2276 2273
2277 /* L4 CORE -> MMC1 interface */ 2274 /* L4 CORE -> MMC1 interface */
2278 static struct omap_hwmod_ocp_if omap3xxx_l4_core__pre_es3_mmc1 = { 2275 static struct omap_hwmod_ocp_if omap3xxx_l4_core__pre_es3_mmc1 = {
2279 .master = &omap3xxx_l4_core_hwmod, 2276 .master = &omap3xxx_l4_core_hwmod,
2280 .slave = &omap3xxx_pre_es3_mmc1_hwmod, 2277 .slave = &omap3xxx_pre_es3_mmc1_hwmod,
2281 .clk = "mmchs1_ick", 2278 .clk = "mmchs1_ick",
2282 .addr = omap2430_mmc1_addr_space, 2279 .addr = omap2430_mmc1_addr_space,
2283 .user = OCP_USER_MPU | OCP_USER_SDMA, 2280 .user = OCP_USER_MPU | OCP_USER_SDMA,
2284 .flags = OMAP_FIREWALL_L4 2281 .flags = OMAP_FIREWALL_L4
2285 }; 2282 };
2286 2283
2287 static struct omap_hwmod_ocp_if omap3xxx_l4_core__es3plus_mmc1 = { 2284 static struct omap_hwmod_ocp_if omap3xxx_l4_core__es3plus_mmc1 = {
2288 .master = &omap3xxx_l4_core_hwmod, 2285 .master = &omap3xxx_l4_core_hwmod,
2289 .slave = &omap3xxx_es3plus_mmc1_hwmod, 2286 .slave = &omap3xxx_es3plus_mmc1_hwmod,
2290 .clk = "mmchs1_ick", 2287 .clk = "mmchs1_ick",
2291 .addr = omap2430_mmc1_addr_space, 2288 .addr = omap2430_mmc1_addr_space,
2292 .user = OCP_USER_MPU | OCP_USER_SDMA, 2289 .user = OCP_USER_MPU | OCP_USER_SDMA,
2293 .flags = OMAP_FIREWALL_L4 2290 .flags = OMAP_FIREWALL_L4
2294 }; 2291 };
2295 2292
2296 /* L4 CORE -> MMC2 interface */ 2293 /* L4 CORE -> MMC2 interface */
2297 static struct omap_hwmod_ocp_if omap3xxx_l4_core__pre_es3_mmc2 = { 2294 static struct omap_hwmod_ocp_if omap3xxx_l4_core__pre_es3_mmc2 = {
2298 .master = &omap3xxx_l4_core_hwmod, 2295 .master = &omap3xxx_l4_core_hwmod,
2299 .slave = &omap3xxx_pre_es3_mmc2_hwmod, 2296 .slave = &omap3xxx_pre_es3_mmc2_hwmod,
2300 .clk = "mmchs2_ick", 2297 .clk = "mmchs2_ick",
2301 .addr = omap2430_mmc2_addr_space, 2298 .addr = omap2430_mmc2_addr_space,
2302 .user = OCP_USER_MPU | OCP_USER_SDMA, 2299 .user = OCP_USER_MPU | OCP_USER_SDMA,
2303 .flags = OMAP_FIREWALL_L4 2300 .flags = OMAP_FIREWALL_L4
2304 }; 2301 };
2305 2302
2306 static struct omap_hwmod_ocp_if omap3xxx_l4_core__es3plus_mmc2 = { 2303 static struct omap_hwmod_ocp_if omap3xxx_l4_core__es3plus_mmc2 = {
2307 .master = &omap3xxx_l4_core_hwmod, 2304 .master = &omap3xxx_l4_core_hwmod,
2308 .slave = &omap3xxx_es3plus_mmc2_hwmod, 2305 .slave = &omap3xxx_es3plus_mmc2_hwmod,
2309 .clk = "mmchs2_ick", 2306 .clk = "mmchs2_ick",
2310 .addr = omap2430_mmc2_addr_space, 2307 .addr = omap2430_mmc2_addr_space,
2311 .user = OCP_USER_MPU | OCP_USER_SDMA, 2308 .user = OCP_USER_MPU | OCP_USER_SDMA,
2312 .flags = OMAP_FIREWALL_L4 2309 .flags = OMAP_FIREWALL_L4
2313 }; 2310 };
2314 2311
2315 /* L4 CORE -> MMC3 interface */ 2312 /* L4 CORE -> MMC3 interface */
2316 static struct omap_hwmod_addr_space omap3xxx_mmc3_addr_space[] = { 2313 static struct omap_hwmod_addr_space omap3xxx_mmc3_addr_space[] = {
2317 { 2314 {
2318 .pa_start = 0x480ad000, 2315 .pa_start = 0x480ad000,
2319 .pa_end = 0x480ad1ff, 2316 .pa_end = 0x480ad1ff,
2320 .flags = ADDR_TYPE_RT, 2317 .flags = ADDR_TYPE_RT,
2321 }, 2318 },
2322 { } 2319 { }
2323 }; 2320 };
2324 2321
2325 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mmc3 = { 2322 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mmc3 = {
2326 .master = &omap3xxx_l4_core_hwmod, 2323 .master = &omap3xxx_l4_core_hwmod,
2327 .slave = &omap3xxx_mmc3_hwmod, 2324 .slave = &omap3xxx_mmc3_hwmod,
2328 .clk = "mmchs3_ick", 2325 .clk = "mmchs3_ick",
2329 .addr = omap3xxx_mmc3_addr_space, 2326 .addr = omap3xxx_mmc3_addr_space,
2330 .user = OCP_USER_MPU | OCP_USER_SDMA, 2327 .user = OCP_USER_MPU | OCP_USER_SDMA,
2331 .flags = OMAP_FIREWALL_L4 2328 .flags = OMAP_FIREWALL_L4
2332 }; 2329 };
2333 2330
2334 /* L4 CORE -> UART1 interface */ 2331 /* L4 CORE -> UART1 interface */
2335 static struct omap_hwmod_addr_space omap3xxx_uart1_addr_space[] = { 2332 static struct omap_hwmod_addr_space omap3xxx_uart1_addr_space[] = {
2336 { 2333 {
2337 .pa_start = OMAP3_UART1_BASE, 2334 .pa_start = OMAP3_UART1_BASE,
2338 .pa_end = OMAP3_UART1_BASE + SZ_8K - 1, 2335 .pa_end = OMAP3_UART1_BASE + SZ_8K - 1,
2339 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT, 2336 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
2340 }, 2337 },
2341 { } 2338 { }
2342 }; 2339 };
2343 2340
2344 static struct omap_hwmod_ocp_if omap3_l4_core__uart1 = { 2341 static struct omap_hwmod_ocp_if omap3_l4_core__uart1 = {
2345 .master = &omap3xxx_l4_core_hwmod, 2342 .master = &omap3xxx_l4_core_hwmod,
2346 .slave = &omap3xxx_uart1_hwmod, 2343 .slave = &omap3xxx_uart1_hwmod,
2347 .clk = "uart1_ick", 2344 .clk = "uart1_ick",
2348 .addr = omap3xxx_uart1_addr_space, 2345 .addr = omap3xxx_uart1_addr_space,
2349 .user = OCP_USER_MPU | OCP_USER_SDMA, 2346 .user = OCP_USER_MPU | OCP_USER_SDMA,
2350 }; 2347 };
2351 2348
2352 /* L4 CORE -> UART2 interface */ 2349 /* L4 CORE -> UART2 interface */
2353 static struct omap_hwmod_addr_space omap3xxx_uart2_addr_space[] = { 2350 static struct omap_hwmod_addr_space omap3xxx_uart2_addr_space[] = {
2354 { 2351 {
2355 .pa_start = OMAP3_UART2_BASE, 2352 .pa_start = OMAP3_UART2_BASE,
2356 .pa_end = OMAP3_UART2_BASE + SZ_1K - 1, 2353 .pa_end = OMAP3_UART2_BASE + SZ_1K - 1,
2357 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT, 2354 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
2358 }, 2355 },
2359 { } 2356 { }
2360 }; 2357 };
2361 2358
2362 static struct omap_hwmod_ocp_if omap3_l4_core__uart2 = { 2359 static struct omap_hwmod_ocp_if omap3_l4_core__uart2 = {
2363 .master = &omap3xxx_l4_core_hwmod, 2360 .master = &omap3xxx_l4_core_hwmod,
2364 .slave = &omap3xxx_uart2_hwmod, 2361 .slave = &omap3xxx_uart2_hwmod,
2365 .clk = "uart2_ick", 2362 .clk = "uart2_ick",
2366 .addr = omap3xxx_uart2_addr_space, 2363 .addr = omap3xxx_uart2_addr_space,
2367 .user = OCP_USER_MPU | OCP_USER_SDMA, 2364 .user = OCP_USER_MPU | OCP_USER_SDMA,
2368 }; 2365 };
2369 2366
2370 /* L4 PER -> UART3 interface */ 2367 /* L4 PER -> UART3 interface */
2371 static struct omap_hwmod_addr_space omap3xxx_uart3_addr_space[] = { 2368 static struct omap_hwmod_addr_space omap3xxx_uart3_addr_space[] = {
2372 { 2369 {
2373 .pa_start = OMAP3_UART3_BASE, 2370 .pa_start = OMAP3_UART3_BASE,
2374 .pa_end = OMAP3_UART3_BASE + SZ_1K - 1, 2371 .pa_end = OMAP3_UART3_BASE + SZ_1K - 1,
2375 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT, 2372 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
2376 }, 2373 },
2377 { } 2374 { }
2378 }; 2375 };
2379 2376
2380 static struct omap_hwmod_ocp_if omap3_l4_per__uart3 = { 2377 static struct omap_hwmod_ocp_if omap3_l4_per__uart3 = {
2381 .master = &omap3xxx_l4_per_hwmod, 2378 .master = &omap3xxx_l4_per_hwmod,
2382 .slave = &omap3xxx_uart3_hwmod, 2379 .slave = &omap3xxx_uart3_hwmod,
2383 .clk = "uart3_ick", 2380 .clk = "uart3_ick",
2384 .addr = omap3xxx_uart3_addr_space, 2381 .addr = omap3xxx_uart3_addr_space,
2385 .user = OCP_USER_MPU | OCP_USER_SDMA, 2382 .user = OCP_USER_MPU | OCP_USER_SDMA,
2386 }; 2383 };
2387 2384
2388 /* L4 PER -> UART4 interface */ 2385 /* L4 PER -> UART4 interface */
2389 static struct omap_hwmod_addr_space omap36xx_uart4_addr_space[] = { 2386 static struct omap_hwmod_addr_space omap36xx_uart4_addr_space[] = {
2390 { 2387 {
2391 .pa_start = OMAP3_UART4_BASE, 2388 .pa_start = OMAP3_UART4_BASE,
2392 .pa_end = OMAP3_UART4_BASE + SZ_1K - 1, 2389 .pa_end = OMAP3_UART4_BASE + SZ_1K - 1,
2393 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT, 2390 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
2394 }, 2391 },
2395 { } 2392 { }
2396 }; 2393 };
2397 2394
2398 static struct omap_hwmod_ocp_if omap36xx_l4_per__uart4 = { 2395 static struct omap_hwmod_ocp_if omap36xx_l4_per__uart4 = {
2399 .master = &omap3xxx_l4_per_hwmod, 2396 .master = &omap3xxx_l4_per_hwmod,
2400 .slave = &omap36xx_uart4_hwmod, 2397 .slave = &omap36xx_uart4_hwmod,
2401 .clk = "uart4_ick", 2398 .clk = "uart4_ick",
2402 .addr = omap36xx_uart4_addr_space, 2399 .addr = omap36xx_uart4_addr_space,
2403 .user = OCP_USER_MPU | OCP_USER_SDMA, 2400 .user = OCP_USER_MPU | OCP_USER_SDMA,
2404 }; 2401 };
2405 2402
2406 /* AM35xx: L4 CORE -> UART4 interface */ 2403 /* AM35xx: L4 CORE -> UART4 interface */
2407 static struct omap_hwmod_addr_space am35xx_uart4_addr_space[] = { 2404 static struct omap_hwmod_addr_space am35xx_uart4_addr_space[] = {
2408 { 2405 {
2409 .pa_start = OMAP3_UART4_AM35XX_BASE, 2406 .pa_start = OMAP3_UART4_AM35XX_BASE,
2410 .pa_end = OMAP3_UART4_AM35XX_BASE + SZ_1K - 1, 2407 .pa_end = OMAP3_UART4_AM35XX_BASE + SZ_1K - 1,
2411 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT, 2408 .flags = ADDR_MAP_ON_INIT | ADDR_TYPE_RT,
2412 }, 2409 },
2413 { } 2410 { }
2414 }; 2411 };
2415 2412
2416 static struct omap_hwmod_ocp_if am35xx_l4_core__uart4 = { 2413 static struct omap_hwmod_ocp_if am35xx_l4_core__uart4 = {
2417 .master = &omap3xxx_l4_core_hwmod, 2414 .master = &omap3xxx_l4_core_hwmod,
2418 .slave = &am35xx_uart4_hwmod, 2415 .slave = &am35xx_uart4_hwmod,
2419 .clk = "uart4_ick", 2416 .clk = "uart4_ick",
2420 .addr = am35xx_uart4_addr_space, 2417 .addr = am35xx_uart4_addr_space,
2421 .user = OCP_USER_MPU | OCP_USER_SDMA, 2418 .user = OCP_USER_MPU | OCP_USER_SDMA,
2422 }; 2419 };
2423 2420
2424 /* L4 CORE -> I2C1 interface */ 2421 /* L4 CORE -> I2C1 interface */
2425 static struct omap_hwmod_ocp_if omap3_l4_core__i2c1 = { 2422 static struct omap_hwmod_ocp_if omap3_l4_core__i2c1 = {
2426 .master = &omap3xxx_l4_core_hwmod, 2423 .master = &omap3xxx_l4_core_hwmod,
2427 .slave = &omap3xxx_i2c1_hwmod, 2424 .slave = &omap3xxx_i2c1_hwmod,
2428 .clk = "i2c1_ick", 2425 .clk = "i2c1_ick",
2429 .addr = omap2_i2c1_addr_space, 2426 .addr = omap2_i2c1_addr_space,
2430 .fw = { 2427 .fw = {
2431 .omap2 = { 2428 .omap2 = {
2432 .l4_fw_region = OMAP3_L4_CORE_FW_I2C1_REGION, 2429 .l4_fw_region = OMAP3_L4_CORE_FW_I2C1_REGION,
2433 .l4_prot_group = 7, 2430 .l4_prot_group = 7,
2434 .flags = OMAP_FIREWALL_L4, 2431 .flags = OMAP_FIREWALL_L4,
2435 } 2432 }
2436 }, 2433 },
2437 .user = OCP_USER_MPU | OCP_USER_SDMA, 2434 .user = OCP_USER_MPU | OCP_USER_SDMA,
2438 }; 2435 };
2439 2436
2440 /* L4 CORE -> I2C2 interface */ 2437 /* L4 CORE -> I2C2 interface */
2441 static struct omap_hwmod_ocp_if omap3_l4_core__i2c2 = { 2438 static struct omap_hwmod_ocp_if omap3_l4_core__i2c2 = {
2442 .master = &omap3xxx_l4_core_hwmod, 2439 .master = &omap3xxx_l4_core_hwmod,
2443 .slave = &omap3xxx_i2c2_hwmod, 2440 .slave = &omap3xxx_i2c2_hwmod,
2444 .clk = "i2c2_ick", 2441 .clk = "i2c2_ick",
2445 .addr = omap2_i2c2_addr_space, 2442 .addr = omap2_i2c2_addr_space,
2446 .fw = { 2443 .fw = {
2447 .omap2 = { 2444 .omap2 = {
2448 .l4_fw_region = OMAP3_L4_CORE_FW_I2C2_REGION, 2445 .l4_fw_region = OMAP3_L4_CORE_FW_I2C2_REGION,
2449 .l4_prot_group = 7, 2446 .l4_prot_group = 7,
2450 .flags = OMAP_FIREWALL_L4, 2447 .flags = OMAP_FIREWALL_L4,
2451 } 2448 }
2452 }, 2449 },
2453 .user = OCP_USER_MPU | OCP_USER_SDMA, 2450 .user = OCP_USER_MPU | OCP_USER_SDMA,
2454 }; 2451 };
2455 2452
2456 /* L4 CORE -> I2C3 interface */ 2453 /* L4 CORE -> I2C3 interface */
2457 static struct omap_hwmod_addr_space omap3xxx_i2c3_addr_space[] = { 2454 static struct omap_hwmod_addr_space omap3xxx_i2c3_addr_space[] = {
2458 { 2455 {
2459 .pa_start = 0x48060000, 2456 .pa_start = 0x48060000,
2460 .pa_end = 0x48060000 + SZ_128 - 1, 2457 .pa_end = 0x48060000 + SZ_128 - 1,
2461 .flags = ADDR_TYPE_RT, 2458 .flags = ADDR_TYPE_RT,
2462 }, 2459 },
2463 { } 2460 { }
2464 }; 2461 };
2465 2462
2466 static struct omap_hwmod_ocp_if omap3_l4_core__i2c3 = { 2463 static struct omap_hwmod_ocp_if omap3_l4_core__i2c3 = {
2467 .master = &omap3xxx_l4_core_hwmod, 2464 .master = &omap3xxx_l4_core_hwmod,
2468 .slave = &omap3xxx_i2c3_hwmod, 2465 .slave = &omap3xxx_i2c3_hwmod,
2469 .clk = "i2c3_ick", 2466 .clk = "i2c3_ick",
2470 .addr = omap3xxx_i2c3_addr_space, 2467 .addr = omap3xxx_i2c3_addr_space,
2471 .fw = { 2468 .fw = {
2472 .omap2 = { 2469 .omap2 = {
2473 .l4_fw_region = OMAP3_L4_CORE_FW_I2C3_REGION, 2470 .l4_fw_region = OMAP3_L4_CORE_FW_I2C3_REGION,
2474 .l4_prot_group = 7, 2471 .l4_prot_group = 7,
2475 .flags = OMAP_FIREWALL_L4, 2472 .flags = OMAP_FIREWALL_L4,
2476 } 2473 }
2477 }, 2474 },
2478 .user = OCP_USER_MPU | OCP_USER_SDMA, 2475 .user = OCP_USER_MPU | OCP_USER_SDMA,
2479 }; 2476 };
2480 2477
2481 /* L4 CORE -> SR1 interface */ 2478 /* L4 CORE -> SR1 interface */
2482 static struct omap_hwmod_addr_space omap3_sr1_addr_space[] = { 2479 static struct omap_hwmod_addr_space omap3_sr1_addr_space[] = {
2483 { 2480 {
2484 .pa_start = OMAP34XX_SR1_BASE, 2481 .pa_start = OMAP34XX_SR1_BASE,
2485 .pa_end = OMAP34XX_SR1_BASE + SZ_1K - 1, 2482 .pa_end = OMAP34XX_SR1_BASE + SZ_1K - 1,
2486 .flags = ADDR_TYPE_RT, 2483 .flags = ADDR_TYPE_RT,
2487 }, 2484 },
2488 { } 2485 { }
2489 }; 2486 };
2490 2487
2491 static struct omap_hwmod_ocp_if omap34xx_l4_core__sr1 = { 2488 static struct omap_hwmod_ocp_if omap34xx_l4_core__sr1 = {
2492 .master = &omap3xxx_l4_core_hwmod, 2489 .master = &omap3xxx_l4_core_hwmod,
2493 .slave = &omap34xx_sr1_hwmod, 2490 .slave = &omap34xx_sr1_hwmod,
2494 .clk = "sr_l4_ick", 2491 .clk = "sr_l4_ick",
2495 .addr = omap3_sr1_addr_space, 2492 .addr = omap3_sr1_addr_space,
2496 .user = OCP_USER_MPU, 2493 .user = OCP_USER_MPU,
2497 }; 2494 };
2498 2495
2499 static struct omap_hwmod_ocp_if omap36xx_l4_core__sr1 = { 2496 static struct omap_hwmod_ocp_if omap36xx_l4_core__sr1 = {
2500 .master = &omap3xxx_l4_core_hwmod, 2497 .master = &omap3xxx_l4_core_hwmod,
2501 .slave = &omap36xx_sr1_hwmod, 2498 .slave = &omap36xx_sr1_hwmod,
2502 .clk = "sr_l4_ick", 2499 .clk = "sr_l4_ick",
2503 .addr = omap3_sr1_addr_space, 2500 .addr = omap3_sr1_addr_space,
2504 .user = OCP_USER_MPU, 2501 .user = OCP_USER_MPU,
2505 }; 2502 };
2506 2503
2507 /* L4 CORE -> SR1 interface */ 2504 /* L4 CORE -> SR1 interface */
2508 static struct omap_hwmod_addr_space omap3_sr2_addr_space[] = { 2505 static struct omap_hwmod_addr_space omap3_sr2_addr_space[] = {
2509 { 2506 {
2510 .pa_start = OMAP34XX_SR2_BASE, 2507 .pa_start = OMAP34XX_SR2_BASE,
2511 .pa_end = OMAP34XX_SR2_BASE + SZ_1K - 1, 2508 .pa_end = OMAP34XX_SR2_BASE + SZ_1K - 1,
2512 .flags = ADDR_TYPE_RT, 2509 .flags = ADDR_TYPE_RT,
2513 }, 2510 },
2514 { } 2511 { }
2515 }; 2512 };
2516 2513
2517 static struct omap_hwmod_ocp_if omap34xx_l4_core__sr2 = { 2514 static struct omap_hwmod_ocp_if omap34xx_l4_core__sr2 = {
2518 .master = &omap3xxx_l4_core_hwmod, 2515 .master = &omap3xxx_l4_core_hwmod,
2519 .slave = &omap34xx_sr2_hwmod, 2516 .slave = &omap34xx_sr2_hwmod,
2520 .clk = "sr_l4_ick", 2517 .clk = "sr_l4_ick",
2521 .addr = omap3_sr2_addr_space, 2518 .addr = omap3_sr2_addr_space,
2522 .user = OCP_USER_MPU, 2519 .user = OCP_USER_MPU,
2523 }; 2520 };
2524 2521
2525 static struct omap_hwmod_ocp_if omap36xx_l4_core__sr2 = { 2522 static struct omap_hwmod_ocp_if omap36xx_l4_core__sr2 = {
2526 .master = &omap3xxx_l4_core_hwmod, 2523 .master = &omap3xxx_l4_core_hwmod,
2527 .slave = &omap36xx_sr2_hwmod, 2524 .slave = &omap36xx_sr2_hwmod,
2528 .clk = "sr_l4_ick", 2525 .clk = "sr_l4_ick",
2529 .addr = omap3_sr2_addr_space, 2526 .addr = omap3_sr2_addr_space,
2530 .user = OCP_USER_MPU, 2527 .user = OCP_USER_MPU,
2531 }; 2528 };
2532 2529
2533 static struct omap_hwmod_addr_space omap3xxx_usbhsotg_addrs[] = { 2530 static struct omap_hwmod_addr_space omap3xxx_usbhsotg_addrs[] = {
2534 { 2531 {
2535 .pa_start = OMAP34XX_HSUSB_OTG_BASE, 2532 .pa_start = OMAP34XX_HSUSB_OTG_BASE,
2536 .pa_end = OMAP34XX_HSUSB_OTG_BASE + SZ_4K - 1, 2533 .pa_end = OMAP34XX_HSUSB_OTG_BASE + SZ_4K - 1,
2537 .flags = ADDR_TYPE_RT 2534 .flags = ADDR_TYPE_RT
2538 }, 2535 },
2539 { } 2536 { }
2540 }; 2537 };
2541 2538
2542 /* l4_core -> usbhsotg */ 2539 /* l4_core -> usbhsotg */
2543 static struct omap_hwmod_ocp_if omap3xxx_l4_core__usbhsotg = { 2540 static struct omap_hwmod_ocp_if omap3xxx_l4_core__usbhsotg = {
2544 .master = &omap3xxx_l4_core_hwmod, 2541 .master = &omap3xxx_l4_core_hwmod,
2545 .slave = &omap3xxx_usbhsotg_hwmod, 2542 .slave = &omap3xxx_usbhsotg_hwmod,
2546 .clk = "l4_ick", 2543 .clk = "l4_ick",
2547 .addr = omap3xxx_usbhsotg_addrs, 2544 .addr = omap3xxx_usbhsotg_addrs,
2548 .user = OCP_USER_MPU, 2545 .user = OCP_USER_MPU,
2549 }; 2546 };
2550 2547
2551 static struct omap_hwmod_addr_space am35xx_usbhsotg_addrs[] = { 2548 static struct omap_hwmod_addr_space am35xx_usbhsotg_addrs[] = {
2552 { 2549 {
2553 .pa_start = AM35XX_IPSS_USBOTGSS_BASE, 2550 .pa_start = AM35XX_IPSS_USBOTGSS_BASE,
2554 .pa_end = AM35XX_IPSS_USBOTGSS_BASE + SZ_4K - 1, 2551 .pa_end = AM35XX_IPSS_USBOTGSS_BASE + SZ_4K - 1,
2555 .flags = ADDR_TYPE_RT 2552 .flags = ADDR_TYPE_RT
2556 }, 2553 },
2557 { } 2554 { }
2558 }; 2555 };
2559 2556
2560 /* l4_core -> usbhsotg */ 2557 /* l4_core -> usbhsotg */
2561 static struct omap_hwmod_ocp_if am35xx_l4_core__usbhsotg = { 2558 static struct omap_hwmod_ocp_if am35xx_l4_core__usbhsotg = {
2562 .master = &omap3xxx_l4_core_hwmod, 2559 .master = &omap3xxx_l4_core_hwmod,
2563 .slave = &am35xx_usbhsotg_hwmod, 2560 .slave = &am35xx_usbhsotg_hwmod,
2564 .clk = "hsotgusb_ick", 2561 .clk = "hsotgusb_ick",
2565 .addr = am35xx_usbhsotg_addrs, 2562 .addr = am35xx_usbhsotg_addrs,
2566 .user = OCP_USER_MPU, 2563 .user = OCP_USER_MPU,
2567 }; 2564 };
2568 2565
2569 /* L4_WKUP -> L4_SEC interface */ 2566 /* L4_WKUP -> L4_SEC interface */
2570 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__l4_sec = { 2567 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__l4_sec = {
2571 .master = &omap3xxx_l4_wkup_hwmod, 2568 .master = &omap3xxx_l4_wkup_hwmod,
2572 .slave = &omap3xxx_l4_sec_hwmod, 2569 .slave = &omap3xxx_l4_sec_hwmod,
2573 .user = OCP_USER_MPU | OCP_USER_SDMA, 2570 .user = OCP_USER_MPU | OCP_USER_SDMA,
2574 }; 2571 };
2575 2572
2576 /* IVA2 <- L3 interface */ 2573 /* IVA2 <- L3 interface */
2577 static struct omap_hwmod_ocp_if omap3xxx_l3__iva = { 2574 static struct omap_hwmod_ocp_if omap3xxx_l3__iva = {
2578 .master = &omap3xxx_l3_main_hwmod, 2575 .master = &omap3xxx_l3_main_hwmod,
2579 .slave = &omap3xxx_iva_hwmod, 2576 .slave = &omap3xxx_iva_hwmod,
2580 .clk = "core_l3_ick", 2577 .clk = "core_l3_ick",
2581 .user = OCP_USER_MPU | OCP_USER_SDMA, 2578 .user = OCP_USER_MPU | OCP_USER_SDMA,
2582 }; 2579 };
2583 2580
2584 static struct omap_hwmod_addr_space omap3xxx_timer1_addrs[] = { 2581 static struct omap_hwmod_addr_space omap3xxx_timer1_addrs[] = {
2585 { 2582 {
2586 .pa_start = 0x48318000, 2583 .pa_start = 0x48318000,
2587 .pa_end = 0x48318000 + SZ_1K - 1, 2584 .pa_end = 0x48318000 + SZ_1K - 1,
2588 .flags = ADDR_TYPE_RT 2585 .flags = ADDR_TYPE_RT
2589 }, 2586 },
2590 { } 2587 { }
2591 }; 2588 };
2592 2589
2593 /* l4_wkup -> timer1 */ 2590 /* l4_wkup -> timer1 */
2594 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__timer1 = { 2591 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__timer1 = {
2595 .master = &omap3xxx_l4_wkup_hwmod, 2592 .master = &omap3xxx_l4_wkup_hwmod,
2596 .slave = &omap3xxx_timer1_hwmod, 2593 .slave = &omap3xxx_timer1_hwmod,
2597 .clk = "gpt1_ick", 2594 .clk = "gpt1_ick",
2598 .addr = omap3xxx_timer1_addrs, 2595 .addr = omap3xxx_timer1_addrs,
2599 .user = OCP_USER_MPU | OCP_USER_SDMA, 2596 .user = OCP_USER_MPU | OCP_USER_SDMA,
2600 }; 2597 };
2601 2598
2602 static struct omap_hwmod_addr_space omap3xxx_timer2_addrs[] = { 2599 static struct omap_hwmod_addr_space omap3xxx_timer2_addrs[] = {
2603 { 2600 {
2604 .pa_start = 0x49032000, 2601 .pa_start = 0x49032000,
2605 .pa_end = 0x49032000 + SZ_1K - 1, 2602 .pa_end = 0x49032000 + SZ_1K - 1,
2606 .flags = ADDR_TYPE_RT 2603 .flags = ADDR_TYPE_RT
2607 }, 2604 },
2608 { } 2605 { }
2609 }; 2606 };
2610 2607
2611 /* l4_per -> timer2 */ 2608 /* l4_per -> timer2 */
2612 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer2 = { 2609 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer2 = {
2613 .master = &omap3xxx_l4_per_hwmod, 2610 .master = &omap3xxx_l4_per_hwmod,
2614 .slave = &omap3xxx_timer2_hwmod, 2611 .slave = &omap3xxx_timer2_hwmod,
2615 .clk = "gpt2_ick", 2612 .clk = "gpt2_ick",
2616 .addr = omap3xxx_timer2_addrs, 2613 .addr = omap3xxx_timer2_addrs,
2617 .user = OCP_USER_MPU | OCP_USER_SDMA, 2614 .user = OCP_USER_MPU | OCP_USER_SDMA,
2618 }; 2615 };
2619 2616
2620 static struct omap_hwmod_addr_space omap3xxx_timer3_addrs[] = { 2617 static struct omap_hwmod_addr_space omap3xxx_timer3_addrs[] = {
2621 { 2618 {
2622 .pa_start = 0x49034000, 2619 .pa_start = 0x49034000,
2623 .pa_end = 0x49034000 + SZ_1K - 1, 2620 .pa_end = 0x49034000 + SZ_1K - 1,
2624 .flags = ADDR_TYPE_RT 2621 .flags = ADDR_TYPE_RT
2625 }, 2622 },
2626 { } 2623 { }
2627 }; 2624 };
2628 2625
2629 /* l4_per -> timer3 */ 2626 /* l4_per -> timer3 */
2630 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer3 = { 2627 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer3 = {
2631 .master = &omap3xxx_l4_per_hwmod, 2628 .master = &omap3xxx_l4_per_hwmod,
2632 .slave = &omap3xxx_timer3_hwmod, 2629 .slave = &omap3xxx_timer3_hwmod,
2633 .clk = "gpt3_ick", 2630 .clk = "gpt3_ick",
2634 .addr = omap3xxx_timer3_addrs, 2631 .addr = omap3xxx_timer3_addrs,
2635 .user = OCP_USER_MPU | OCP_USER_SDMA, 2632 .user = OCP_USER_MPU | OCP_USER_SDMA,
2636 }; 2633 };
2637 2634
2638 static struct omap_hwmod_addr_space omap3xxx_timer4_addrs[] = { 2635 static struct omap_hwmod_addr_space omap3xxx_timer4_addrs[] = {
2639 { 2636 {
2640 .pa_start = 0x49036000, 2637 .pa_start = 0x49036000,
2641 .pa_end = 0x49036000 + SZ_1K - 1, 2638 .pa_end = 0x49036000 + SZ_1K - 1,
2642 .flags = ADDR_TYPE_RT 2639 .flags = ADDR_TYPE_RT
2643 }, 2640 },
2644 { } 2641 { }
2645 }; 2642 };
2646 2643
2647 /* l4_per -> timer4 */ 2644 /* l4_per -> timer4 */
2648 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer4 = { 2645 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer4 = {
2649 .master = &omap3xxx_l4_per_hwmod, 2646 .master = &omap3xxx_l4_per_hwmod,
2650 .slave = &omap3xxx_timer4_hwmod, 2647 .slave = &omap3xxx_timer4_hwmod,
2651 .clk = "gpt4_ick", 2648 .clk = "gpt4_ick",
2652 .addr = omap3xxx_timer4_addrs, 2649 .addr = omap3xxx_timer4_addrs,
2653 .user = OCP_USER_MPU | OCP_USER_SDMA, 2650 .user = OCP_USER_MPU | OCP_USER_SDMA,
2654 }; 2651 };
2655 2652
2656 static struct omap_hwmod_addr_space omap3xxx_timer5_addrs[] = { 2653 static struct omap_hwmod_addr_space omap3xxx_timer5_addrs[] = {
2657 { 2654 {
2658 .pa_start = 0x49038000, 2655 .pa_start = 0x49038000,
2659 .pa_end = 0x49038000 + SZ_1K - 1, 2656 .pa_end = 0x49038000 + SZ_1K - 1,
2660 .flags = ADDR_TYPE_RT 2657 .flags = ADDR_TYPE_RT
2661 }, 2658 },
2662 { } 2659 { }
2663 }; 2660 };
2664 2661
2665 /* l4_per -> timer5 */ 2662 /* l4_per -> timer5 */
2666 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer5 = { 2663 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer5 = {
2667 .master = &omap3xxx_l4_per_hwmod, 2664 .master = &omap3xxx_l4_per_hwmod,
2668 .slave = &omap3xxx_timer5_hwmod, 2665 .slave = &omap3xxx_timer5_hwmod,
2669 .clk = "gpt5_ick", 2666 .clk = "gpt5_ick",
2670 .addr = omap3xxx_timer5_addrs, 2667 .addr = omap3xxx_timer5_addrs,
2671 .user = OCP_USER_MPU | OCP_USER_SDMA, 2668 .user = OCP_USER_MPU | OCP_USER_SDMA,
2672 }; 2669 };
2673 2670
2674 static struct omap_hwmod_addr_space omap3xxx_timer6_addrs[] = { 2671 static struct omap_hwmod_addr_space omap3xxx_timer6_addrs[] = {
2675 { 2672 {
2676 .pa_start = 0x4903A000, 2673 .pa_start = 0x4903A000,
2677 .pa_end = 0x4903A000 + SZ_1K - 1, 2674 .pa_end = 0x4903A000 + SZ_1K - 1,
2678 .flags = ADDR_TYPE_RT 2675 .flags = ADDR_TYPE_RT
2679 }, 2676 },
2680 { } 2677 { }
2681 }; 2678 };
2682 2679
2683 /* l4_per -> timer6 */ 2680 /* l4_per -> timer6 */
2684 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer6 = { 2681 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer6 = {
2685 .master = &omap3xxx_l4_per_hwmod, 2682 .master = &omap3xxx_l4_per_hwmod,
2686 .slave = &omap3xxx_timer6_hwmod, 2683 .slave = &omap3xxx_timer6_hwmod,
2687 .clk = "gpt6_ick", 2684 .clk = "gpt6_ick",
2688 .addr = omap3xxx_timer6_addrs, 2685 .addr = omap3xxx_timer6_addrs,
2689 .user = OCP_USER_MPU | OCP_USER_SDMA, 2686 .user = OCP_USER_MPU | OCP_USER_SDMA,
2690 }; 2687 };
2691 2688
2692 static struct omap_hwmod_addr_space omap3xxx_timer7_addrs[] = { 2689 static struct omap_hwmod_addr_space omap3xxx_timer7_addrs[] = {
2693 { 2690 {
2694 .pa_start = 0x4903C000, 2691 .pa_start = 0x4903C000,
2695 .pa_end = 0x4903C000 + SZ_1K - 1, 2692 .pa_end = 0x4903C000 + SZ_1K - 1,
2696 .flags = ADDR_TYPE_RT 2693 .flags = ADDR_TYPE_RT
2697 }, 2694 },
2698 { } 2695 { }
2699 }; 2696 };
2700 2697
2701 /* l4_per -> timer7 */ 2698 /* l4_per -> timer7 */
2702 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer7 = { 2699 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer7 = {
2703 .master = &omap3xxx_l4_per_hwmod, 2700 .master = &omap3xxx_l4_per_hwmod,
2704 .slave = &omap3xxx_timer7_hwmod, 2701 .slave = &omap3xxx_timer7_hwmod,
2705 .clk = "gpt7_ick", 2702 .clk = "gpt7_ick",
2706 .addr = omap3xxx_timer7_addrs, 2703 .addr = omap3xxx_timer7_addrs,
2707 .user = OCP_USER_MPU | OCP_USER_SDMA, 2704 .user = OCP_USER_MPU | OCP_USER_SDMA,
2708 }; 2705 };
2709 2706
2710 static struct omap_hwmod_addr_space omap3xxx_timer8_addrs[] = { 2707 static struct omap_hwmod_addr_space omap3xxx_timer8_addrs[] = {
2711 { 2708 {
2712 .pa_start = 0x4903E000, 2709 .pa_start = 0x4903E000,
2713 .pa_end = 0x4903E000 + SZ_1K - 1, 2710 .pa_end = 0x4903E000 + SZ_1K - 1,
2714 .flags = ADDR_TYPE_RT 2711 .flags = ADDR_TYPE_RT
2715 }, 2712 },
2716 { } 2713 { }
2717 }; 2714 };
2718 2715
2719 /* l4_per -> timer8 */ 2716 /* l4_per -> timer8 */
2720 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer8 = { 2717 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer8 = {
2721 .master = &omap3xxx_l4_per_hwmod, 2718 .master = &omap3xxx_l4_per_hwmod,
2722 .slave = &omap3xxx_timer8_hwmod, 2719 .slave = &omap3xxx_timer8_hwmod,
2723 .clk = "gpt8_ick", 2720 .clk = "gpt8_ick",
2724 .addr = omap3xxx_timer8_addrs, 2721 .addr = omap3xxx_timer8_addrs,
2725 .user = OCP_USER_MPU | OCP_USER_SDMA, 2722 .user = OCP_USER_MPU | OCP_USER_SDMA,
2726 }; 2723 };
2727 2724
2728 static struct omap_hwmod_addr_space omap3xxx_timer9_addrs[] = { 2725 static struct omap_hwmod_addr_space omap3xxx_timer9_addrs[] = {
2729 { 2726 {
2730 .pa_start = 0x49040000, 2727 .pa_start = 0x49040000,
2731 .pa_end = 0x49040000 + SZ_1K - 1, 2728 .pa_end = 0x49040000 + SZ_1K - 1,
2732 .flags = ADDR_TYPE_RT 2729 .flags = ADDR_TYPE_RT
2733 }, 2730 },
2734 { } 2731 { }
2735 }; 2732 };
2736 2733
2737 /* l4_per -> timer9 */ 2734 /* l4_per -> timer9 */
2738 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer9 = { 2735 static struct omap_hwmod_ocp_if omap3xxx_l4_per__timer9 = {
2739 .master = &omap3xxx_l4_per_hwmod, 2736 .master = &omap3xxx_l4_per_hwmod,
2740 .slave = &omap3xxx_timer9_hwmod, 2737 .slave = &omap3xxx_timer9_hwmod,
2741 .clk = "gpt9_ick", 2738 .clk = "gpt9_ick",
2742 .addr = omap3xxx_timer9_addrs, 2739 .addr = omap3xxx_timer9_addrs,
2743 .user = OCP_USER_MPU | OCP_USER_SDMA, 2740 .user = OCP_USER_MPU | OCP_USER_SDMA,
2744 }; 2741 };
2745 2742
2746 /* l4_core -> timer10 */ 2743 /* l4_core -> timer10 */
2747 static struct omap_hwmod_ocp_if omap3xxx_l4_core__timer10 = { 2744 static struct omap_hwmod_ocp_if omap3xxx_l4_core__timer10 = {
2748 .master = &omap3xxx_l4_core_hwmod, 2745 .master = &omap3xxx_l4_core_hwmod,
2749 .slave = &omap3xxx_timer10_hwmod, 2746 .slave = &omap3xxx_timer10_hwmod,
2750 .clk = "gpt10_ick", 2747 .clk = "gpt10_ick",
2751 .addr = omap2_timer10_addrs, 2748 .addr = omap2_timer10_addrs,
2752 .user = OCP_USER_MPU | OCP_USER_SDMA, 2749 .user = OCP_USER_MPU | OCP_USER_SDMA,
2753 }; 2750 };
2754 2751
2755 /* l4_core -> timer11 */ 2752 /* l4_core -> timer11 */
2756 static struct omap_hwmod_ocp_if omap3xxx_l4_core__timer11 = { 2753 static struct omap_hwmod_ocp_if omap3xxx_l4_core__timer11 = {
2757 .master = &omap3xxx_l4_core_hwmod, 2754 .master = &omap3xxx_l4_core_hwmod,
2758 .slave = &omap3xxx_timer11_hwmod, 2755 .slave = &omap3xxx_timer11_hwmod,
2759 .clk = "gpt11_ick", 2756 .clk = "gpt11_ick",
2760 .addr = omap2_timer11_addrs, 2757 .addr = omap2_timer11_addrs,
2761 .user = OCP_USER_MPU | OCP_USER_SDMA, 2758 .user = OCP_USER_MPU | OCP_USER_SDMA,
2762 }; 2759 };
2763 2760
2764 static struct omap_hwmod_addr_space omap3xxx_timer12_addrs[] = { 2761 static struct omap_hwmod_addr_space omap3xxx_timer12_addrs[] = {
2765 { 2762 {
2766 .pa_start = 0x48304000, 2763 .pa_start = 0x48304000,
2767 .pa_end = 0x48304000 + SZ_1K - 1, 2764 .pa_end = 0x48304000 + SZ_1K - 1,
2768 .flags = ADDR_TYPE_RT 2765 .flags = ADDR_TYPE_RT
2769 }, 2766 },
2770 { } 2767 { }
2771 }; 2768 };
2772 2769
2773 /* l4_core -> timer12 */ 2770 /* l4_core -> timer12 */
2774 static struct omap_hwmod_ocp_if omap3xxx_l4_sec__timer12 = { 2771 static struct omap_hwmod_ocp_if omap3xxx_l4_sec__timer12 = {
2775 .master = &omap3xxx_l4_sec_hwmod, 2772 .master = &omap3xxx_l4_sec_hwmod,
2776 .slave = &omap3xxx_timer12_hwmod, 2773 .slave = &omap3xxx_timer12_hwmod,
2777 .clk = "gpt12_ick", 2774 .clk = "gpt12_ick",
2778 .addr = omap3xxx_timer12_addrs, 2775 .addr = omap3xxx_timer12_addrs,
2779 .user = OCP_USER_MPU | OCP_USER_SDMA, 2776 .user = OCP_USER_MPU | OCP_USER_SDMA,
2780 }; 2777 };
2781 2778
2782 /* l4_wkup -> wd_timer2 */ 2779 /* l4_wkup -> wd_timer2 */
2783 static struct omap_hwmod_addr_space omap3xxx_wd_timer2_addrs[] = { 2780 static struct omap_hwmod_addr_space omap3xxx_wd_timer2_addrs[] = {
2784 { 2781 {
2785 .pa_start = 0x48314000, 2782 .pa_start = 0x48314000,
2786 .pa_end = 0x4831407f, 2783 .pa_end = 0x4831407f,
2787 .flags = ADDR_TYPE_RT 2784 .flags = ADDR_TYPE_RT
2788 }, 2785 },
2789 { } 2786 { }
2790 }; 2787 };
2791 2788
2792 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__wd_timer2 = { 2789 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__wd_timer2 = {
2793 .master = &omap3xxx_l4_wkup_hwmod, 2790 .master = &omap3xxx_l4_wkup_hwmod,
2794 .slave = &omap3xxx_wd_timer2_hwmod, 2791 .slave = &omap3xxx_wd_timer2_hwmod,
2795 .clk = "wdt2_ick", 2792 .clk = "wdt2_ick",
2796 .addr = omap3xxx_wd_timer2_addrs, 2793 .addr = omap3xxx_wd_timer2_addrs,
2797 .user = OCP_USER_MPU | OCP_USER_SDMA, 2794 .user = OCP_USER_MPU | OCP_USER_SDMA,
2798 }; 2795 };
2799 2796
2800 /* l4_core -> dss */ 2797 /* l4_core -> dss */
2801 static struct omap_hwmod_ocp_if omap3430es1_l4_core__dss = { 2798 static struct omap_hwmod_ocp_if omap3430es1_l4_core__dss = {
2802 .master = &omap3xxx_l4_core_hwmod, 2799 .master = &omap3xxx_l4_core_hwmod,
2803 .slave = &omap3430es1_dss_core_hwmod, 2800 .slave = &omap3430es1_dss_core_hwmod,
2804 .clk = "dss_ick", 2801 .clk = "dss_ick",
2805 .addr = omap2_dss_addrs, 2802 .addr = omap2_dss_addrs,
2806 .fw = { 2803 .fw = {
2807 .omap2 = { 2804 .omap2 = {
2808 .l4_fw_region = OMAP3ES1_L4_CORE_FW_DSS_CORE_REGION, 2805 .l4_fw_region = OMAP3ES1_L4_CORE_FW_DSS_CORE_REGION,
2809 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP, 2806 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
2810 .flags = OMAP_FIREWALL_L4, 2807 .flags = OMAP_FIREWALL_L4,
2811 } 2808 }
2812 }, 2809 },
2813 .user = OCP_USER_MPU | OCP_USER_SDMA, 2810 .user = OCP_USER_MPU | OCP_USER_SDMA,
2814 }; 2811 };
2815 2812
2816 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss = { 2813 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss = {
2817 .master = &omap3xxx_l4_core_hwmod, 2814 .master = &omap3xxx_l4_core_hwmod,
2818 .slave = &omap3xxx_dss_core_hwmod, 2815 .slave = &omap3xxx_dss_core_hwmod,
2819 .clk = "dss_ick", 2816 .clk = "dss_ick",
2820 .addr = omap2_dss_addrs, 2817 .addr = omap2_dss_addrs,
2821 .fw = { 2818 .fw = {
2822 .omap2 = { 2819 .omap2 = {
2823 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_CORE_REGION, 2820 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_CORE_REGION,
2824 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP, 2821 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
2825 .flags = OMAP_FIREWALL_L4, 2822 .flags = OMAP_FIREWALL_L4,
2826 } 2823 }
2827 }, 2824 },
2828 .user = OCP_USER_MPU | OCP_USER_SDMA, 2825 .user = OCP_USER_MPU | OCP_USER_SDMA,
2829 }; 2826 };
2830 2827
2831 /* l4_core -> dss_dispc */ 2828 /* l4_core -> dss_dispc */
2832 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_dispc = { 2829 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_dispc = {
2833 .master = &omap3xxx_l4_core_hwmod, 2830 .master = &omap3xxx_l4_core_hwmod,
2834 .slave = &omap3xxx_dss_dispc_hwmod, 2831 .slave = &omap3xxx_dss_dispc_hwmod,
2835 .clk = "dss_ick", 2832 .clk = "dss_ick",
2836 .addr = omap2_dss_dispc_addrs, 2833 .addr = omap2_dss_dispc_addrs,
2837 .fw = { 2834 .fw = {
2838 .omap2 = { 2835 .omap2 = {
2839 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_DISPC_REGION, 2836 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_DISPC_REGION,
2840 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP, 2837 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
2841 .flags = OMAP_FIREWALL_L4, 2838 .flags = OMAP_FIREWALL_L4,
2842 } 2839 }
2843 }, 2840 },
2844 .user = OCP_USER_MPU | OCP_USER_SDMA, 2841 .user = OCP_USER_MPU | OCP_USER_SDMA,
2845 }; 2842 };
2846 2843
2847 static struct omap_hwmod_addr_space omap3xxx_dss_dsi1_addrs[] = { 2844 static struct omap_hwmod_addr_space omap3xxx_dss_dsi1_addrs[] = {
2848 { 2845 {
2849 .pa_start = 0x4804FC00, 2846 .pa_start = 0x4804FC00,
2850 .pa_end = 0x4804FFFF, 2847 .pa_end = 0x4804FFFF,
2851 .flags = ADDR_TYPE_RT 2848 .flags = ADDR_TYPE_RT
2852 }, 2849 },
2853 { } 2850 { }
2854 }; 2851 };
2855 2852
2856 /* l4_core -> dss_dsi1 */ 2853 /* l4_core -> dss_dsi1 */
2857 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_dsi1 = { 2854 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_dsi1 = {
2858 .master = &omap3xxx_l4_core_hwmod, 2855 .master = &omap3xxx_l4_core_hwmod,
2859 .slave = &omap3xxx_dss_dsi1_hwmod, 2856 .slave = &omap3xxx_dss_dsi1_hwmod,
2860 .clk = "dss_ick", 2857 .clk = "dss_ick",
2861 .addr = omap3xxx_dss_dsi1_addrs, 2858 .addr = omap3xxx_dss_dsi1_addrs,
2862 .fw = { 2859 .fw = {
2863 .omap2 = { 2860 .omap2 = {
2864 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_DSI_REGION, 2861 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_DSI_REGION,
2865 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP, 2862 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
2866 .flags = OMAP_FIREWALL_L4, 2863 .flags = OMAP_FIREWALL_L4,
2867 } 2864 }
2868 }, 2865 },
2869 .user = OCP_USER_MPU | OCP_USER_SDMA, 2866 .user = OCP_USER_MPU | OCP_USER_SDMA,
2870 }; 2867 };
2871 2868
2872 /* l4_core -> dss_rfbi */ 2869 /* l4_core -> dss_rfbi */
2873 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_rfbi = { 2870 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_rfbi = {
2874 .master = &omap3xxx_l4_core_hwmod, 2871 .master = &omap3xxx_l4_core_hwmod,
2875 .slave = &omap3xxx_dss_rfbi_hwmod, 2872 .slave = &omap3xxx_dss_rfbi_hwmod,
2876 .clk = "dss_ick", 2873 .clk = "dss_ick",
2877 .addr = omap2_dss_rfbi_addrs, 2874 .addr = omap2_dss_rfbi_addrs,
2878 .fw = { 2875 .fw = {
2879 .omap2 = { 2876 .omap2 = {
2880 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_RFBI_REGION, 2877 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_RFBI_REGION,
2881 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP , 2878 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP ,
2882 .flags = OMAP_FIREWALL_L4, 2879 .flags = OMAP_FIREWALL_L4,
2883 } 2880 }
2884 }, 2881 },
2885 .user = OCP_USER_MPU | OCP_USER_SDMA, 2882 .user = OCP_USER_MPU | OCP_USER_SDMA,
2886 }; 2883 };
2887 2884
2888 /* l4_core -> dss_venc */ 2885 /* l4_core -> dss_venc */
2889 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_venc = { 2886 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dss_venc = {
2890 .master = &omap3xxx_l4_core_hwmod, 2887 .master = &omap3xxx_l4_core_hwmod,
2891 .slave = &omap3xxx_dss_venc_hwmod, 2888 .slave = &omap3xxx_dss_venc_hwmod,
2892 .clk = "dss_ick", 2889 .clk = "dss_ick",
2893 .addr = omap2_dss_venc_addrs, 2890 .addr = omap2_dss_venc_addrs,
2894 .fw = { 2891 .fw = {
2895 .omap2 = { 2892 .omap2 = {
2896 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_VENC_REGION, 2893 .l4_fw_region = OMAP3_L4_CORE_FW_DSS_VENC_REGION,
2897 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP, 2894 .l4_prot_group = OMAP3_L4_CORE_FW_DSS_PROT_GROUP,
2898 .flags = OMAP_FIREWALL_L4, 2895 .flags = OMAP_FIREWALL_L4,
2899 } 2896 }
2900 }, 2897 },
2901 .flags = OCPIF_SWSUP_IDLE, 2898 .flags = OCPIF_SWSUP_IDLE,
2902 .user = OCP_USER_MPU | OCP_USER_SDMA, 2899 .user = OCP_USER_MPU | OCP_USER_SDMA,
2903 }; 2900 };
2904 2901
2905 /* l4_wkup -> gpio1 */ 2902 /* l4_wkup -> gpio1 */
2906 static struct omap_hwmod_addr_space omap3xxx_gpio1_addrs[] = { 2903 static struct omap_hwmod_addr_space omap3xxx_gpio1_addrs[] = {
2907 { 2904 {
2908 .pa_start = 0x48310000, 2905 .pa_start = 0x48310000,
2909 .pa_end = 0x483101ff, 2906 .pa_end = 0x483101ff,
2910 .flags = ADDR_TYPE_RT 2907 .flags = ADDR_TYPE_RT
2911 }, 2908 },
2912 { } 2909 { }
2913 }; 2910 };
2914 2911
2915 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__gpio1 = { 2912 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__gpio1 = {
2916 .master = &omap3xxx_l4_wkup_hwmod, 2913 .master = &omap3xxx_l4_wkup_hwmod,
2917 .slave = &omap3xxx_gpio1_hwmod, 2914 .slave = &omap3xxx_gpio1_hwmod,
2918 .addr = omap3xxx_gpio1_addrs, 2915 .addr = omap3xxx_gpio1_addrs,
2919 .user = OCP_USER_MPU | OCP_USER_SDMA, 2916 .user = OCP_USER_MPU | OCP_USER_SDMA,
2920 }; 2917 };
2921 2918
2922 /* l4_per -> gpio2 */ 2919 /* l4_per -> gpio2 */
2923 static struct omap_hwmod_addr_space omap3xxx_gpio2_addrs[] = { 2920 static struct omap_hwmod_addr_space omap3xxx_gpio2_addrs[] = {
2924 { 2921 {
2925 .pa_start = 0x49050000, 2922 .pa_start = 0x49050000,
2926 .pa_end = 0x490501ff, 2923 .pa_end = 0x490501ff,
2927 .flags = ADDR_TYPE_RT 2924 .flags = ADDR_TYPE_RT
2928 }, 2925 },
2929 { } 2926 { }
2930 }; 2927 };
2931 2928
2932 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio2 = { 2929 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio2 = {
2933 .master = &omap3xxx_l4_per_hwmod, 2930 .master = &omap3xxx_l4_per_hwmod,
2934 .slave = &omap3xxx_gpio2_hwmod, 2931 .slave = &omap3xxx_gpio2_hwmod,
2935 .addr = omap3xxx_gpio2_addrs, 2932 .addr = omap3xxx_gpio2_addrs,
2936 .user = OCP_USER_MPU | OCP_USER_SDMA, 2933 .user = OCP_USER_MPU | OCP_USER_SDMA,
2937 }; 2934 };
2938 2935
2939 /* l4_per -> gpio3 */ 2936 /* l4_per -> gpio3 */
2940 static struct omap_hwmod_addr_space omap3xxx_gpio3_addrs[] = { 2937 static struct omap_hwmod_addr_space omap3xxx_gpio3_addrs[] = {
2941 { 2938 {
2942 .pa_start = 0x49052000, 2939 .pa_start = 0x49052000,
2943 .pa_end = 0x490521ff, 2940 .pa_end = 0x490521ff,
2944 .flags = ADDR_TYPE_RT 2941 .flags = ADDR_TYPE_RT
2945 }, 2942 },
2946 { } 2943 { }
2947 }; 2944 };
2948 2945
2949 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio3 = { 2946 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio3 = {
2950 .master = &omap3xxx_l4_per_hwmod, 2947 .master = &omap3xxx_l4_per_hwmod,
2951 .slave = &omap3xxx_gpio3_hwmod, 2948 .slave = &omap3xxx_gpio3_hwmod,
2952 .addr = omap3xxx_gpio3_addrs, 2949 .addr = omap3xxx_gpio3_addrs,
2953 .user = OCP_USER_MPU | OCP_USER_SDMA, 2950 .user = OCP_USER_MPU | OCP_USER_SDMA,
2954 }; 2951 };
2955 2952
2956 /* 2953 /*
2957 * 'mmu' class 2954 * 'mmu' class
2958 * The memory management unit performs virtual to physical address translation 2955 * The memory management unit performs virtual to physical address translation
2959 * for its requestors. 2956 * for its requestors.
2960 */ 2957 */
2961 2958
2962 static struct omap_hwmod_class_sysconfig mmu_sysc = { 2959 static struct omap_hwmod_class_sysconfig mmu_sysc = {
2963 .rev_offs = 0x000, 2960 .rev_offs = 0x000,
2964 .sysc_offs = 0x010, 2961 .sysc_offs = 0x010,
2965 .syss_offs = 0x014, 2962 .syss_offs = 0x014,
2966 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 2963 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
2967 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE), 2964 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
2968 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 2965 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2969 .sysc_fields = &omap_hwmod_sysc_type1, 2966 .sysc_fields = &omap_hwmod_sysc_type1,
2970 }; 2967 };
2971 2968
2972 static struct omap_hwmod_class omap3xxx_mmu_hwmod_class = { 2969 static struct omap_hwmod_class omap3xxx_mmu_hwmod_class = {
2973 .name = "mmu", 2970 .name = "mmu",
2974 .sysc = &mmu_sysc, 2971 .sysc = &mmu_sysc,
2975 }; 2972 };
2976 2973
2977 /* mmu isp */ 2974 /* mmu isp */
2978 2975
2979 static struct omap_mmu_dev_attr mmu_isp_dev_attr = { 2976 static struct omap_mmu_dev_attr mmu_isp_dev_attr = {
2980 .da_start = 0x0, 2977 .da_start = 0x0,
2981 .da_end = 0xfffff000, 2978 .da_end = 0xfffff000,
2982 .nr_tlb_entries = 8, 2979 .nr_tlb_entries = 8,
2983 }; 2980 };
2984 2981
2985 static struct omap_hwmod omap3xxx_mmu_isp_hwmod; 2982 static struct omap_hwmod omap3xxx_mmu_isp_hwmod;
2986 static struct omap_hwmod_irq_info omap3xxx_mmu_isp_irqs[] = { 2983 static struct omap_hwmod_irq_info omap3xxx_mmu_isp_irqs[] = {
2987 { .irq = 24 }, 2984 { .irq = 24 },
2988 { .irq = -1 } 2985 { .irq = -1 }
2989 }; 2986 };
2990 2987
2991 static struct omap_hwmod_addr_space omap3xxx_mmu_isp_addrs[] = { 2988 static struct omap_hwmod_addr_space omap3xxx_mmu_isp_addrs[] = {
2992 { 2989 {
2993 .pa_start = 0x480bd400, 2990 .pa_start = 0x480bd400,
2994 .pa_end = 0x480bd47f, 2991 .pa_end = 0x480bd47f,
2995 .flags = ADDR_TYPE_RT, 2992 .flags = ADDR_TYPE_RT,
2996 }, 2993 },
2997 { } 2994 { }
2998 }; 2995 };
2999 2996
3000 /* l4_core -> mmu isp */ 2997 /* l4_core -> mmu isp */
3001 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mmu_isp = { 2998 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mmu_isp = {
3002 .master = &omap3xxx_l4_core_hwmod, 2999 .master = &omap3xxx_l4_core_hwmod,
3003 .slave = &omap3xxx_mmu_isp_hwmod, 3000 .slave = &omap3xxx_mmu_isp_hwmod,
3004 .addr = omap3xxx_mmu_isp_addrs, 3001 .addr = omap3xxx_mmu_isp_addrs,
3005 .user = OCP_USER_MPU | OCP_USER_SDMA, 3002 .user = OCP_USER_MPU | OCP_USER_SDMA,
3006 }; 3003 };
3007 3004
3008 static struct omap_hwmod omap3xxx_mmu_isp_hwmod = { 3005 static struct omap_hwmod omap3xxx_mmu_isp_hwmod = {
3009 .name = "mmu_isp", 3006 .name = "mmu_isp",
3010 .class = &omap3xxx_mmu_hwmod_class, 3007 .class = &omap3xxx_mmu_hwmod_class,
3011 .mpu_irqs = omap3xxx_mmu_isp_irqs, 3008 .mpu_irqs = omap3xxx_mmu_isp_irqs,
3012 .main_clk = "cam_ick", 3009 .main_clk = "cam_ick",
3013 .dev_attr = &mmu_isp_dev_attr, 3010 .dev_attr = &mmu_isp_dev_attr,
3014 .flags = HWMOD_NO_IDLEST, 3011 .flags = HWMOD_NO_IDLEST,
3015 }; 3012 };
3016 3013
3017 #ifdef CONFIG_OMAP_IOMMU_IVA2 3014 #ifdef CONFIG_OMAP_IOMMU_IVA2
3018 3015
3019 /* mmu iva */ 3016 /* mmu iva */
3020 3017
3021 static struct omap_mmu_dev_attr mmu_iva_dev_attr = { 3018 static struct omap_mmu_dev_attr mmu_iva_dev_attr = {
3022 .da_start = 0x11000000, 3019 .da_start = 0x11000000,
3023 .da_end = 0xfffff000, 3020 .da_end = 0xfffff000,
3024 .nr_tlb_entries = 32, 3021 .nr_tlb_entries = 32,
3025 }; 3022 };
3026 3023
3027 static struct omap_hwmod omap3xxx_mmu_iva_hwmod; 3024 static struct omap_hwmod omap3xxx_mmu_iva_hwmod;
3028 static struct omap_hwmod_irq_info omap3xxx_mmu_iva_irqs[] = { 3025 static struct omap_hwmod_irq_info omap3xxx_mmu_iva_irqs[] = {
3029 { .irq = 28 }, 3026 { .irq = 28 },
3030 { .irq = -1 } 3027 { .irq = -1 }
3031 }; 3028 };
3032 3029
3033 static struct omap_hwmod_rst_info omap3xxx_mmu_iva_resets[] = { 3030 static struct omap_hwmod_rst_info omap3xxx_mmu_iva_resets[] = {
3034 { .name = "mmu", .rst_shift = 1, .st_shift = 9 }, 3031 { .name = "mmu", .rst_shift = 1, .st_shift = 9 },
3035 }; 3032 };
3036 3033
3037 static struct omap_hwmod_addr_space omap3xxx_mmu_iva_addrs[] = { 3034 static struct omap_hwmod_addr_space omap3xxx_mmu_iva_addrs[] = {
3038 { 3035 {
3039 .pa_start = 0x5d000000, 3036 .pa_start = 0x5d000000,
3040 .pa_end = 0x5d00007f, 3037 .pa_end = 0x5d00007f,
3041 .flags = ADDR_TYPE_RT, 3038 .flags = ADDR_TYPE_RT,
3042 }, 3039 },
3043 { } 3040 { }
3044 }; 3041 };
3045 3042
3046 /* l3_main -> iva mmu */ 3043 /* l3_main -> iva mmu */
3047 static struct omap_hwmod_ocp_if omap3xxx_l3_main__mmu_iva = { 3044 static struct omap_hwmod_ocp_if omap3xxx_l3_main__mmu_iva = {
3048 .master = &omap3xxx_l3_main_hwmod, 3045 .master = &omap3xxx_l3_main_hwmod,
3049 .slave = &omap3xxx_mmu_iva_hwmod, 3046 .slave = &omap3xxx_mmu_iva_hwmod,
3050 .addr = omap3xxx_mmu_iva_addrs, 3047 .addr = omap3xxx_mmu_iva_addrs,
3051 .user = OCP_USER_MPU | OCP_USER_SDMA, 3048 .user = OCP_USER_MPU | OCP_USER_SDMA,
3052 }; 3049 };
3053 3050
3054 static struct omap_hwmod omap3xxx_mmu_iva_hwmod = { 3051 static struct omap_hwmod omap3xxx_mmu_iva_hwmod = {
3055 .name = "mmu_iva", 3052 .name = "mmu_iva",
3056 .class = &omap3xxx_mmu_hwmod_class, 3053 .class = &omap3xxx_mmu_hwmod_class,
3057 .mpu_irqs = omap3xxx_mmu_iva_irqs, 3054 .mpu_irqs = omap3xxx_mmu_iva_irqs,
3058 .rst_lines = omap3xxx_mmu_iva_resets, 3055 .rst_lines = omap3xxx_mmu_iva_resets,
3059 .rst_lines_cnt = ARRAY_SIZE(omap3xxx_mmu_iva_resets), 3056 .rst_lines_cnt = ARRAY_SIZE(omap3xxx_mmu_iva_resets),
3060 .main_clk = "iva2_ck", 3057 .main_clk = "iva2_ck",
3061 .prcm = { 3058 .prcm = {
3062 .omap2 = { 3059 .omap2 = {
3063 .module_offs = OMAP3430_IVA2_MOD, 3060 .module_offs = OMAP3430_IVA2_MOD,
3064 }, 3061 },
3065 }, 3062 },
3066 .dev_attr = &mmu_iva_dev_attr, 3063 .dev_attr = &mmu_iva_dev_attr,
3067 .flags = HWMOD_NO_IDLEST, 3064 .flags = HWMOD_NO_IDLEST,
3068 }; 3065 };
3069 3066
3070 #endif 3067 #endif
3071 3068
3072 /* l4_per -> gpio4 */ 3069 /* l4_per -> gpio4 */
3073 static struct omap_hwmod_addr_space omap3xxx_gpio4_addrs[] = { 3070 static struct omap_hwmod_addr_space omap3xxx_gpio4_addrs[] = {
3074 { 3071 {
3075 .pa_start = 0x49054000, 3072 .pa_start = 0x49054000,
3076 .pa_end = 0x490541ff, 3073 .pa_end = 0x490541ff,
3077 .flags = ADDR_TYPE_RT 3074 .flags = ADDR_TYPE_RT
3078 }, 3075 },
3079 { } 3076 { }
3080 }; 3077 };
3081 3078
3082 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio4 = { 3079 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio4 = {
3083 .master = &omap3xxx_l4_per_hwmod, 3080 .master = &omap3xxx_l4_per_hwmod,
3084 .slave = &omap3xxx_gpio4_hwmod, 3081 .slave = &omap3xxx_gpio4_hwmod,
3085 .addr = omap3xxx_gpio4_addrs, 3082 .addr = omap3xxx_gpio4_addrs,
3086 .user = OCP_USER_MPU | OCP_USER_SDMA, 3083 .user = OCP_USER_MPU | OCP_USER_SDMA,
3087 }; 3084 };
3088 3085
3089 /* l4_per -> gpio5 */ 3086 /* l4_per -> gpio5 */
3090 static struct omap_hwmod_addr_space omap3xxx_gpio5_addrs[] = { 3087 static struct omap_hwmod_addr_space omap3xxx_gpio5_addrs[] = {
3091 { 3088 {
3092 .pa_start = 0x49056000, 3089 .pa_start = 0x49056000,
3093 .pa_end = 0x490561ff, 3090 .pa_end = 0x490561ff,
3094 .flags = ADDR_TYPE_RT 3091 .flags = ADDR_TYPE_RT
3095 }, 3092 },
3096 { } 3093 { }
3097 }; 3094 };
3098 3095
3099 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio5 = { 3096 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio5 = {
3100 .master = &omap3xxx_l4_per_hwmod, 3097 .master = &omap3xxx_l4_per_hwmod,
3101 .slave = &omap3xxx_gpio5_hwmod, 3098 .slave = &omap3xxx_gpio5_hwmod,
3102 .addr = omap3xxx_gpio5_addrs, 3099 .addr = omap3xxx_gpio5_addrs,
3103 .user = OCP_USER_MPU | OCP_USER_SDMA, 3100 .user = OCP_USER_MPU | OCP_USER_SDMA,
3104 }; 3101 };
3105 3102
3106 /* l4_per -> gpio6 */ 3103 /* l4_per -> gpio6 */
3107 static struct omap_hwmod_addr_space omap3xxx_gpio6_addrs[] = { 3104 static struct omap_hwmod_addr_space omap3xxx_gpio6_addrs[] = {
3108 { 3105 {
3109 .pa_start = 0x49058000, 3106 .pa_start = 0x49058000,
3110 .pa_end = 0x490581ff, 3107 .pa_end = 0x490581ff,
3111 .flags = ADDR_TYPE_RT 3108 .flags = ADDR_TYPE_RT
3112 }, 3109 },
3113 { } 3110 { }
3114 }; 3111 };
3115 3112
3116 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio6 = { 3113 static struct omap_hwmod_ocp_if omap3xxx_l4_per__gpio6 = {
3117 .master = &omap3xxx_l4_per_hwmod, 3114 .master = &omap3xxx_l4_per_hwmod,
3118 .slave = &omap3xxx_gpio6_hwmod, 3115 .slave = &omap3xxx_gpio6_hwmod,
3119 .addr = omap3xxx_gpio6_addrs, 3116 .addr = omap3xxx_gpio6_addrs,
3120 .user = OCP_USER_MPU | OCP_USER_SDMA, 3117 .user = OCP_USER_MPU | OCP_USER_SDMA,
3121 }; 3118 };
3122 3119
3123 /* dma_system -> L3 */ 3120 /* dma_system -> L3 */
3124 static struct omap_hwmod_ocp_if omap3xxx_dma_system__l3 = { 3121 static struct omap_hwmod_ocp_if omap3xxx_dma_system__l3 = {
3125 .master = &omap3xxx_dma_system_hwmod, 3122 .master = &omap3xxx_dma_system_hwmod,
3126 .slave = &omap3xxx_l3_main_hwmod, 3123 .slave = &omap3xxx_l3_main_hwmod,
3127 .clk = "core_l3_ick", 3124 .clk = "core_l3_ick",
3128 .user = OCP_USER_MPU | OCP_USER_SDMA, 3125 .user = OCP_USER_MPU | OCP_USER_SDMA,
3129 }; 3126 };
3130 3127
3131 static struct omap_hwmod_addr_space omap3xxx_dma_system_addrs[] = { 3128 static struct omap_hwmod_addr_space omap3xxx_dma_system_addrs[] = {
3132 { 3129 {
3133 .pa_start = 0x48056000, 3130 .pa_start = 0x48056000,
3134 .pa_end = 0x48056fff, 3131 .pa_end = 0x48056fff,
3135 .flags = ADDR_TYPE_RT 3132 .flags = ADDR_TYPE_RT
3136 }, 3133 },
3137 { } 3134 { }
3138 }; 3135 };
3139 3136
3140 /* l4_cfg -> dma_system */ 3137 /* l4_cfg -> dma_system */
3141 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dma_system = { 3138 static struct omap_hwmod_ocp_if omap3xxx_l4_core__dma_system = {
3142 .master = &omap3xxx_l4_core_hwmod, 3139 .master = &omap3xxx_l4_core_hwmod,
3143 .slave = &omap3xxx_dma_system_hwmod, 3140 .slave = &omap3xxx_dma_system_hwmod,
3144 .clk = "core_l4_ick", 3141 .clk = "core_l4_ick",
3145 .addr = omap3xxx_dma_system_addrs, 3142 .addr = omap3xxx_dma_system_addrs,
3146 .user = OCP_USER_MPU | OCP_USER_SDMA, 3143 .user = OCP_USER_MPU | OCP_USER_SDMA,
3147 }; 3144 };
3148 3145
3149 static struct omap_hwmod_addr_space omap3xxx_mcbsp1_addrs[] = { 3146 static struct omap_hwmod_addr_space omap3xxx_mcbsp1_addrs[] = {
3150 { 3147 {
3151 .name = "mpu", 3148 .name = "mpu",
3152 .pa_start = 0x48074000, 3149 .pa_start = 0x48074000,
3153 .pa_end = 0x480740ff, 3150 .pa_end = 0x480740ff,
3154 .flags = ADDR_TYPE_RT 3151 .flags = ADDR_TYPE_RT
3155 }, 3152 },
3156 { } 3153 { }
3157 }; 3154 };
3158 3155
3159 /* l4_core -> mcbsp1 */ 3156 /* l4_core -> mcbsp1 */
3160 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mcbsp1 = { 3157 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mcbsp1 = {
3161 .master = &omap3xxx_l4_core_hwmod, 3158 .master = &omap3xxx_l4_core_hwmod,
3162 .slave = &omap3xxx_mcbsp1_hwmod, 3159 .slave = &omap3xxx_mcbsp1_hwmod,
3163 .clk = "mcbsp1_ick", 3160 .clk = "mcbsp1_ick",
3164 .addr = omap3xxx_mcbsp1_addrs, 3161 .addr = omap3xxx_mcbsp1_addrs,
3165 .user = OCP_USER_MPU | OCP_USER_SDMA, 3162 .user = OCP_USER_MPU | OCP_USER_SDMA,
3166 }; 3163 };
3167 3164
3168 static struct omap_hwmod_addr_space omap3xxx_mcbsp2_addrs[] = { 3165 static struct omap_hwmod_addr_space omap3xxx_mcbsp2_addrs[] = {
3169 { 3166 {
3170 .name = "mpu", 3167 .name = "mpu",
3171 .pa_start = 0x49022000, 3168 .pa_start = 0x49022000,
3172 .pa_end = 0x490220ff, 3169 .pa_end = 0x490220ff,
3173 .flags = ADDR_TYPE_RT 3170 .flags = ADDR_TYPE_RT
3174 }, 3171 },
3175 { } 3172 { }
3176 }; 3173 };
3177 3174
3178 /* l4_per -> mcbsp2 */ 3175 /* l4_per -> mcbsp2 */
3179 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp2 = { 3176 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp2 = {
3180 .master = &omap3xxx_l4_per_hwmod, 3177 .master = &omap3xxx_l4_per_hwmod,
3181 .slave = &omap3xxx_mcbsp2_hwmod, 3178 .slave = &omap3xxx_mcbsp2_hwmod,
3182 .clk = "mcbsp2_ick", 3179 .clk = "mcbsp2_ick",
3183 .addr = omap3xxx_mcbsp2_addrs, 3180 .addr = omap3xxx_mcbsp2_addrs,
3184 .user = OCP_USER_MPU | OCP_USER_SDMA, 3181 .user = OCP_USER_MPU | OCP_USER_SDMA,
3185 }; 3182 };
3186 3183
3187 static struct omap_hwmod_addr_space omap3xxx_mcbsp3_addrs[] = { 3184 static struct omap_hwmod_addr_space omap3xxx_mcbsp3_addrs[] = {
3188 { 3185 {
3189 .name = "mpu", 3186 .name = "mpu",
3190 .pa_start = 0x49024000, 3187 .pa_start = 0x49024000,
3191 .pa_end = 0x490240ff, 3188 .pa_end = 0x490240ff,
3192 .flags = ADDR_TYPE_RT 3189 .flags = ADDR_TYPE_RT
3193 }, 3190 },
3194 { } 3191 { }
3195 }; 3192 };
3196 3193
3197 /* l4_per -> mcbsp3 */ 3194 /* l4_per -> mcbsp3 */
3198 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp3 = { 3195 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp3 = {
3199 .master = &omap3xxx_l4_per_hwmod, 3196 .master = &omap3xxx_l4_per_hwmod,
3200 .slave = &omap3xxx_mcbsp3_hwmod, 3197 .slave = &omap3xxx_mcbsp3_hwmod,
3201 .clk = "mcbsp3_ick", 3198 .clk = "mcbsp3_ick",
3202 .addr = omap3xxx_mcbsp3_addrs, 3199 .addr = omap3xxx_mcbsp3_addrs,
3203 .user = OCP_USER_MPU | OCP_USER_SDMA, 3200 .user = OCP_USER_MPU | OCP_USER_SDMA,
3204 }; 3201 };
3205 3202
3206 static struct omap_hwmod_addr_space omap3xxx_mcbsp4_addrs[] = { 3203 static struct omap_hwmod_addr_space omap3xxx_mcbsp4_addrs[] = {
3207 { 3204 {
3208 .name = "mpu", 3205 .name = "mpu",
3209 .pa_start = 0x49026000, 3206 .pa_start = 0x49026000,
3210 .pa_end = 0x490260ff, 3207 .pa_end = 0x490260ff,
3211 .flags = ADDR_TYPE_RT 3208 .flags = ADDR_TYPE_RT
3212 }, 3209 },
3213 { } 3210 { }
3214 }; 3211 };
3215 3212
3216 /* l4_per -> mcbsp4 */ 3213 /* l4_per -> mcbsp4 */
3217 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp4 = { 3214 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp4 = {
3218 .master = &omap3xxx_l4_per_hwmod, 3215 .master = &omap3xxx_l4_per_hwmod,
3219 .slave = &omap3xxx_mcbsp4_hwmod, 3216 .slave = &omap3xxx_mcbsp4_hwmod,
3220 .clk = "mcbsp4_ick", 3217 .clk = "mcbsp4_ick",
3221 .addr = omap3xxx_mcbsp4_addrs, 3218 .addr = omap3xxx_mcbsp4_addrs,
3222 .user = OCP_USER_MPU | OCP_USER_SDMA, 3219 .user = OCP_USER_MPU | OCP_USER_SDMA,
3223 }; 3220 };
3224 3221
3225 static struct omap_hwmod_addr_space omap3xxx_mcbsp5_addrs[] = { 3222 static struct omap_hwmod_addr_space omap3xxx_mcbsp5_addrs[] = {
3226 { 3223 {
3227 .name = "mpu", 3224 .name = "mpu",
3228 .pa_start = 0x48096000, 3225 .pa_start = 0x48096000,
3229 .pa_end = 0x480960ff, 3226 .pa_end = 0x480960ff,
3230 .flags = ADDR_TYPE_RT 3227 .flags = ADDR_TYPE_RT
3231 }, 3228 },
3232 { } 3229 { }
3233 }; 3230 };
3234 3231
3235 /* l4_core -> mcbsp5 */ 3232 /* l4_core -> mcbsp5 */
3236 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mcbsp5 = { 3233 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mcbsp5 = {
3237 .master = &omap3xxx_l4_core_hwmod, 3234 .master = &omap3xxx_l4_core_hwmod,
3238 .slave = &omap3xxx_mcbsp5_hwmod, 3235 .slave = &omap3xxx_mcbsp5_hwmod,
3239 .clk = "mcbsp5_ick", 3236 .clk = "mcbsp5_ick",
3240 .addr = omap3xxx_mcbsp5_addrs, 3237 .addr = omap3xxx_mcbsp5_addrs,
3241 .user = OCP_USER_MPU | OCP_USER_SDMA, 3238 .user = OCP_USER_MPU | OCP_USER_SDMA,
3242 }; 3239 };
3243 3240
3244 static struct omap_hwmod_addr_space omap3xxx_mcbsp2_sidetone_addrs[] = { 3241 static struct omap_hwmod_addr_space omap3xxx_mcbsp2_sidetone_addrs[] = {
3245 { 3242 {
3246 .name = "sidetone", 3243 .name = "sidetone",
3247 .pa_start = 0x49028000, 3244 .pa_start = 0x49028000,
3248 .pa_end = 0x490280ff, 3245 .pa_end = 0x490280ff,
3249 .flags = ADDR_TYPE_RT 3246 .flags = ADDR_TYPE_RT
3250 }, 3247 },
3251 { } 3248 { }
3252 }; 3249 };
3253 3250
3254 /* l4_per -> mcbsp2_sidetone */ 3251 /* l4_per -> mcbsp2_sidetone */
3255 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp2_sidetone = { 3252 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp2_sidetone = {
3256 .master = &omap3xxx_l4_per_hwmod, 3253 .master = &omap3xxx_l4_per_hwmod,
3257 .slave = &omap3xxx_mcbsp2_sidetone_hwmod, 3254 .slave = &omap3xxx_mcbsp2_sidetone_hwmod,
3258 .clk = "mcbsp2_ick", 3255 .clk = "mcbsp2_ick",
3259 .addr = omap3xxx_mcbsp2_sidetone_addrs, 3256 .addr = omap3xxx_mcbsp2_sidetone_addrs,
3260 .user = OCP_USER_MPU, 3257 .user = OCP_USER_MPU,
3261 }; 3258 };
3262 3259
3263 static struct omap_hwmod_addr_space omap3xxx_mcbsp3_sidetone_addrs[] = { 3260 static struct omap_hwmod_addr_space omap3xxx_mcbsp3_sidetone_addrs[] = {
3264 { 3261 {
3265 .name = "sidetone", 3262 .name = "sidetone",
3266 .pa_start = 0x4902A000, 3263 .pa_start = 0x4902A000,
3267 .pa_end = 0x4902A0ff, 3264 .pa_end = 0x4902A0ff,
3268 .flags = ADDR_TYPE_RT 3265 .flags = ADDR_TYPE_RT
3269 }, 3266 },
3270 { } 3267 { }
3271 }; 3268 };
3272 3269
3273 /* l4_per -> mcbsp3_sidetone */ 3270 /* l4_per -> mcbsp3_sidetone */
3274 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp3_sidetone = { 3271 static struct omap_hwmod_ocp_if omap3xxx_l4_per__mcbsp3_sidetone = {
3275 .master = &omap3xxx_l4_per_hwmod, 3272 .master = &omap3xxx_l4_per_hwmod,
3276 .slave = &omap3xxx_mcbsp3_sidetone_hwmod, 3273 .slave = &omap3xxx_mcbsp3_sidetone_hwmod,
3277 .clk = "mcbsp3_ick", 3274 .clk = "mcbsp3_ick",
3278 .addr = omap3xxx_mcbsp3_sidetone_addrs, 3275 .addr = omap3xxx_mcbsp3_sidetone_addrs,
3279 .user = OCP_USER_MPU, 3276 .user = OCP_USER_MPU,
3280 }; 3277 };
3281 3278
3282 static struct omap_hwmod_addr_space omap3xxx_mailbox_addrs[] = { 3279 static struct omap_hwmod_addr_space omap3xxx_mailbox_addrs[] = {
3283 { 3280 {
3284 .pa_start = 0x48094000, 3281 .pa_start = 0x48094000,
3285 .pa_end = 0x480941ff, 3282 .pa_end = 0x480941ff,
3286 .flags = ADDR_TYPE_RT, 3283 .flags = ADDR_TYPE_RT,
3287 }, 3284 },
3288 { } 3285 { }
3289 }; 3286 };
3290 3287
3291 /* l4_core -> mailbox */ 3288 /* l4_core -> mailbox */
3292 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mailbox = { 3289 static struct omap_hwmod_ocp_if omap3xxx_l4_core__mailbox = {
3293 .master = &omap3xxx_l4_core_hwmod, 3290 .master = &omap3xxx_l4_core_hwmod,
3294 .slave = &omap3xxx_mailbox_hwmod, 3291 .slave = &omap3xxx_mailbox_hwmod,
3295 .addr = omap3xxx_mailbox_addrs, 3292 .addr = omap3xxx_mailbox_addrs,
3296 .user = OCP_USER_MPU | OCP_USER_SDMA, 3293 .user = OCP_USER_MPU | OCP_USER_SDMA,
3297 }; 3294 };
3298 3295
3299 /* l4 core -> mcspi1 interface */ 3296 /* l4 core -> mcspi1 interface */
3300 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi1 = { 3297 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi1 = {
3301 .master = &omap3xxx_l4_core_hwmod, 3298 .master = &omap3xxx_l4_core_hwmod,
3302 .slave = &omap34xx_mcspi1, 3299 .slave = &omap34xx_mcspi1,
3303 .clk = "mcspi1_ick", 3300 .clk = "mcspi1_ick",
3304 .addr = omap2_mcspi1_addr_space, 3301 .addr = omap2_mcspi1_addr_space,
3305 .user = OCP_USER_MPU | OCP_USER_SDMA, 3302 .user = OCP_USER_MPU | OCP_USER_SDMA,
3306 }; 3303 };
3307 3304
3308 /* l4 core -> mcspi2 interface */ 3305 /* l4 core -> mcspi2 interface */
3309 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi2 = { 3306 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi2 = {
3310 .master = &omap3xxx_l4_core_hwmod, 3307 .master = &omap3xxx_l4_core_hwmod,
3311 .slave = &omap34xx_mcspi2, 3308 .slave = &omap34xx_mcspi2,
3312 .clk = "mcspi2_ick", 3309 .clk = "mcspi2_ick",
3313 .addr = omap2_mcspi2_addr_space, 3310 .addr = omap2_mcspi2_addr_space,
3314 .user = OCP_USER_MPU | OCP_USER_SDMA, 3311 .user = OCP_USER_MPU | OCP_USER_SDMA,
3315 }; 3312 };
3316 3313
3317 /* l4 core -> mcspi3 interface */ 3314 /* l4 core -> mcspi3 interface */
3318 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi3 = { 3315 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi3 = {
3319 .master = &omap3xxx_l4_core_hwmod, 3316 .master = &omap3xxx_l4_core_hwmod,
3320 .slave = &omap34xx_mcspi3, 3317 .slave = &omap34xx_mcspi3,
3321 .clk = "mcspi3_ick", 3318 .clk = "mcspi3_ick",
3322 .addr = omap2430_mcspi3_addr_space, 3319 .addr = omap2430_mcspi3_addr_space,
3323 .user = OCP_USER_MPU | OCP_USER_SDMA, 3320 .user = OCP_USER_MPU | OCP_USER_SDMA,
3324 }; 3321 };
3325 3322
3326 /* l4 core -> mcspi4 interface */ 3323 /* l4 core -> mcspi4 interface */
3327 static struct omap_hwmod_addr_space omap34xx_mcspi4_addr_space[] = { 3324 static struct omap_hwmod_addr_space omap34xx_mcspi4_addr_space[] = {
3328 { 3325 {
3329 .pa_start = 0x480ba000, 3326 .pa_start = 0x480ba000,
3330 .pa_end = 0x480ba0ff, 3327 .pa_end = 0x480ba0ff,
3331 .flags = ADDR_TYPE_RT, 3328 .flags = ADDR_TYPE_RT,
3332 }, 3329 },
3333 { } 3330 { }
3334 }; 3331 };
3335 3332
3336 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi4 = { 3333 static struct omap_hwmod_ocp_if omap34xx_l4_core__mcspi4 = {
3337 .master = &omap3xxx_l4_core_hwmod, 3334 .master = &omap3xxx_l4_core_hwmod,
3338 .slave = &omap34xx_mcspi4, 3335 .slave = &omap34xx_mcspi4,
3339 .clk = "mcspi4_ick", 3336 .clk = "mcspi4_ick",
3340 .addr = omap34xx_mcspi4_addr_space, 3337 .addr = omap34xx_mcspi4_addr_space,
3341 .user = OCP_USER_MPU | OCP_USER_SDMA, 3338 .user = OCP_USER_MPU | OCP_USER_SDMA,
3342 }; 3339 };
3343 3340
3344 static struct omap_hwmod_ocp_if omap3xxx_usb_host_hs__l3_main_2 = { 3341 static struct omap_hwmod_ocp_if omap3xxx_usb_host_hs__l3_main_2 = {
3345 .master = &omap3xxx_usb_host_hs_hwmod, 3342 .master = &omap3xxx_usb_host_hs_hwmod,
3346 .slave = &omap3xxx_l3_main_hwmod, 3343 .slave = &omap3xxx_l3_main_hwmod,
3347 .clk = "core_l3_ick", 3344 .clk = "core_l3_ick",
3348 .user = OCP_USER_MPU, 3345 .user = OCP_USER_MPU,
3349 }; 3346 };
3350 3347
3351 static struct omap_hwmod_addr_space omap3xxx_usb_host_hs_addrs[] = { 3348 static struct omap_hwmod_addr_space omap3xxx_usb_host_hs_addrs[] = {
3352 { 3349 {
3353 .name = "uhh", 3350 .name = "uhh",
3354 .pa_start = 0x48064000, 3351 .pa_start = 0x48064000,
3355 .pa_end = 0x480643ff, 3352 .pa_end = 0x480643ff,
3356 .flags = ADDR_TYPE_RT 3353 .flags = ADDR_TYPE_RT
3357 }, 3354 },
3358 { 3355 {
3359 .name = "ohci", 3356 .name = "ohci",
3360 .pa_start = 0x48064400, 3357 .pa_start = 0x48064400,
3361 .pa_end = 0x480647ff, 3358 .pa_end = 0x480647ff,
3362 }, 3359 },
3363 { 3360 {
3364 .name = "ehci", 3361 .name = "ehci",
3365 .pa_start = 0x48064800, 3362 .pa_start = 0x48064800,
3366 .pa_end = 0x48064cff, 3363 .pa_end = 0x48064cff,
3367 }, 3364 },
3368 {} 3365 {}
3369 }; 3366 };
3370 3367
3371 static struct omap_hwmod_ocp_if omap3xxx_l4_core__usb_host_hs = { 3368 static struct omap_hwmod_ocp_if omap3xxx_l4_core__usb_host_hs = {
3372 .master = &omap3xxx_l4_core_hwmod, 3369 .master = &omap3xxx_l4_core_hwmod,
3373 .slave = &omap3xxx_usb_host_hs_hwmod, 3370 .slave = &omap3xxx_usb_host_hs_hwmod,
3374 .clk = "usbhost_ick", 3371 .clk = "usbhost_ick",
3375 .addr = omap3xxx_usb_host_hs_addrs, 3372 .addr = omap3xxx_usb_host_hs_addrs,
3376 .user = OCP_USER_MPU | OCP_USER_SDMA, 3373 .user = OCP_USER_MPU | OCP_USER_SDMA,
3377 }; 3374 };
3378 3375
3379 static struct omap_hwmod_addr_space omap3xxx_usb_tll_hs_addrs[] = { 3376 static struct omap_hwmod_addr_space omap3xxx_usb_tll_hs_addrs[] = {
3380 { 3377 {
3381 .name = "tll", 3378 .name = "tll",
3382 .pa_start = 0x48062000, 3379 .pa_start = 0x48062000,
3383 .pa_end = 0x48062fff, 3380 .pa_end = 0x48062fff,
3384 .flags = ADDR_TYPE_RT 3381 .flags = ADDR_TYPE_RT
3385 }, 3382 },
3386 {} 3383 {}
3387 }; 3384 };
3388 3385
3389 static struct omap_hwmod_ocp_if omap3xxx_l4_core__usb_tll_hs = { 3386 static struct omap_hwmod_ocp_if omap3xxx_l4_core__usb_tll_hs = {
3390 .master = &omap3xxx_l4_core_hwmod, 3387 .master = &omap3xxx_l4_core_hwmod,
3391 .slave = &omap3xxx_usb_tll_hs_hwmod, 3388 .slave = &omap3xxx_usb_tll_hs_hwmod,
3392 .clk = "usbtll_ick", 3389 .clk = "usbtll_ick",
3393 .addr = omap3xxx_usb_tll_hs_addrs, 3390 .addr = omap3xxx_usb_tll_hs_addrs,
3394 .user = OCP_USER_MPU | OCP_USER_SDMA, 3391 .user = OCP_USER_MPU | OCP_USER_SDMA,
3395 }; 3392 };
3396 3393
3397 /* l4_core -> hdq1w interface */ 3394 /* l4_core -> hdq1w interface */
3398 static struct omap_hwmod_ocp_if omap3xxx_l4_core__hdq1w = { 3395 static struct omap_hwmod_ocp_if omap3xxx_l4_core__hdq1w = {
3399 .master = &omap3xxx_l4_core_hwmod, 3396 .master = &omap3xxx_l4_core_hwmod,
3400 .slave = &omap3xxx_hdq1w_hwmod, 3397 .slave = &omap3xxx_hdq1w_hwmod,
3401 .clk = "hdq_ick", 3398 .clk = "hdq_ick",
3402 .addr = omap2_hdq1w_addr_space, 3399 .addr = omap2_hdq1w_addr_space,
3403 .user = OCP_USER_MPU | OCP_USER_SDMA, 3400 .user = OCP_USER_MPU | OCP_USER_SDMA,
3404 .flags = OMAP_FIREWALL_L4 | OCPIF_SWSUP_IDLE, 3401 .flags = OMAP_FIREWALL_L4 | OCPIF_SWSUP_IDLE,
3405 }; 3402 };
3406 3403
3407 /* l4_wkup -> 32ksync_counter */ 3404 /* l4_wkup -> 32ksync_counter */
3408 static struct omap_hwmod_addr_space omap3xxx_counter_32k_addrs[] = { 3405 static struct omap_hwmod_addr_space omap3xxx_counter_32k_addrs[] = {
3409 { 3406 {
3410 .pa_start = 0x48320000, 3407 .pa_start = 0x48320000,
3411 .pa_end = 0x4832001f, 3408 .pa_end = 0x4832001f,
3412 .flags = ADDR_TYPE_RT 3409 .flags = ADDR_TYPE_RT
3413 }, 3410 },
3414 { } 3411 { }
3415 }; 3412 };
3416 3413
3417 static struct omap_hwmod_addr_space omap3xxx_gpmc_addrs[] = { 3414 static struct omap_hwmod_addr_space omap3xxx_gpmc_addrs[] = {
3418 { 3415 {
3419 .pa_start = 0x6e000000, 3416 .pa_start = 0x6e000000,
3420 .pa_end = 0x6e000fff, 3417 .pa_end = 0x6e000fff,
3421 .flags = ADDR_TYPE_RT 3418 .flags = ADDR_TYPE_RT
3422 }, 3419 },
3423 { } 3420 { }
3424 }; 3421 };
3425 3422
3426 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__counter_32k = { 3423 static struct omap_hwmod_ocp_if omap3xxx_l4_wkup__counter_32k = {
3427 .master = &omap3xxx_l4_wkup_hwmod, 3424 .master = &omap3xxx_l4_wkup_hwmod,
3428 .slave = &omap3xxx_counter_32k_hwmod, 3425 .slave = &omap3xxx_counter_32k_hwmod,
3429 .clk = "omap_32ksync_ick", 3426 .clk = "omap_32ksync_ick",
3430 .addr = omap3xxx_counter_32k_addrs, 3427 .addr = omap3xxx_counter_32k_addrs,
3431 .user = OCP_USER_MPU | OCP_USER_SDMA, 3428 .user = OCP_USER_MPU | OCP_USER_SDMA,
3432 }; 3429 };
3433 3430
3434 /* am35xx has Davinci MDIO & EMAC */ 3431 /* am35xx has Davinci MDIO & EMAC */
3435 static struct omap_hwmod_class am35xx_mdio_class = { 3432 static struct omap_hwmod_class am35xx_mdio_class = {
3436 .name = "davinci_mdio", 3433 .name = "davinci_mdio",
3437 }; 3434 };
3438 3435
3439 static struct omap_hwmod am35xx_mdio_hwmod = { 3436 static struct omap_hwmod am35xx_mdio_hwmod = {
3440 .name = "davinci_mdio", 3437 .name = "davinci_mdio",
3441 .class = &am35xx_mdio_class, 3438 .class = &am35xx_mdio_class,
3442 .flags = HWMOD_NO_IDLEST, 3439 .flags = HWMOD_NO_IDLEST,
3443 }; 3440 };
3444 3441
3445 /* 3442 /*
3446 * XXX Should be connected to an IPSS hwmod, not the L3 directly; 3443 * XXX Should be connected to an IPSS hwmod, not the L3 directly;
3447 * but this will probably require some additional hwmod core support, 3444 * but this will probably require some additional hwmod core support,
3448 * so is left as a future to-do item. 3445 * so is left as a future to-do item.
3449 */ 3446 */
3450 static struct omap_hwmod_ocp_if am35xx_mdio__l3 = { 3447 static struct omap_hwmod_ocp_if am35xx_mdio__l3 = {
3451 .master = &am35xx_mdio_hwmod, 3448 .master = &am35xx_mdio_hwmod,
3452 .slave = &omap3xxx_l3_main_hwmod, 3449 .slave = &omap3xxx_l3_main_hwmod,
3453 .clk = "emac_fck", 3450 .clk = "emac_fck",
3454 .user = OCP_USER_MPU, 3451 .user = OCP_USER_MPU,
3455 }; 3452 };
3456 3453
3457 static struct omap_hwmod_addr_space am35xx_mdio_addrs[] = { 3454 static struct omap_hwmod_addr_space am35xx_mdio_addrs[] = {
3458 { 3455 {
3459 .pa_start = AM35XX_IPSS_MDIO_BASE, 3456 .pa_start = AM35XX_IPSS_MDIO_BASE,
3460 .pa_end = AM35XX_IPSS_MDIO_BASE + SZ_4K - 1, 3457 .pa_end = AM35XX_IPSS_MDIO_BASE + SZ_4K - 1,
3461 .flags = ADDR_TYPE_RT, 3458 .flags = ADDR_TYPE_RT,
3462 }, 3459 },
3463 { } 3460 { }
3464 }; 3461 };
3465 3462
3466 /* l4_core -> davinci mdio */ 3463 /* l4_core -> davinci mdio */
3467 /* 3464 /*
3468 * XXX Should be connected to an IPSS hwmod, not the L4_CORE directly; 3465 * XXX Should be connected to an IPSS hwmod, not the L4_CORE directly;
3469 * but this will probably require some additional hwmod core support, 3466 * but this will probably require some additional hwmod core support,
3470 * so is left as a future to-do item. 3467 * so is left as a future to-do item.
3471 */ 3468 */
3472 static struct omap_hwmod_ocp_if am35xx_l4_core__mdio = { 3469 static struct omap_hwmod_ocp_if am35xx_l4_core__mdio = {
3473 .master = &omap3xxx_l4_core_hwmod, 3470 .master = &omap3xxx_l4_core_hwmod,
3474 .slave = &am35xx_mdio_hwmod, 3471 .slave = &am35xx_mdio_hwmod,
3475 .clk = "emac_fck", 3472 .clk = "emac_fck",
3476 .addr = am35xx_mdio_addrs, 3473 .addr = am35xx_mdio_addrs,
3477 .user = OCP_USER_MPU, 3474 .user = OCP_USER_MPU,
3478 }; 3475 };
3479 3476
3480 static struct omap_hwmod_irq_info am35xx_emac_mpu_irqs[] = { 3477 static struct omap_hwmod_irq_info am35xx_emac_mpu_irqs[] = {
3481 { .name = "rxthresh", .irq = 67 + OMAP_INTC_START, }, 3478 { .name = "rxthresh", .irq = 67 + OMAP_INTC_START, },
3482 { .name = "rx_pulse", .irq = 68 + OMAP_INTC_START, }, 3479 { .name = "rx_pulse", .irq = 68 + OMAP_INTC_START, },
3483 { .name = "tx_pulse", .irq = 69 + OMAP_INTC_START }, 3480 { .name = "tx_pulse", .irq = 69 + OMAP_INTC_START },
3484 { .name = "misc_pulse", .irq = 70 + OMAP_INTC_START }, 3481 { .name = "misc_pulse", .irq = 70 + OMAP_INTC_START },
3485 { .irq = -1 }, 3482 { .irq = -1 },
3486 }; 3483 };
3487 3484
3488 static struct omap_hwmod_class am35xx_emac_class = { 3485 static struct omap_hwmod_class am35xx_emac_class = {
3489 .name = "davinci_emac", 3486 .name = "davinci_emac",
3490 }; 3487 };
3491 3488
3492 static struct omap_hwmod am35xx_emac_hwmod = { 3489 static struct omap_hwmod am35xx_emac_hwmod = {
3493 .name = "davinci_emac", 3490 .name = "davinci_emac",
3494 .mpu_irqs = am35xx_emac_mpu_irqs, 3491 .mpu_irqs = am35xx_emac_mpu_irqs,
3495 .class = &am35xx_emac_class, 3492 .class = &am35xx_emac_class,
3496 .flags = HWMOD_NO_IDLEST, 3493 .flags = HWMOD_NO_IDLEST,
3497 }; 3494 };
3498 3495
3499 /* l3_core -> davinci emac interface */ 3496 /* l3_core -> davinci emac interface */
3500 /* 3497 /*
3501 * XXX Should be connected to an IPSS hwmod, not the L3 directly; 3498 * XXX Should be connected to an IPSS hwmod, not the L3 directly;
3502 * but this will probably require some additional hwmod core support, 3499 * but this will probably require some additional hwmod core support,
3503 * so is left as a future to-do item. 3500 * so is left as a future to-do item.
3504 */ 3501 */
3505 static struct omap_hwmod_ocp_if am35xx_emac__l3 = { 3502 static struct omap_hwmod_ocp_if am35xx_emac__l3 = {
3506 .master = &am35xx_emac_hwmod, 3503 .master = &am35xx_emac_hwmod,
3507 .slave = &omap3xxx_l3_main_hwmod, 3504 .slave = &omap3xxx_l3_main_hwmod,
3508 .clk = "emac_ick", 3505 .clk = "emac_ick",
3509 .user = OCP_USER_MPU, 3506 .user = OCP_USER_MPU,
3510 }; 3507 };
3511 3508
3512 static struct omap_hwmod_addr_space am35xx_emac_addrs[] = { 3509 static struct omap_hwmod_addr_space am35xx_emac_addrs[] = {
3513 { 3510 {
3514 .pa_start = AM35XX_IPSS_EMAC_BASE, 3511 .pa_start = AM35XX_IPSS_EMAC_BASE,
3515 .pa_end = AM35XX_IPSS_EMAC_BASE + 0x30000 - 1, 3512 .pa_end = AM35XX_IPSS_EMAC_BASE + 0x30000 - 1,
3516 .flags = ADDR_TYPE_RT, 3513 .flags = ADDR_TYPE_RT,
3517 }, 3514 },
3518 { } 3515 { }
3519 }; 3516 };
3520 3517
3521 /* l4_core -> davinci emac */ 3518 /* l4_core -> davinci emac */
3522 /* 3519 /*
3523 * XXX Should be connected to an IPSS hwmod, not the L4_CORE directly; 3520 * XXX Should be connected to an IPSS hwmod, not the L4_CORE directly;
3524 * but this will probably require some additional hwmod core support, 3521 * but this will probably require some additional hwmod core support,
3525 * so is left as a future to-do item. 3522 * so is left as a future to-do item.
3526 */ 3523 */
3527 static struct omap_hwmod_ocp_if am35xx_l4_core__emac = { 3524 static struct omap_hwmod_ocp_if am35xx_l4_core__emac = {
3528 .master = &omap3xxx_l4_core_hwmod, 3525 .master = &omap3xxx_l4_core_hwmod,
3529 .slave = &am35xx_emac_hwmod, 3526 .slave = &am35xx_emac_hwmod,
3530 .clk = "emac_ick", 3527 .clk = "emac_ick",
3531 .addr = am35xx_emac_addrs, 3528 .addr = am35xx_emac_addrs,
3532 .user = OCP_USER_MPU, 3529 .user = OCP_USER_MPU,
3533 }; 3530 };
3534 3531
3535 static struct omap_hwmod_ocp_if omap3xxx_l3_main__gpmc = { 3532 static struct omap_hwmod_ocp_if omap3xxx_l3_main__gpmc = {
3536 .master = &omap3xxx_l3_main_hwmod, 3533 .master = &omap3xxx_l3_main_hwmod,
3537 .slave = &omap3xxx_gpmc_hwmod, 3534 .slave = &omap3xxx_gpmc_hwmod,
3538 .clk = "core_l3_ick", 3535 .clk = "core_l3_ick",
3539 .addr = omap3xxx_gpmc_addrs, 3536 .addr = omap3xxx_gpmc_addrs,
3540 .user = OCP_USER_MPU | OCP_USER_SDMA, 3537 .user = OCP_USER_MPU | OCP_USER_SDMA,
3541 }; 3538 };
3542 3539
3543 static struct omap_hwmod_ocp_if *omap3xxx_hwmod_ocp_ifs[] __initdata = { 3540 static struct omap_hwmod_ocp_if *omap3xxx_hwmod_ocp_ifs[] __initdata = {
3544 &omap3xxx_l3_main__l4_core, 3541 &omap3xxx_l3_main__l4_core,
3545 &omap3xxx_l3_main__l4_per, 3542 &omap3xxx_l3_main__l4_per,
3546 &omap3xxx_mpu__l3_main, 3543 &omap3xxx_mpu__l3_main,
3547 &omap3xxx_l3_main__l4_debugss, 3544 &omap3xxx_l3_main__l4_debugss,
3548 &omap3xxx_l4_core__l4_wkup, 3545 &omap3xxx_l4_core__l4_wkup,
3549 &omap3xxx_l4_core__mmc3, 3546 &omap3xxx_l4_core__mmc3,
3550 &omap3_l4_core__uart1, 3547 &omap3_l4_core__uart1,
3551 &omap3_l4_core__uart2, 3548 &omap3_l4_core__uart2,
3552 &omap3_l4_per__uart3, 3549 &omap3_l4_per__uart3,
3553 &omap3_l4_core__i2c1, 3550 &omap3_l4_core__i2c1,
3554 &omap3_l4_core__i2c2, 3551 &omap3_l4_core__i2c2,
3555 &omap3_l4_core__i2c3, 3552 &omap3_l4_core__i2c3,
3556 &omap3xxx_l4_wkup__l4_sec, 3553 &omap3xxx_l4_wkup__l4_sec,
3557 &omap3xxx_l4_wkup__timer1, 3554 &omap3xxx_l4_wkup__timer1,
3558 &omap3xxx_l4_per__timer2, 3555 &omap3xxx_l4_per__timer2,
3559 &omap3xxx_l4_per__timer3, 3556 &omap3xxx_l4_per__timer3,
3560 &omap3xxx_l4_per__timer4, 3557 &omap3xxx_l4_per__timer4,
3561 &omap3xxx_l4_per__timer5, 3558 &omap3xxx_l4_per__timer5,
3562 &omap3xxx_l4_per__timer6, 3559 &omap3xxx_l4_per__timer6,
3563 &omap3xxx_l4_per__timer7, 3560 &omap3xxx_l4_per__timer7,
3564 &omap3xxx_l4_per__timer8, 3561 &omap3xxx_l4_per__timer8,
3565 &omap3xxx_l4_per__timer9, 3562 &omap3xxx_l4_per__timer9,
3566 &omap3xxx_l4_core__timer10, 3563 &omap3xxx_l4_core__timer10,
3567 &omap3xxx_l4_core__timer11, 3564 &omap3xxx_l4_core__timer11,
3568 &omap3xxx_l4_wkup__wd_timer2, 3565 &omap3xxx_l4_wkup__wd_timer2,
3569 &omap3xxx_l4_wkup__gpio1, 3566 &omap3xxx_l4_wkup__gpio1,
3570 &omap3xxx_l4_per__gpio2, 3567 &omap3xxx_l4_per__gpio2,
3571 &omap3xxx_l4_per__gpio3, 3568 &omap3xxx_l4_per__gpio3,
3572 &omap3xxx_l4_per__gpio4, 3569 &omap3xxx_l4_per__gpio4,
3573 &omap3xxx_l4_per__gpio5, 3570 &omap3xxx_l4_per__gpio5,
3574 &omap3xxx_l4_per__gpio6, 3571 &omap3xxx_l4_per__gpio6,
3575 &omap3xxx_dma_system__l3, 3572 &omap3xxx_dma_system__l3,
3576 &omap3xxx_l4_core__dma_system, 3573 &omap3xxx_l4_core__dma_system,
3577 &omap3xxx_l4_core__mcbsp1, 3574 &omap3xxx_l4_core__mcbsp1,
3578 &omap3xxx_l4_per__mcbsp2, 3575 &omap3xxx_l4_per__mcbsp2,
3579 &omap3xxx_l4_per__mcbsp3, 3576 &omap3xxx_l4_per__mcbsp3,
3580 &omap3xxx_l4_per__mcbsp4, 3577 &omap3xxx_l4_per__mcbsp4,
3581 &omap3xxx_l4_core__mcbsp5, 3578 &omap3xxx_l4_core__mcbsp5,
3582 &omap3xxx_l4_per__mcbsp2_sidetone, 3579 &omap3xxx_l4_per__mcbsp2_sidetone,
3583 &omap3xxx_l4_per__mcbsp3_sidetone, 3580 &omap3xxx_l4_per__mcbsp3_sidetone,
3584 &omap34xx_l4_core__mcspi1, 3581 &omap34xx_l4_core__mcspi1,
3585 &omap34xx_l4_core__mcspi2, 3582 &omap34xx_l4_core__mcspi2,
3586 &omap34xx_l4_core__mcspi3, 3583 &omap34xx_l4_core__mcspi3,
3587 &omap34xx_l4_core__mcspi4, 3584 &omap34xx_l4_core__mcspi4,
3588 &omap3xxx_l4_wkup__counter_32k, 3585 &omap3xxx_l4_wkup__counter_32k,
3589 &omap3xxx_l3_main__gpmc, 3586 &omap3xxx_l3_main__gpmc,
3590 NULL, 3587 NULL,
3591 }; 3588 };
3592 3589
3593 /* GP-only hwmod links */ 3590 /* GP-only hwmod links */
3594 static struct omap_hwmod_ocp_if *omap3xxx_gp_hwmod_ocp_ifs[] __initdata = { 3591 static struct omap_hwmod_ocp_if *omap3xxx_gp_hwmod_ocp_ifs[] __initdata = {
3595 &omap3xxx_l4_sec__timer12, 3592 &omap3xxx_l4_sec__timer12,
3596 NULL 3593 NULL
3597 }; 3594 };
3598 3595
3599 /* 3430ES1-only hwmod links */ 3596 /* 3430ES1-only hwmod links */
3600 static struct omap_hwmod_ocp_if *omap3430es1_hwmod_ocp_ifs[] __initdata = { 3597 static struct omap_hwmod_ocp_if *omap3430es1_hwmod_ocp_ifs[] __initdata = {
3601 &omap3430es1_dss__l3, 3598 &omap3430es1_dss__l3,
3602 &omap3430es1_l4_core__dss, 3599 &omap3430es1_l4_core__dss,
3603 NULL 3600 NULL
3604 }; 3601 };
3605 3602
3606 /* 3430ES2+-only hwmod links */ 3603 /* 3430ES2+-only hwmod links */
3607 static struct omap_hwmod_ocp_if *omap3430es2plus_hwmod_ocp_ifs[] __initdata = { 3604 static struct omap_hwmod_ocp_if *omap3430es2plus_hwmod_ocp_ifs[] __initdata = {
3608 &omap3xxx_dss__l3, 3605 &omap3xxx_dss__l3,
3609 &omap3xxx_l4_core__dss, 3606 &omap3xxx_l4_core__dss,
3610 &omap3xxx_usbhsotg__l3, 3607 &omap3xxx_usbhsotg__l3,
3611 &omap3xxx_l4_core__usbhsotg, 3608 &omap3xxx_l4_core__usbhsotg,
3612 &omap3xxx_usb_host_hs__l3_main_2, 3609 &omap3xxx_usb_host_hs__l3_main_2,
3613 &omap3xxx_l4_core__usb_host_hs, 3610 &omap3xxx_l4_core__usb_host_hs,
3614 &omap3xxx_l4_core__usb_tll_hs, 3611 &omap3xxx_l4_core__usb_tll_hs,
3615 NULL 3612 NULL
3616 }; 3613 };
3617 3614
3618 /* <= 3430ES3-only hwmod links */ 3615 /* <= 3430ES3-only hwmod links */
3619 static struct omap_hwmod_ocp_if *omap3430_pre_es3_hwmod_ocp_ifs[] __initdata = { 3616 static struct omap_hwmod_ocp_if *omap3430_pre_es3_hwmod_ocp_ifs[] __initdata = {
3620 &omap3xxx_l4_core__pre_es3_mmc1, 3617 &omap3xxx_l4_core__pre_es3_mmc1,
3621 &omap3xxx_l4_core__pre_es3_mmc2, 3618 &omap3xxx_l4_core__pre_es3_mmc2,
3622 NULL 3619 NULL
3623 }; 3620 };
3624 3621
3625 /* 3430ES3+-only hwmod links */ 3622 /* 3430ES3+-only hwmod links */
3626 static struct omap_hwmod_ocp_if *omap3430_es3plus_hwmod_ocp_ifs[] __initdata = { 3623 static struct omap_hwmod_ocp_if *omap3430_es3plus_hwmod_ocp_ifs[] __initdata = {
3627 &omap3xxx_l4_core__es3plus_mmc1, 3624 &omap3xxx_l4_core__es3plus_mmc1,
3628 &omap3xxx_l4_core__es3plus_mmc2, 3625 &omap3xxx_l4_core__es3plus_mmc2,
3629 NULL 3626 NULL
3630 }; 3627 };
3631 3628
3632 /* 34xx-only hwmod links (all ES revisions) */ 3629 /* 34xx-only hwmod links (all ES revisions) */
3633 static struct omap_hwmod_ocp_if *omap34xx_hwmod_ocp_ifs[] __initdata = { 3630 static struct omap_hwmod_ocp_if *omap34xx_hwmod_ocp_ifs[] __initdata = {
3634 &omap3xxx_l3__iva, 3631 &omap3xxx_l3__iva,
3635 &omap34xx_l4_core__sr1, 3632 &omap34xx_l4_core__sr1,
3636 &omap34xx_l4_core__sr2, 3633 &omap34xx_l4_core__sr2,
3637 &omap3xxx_l4_core__mailbox, 3634 &omap3xxx_l4_core__mailbox,
3638 &omap3xxx_l4_core__hdq1w, 3635 &omap3xxx_l4_core__hdq1w,
3639 &omap3xxx_sad2d__l3, 3636 &omap3xxx_sad2d__l3,
3640 &omap3xxx_l4_core__mmu_isp, 3637 &omap3xxx_l4_core__mmu_isp,
3641 #ifdef CONFIG_OMAP_IOMMU_IVA2 3638 #ifdef CONFIG_OMAP_IOMMU_IVA2
3642 &omap3xxx_l3_main__mmu_iva, 3639 &omap3xxx_l3_main__mmu_iva,
3643 #endif 3640 #endif
3644 NULL 3641 NULL
3645 }; 3642 };
3646 3643
3647 /* 36xx-only hwmod links (all ES revisions) */ 3644 /* 36xx-only hwmod links (all ES revisions) */
3648 static struct omap_hwmod_ocp_if *omap36xx_hwmod_ocp_ifs[] __initdata = { 3645 static struct omap_hwmod_ocp_if *omap36xx_hwmod_ocp_ifs[] __initdata = {
3649 &omap3xxx_l3__iva, 3646 &omap3xxx_l3__iva,
3650 &omap36xx_l4_per__uart4, 3647 &omap36xx_l4_per__uart4,
3651 &omap3xxx_dss__l3, 3648 &omap3xxx_dss__l3,
3652 &omap3xxx_l4_core__dss, 3649 &omap3xxx_l4_core__dss,
3653 &omap36xx_l4_core__sr1, 3650 &omap36xx_l4_core__sr1,
3654 &omap36xx_l4_core__sr2, 3651 &omap36xx_l4_core__sr2,
3655 &omap3xxx_usbhsotg__l3, 3652 &omap3xxx_usbhsotg__l3,
3656 &omap3xxx_l4_core__usbhsotg, 3653 &omap3xxx_l4_core__usbhsotg,
3657 &omap3xxx_l4_core__mailbox, 3654 &omap3xxx_l4_core__mailbox,
3658 &omap3xxx_usb_host_hs__l3_main_2, 3655 &omap3xxx_usb_host_hs__l3_main_2,
3659 &omap3xxx_l4_core__usb_host_hs, 3656 &omap3xxx_l4_core__usb_host_hs,
3660 &omap3xxx_l4_core__usb_tll_hs, 3657 &omap3xxx_l4_core__usb_tll_hs,
3661 &omap3xxx_l4_core__es3plus_mmc1, 3658 &omap3xxx_l4_core__es3plus_mmc1,
3662 &omap3xxx_l4_core__es3plus_mmc2, 3659 &omap3xxx_l4_core__es3plus_mmc2,
3663 &omap3xxx_l4_core__hdq1w, 3660 &omap3xxx_l4_core__hdq1w,
3664 &omap3xxx_sad2d__l3, 3661 &omap3xxx_sad2d__l3,
3665 &omap3xxx_l4_core__mmu_isp, 3662 &omap3xxx_l4_core__mmu_isp,
3666 #ifdef CONFIG_OMAP_IOMMU_IVA2 3663 #ifdef CONFIG_OMAP_IOMMU_IVA2
3667 &omap3xxx_l3_main__mmu_iva, 3664 &omap3xxx_l3_main__mmu_iva,
3668 #endif 3665 #endif
3669 NULL 3666 NULL
3670 }; 3667 };
3671 3668
3672 static struct omap_hwmod_ocp_if *am35xx_hwmod_ocp_ifs[] __initdata = { 3669 static struct omap_hwmod_ocp_if *am35xx_hwmod_ocp_ifs[] __initdata = {
3673 &omap3xxx_dss__l3, 3670 &omap3xxx_dss__l3,
3674 &omap3xxx_l4_core__dss, 3671 &omap3xxx_l4_core__dss,
3675 &am35xx_usbhsotg__l3, 3672 &am35xx_usbhsotg__l3,
3676 &am35xx_l4_core__usbhsotg, 3673 &am35xx_l4_core__usbhsotg,
3677 &am35xx_l4_core__uart4, 3674 &am35xx_l4_core__uart4,
3678 &omap3xxx_usb_host_hs__l3_main_2, 3675 &omap3xxx_usb_host_hs__l3_main_2,
3679 &omap3xxx_l4_core__usb_host_hs, 3676 &omap3xxx_l4_core__usb_host_hs,
3680 &omap3xxx_l4_core__usb_tll_hs, 3677 &omap3xxx_l4_core__usb_tll_hs,
3681 &omap3xxx_l4_core__es3plus_mmc1, 3678 &omap3xxx_l4_core__es3plus_mmc1,
3682 &omap3xxx_l4_core__es3plus_mmc2, 3679 &omap3xxx_l4_core__es3plus_mmc2,
3683 &omap3xxx_l4_core__hdq1w, 3680 &omap3xxx_l4_core__hdq1w,
3684 &am35xx_mdio__l3, 3681 &am35xx_mdio__l3,
3685 &am35xx_l4_core__mdio, 3682 &am35xx_l4_core__mdio,
3686 &am35xx_emac__l3, 3683 &am35xx_emac__l3,
3687 &am35xx_l4_core__emac, 3684 &am35xx_l4_core__emac,
3688 NULL 3685 NULL
3689 }; 3686 };
3690 3687
3691 static struct omap_hwmod_ocp_if *omap3xxx_dss_hwmod_ocp_ifs[] __initdata = { 3688 static struct omap_hwmod_ocp_if *omap3xxx_dss_hwmod_ocp_ifs[] __initdata = {
3692 &omap3xxx_l4_core__dss_dispc, 3689 &omap3xxx_l4_core__dss_dispc,
3693 &omap3xxx_l4_core__dss_dsi1, 3690 &omap3xxx_l4_core__dss_dsi1,
3694 &omap3xxx_l4_core__dss_rfbi, 3691 &omap3xxx_l4_core__dss_rfbi,
3695 &omap3xxx_l4_core__dss_venc, 3692 &omap3xxx_l4_core__dss_venc,
3696 NULL 3693 NULL
3697 }; 3694 };
3698 3695
3699 int __init omap3xxx_hwmod_init(void) 3696 int __init omap3xxx_hwmod_init(void)
3700 { 3697 {
3701 int r; 3698 int r;
3702 struct omap_hwmod_ocp_if **h = NULL; 3699 struct omap_hwmod_ocp_if **h = NULL;
3703 unsigned int rev; 3700 unsigned int rev;
3704 3701
3705 omap_hwmod_init(); 3702 omap_hwmod_init();
3706 3703
3707 /* Register hwmod links common to all OMAP3 */ 3704 /* Register hwmod links common to all OMAP3 */
3708 r = omap_hwmod_register_links(omap3xxx_hwmod_ocp_ifs); 3705 r = omap_hwmod_register_links(omap3xxx_hwmod_ocp_ifs);
3709 if (r < 0) 3706 if (r < 0)
3710 return r; 3707 return r;
3711 3708
3712 /* Register GP-only hwmod links. */ 3709 /* Register GP-only hwmod links. */
3713 if (omap_type() == OMAP2_DEVICE_TYPE_GP) { 3710 if (omap_type() == OMAP2_DEVICE_TYPE_GP) {
3714 r = omap_hwmod_register_links(omap3xxx_gp_hwmod_ocp_ifs); 3711 r = omap_hwmod_register_links(omap3xxx_gp_hwmod_ocp_ifs);
3715 if (r < 0) 3712 if (r < 0)
3716 return r; 3713 return r;
3717 } 3714 }
3718 3715
3719 rev = omap_rev(); 3716 rev = omap_rev();
3720 3717
3721 /* 3718 /*
3722 * Register hwmod links common to individual OMAP3 families, all 3719 * Register hwmod links common to individual OMAP3 families, all
3723 * silicon revisions (e.g., 34xx, or AM3505/3517, or 36xx) 3720 * silicon revisions (e.g., 34xx, or AM3505/3517, or 36xx)
3724 * All possible revisions should be included in this conditional. 3721 * All possible revisions should be included in this conditional.
3725 */ 3722 */
3726 if (rev == OMAP3430_REV_ES1_0 || rev == OMAP3430_REV_ES2_0 || 3723 if (rev == OMAP3430_REV_ES1_0 || rev == OMAP3430_REV_ES2_0 ||
3727 rev == OMAP3430_REV_ES2_1 || rev == OMAP3430_REV_ES3_0 || 3724 rev == OMAP3430_REV_ES2_1 || rev == OMAP3430_REV_ES3_0 ||
3728 rev == OMAP3430_REV_ES3_1 || rev == OMAP3430_REV_ES3_1_2) { 3725 rev == OMAP3430_REV_ES3_1 || rev == OMAP3430_REV_ES3_1_2) {
3729 h = omap34xx_hwmod_ocp_ifs; 3726 h = omap34xx_hwmod_ocp_ifs;
3730 } else if (rev == AM35XX_REV_ES1_0 || rev == AM35XX_REV_ES1_1) { 3727 } else if (rev == AM35XX_REV_ES1_0 || rev == AM35XX_REV_ES1_1) {
3731 h = am35xx_hwmod_ocp_ifs; 3728 h = am35xx_hwmod_ocp_ifs;
3732 } else if (rev == OMAP3630_REV_ES1_0 || rev == OMAP3630_REV_ES1_1 || 3729 } else if (rev == OMAP3630_REV_ES1_0 || rev == OMAP3630_REV_ES1_1 ||
3733 rev == OMAP3630_REV_ES1_2) { 3730 rev == OMAP3630_REV_ES1_2) {
3734 h = omap36xx_hwmod_ocp_ifs; 3731 h = omap36xx_hwmod_ocp_ifs;
3735 } else { 3732 } else {
3736 WARN(1, "OMAP3 hwmod family init: unknown chip type\n"); 3733 WARN(1, "OMAP3 hwmod family init: unknown chip type\n");
3737 return -EINVAL; 3734 return -EINVAL;
3738 } 3735 }
3739 3736
3740 r = omap_hwmod_register_links(h); 3737 r = omap_hwmod_register_links(h);
3741 if (r < 0) 3738 if (r < 0)
3742 return r; 3739 return r;
3743 3740
3744 /* 3741 /*
3745 * Register hwmod links specific to certain ES levels of a 3742 * Register hwmod links specific to certain ES levels of a
3746 * particular family of silicon (e.g., 34xx ES1.0) 3743 * particular family of silicon (e.g., 34xx ES1.0)
3747 */ 3744 */
3748 h = NULL; 3745 h = NULL;
3749 if (rev == OMAP3430_REV_ES1_0) { 3746 if (rev == OMAP3430_REV_ES1_0) {
3750 h = omap3430es1_hwmod_ocp_ifs; 3747 h = omap3430es1_hwmod_ocp_ifs;
3751 } else if (rev == OMAP3430_REV_ES2_0 || rev == OMAP3430_REV_ES2_1 || 3748 } else if (rev == OMAP3430_REV_ES2_0 || rev == OMAP3430_REV_ES2_1 ||
3752 rev == OMAP3430_REV_ES3_0 || rev == OMAP3430_REV_ES3_1 || 3749 rev == OMAP3430_REV_ES3_0 || rev == OMAP3430_REV_ES3_1 ||
3753 rev == OMAP3430_REV_ES3_1_2) { 3750 rev == OMAP3430_REV_ES3_1_2) {
3754 h = omap3430es2plus_hwmod_ocp_ifs; 3751 h = omap3430es2plus_hwmod_ocp_ifs;
3755 } 3752 }
3756 3753
3757 if (h) { 3754 if (h) {
3758 r = omap_hwmod_register_links(h); 3755 r = omap_hwmod_register_links(h);
3759 if (r < 0) 3756 if (r < 0)
3760 return r; 3757 return r;
3761 } 3758 }
3762 3759
3763 h = NULL; 3760 h = NULL;
3764 if (rev == OMAP3430_REV_ES1_0 || rev == OMAP3430_REV_ES2_0 || 3761 if (rev == OMAP3430_REV_ES1_0 || rev == OMAP3430_REV_ES2_0 ||
3765 rev == OMAP3430_REV_ES2_1) { 3762 rev == OMAP3430_REV_ES2_1) {
3766 h = omap3430_pre_es3_hwmod_ocp_ifs; 3763 h = omap3430_pre_es3_hwmod_ocp_ifs;
3767 } else if (rev == OMAP3430_REV_ES3_0 || rev == OMAP3430_REV_ES3_1 || 3764 } else if (rev == OMAP3430_REV_ES3_0 || rev == OMAP3430_REV_ES3_1 ||
3768 rev == OMAP3430_REV_ES3_1_2) { 3765 rev == OMAP3430_REV_ES3_1_2) {
3769 h = omap3430_es3plus_hwmod_ocp_ifs; 3766 h = omap3430_es3plus_hwmod_ocp_ifs;
3770 } 3767 }
3771 3768
3772 if (h) 3769 if (h)
3773 r = omap_hwmod_register_links(h); 3770 r = omap_hwmod_register_links(h);
3774 if (r < 0) 3771 if (r < 0)
3775 return r; 3772 return r;
3776 3773
3777 /* 3774 /*
3778 * DSS code presumes that dss_core hwmod is handled first, 3775 * DSS code presumes that dss_core hwmod is handled first,
3779 * _before_ any other DSS related hwmods so register common 3776 * _before_ any other DSS related hwmods so register common
3780 * DSS hwmod links last to ensure that dss_core is already 3777 * DSS hwmod links last to ensure that dss_core is already
3781 * registered. Otherwise some change things may happen, for 3778 * registered. Otherwise some change things may happen, for
3782 * ex. if dispc is handled before dss_core and DSS is enabled 3779 * ex. if dispc is handled before dss_core and DSS is enabled
3783 * in bootloader DISPC will be reset with outputs enabled 3780 * in bootloader DISPC will be reset with outputs enabled
3784 * which sometimes leads to unrecoverable L3 error. XXX The 3781 * which sometimes leads to unrecoverable L3 error. XXX The
3785 * long-term fix to this is to ensure hwmods are set up in 3782 * long-term fix to this is to ensure hwmods are set up in
3786 * dependency order in the hwmod core code. 3783 * dependency order in the hwmod core code.
3787 */ 3784 */
3788 r = omap_hwmod_register_links(omap3xxx_dss_hwmod_ocp_ifs); 3785 r = omap_hwmod_register_links(omap3xxx_dss_hwmod_ocp_ifs);
3789 3786
3790 return r; 3787 return r;
3791 } 3788 }
3792 3789
arch/arm/mach-omap2/omap_hwmod_44xx_data.c
1 /* 1 /*
2 * Hardware modules present on the OMAP44xx chips 2 * Hardware modules present on the OMAP44xx chips
3 * 3 *
4 * Copyright (C) 2009-2012 Texas Instruments, Inc. 4 * Copyright (C) 2009-2012 Texas Instruments, Inc.
5 * Copyright (C) 2009-2010 Nokia Corporation 5 * Copyright (C) 2009-2010 Nokia Corporation
6 * 6 *
7 * Paul Walmsley 7 * Paul Walmsley
8 * Benoit Cousson 8 * Benoit Cousson
9 * 9 *
10 * This file is automatically generated from the OMAP hardware databases. 10 * This file is automatically generated from the OMAP hardware databases.
11 * We respectfully ask that any modifications to this file be coordinated 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 12 * with the public linux-omap@vger.kernel.org mailing list and the
13 * authors above to ensure that the autogeneration scripts are kept 13 * authors above to ensure that the autogeneration scripts are kept
14 * up-to-date with the file contents. 14 * up-to-date with the file contents.
15 * 15 *
16 * This program is free software; you can redistribute it and/or modify 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 17 * it under the terms of the GNU General Public License version 2 as
18 * published by the Free Software Foundation. 18 * published by the Free Software Foundation.
19 */ 19 */
20 20
21 #include <linux/io.h> 21 #include <linux/io.h>
22 #include <linux/platform_data/gpio-omap.h> 22 #include <linux/platform_data/gpio-omap.h>
23 #include <linux/power/smartreflex.h> 23 #include <linux/power/smartreflex.h>
24 24
25 #include <plat/omap_hwmod.h> 25 #include <plat/omap_hwmod.h>
26 #include <plat/i2c.h> 26 #include <plat/i2c.h>
27 #include <plat/dma.h> 27 #include <plat/dma.h>
28 #include <linux/platform_data/spi-omap2-mcspi.h> 28 #include <linux/platform_data/spi-omap2-mcspi.h>
29 #include <linux/platform_data/asoc-ti-mcbsp.h> 29 #include <linux/platform_data/asoc-ti-mcbsp.h>
30 #include <plat/mmc.h> 30 #include <plat/mmc.h>
31 #include <plat/dmtimer.h> 31 #include <plat/dmtimer.h>
32 #include <plat/common.h> 32 #include <plat/common.h>
33 #include <plat/iommu.h> 33 #include <plat/iommu.h>
34 34
35 #include "omap_hwmod_common_data.h" 35 #include "omap_hwmod_common_data.h"
36 #include "cm1_44xx.h" 36 #include "cm1_44xx.h"
37 #include "cm2_44xx.h" 37 #include "cm2_44xx.h"
38 #include "prm44xx.h" 38 #include "prm44xx.h"
39 #include "prm-regbits-44xx.h" 39 #include "prm-regbits-44xx.h"
40 #include "wd_timer.h" 40 #include "wd_timer.h"
41 41
42 /* Base offset for all OMAP4 interrupts external to MPUSS */ 42 /* Base offset for all OMAP4 interrupts external to MPUSS */
43 #define OMAP44XX_IRQ_GIC_START 32 43 #define OMAP44XX_IRQ_GIC_START 32
44 44
45 /* Base offset for all OMAP4 dma requests */ 45 /* Base offset for all OMAP4 dma requests */
46 #define OMAP44XX_DMA_REQ_START 1 46 #define OMAP44XX_DMA_REQ_START 1
47 47
48 /* 48 /*
49 * IP blocks 49 * IP blocks
50 */ 50 */
51 51
52 /* 52 /*
53 * 'c2c_target_fw' class 53 * 'c2c_target_fw' class
54 * instance(s): c2c_target_fw 54 * instance(s): c2c_target_fw
55 */ 55 */
56 static struct omap_hwmod_class omap44xx_c2c_target_fw_hwmod_class = { 56 static struct omap_hwmod_class omap44xx_c2c_target_fw_hwmod_class = {
57 .name = "c2c_target_fw", 57 .name = "c2c_target_fw",
58 }; 58 };
59 59
60 /* c2c_target_fw */ 60 /* c2c_target_fw */
61 static struct omap_hwmod omap44xx_c2c_target_fw_hwmod = { 61 static struct omap_hwmod omap44xx_c2c_target_fw_hwmod = {
62 .name = "c2c_target_fw", 62 .name = "c2c_target_fw",
63 .class = &omap44xx_c2c_target_fw_hwmod_class, 63 .class = &omap44xx_c2c_target_fw_hwmod_class,
64 .clkdm_name = "d2d_clkdm", 64 .clkdm_name = "d2d_clkdm",
65 .prcm = { 65 .prcm = {
66 .omap4 = { 66 .omap4 = {
67 .clkctrl_offs = OMAP4_CM_D2D_SAD2D_FW_CLKCTRL_OFFSET, 67 .clkctrl_offs = OMAP4_CM_D2D_SAD2D_FW_CLKCTRL_OFFSET,
68 .context_offs = OMAP4_RM_D2D_SAD2D_FW_CONTEXT_OFFSET, 68 .context_offs = OMAP4_RM_D2D_SAD2D_FW_CONTEXT_OFFSET,
69 }, 69 },
70 }, 70 },
71 }; 71 };
72 72
73 /* 73 /*
74 * 'dmm' class 74 * 'dmm' class
75 * instance(s): dmm 75 * instance(s): dmm
76 */ 76 */
77 static struct omap_hwmod_class omap44xx_dmm_hwmod_class = { 77 static struct omap_hwmod_class omap44xx_dmm_hwmod_class = {
78 .name = "dmm", 78 .name = "dmm",
79 }; 79 };
80 80
81 /* dmm */ 81 /* dmm */
82 static struct omap_hwmod_irq_info omap44xx_dmm_irqs[] = { 82 static struct omap_hwmod_irq_info omap44xx_dmm_irqs[] = {
83 { .irq = 113 + OMAP44XX_IRQ_GIC_START }, 83 { .irq = 113 + OMAP44XX_IRQ_GIC_START },
84 { .irq = -1 } 84 { .irq = -1 }
85 }; 85 };
86 86
87 static struct omap_hwmod omap44xx_dmm_hwmod = { 87 static struct omap_hwmod omap44xx_dmm_hwmod = {
88 .name = "dmm", 88 .name = "dmm",
89 .class = &omap44xx_dmm_hwmod_class, 89 .class = &omap44xx_dmm_hwmod_class,
90 .clkdm_name = "l3_emif_clkdm", 90 .clkdm_name = "l3_emif_clkdm",
91 .mpu_irqs = omap44xx_dmm_irqs, 91 .mpu_irqs = omap44xx_dmm_irqs,
92 .prcm = { 92 .prcm = {
93 .omap4 = { 93 .omap4 = {
94 .clkctrl_offs = OMAP4_CM_MEMIF_DMM_CLKCTRL_OFFSET, 94 .clkctrl_offs = OMAP4_CM_MEMIF_DMM_CLKCTRL_OFFSET,
95 .context_offs = OMAP4_RM_MEMIF_DMM_CONTEXT_OFFSET, 95 .context_offs = OMAP4_RM_MEMIF_DMM_CONTEXT_OFFSET,
96 }, 96 },
97 }, 97 },
98 }; 98 };
99 99
100 /* 100 /*
101 * 'emif_fw' class 101 * 'emif_fw' class
102 * instance(s): emif_fw 102 * instance(s): emif_fw
103 */ 103 */
104 static struct omap_hwmod_class omap44xx_emif_fw_hwmod_class = { 104 static struct omap_hwmod_class omap44xx_emif_fw_hwmod_class = {
105 .name = "emif_fw", 105 .name = "emif_fw",
106 }; 106 };
107 107
108 /* emif_fw */ 108 /* emif_fw */
109 static struct omap_hwmod omap44xx_emif_fw_hwmod = { 109 static struct omap_hwmod omap44xx_emif_fw_hwmod = {
110 .name = "emif_fw", 110 .name = "emif_fw",
111 .class = &omap44xx_emif_fw_hwmod_class, 111 .class = &omap44xx_emif_fw_hwmod_class,
112 .clkdm_name = "l3_emif_clkdm", 112 .clkdm_name = "l3_emif_clkdm",
113 .prcm = { 113 .prcm = {
114 .omap4 = { 114 .omap4 = {
115 .clkctrl_offs = OMAP4_CM_MEMIF_EMIF_FW_CLKCTRL_OFFSET, 115 .clkctrl_offs = OMAP4_CM_MEMIF_EMIF_FW_CLKCTRL_OFFSET,
116 .context_offs = OMAP4_RM_MEMIF_EMIF_FW_CONTEXT_OFFSET, 116 .context_offs = OMAP4_RM_MEMIF_EMIF_FW_CONTEXT_OFFSET,
117 }, 117 },
118 }, 118 },
119 }; 119 };
120 120
121 /* 121 /*
122 * 'l3' class 122 * 'l3' class
123 * instance(s): l3_instr, l3_main_1, l3_main_2, l3_main_3 123 * instance(s): l3_instr, l3_main_1, l3_main_2, l3_main_3
124 */ 124 */
125 static struct omap_hwmod_class omap44xx_l3_hwmod_class = { 125 static struct omap_hwmod_class omap44xx_l3_hwmod_class = {
126 .name = "l3", 126 .name = "l3",
127 }; 127 };
128 128
129 /* l3_instr */ 129 /* l3_instr */
130 static struct omap_hwmod omap44xx_l3_instr_hwmod = { 130 static struct omap_hwmod omap44xx_l3_instr_hwmod = {
131 .name = "l3_instr", 131 .name = "l3_instr",
132 .class = &omap44xx_l3_hwmod_class, 132 .class = &omap44xx_l3_hwmod_class,
133 .clkdm_name = "l3_instr_clkdm", 133 .clkdm_name = "l3_instr_clkdm",
134 .prcm = { 134 .prcm = {
135 .omap4 = { 135 .omap4 = {
136 .clkctrl_offs = OMAP4_CM_L3INSTR_L3_INSTR_CLKCTRL_OFFSET, 136 .clkctrl_offs = OMAP4_CM_L3INSTR_L3_INSTR_CLKCTRL_OFFSET,
137 .context_offs = OMAP4_RM_L3INSTR_L3_INSTR_CONTEXT_OFFSET, 137 .context_offs = OMAP4_RM_L3INSTR_L3_INSTR_CONTEXT_OFFSET,
138 .modulemode = MODULEMODE_HWCTRL, 138 .modulemode = MODULEMODE_HWCTRL,
139 }, 139 },
140 }, 140 },
141 }; 141 };
142 142
143 /* l3_main_1 */ 143 /* l3_main_1 */
144 static struct omap_hwmod_irq_info omap44xx_l3_main_1_irqs[] = { 144 static struct omap_hwmod_irq_info omap44xx_l3_main_1_irqs[] = {
145 { .name = "dbg_err", .irq = 9 + OMAP44XX_IRQ_GIC_START }, 145 { .name = "dbg_err", .irq = 9 + OMAP44XX_IRQ_GIC_START },
146 { .name = "app_err", .irq = 10 + OMAP44XX_IRQ_GIC_START }, 146 { .name = "app_err", .irq = 10 + OMAP44XX_IRQ_GIC_START },
147 { .irq = -1 } 147 { .irq = -1 }
148 }; 148 };
149 149
150 static struct omap_hwmod omap44xx_l3_main_1_hwmod = { 150 static struct omap_hwmod omap44xx_l3_main_1_hwmod = {
151 .name = "l3_main_1", 151 .name = "l3_main_1",
152 .class = &omap44xx_l3_hwmod_class, 152 .class = &omap44xx_l3_hwmod_class,
153 .clkdm_name = "l3_1_clkdm", 153 .clkdm_name = "l3_1_clkdm",
154 .mpu_irqs = omap44xx_l3_main_1_irqs, 154 .mpu_irqs = omap44xx_l3_main_1_irqs,
155 .prcm = { 155 .prcm = {
156 .omap4 = { 156 .omap4 = {
157 .clkctrl_offs = OMAP4_CM_L3_1_L3_1_CLKCTRL_OFFSET, 157 .clkctrl_offs = OMAP4_CM_L3_1_L3_1_CLKCTRL_OFFSET,
158 .context_offs = OMAP4_RM_L3_1_L3_1_CONTEXT_OFFSET, 158 .context_offs = OMAP4_RM_L3_1_L3_1_CONTEXT_OFFSET,
159 }, 159 },
160 }, 160 },
161 }; 161 };
162 162
163 /* l3_main_2 */ 163 /* l3_main_2 */
164 static struct omap_hwmod omap44xx_l3_main_2_hwmod = { 164 static struct omap_hwmod omap44xx_l3_main_2_hwmod = {
165 .name = "l3_main_2", 165 .name = "l3_main_2",
166 .class = &omap44xx_l3_hwmod_class, 166 .class = &omap44xx_l3_hwmod_class,
167 .clkdm_name = "l3_2_clkdm", 167 .clkdm_name = "l3_2_clkdm",
168 .prcm = { 168 .prcm = {
169 .omap4 = { 169 .omap4 = {
170 .clkctrl_offs = OMAP4_CM_L3_2_L3_2_CLKCTRL_OFFSET, 170 .clkctrl_offs = OMAP4_CM_L3_2_L3_2_CLKCTRL_OFFSET,
171 .context_offs = OMAP4_RM_L3_2_L3_2_CONTEXT_OFFSET, 171 .context_offs = OMAP4_RM_L3_2_L3_2_CONTEXT_OFFSET,
172 }, 172 },
173 }, 173 },
174 }; 174 };
175 175
176 /* l3_main_3 */ 176 /* l3_main_3 */
177 static struct omap_hwmod omap44xx_l3_main_3_hwmod = { 177 static struct omap_hwmod omap44xx_l3_main_3_hwmod = {
178 .name = "l3_main_3", 178 .name = "l3_main_3",
179 .class = &omap44xx_l3_hwmod_class, 179 .class = &omap44xx_l3_hwmod_class,
180 .clkdm_name = "l3_instr_clkdm", 180 .clkdm_name = "l3_instr_clkdm",
181 .prcm = { 181 .prcm = {
182 .omap4 = { 182 .omap4 = {
183 .clkctrl_offs = OMAP4_CM_L3INSTR_L3_3_CLKCTRL_OFFSET, 183 .clkctrl_offs = OMAP4_CM_L3INSTR_L3_3_CLKCTRL_OFFSET,
184 .context_offs = OMAP4_RM_L3INSTR_L3_3_CONTEXT_OFFSET, 184 .context_offs = OMAP4_RM_L3INSTR_L3_3_CONTEXT_OFFSET,
185 .modulemode = MODULEMODE_HWCTRL, 185 .modulemode = MODULEMODE_HWCTRL,
186 }, 186 },
187 }, 187 },
188 }; 188 };
189 189
190 /* 190 /*
191 * 'l4' class 191 * 'l4' class
192 * instance(s): l4_abe, l4_cfg, l4_per, l4_wkup 192 * instance(s): l4_abe, l4_cfg, l4_per, l4_wkup
193 */ 193 */
194 static struct omap_hwmod_class omap44xx_l4_hwmod_class = { 194 static struct omap_hwmod_class omap44xx_l4_hwmod_class = {
195 .name = "l4", 195 .name = "l4",
196 }; 196 };
197 197
198 /* l4_abe */ 198 /* l4_abe */
199 static struct omap_hwmod omap44xx_l4_abe_hwmod = { 199 static struct omap_hwmod omap44xx_l4_abe_hwmod = {
200 .name = "l4_abe", 200 .name = "l4_abe",
201 .class = &omap44xx_l4_hwmod_class, 201 .class = &omap44xx_l4_hwmod_class,
202 .clkdm_name = "abe_clkdm", 202 .clkdm_name = "abe_clkdm",
203 .prcm = { 203 .prcm = {
204 .omap4 = { 204 .omap4 = {
205 .clkctrl_offs = OMAP4_CM1_ABE_L4ABE_CLKCTRL_OFFSET, 205 .clkctrl_offs = OMAP4_CM1_ABE_L4ABE_CLKCTRL_OFFSET,
206 .context_offs = OMAP4_RM_ABE_AESS_CONTEXT_OFFSET, 206 .context_offs = OMAP4_RM_ABE_AESS_CONTEXT_OFFSET,
207 .lostcontext_mask = OMAP4430_LOSTMEM_AESSMEM_MASK, 207 .lostcontext_mask = OMAP4430_LOSTMEM_AESSMEM_MASK,
208 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 208 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
209 }, 209 },
210 }, 210 },
211 }; 211 };
212 212
213 /* l4_cfg */ 213 /* l4_cfg */
214 static struct omap_hwmod omap44xx_l4_cfg_hwmod = { 214 static struct omap_hwmod omap44xx_l4_cfg_hwmod = {
215 .name = "l4_cfg", 215 .name = "l4_cfg",
216 .class = &omap44xx_l4_hwmod_class, 216 .class = &omap44xx_l4_hwmod_class,
217 .clkdm_name = "l4_cfg_clkdm", 217 .clkdm_name = "l4_cfg_clkdm",
218 .prcm = { 218 .prcm = {
219 .omap4 = { 219 .omap4 = {
220 .clkctrl_offs = OMAP4_CM_L4CFG_L4_CFG_CLKCTRL_OFFSET, 220 .clkctrl_offs = OMAP4_CM_L4CFG_L4_CFG_CLKCTRL_OFFSET,
221 .context_offs = OMAP4_RM_L4CFG_L4_CFG_CONTEXT_OFFSET, 221 .context_offs = OMAP4_RM_L4CFG_L4_CFG_CONTEXT_OFFSET,
222 }, 222 },
223 }, 223 },
224 }; 224 };
225 225
226 /* l4_per */ 226 /* l4_per */
227 static struct omap_hwmod omap44xx_l4_per_hwmod = { 227 static struct omap_hwmod omap44xx_l4_per_hwmod = {
228 .name = "l4_per", 228 .name = "l4_per",
229 .class = &omap44xx_l4_hwmod_class, 229 .class = &omap44xx_l4_hwmod_class,
230 .clkdm_name = "l4_per_clkdm", 230 .clkdm_name = "l4_per_clkdm",
231 .prcm = { 231 .prcm = {
232 .omap4 = { 232 .omap4 = {
233 .clkctrl_offs = OMAP4_CM_L4PER_L4PER_CLKCTRL_OFFSET, 233 .clkctrl_offs = OMAP4_CM_L4PER_L4PER_CLKCTRL_OFFSET,
234 .context_offs = OMAP4_RM_L4PER_L4_PER_CONTEXT_OFFSET, 234 .context_offs = OMAP4_RM_L4PER_L4_PER_CONTEXT_OFFSET,
235 }, 235 },
236 }, 236 },
237 }; 237 };
238 238
239 /* l4_wkup */ 239 /* l4_wkup */
240 static struct omap_hwmod omap44xx_l4_wkup_hwmod = { 240 static struct omap_hwmod omap44xx_l4_wkup_hwmod = {
241 .name = "l4_wkup", 241 .name = "l4_wkup",
242 .class = &omap44xx_l4_hwmod_class, 242 .class = &omap44xx_l4_hwmod_class,
243 .clkdm_name = "l4_wkup_clkdm", 243 .clkdm_name = "l4_wkup_clkdm",
244 .prcm = { 244 .prcm = {
245 .omap4 = { 245 .omap4 = {
246 .clkctrl_offs = OMAP4_CM_WKUP_L4WKUP_CLKCTRL_OFFSET, 246 .clkctrl_offs = OMAP4_CM_WKUP_L4WKUP_CLKCTRL_OFFSET,
247 .context_offs = OMAP4_RM_WKUP_L4WKUP_CONTEXT_OFFSET, 247 .context_offs = OMAP4_RM_WKUP_L4WKUP_CONTEXT_OFFSET,
248 }, 248 },
249 }, 249 },
250 }; 250 };
251 251
252 /* 252 /*
253 * 'mpu_bus' class 253 * 'mpu_bus' class
254 * instance(s): mpu_private 254 * instance(s): mpu_private
255 */ 255 */
256 static struct omap_hwmod_class omap44xx_mpu_bus_hwmod_class = { 256 static struct omap_hwmod_class omap44xx_mpu_bus_hwmod_class = {
257 .name = "mpu_bus", 257 .name = "mpu_bus",
258 }; 258 };
259 259
260 /* mpu_private */ 260 /* mpu_private */
261 static struct omap_hwmod omap44xx_mpu_private_hwmod = { 261 static struct omap_hwmod omap44xx_mpu_private_hwmod = {
262 .name = "mpu_private", 262 .name = "mpu_private",
263 .class = &omap44xx_mpu_bus_hwmod_class, 263 .class = &omap44xx_mpu_bus_hwmod_class,
264 .clkdm_name = "mpuss_clkdm", 264 .clkdm_name = "mpuss_clkdm",
265 .prcm = { 265 .prcm = {
266 .omap4 = { 266 .omap4 = {
267 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 267 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
268 }, 268 },
269 }, 269 },
270 }; 270 };
271 271
272 /* 272 /*
273 * 'ocp_wp_noc' class 273 * 'ocp_wp_noc' class
274 * instance(s): ocp_wp_noc 274 * instance(s): ocp_wp_noc
275 */ 275 */
276 static struct omap_hwmod_class omap44xx_ocp_wp_noc_hwmod_class = { 276 static struct omap_hwmod_class omap44xx_ocp_wp_noc_hwmod_class = {
277 .name = "ocp_wp_noc", 277 .name = "ocp_wp_noc",
278 }; 278 };
279 279
280 /* ocp_wp_noc */ 280 /* ocp_wp_noc */
281 static struct omap_hwmod omap44xx_ocp_wp_noc_hwmod = { 281 static struct omap_hwmod omap44xx_ocp_wp_noc_hwmod = {
282 .name = "ocp_wp_noc", 282 .name = "ocp_wp_noc",
283 .class = &omap44xx_ocp_wp_noc_hwmod_class, 283 .class = &omap44xx_ocp_wp_noc_hwmod_class,
284 .clkdm_name = "l3_instr_clkdm", 284 .clkdm_name = "l3_instr_clkdm",
285 .prcm = { 285 .prcm = {
286 .omap4 = { 286 .omap4 = {
287 .clkctrl_offs = OMAP4_CM_L3INSTR_OCP_WP1_CLKCTRL_OFFSET, 287 .clkctrl_offs = OMAP4_CM_L3INSTR_OCP_WP1_CLKCTRL_OFFSET,
288 .context_offs = OMAP4_RM_L3INSTR_OCP_WP1_CONTEXT_OFFSET, 288 .context_offs = OMAP4_RM_L3INSTR_OCP_WP1_CONTEXT_OFFSET,
289 .modulemode = MODULEMODE_HWCTRL, 289 .modulemode = MODULEMODE_HWCTRL,
290 }, 290 },
291 }, 291 },
292 }; 292 };
293 293
294 /* 294 /*
295 * Modules omap_hwmod structures 295 * Modules omap_hwmod structures
296 * 296 *
297 * The following IPs are excluded for the moment because: 297 * The following IPs are excluded for the moment because:
298 * - They do not need an explicit SW control using omap_hwmod API. 298 * - They do not need an explicit SW control using omap_hwmod API.
299 * - They still need to be validated with the driver 299 * - They still need to be validated with the driver
300 * properly adapted to omap_hwmod / omap_device 300 * properly adapted to omap_hwmod / omap_device
301 * 301 *
302 * usim 302 * usim
303 */ 303 */
304 304
305 /* 305 /*
306 * 'aess' class 306 * 'aess' class
307 * audio engine sub system 307 * audio engine sub system
308 */ 308 */
309 309
310 static struct omap_hwmod_class_sysconfig omap44xx_aess_sysc = { 310 static struct omap_hwmod_class_sysconfig omap44xx_aess_sysc = {
311 .rev_offs = 0x0000, 311 .rev_offs = 0x0000,
312 .sysc_offs = 0x0010, 312 .sysc_offs = 0x0010,
313 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE), 313 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
314 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 314 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
315 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART | 315 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART |
316 MSTANDBY_SMART_WKUP), 316 MSTANDBY_SMART_WKUP),
317 .sysc_fields = &omap_hwmod_sysc_type2, 317 .sysc_fields = &omap_hwmod_sysc_type2,
318 }; 318 };
319 319
320 static struct omap_hwmod_class omap44xx_aess_hwmod_class = { 320 static struct omap_hwmod_class omap44xx_aess_hwmod_class = {
321 .name = "aess", 321 .name = "aess",
322 .sysc = &omap44xx_aess_sysc, 322 .sysc = &omap44xx_aess_sysc,
323 }; 323 };
324 324
325 /* aess */ 325 /* aess */
326 static struct omap_hwmod_irq_info omap44xx_aess_irqs[] = { 326 static struct omap_hwmod_irq_info omap44xx_aess_irqs[] = {
327 { .irq = 99 + OMAP44XX_IRQ_GIC_START }, 327 { .irq = 99 + OMAP44XX_IRQ_GIC_START },
328 { .irq = -1 } 328 { .irq = -1 }
329 }; 329 };
330 330
331 static struct omap_hwmod_dma_info omap44xx_aess_sdma_reqs[] = { 331 static struct omap_hwmod_dma_info omap44xx_aess_sdma_reqs[] = {
332 { .name = "fifo0", .dma_req = 100 + OMAP44XX_DMA_REQ_START }, 332 { .name = "fifo0", .dma_req = 100 + OMAP44XX_DMA_REQ_START },
333 { .name = "fifo1", .dma_req = 101 + OMAP44XX_DMA_REQ_START }, 333 { .name = "fifo1", .dma_req = 101 + OMAP44XX_DMA_REQ_START },
334 { .name = "fifo2", .dma_req = 102 + OMAP44XX_DMA_REQ_START }, 334 { .name = "fifo2", .dma_req = 102 + OMAP44XX_DMA_REQ_START },
335 { .name = "fifo3", .dma_req = 103 + OMAP44XX_DMA_REQ_START }, 335 { .name = "fifo3", .dma_req = 103 + OMAP44XX_DMA_REQ_START },
336 { .name = "fifo4", .dma_req = 104 + OMAP44XX_DMA_REQ_START }, 336 { .name = "fifo4", .dma_req = 104 + OMAP44XX_DMA_REQ_START },
337 { .name = "fifo5", .dma_req = 105 + OMAP44XX_DMA_REQ_START }, 337 { .name = "fifo5", .dma_req = 105 + OMAP44XX_DMA_REQ_START },
338 { .name = "fifo6", .dma_req = 106 + OMAP44XX_DMA_REQ_START }, 338 { .name = "fifo6", .dma_req = 106 + OMAP44XX_DMA_REQ_START },
339 { .name = "fifo7", .dma_req = 107 + OMAP44XX_DMA_REQ_START }, 339 { .name = "fifo7", .dma_req = 107 + OMAP44XX_DMA_REQ_START },
340 { .dma_req = -1 } 340 { .dma_req = -1 }
341 }; 341 };
342 342
343 static struct omap_hwmod omap44xx_aess_hwmod = { 343 static struct omap_hwmod omap44xx_aess_hwmod = {
344 .name = "aess", 344 .name = "aess",
345 .class = &omap44xx_aess_hwmod_class, 345 .class = &omap44xx_aess_hwmod_class,
346 .clkdm_name = "abe_clkdm", 346 .clkdm_name = "abe_clkdm",
347 .mpu_irqs = omap44xx_aess_irqs, 347 .mpu_irqs = omap44xx_aess_irqs,
348 .sdma_reqs = omap44xx_aess_sdma_reqs, 348 .sdma_reqs = omap44xx_aess_sdma_reqs,
349 .main_clk = "aess_fck", 349 .main_clk = "aess_fck",
350 .prcm = { 350 .prcm = {
351 .omap4 = { 351 .omap4 = {
352 .clkctrl_offs = OMAP4_CM1_ABE_AESS_CLKCTRL_OFFSET, 352 .clkctrl_offs = OMAP4_CM1_ABE_AESS_CLKCTRL_OFFSET,
353 .context_offs = OMAP4_RM_ABE_AESS_CONTEXT_OFFSET, 353 .context_offs = OMAP4_RM_ABE_AESS_CONTEXT_OFFSET,
354 .lostcontext_mask = OMAP4430_LOSTCONTEXT_DFF_MASK, 354 .lostcontext_mask = OMAP4430_LOSTCONTEXT_DFF_MASK,
355 .modulemode = MODULEMODE_SWCTRL, 355 .modulemode = MODULEMODE_SWCTRL,
356 }, 356 },
357 }, 357 },
358 }; 358 };
359 359
360 /* 360 /*
361 * 'c2c' class 361 * 'c2c' class
362 * chip 2 chip interface used to plug the ape soc (omap) with an external modem 362 * chip 2 chip interface used to plug the ape soc (omap) with an external modem
363 * soc 363 * soc
364 */ 364 */
365 365
366 static struct omap_hwmod_class omap44xx_c2c_hwmod_class = { 366 static struct omap_hwmod_class omap44xx_c2c_hwmod_class = {
367 .name = "c2c", 367 .name = "c2c",
368 }; 368 };
369 369
370 /* c2c */ 370 /* c2c */
371 static struct omap_hwmod_irq_info omap44xx_c2c_irqs[] = { 371 static struct omap_hwmod_irq_info omap44xx_c2c_irqs[] = {
372 { .irq = 88 + OMAP44XX_IRQ_GIC_START }, 372 { .irq = 88 + OMAP44XX_IRQ_GIC_START },
373 { .irq = -1 } 373 { .irq = -1 }
374 }; 374 };
375 375
376 static struct omap_hwmod_dma_info omap44xx_c2c_sdma_reqs[] = { 376 static struct omap_hwmod_dma_info omap44xx_c2c_sdma_reqs[] = {
377 { .dma_req = 68 + OMAP44XX_DMA_REQ_START }, 377 { .dma_req = 68 + OMAP44XX_DMA_REQ_START },
378 { .dma_req = -1 } 378 { .dma_req = -1 }
379 }; 379 };
380 380
381 static struct omap_hwmod omap44xx_c2c_hwmod = { 381 static struct omap_hwmod omap44xx_c2c_hwmod = {
382 .name = "c2c", 382 .name = "c2c",
383 .class = &omap44xx_c2c_hwmod_class, 383 .class = &omap44xx_c2c_hwmod_class,
384 .clkdm_name = "d2d_clkdm", 384 .clkdm_name = "d2d_clkdm",
385 .mpu_irqs = omap44xx_c2c_irqs, 385 .mpu_irqs = omap44xx_c2c_irqs,
386 .sdma_reqs = omap44xx_c2c_sdma_reqs, 386 .sdma_reqs = omap44xx_c2c_sdma_reqs,
387 .prcm = { 387 .prcm = {
388 .omap4 = { 388 .omap4 = {
389 .clkctrl_offs = OMAP4_CM_D2D_SAD2D_CLKCTRL_OFFSET, 389 .clkctrl_offs = OMAP4_CM_D2D_SAD2D_CLKCTRL_OFFSET,
390 .context_offs = OMAP4_RM_D2D_SAD2D_CONTEXT_OFFSET, 390 .context_offs = OMAP4_RM_D2D_SAD2D_CONTEXT_OFFSET,
391 }, 391 },
392 }, 392 },
393 }; 393 };
394 394
395 /* 395 /*
396 * 'counter' class 396 * 'counter' class
397 * 32-bit ordinary counter, clocked by the falling edge of the 32 khz clock 397 * 32-bit ordinary counter, clocked by the falling edge of the 32 khz clock
398 */ 398 */
399 399
400 static struct omap_hwmod_class_sysconfig omap44xx_counter_sysc = { 400 static struct omap_hwmod_class_sysconfig omap44xx_counter_sysc = {
401 .rev_offs = 0x0000, 401 .rev_offs = 0x0000,
402 .sysc_offs = 0x0004, 402 .sysc_offs = 0x0004,
403 .sysc_flags = SYSC_HAS_SIDLEMODE, 403 .sysc_flags = SYSC_HAS_SIDLEMODE,
404 .idlemodes = (SIDLE_FORCE | SIDLE_NO), 404 .idlemodes = (SIDLE_FORCE | SIDLE_NO),
405 .sysc_fields = &omap_hwmod_sysc_type1, 405 .sysc_fields = &omap_hwmod_sysc_type1,
406 }; 406 };
407 407
408 static struct omap_hwmod_class omap44xx_counter_hwmod_class = { 408 static struct omap_hwmod_class omap44xx_counter_hwmod_class = {
409 .name = "counter", 409 .name = "counter",
410 .sysc = &omap44xx_counter_sysc, 410 .sysc = &omap44xx_counter_sysc,
411 }; 411 };
412 412
413 /* counter_32k */ 413 /* counter_32k */
414 static struct omap_hwmod omap44xx_counter_32k_hwmod = { 414 static struct omap_hwmod omap44xx_counter_32k_hwmod = {
415 .name = "counter_32k", 415 .name = "counter_32k",
416 .class = &omap44xx_counter_hwmod_class, 416 .class = &omap44xx_counter_hwmod_class,
417 .clkdm_name = "l4_wkup_clkdm", 417 .clkdm_name = "l4_wkup_clkdm",
418 .flags = HWMOD_SWSUP_SIDLE, 418 .flags = HWMOD_SWSUP_SIDLE,
419 .main_clk = "sys_32k_ck", 419 .main_clk = "sys_32k_ck",
420 .prcm = { 420 .prcm = {
421 .omap4 = { 421 .omap4 = {
422 .clkctrl_offs = OMAP4_CM_WKUP_SYNCTIMER_CLKCTRL_OFFSET, 422 .clkctrl_offs = OMAP4_CM_WKUP_SYNCTIMER_CLKCTRL_OFFSET,
423 .context_offs = OMAP4_RM_WKUP_SYNCTIMER_CONTEXT_OFFSET, 423 .context_offs = OMAP4_RM_WKUP_SYNCTIMER_CONTEXT_OFFSET,
424 }, 424 },
425 }, 425 },
426 }; 426 };
427 427
428 /* 428 /*
429 * 'ctrl_module' class 429 * 'ctrl_module' class
430 * attila core control module + core pad control module + wkup pad control 430 * attila core control module + core pad control module + wkup pad control
431 * module + attila wkup control module 431 * module + attila wkup control module
432 */ 432 */
433 433
434 static struct omap_hwmod_class_sysconfig omap44xx_ctrl_module_sysc = { 434 static struct omap_hwmod_class_sysconfig omap44xx_ctrl_module_sysc = {
435 .rev_offs = 0x0000, 435 .rev_offs = 0x0000,
436 .sysc_offs = 0x0010, 436 .sysc_offs = 0x0010,
437 .sysc_flags = SYSC_HAS_SIDLEMODE, 437 .sysc_flags = SYSC_HAS_SIDLEMODE,
438 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 438 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
439 SIDLE_SMART_WKUP), 439 SIDLE_SMART_WKUP),
440 .sysc_fields = &omap_hwmod_sysc_type2, 440 .sysc_fields = &omap_hwmod_sysc_type2,
441 }; 441 };
442 442
443 static struct omap_hwmod_class omap44xx_ctrl_module_hwmod_class = { 443 static struct omap_hwmod_class omap44xx_ctrl_module_hwmod_class = {
444 .name = "ctrl_module", 444 .name = "ctrl_module",
445 .sysc = &omap44xx_ctrl_module_sysc, 445 .sysc = &omap44xx_ctrl_module_sysc,
446 }; 446 };
447 447
448 /* ctrl_module_core */ 448 /* ctrl_module_core */
449 static struct omap_hwmod_irq_info omap44xx_ctrl_module_core_irqs[] = { 449 static struct omap_hwmod_irq_info omap44xx_ctrl_module_core_irqs[] = {
450 { .irq = 8 + OMAP44XX_IRQ_GIC_START }, 450 { .irq = 8 + OMAP44XX_IRQ_GIC_START },
451 { .irq = -1 } 451 { .irq = -1 }
452 }; 452 };
453 453
454 static struct omap_hwmod omap44xx_ctrl_module_core_hwmod = { 454 static struct omap_hwmod omap44xx_ctrl_module_core_hwmod = {
455 .name = "ctrl_module_core", 455 .name = "ctrl_module_core",
456 .class = &omap44xx_ctrl_module_hwmod_class, 456 .class = &omap44xx_ctrl_module_hwmod_class,
457 .clkdm_name = "l4_cfg_clkdm", 457 .clkdm_name = "l4_cfg_clkdm",
458 .mpu_irqs = omap44xx_ctrl_module_core_irqs, 458 .mpu_irqs = omap44xx_ctrl_module_core_irqs,
459 .prcm = { 459 .prcm = {
460 .omap4 = { 460 .omap4 = {
461 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 461 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
462 }, 462 },
463 }, 463 },
464 }; 464 };
465 465
466 /* ctrl_module_pad_core */ 466 /* ctrl_module_pad_core */
467 static struct omap_hwmod omap44xx_ctrl_module_pad_core_hwmod = { 467 static struct omap_hwmod omap44xx_ctrl_module_pad_core_hwmod = {
468 .name = "ctrl_module_pad_core", 468 .name = "ctrl_module_pad_core",
469 .class = &omap44xx_ctrl_module_hwmod_class, 469 .class = &omap44xx_ctrl_module_hwmod_class,
470 .clkdm_name = "l4_cfg_clkdm", 470 .clkdm_name = "l4_cfg_clkdm",
471 .prcm = { 471 .prcm = {
472 .omap4 = { 472 .omap4 = {
473 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 473 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
474 }, 474 },
475 }, 475 },
476 }; 476 };
477 477
478 /* ctrl_module_wkup */ 478 /* ctrl_module_wkup */
479 static struct omap_hwmod omap44xx_ctrl_module_wkup_hwmod = { 479 static struct omap_hwmod omap44xx_ctrl_module_wkup_hwmod = {
480 .name = "ctrl_module_wkup", 480 .name = "ctrl_module_wkup",
481 .class = &omap44xx_ctrl_module_hwmod_class, 481 .class = &omap44xx_ctrl_module_hwmod_class,
482 .clkdm_name = "l4_wkup_clkdm", 482 .clkdm_name = "l4_wkup_clkdm",
483 .prcm = { 483 .prcm = {
484 .omap4 = { 484 .omap4 = {
485 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 485 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
486 }, 486 },
487 }, 487 },
488 }; 488 };
489 489
490 /* ctrl_module_pad_wkup */ 490 /* ctrl_module_pad_wkup */
491 static struct omap_hwmod omap44xx_ctrl_module_pad_wkup_hwmod = { 491 static struct omap_hwmod omap44xx_ctrl_module_pad_wkup_hwmod = {
492 .name = "ctrl_module_pad_wkup", 492 .name = "ctrl_module_pad_wkup",
493 .class = &omap44xx_ctrl_module_hwmod_class, 493 .class = &omap44xx_ctrl_module_hwmod_class,
494 .clkdm_name = "l4_wkup_clkdm", 494 .clkdm_name = "l4_wkup_clkdm",
495 .prcm = { 495 .prcm = {
496 .omap4 = { 496 .omap4 = {
497 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 497 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
498 }, 498 },
499 }, 499 },
500 }; 500 };
501 501
502 /* 502 /*
503 * 'debugss' class 503 * 'debugss' class
504 * debug and emulation sub system 504 * debug and emulation sub system
505 */ 505 */
506 506
507 static struct omap_hwmod_class omap44xx_debugss_hwmod_class = { 507 static struct omap_hwmod_class omap44xx_debugss_hwmod_class = {
508 .name = "debugss", 508 .name = "debugss",
509 }; 509 };
510 510
511 /* debugss */ 511 /* debugss */
512 static struct omap_hwmod omap44xx_debugss_hwmod = { 512 static struct omap_hwmod omap44xx_debugss_hwmod = {
513 .name = "debugss", 513 .name = "debugss",
514 .class = &omap44xx_debugss_hwmod_class, 514 .class = &omap44xx_debugss_hwmod_class,
515 .clkdm_name = "emu_sys_clkdm", 515 .clkdm_name = "emu_sys_clkdm",
516 .main_clk = "trace_clk_div_ck", 516 .main_clk = "trace_clk_div_ck",
517 .prcm = { 517 .prcm = {
518 .omap4 = { 518 .omap4 = {
519 .clkctrl_offs = OMAP4_CM_EMU_DEBUGSS_CLKCTRL_OFFSET, 519 .clkctrl_offs = OMAP4_CM_EMU_DEBUGSS_CLKCTRL_OFFSET,
520 .context_offs = OMAP4_RM_EMU_DEBUGSS_CONTEXT_OFFSET, 520 .context_offs = OMAP4_RM_EMU_DEBUGSS_CONTEXT_OFFSET,
521 }, 521 },
522 }, 522 },
523 }; 523 };
524 524
525 /* 525 /*
526 * 'dma' class 526 * 'dma' class
527 * dma controller for data exchange between memory to memory (i.e. internal or 527 * dma controller for data exchange between memory to memory (i.e. internal or
528 * external memory) and gp peripherals to memory or memory to gp peripherals 528 * external memory) and gp peripherals to memory or memory to gp peripherals
529 */ 529 */
530 530
531 static struct omap_hwmod_class_sysconfig omap44xx_dma_sysc = { 531 static struct omap_hwmod_class_sysconfig omap44xx_dma_sysc = {
532 .rev_offs = 0x0000, 532 .rev_offs = 0x0000,
533 .sysc_offs = 0x002c, 533 .sysc_offs = 0x002c,
534 .syss_offs = 0x0028, 534 .syss_offs = 0x0028,
535 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY | 535 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
536 SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE | 536 SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE |
537 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET | 537 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
538 SYSS_HAS_RESET_STATUS), 538 SYSS_HAS_RESET_STATUS),
539 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 539 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
540 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART), 540 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
541 .sysc_fields = &omap_hwmod_sysc_type1, 541 .sysc_fields = &omap_hwmod_sysc_type1,
542 }; 542 };
543 543
544 static struct omap_hwmod_class omap44xx_dma_hwmod_class = { 544 static struct omap_hwmod_class omap44xx_dma_hwmod_class = {
545 .name = "dma", 545 .name = "dma",
546 .sysc = &omap44xx_dma_sysc, 546 .sysc = &omap44xx_dma_sysc,
547 }; 547 };
548 548
549 /* dma dev_attr */ 549 /* dma dev_attr */
550 static struct omap_dma_dev_attr dma_dev_attr = { 550 static struct omap_dma_dev_attr dma_dev_attr = {
551 .dev_caps = RESERVE_CHANNEL | DMA_LINKED_LCH | GLOBAL_PRIORITY | 551 .dev_caps = RESERVE_CHANNEL | DMA_LINKED_LCH | GLOBAL_PRIORITY |
552 IS_CSSA_32 | IS_CDSA_32 | IS_RW_PRIORITY, 552 IS_CSSA_32 | IS_CDSA_32 | IS_RW_PRIORITY,
553 .lch_count = 32, 553 .lch_count = 32,
554 }; 554 };
555 555
556 /* dma_system */ 556 /* dma_system */
557 static struct omap_hwmod_irq_info omap44xx_dma_system_irqs[] = { 557 static struct omap_hwmod_irq_info omap44xx_dma_system_irqs[] = {
558 { .name = "0", .irq = 12 + OMAP44XX_IRQ_GIC_START }, 558 { .name = "0", .irq = 12 + OMAP44XX_IRQ_GIC_START },
559 { .name = "1", .irq = 13 + OMAP44XX_IRQ_GIC_START }, 559 { .name = "1", .irq = 13 + OMAP44XX_IRQ_GIC_START },
560 { .name = "2", .irq = 14 + OMAP44XX_IRQ_GIC_START }, 560 { .name = "2", .irq = 14 + OMAP44XX_IRQ_GIC_START },
561 { .name = "3", .irq = 15 + OMAP44XX_IRQ_GIC_START }, 561 { .name = "3", .irq = 15 + OMAP44XX_IRQ_GIC_START },
562 { .irq = -1 } 562 { .irq = -1 }
563 }; 563 };
564 564
565 static struct omap_hwmod omap44xx_dma_system_hwmod = { 565 static struct omap_hwmod omap44xx_dma_system_hwmod = {
566 .name = "dma_system", 566 .name = "dma_system",
567 .class = &omap44xx_dma_hwmod_class, 567 .class = &omap44xx_dma_hwmod_class,
568 .clkdm_name = "l3_dma_clkdm", 568 .clkdm_name = "l3_dma_clkdm",
569 .mpu_irqs = omap44xx_dma_system_irqs, 569 .mpu_irqs = omap44xx_dma_system_irqs,
570 .main_clk = "l3_div_ck", 570 .main_clk = "l3_div_ck",
571 .prcm = { 571 .prcm = {
572 .omap4 = { 572 .omap4 = {
573 .clkctrl_offs = OMAP4_CM_SDMA_SDMA_CLKCTRL_OFFSET, 573 .clkctrl_offs = OMAP4_CM_SDMA_SDMA_CLKCTRL_OFFSET,
574 .context_offs = OMAP4_RM_SDMA_SDMA_CONTEXT_OFFSET, 574 .context_offs = OMAP4_RM_SDMA_SDMA_CONTEXT_OFFSET,
575 }, 575 },
576 }, 576 },
577 .dev_attr = &dma_dev_attr, 577 .dev_attr = &dma_dev_attr,
578 }; 578 };
579 579
580 /* 580 /*
581 * 'dmic' class 581 * 'dmic' class
582 * digital microphone controller 582 * digital microphone controller
583 */ 583 */
584 584
585 static struct omap_hwmod_class_sysconfig omap44xx_dmic_sysc = { 585 static struct omap_hwmod_class_sysconfig omap44xx_dmic_sysc = {
586 .rev_offs = 0x0000, 586 .rev_offs = 0x0000,
587 .sysc_offs = 0x0010, 587 .sysc_offs = 0x0010,
588 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS | 588 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
589 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET), 589 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
590 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 590 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
591 SIDLE_SMART_WKUP), 591 SIDLE_SMART_WKUP),
592 .sysc_fields = &omap_hwmod_sysc_type2, 592 .sysc_fields = &omap_hwmod_sysc_type2,
593 }; 593 };
594 594
595 static struct omap_hwmod_class omap44xx_dmic_hwmod_class = { 595 static struct omap_hwmod_class omap44xx_dmic_hwmod_class = {
596 .name = "dmic", 596 .name = "dmic",
597 .sysc = &omap44xx_dmic_sysc, 597 .sysc = &omap44xx_dmic_sysc,
598 }; 598 };
599 599
600 /* dmic */ 600 /* dmic */
601 static struct omap_hwmod_irq_info omap44xx_dmic_irqs[] = { 601 static struct omap_hwmod_irq_info omap44xx_dmic_irqs[] = {
602 { .irq = 114 + OMAP44XX_IRQ_GIC_START }, 602 { .irq = 114 + OMAP44XX_IRQ_GIC_START },
603 { .irq = -1 } 603 { .irq = -1 }
604 }; 604 };
605 605
606 static struct omap_hwmod_dma_info omap44xx_dmic_sdma_reqs[] = { 606 static struct omap_hwmod_dma_info omap44xx_dmic_sdma_reqs[] = {
607 { .dma_req = 66 + OMAP44XX_DMA_REQ_START }, 607 { .dma_req = 66 + OMAP44XX_DMA_REQ_START },
608 { .dma_req = -1 } 608 { .dma_req = -1 }
609 }; 609 };
610 610
611 static struct omap_hwmod omap44xx_dmic_hwmod = { 611 static struct omap_hwmod omap44xx_dmic_hwmod = {
612 .name = "dmic", 612 .name = "dmic",
613 .class = &omap44xx_dmic_hwmod_class, 613 .class = &omap44xx_dmic_hwmod_class,
614 .clkdm_name = "abe_clkdm", 614 .clkdm_name = "abe_clkdm",
615 .mpu_irqs = omap44xx_dmic_irqs, 615 .mpu_irqs = omap44xx_dmic_irqs,
616 .sdma_reqs = omap44xx_dmic_sdma_reqs, 616 .sdma_reqs = omap44xx_dmic_sdma_reqs,
617 .main_clk = "dmic_fck", 617 .main_clk = "dmic_fck",
618 .prcm = { 618 .prcm = {
619 .omap4 = { 619 .omap4 = {
620 .clkctrl_offs = OMAP4_CM1_ABE_DMIC_CLKCTRL_OFFSET, 620 .clkctrl_offs = OMAP4_CM1_ABE_DMIC_CLKCTRL_OFFSET,
621 .context_offs = OMAP4_RM_ABE_DMIC_CONTEXT_OFFSET, 621 .context_offs = OMAP4_RM_ABE_DMIC_CONTEXT_OFFSET,
622 .modulemode = MODULEMODE_SWCTRL, 622 .modulemode = MODULEMODE_SWCTRL,
623 }, 623 },
624 }, 624 },
625 }; 625 };
626 626
627 /* 627 /*
628 * 'dsp' class 628 * 'dsp' class
629 * dsp sub-system 629 * dsp sub-system
630 */ 630 */
631 631
632 static struct omap_hwmod_class omap44xx_dsp_hwmod_class = { 632 static struct omap_hwmod_class omap44xx_dsp_hwmod_class = {
633 .name = "dsp", 633 .name = "dsp",
634 }; 634 };
635 635
636 /* dsp */ 636 /* dsp */
637 static struct omap_hwmod_irq_info omap44xx_dsp_irqs[] = { 637 static struct omap_hwmod_irq_info omap44xx_dsp_irqs[] = {
638 { .irq = 28 + OMAP44XX_IRQ_GIC_START }, 638 { .irq = 28 + OMAP44XX_IRQ_GIC_START },
639 { .irq = -1 } 639 { .irq = -1 }
640 }; 640 };
641 641
642 static struct omap_hwmod_rst_info omap44xx_dsp_resets[] = { 642 static struct omap_hwmod_rst_info omap44xx_dsp_resets[] = {
643 { .name = "dsp", .rst_shift = 0 }, 643 { .name = "dsp", .rst_shift = 0 },
644 }; 644 };
645 645
646 static struct omap_hwmod omap44xx_dsp_hwmod = { 646 static struct omap_hwmod omap44xx_dsp_hwmod = {
647 .name = "dsp", 647 .name = "dsp",
648 .class = &omap44xx_dsp_hwmod_class, 648 .class = &omap44xx_dsp_hwmod_class,
649 .clkdm_name = "tesla_clkdm", 649 .clkdm_name = "tesla_clkdm",
650 .mpu_irqs = omap44xx_dsp_irqs, 650 .mpu_irqs = omap44xx_dsp_irqs,
651 .rst_lines = omap44xx_dsp_resets, 651 .rst_lines = omap44xx_dsp_resets,
652 .rst_lines_cnt = ARRAY_SIZE(omap44xx_dsp_resets), 652 .rst_lines_cnt = ARRAY_SIZE(omap44xx_dsp_resets),
653 .main_clk = "dsp_fck", 653 .main_clk = "dsp_fck",
654 .prcm = { 654 .prcm = {
655 .omap4 = { 655 .omap4 = {
656 .clkctrl_offs = OMAP4_CM_TESLA_TESLA_CLKCTRL_OFFSET, 656 .clkctrl_offs = OMAP4_CM_TESLA_TESLA_CLKCTRL_OFFSET,
657 .rstctrl_offs = OMAP4_RM_TESLA_RSTCTRL_OFFSET, 657 .rstctrl_offs = OMAP4_RM_TESLA_RSTCTRL_OFFSET,
658 .context_offs = OMAP4_RM_TESLA_TESLA_CONTEXT_OFFSET, 658 .context_offs = OMAP4_RM_TESLA_TESLA_CONTEXT_OFFSET,
659 .modulemode = MODULEMODE_HWCTRL, 659 .modulemode = MODULEMODE_HWCTRL,
660 }, 660 },
661 }, 661 },
662 }; 662 };
663 663
664 /* 664 /*
665 * 'dss' class 665 * 'dss' class
666 * display sub-system 666 * display sub-system
667 */ 667 */
668 668
669 static struct omap_hwmod_class_sysconfig omap44xx_dss_sysc = { 669 static struct omap_hwmod_class_sysconfig omap44xx_dss_sysc = {
670 .rev_offs = 0x0000, 670 .rev_offs = 0x0000,
671 .syss_offs = 0x0014, 671 .syss_offs = 0x0014,
672 .sysc_flags = SYSS_HAS_RESET_STATUS, 672 .sysc_flags = SYSS_HAS_RESET_STATUS,
673 }; 673 };
674 674
675 static struct omap_hwmod_class omap44xx_dss_hwmod_class = { 675 static struct omap_hwmod_class omap44xx_dss_hwmod_class = {
676 .name = "dss", 676 .name = "dss",
677 .sysc = &omap44xx_dss_sysc, 677 .sysc = &omap44xx_dss_sysc,
678 .reset = omap_dss_reset, 678 .reset = omap_dss_reset,
679 }; 679 };
680 680
681 /* dss */ 681 /* dss */
682 static struct omap_hwmod_opt_clk dss_opt_clks[] = { 682 static struct omap_hwmod_opt_clk dss_opt_clks[] = {
683 { .role = "sys_clk", .clk = "dss_sys_clk" }, 683 { .role = "sys_clk", .clk = "dss_sys_clk" },
684 { .role = "tv_clk", .clk = "dss_tv_clk" }, 684 { .role = "tv_clk", .clk = "dss_tv_clk" },
685 { .role = "hdmi_clk", .clk = "dss_48mhz_clk" }, 685 { .role = "hdmi_clk", .clk = "dss_48mhz_clk" },
686 }; 686 };
687 687
688 static struct omap_hwmod omap44xx_dss_hwmod = { 688 static struct omap_hwmod omap44xx_dss_hwmod = {
689 .name = "dss_core", 689 .name = "dss_core",
690 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 690 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
691 .class = &omap44xx_dss_hwmod_class, 691 .class = &omap44xx_dss_hwmod_class,
692 .clkdm_name = "l3_dss_clkdm", 692 .clkdm_name = "l3_dss_clkdm",
693 .main_clk = "dss_dss_clk", 693 .main_clk = "dss_dss_clk",
694 .prcm = { 694 .prcm = {
695 .omap4 = { 695 .omap4 = {
696 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET, 696 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
697 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET, 697 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
698 }, 698 },
699 }, 699 },
700 .opt_clks = dss_opt_clks, 700 .opt_clks = dss_opt_clks,
701 .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks), 701 .opt_clks_cnt = ARRAY_SIZE(dss_opt_clks),
702 }; 702 };
703 703
704 /* 704 /*
705 * 'dispc' class 705 * 'dispc' class
706 * display controller 706 * display controller
707 */ 707 */
708 708
709 static struct omap_hwmod_class_sysconfig omap44xx_dispc_sysc = { 709 static struct omap_hwmod_class_sysconfig omap44xx_dispc_sysc = {
710 .rev_offs = 0x0000, 710 .rev_offs = 0x0000,
711 .sysc_offs = 0x0010, 711 .sysc_offs = 0x0010,
712 .syss_offs = 0x0014, 712 .syss_offs = 0x0014,
713 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY | 713 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
714 SYSC_HAS_ENAWAKEUP | SYSC_HAS_MIDLEMODE | 714 SYSC_HAS_ENAWAKEUP | SYSC_HAS_MIDLEMODE |
715 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET | 715 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
716 SYSS_HAS_RESET_STATUS), 716 SYSS_HAS_RESET_STATUS),
717 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 717 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
718 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART), 718 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
719 .sysc_fields = &omap_hwmod_sysc_type1, 719 .sysc_fields = &omap_hwmod_sysc_type1,
720 }; 720 };
721 721
722 static struct omap_hwmod_class omap44xx_dispc_hwmod_class = { 722 static struct omap_hwmod_class omap44xx_dispc_hwmod_class = {
723 .name = "dispc", 723 .name = "dispc",
724 .sysc = &omap44xx_dispc_sysc, 724 .sysc = &omap44xx_dispc_sysc,
725 }; 725 };
726 726
727 /* dss_dispc */ 727 /* dss_dispc */
728 static struct omap_hwmod_irq_info omap44xx_dss_dispc_irqs[] = { 728 static struct omap_hwmod_irq_info omap44xx_dss_dispc_irqs[] = {
729 { .irq = 25 + OMAP44XX_IRQ_GIC_START }, 729 { .irq = 25 + OMAP44XX_IRQ_GIC_START },
730 { .irq = -1 } 730 { .irq = -1 }
731 }; 731 };
732 732
733 static struct omap_hwmod_dma_info omap44xx_dss_dispc_sdma_reqs[] = { 733 static struct omap_hwmod_dma_info omap44xx_dss_dispc_sdma_reqs[] = {
734 { .dma_req = 5 + OMAP44XX_DMA_REQ_START }, 734 { .dma_req = 5 + OMAP44XX_DMA_REQ_START },
735 { .dma_req = -1 } 735 { .dma_req = -1 }
736 }; 736 };
737 737
738 static struct omap_dss_dispc_dev_attr omap44xx_dss_dispc_dev_attr = { 738 static struct omap_dss_dispc_dev_attr omap44xx_dss_dispc_dev_attr = {
739 .manager_count = 3, 739 .manager_count = 3,
740 .has_framedonetv_irq = 1 740 .has_framedonetv_irq = 1
741 }; 741 };
742 742
743 static struct omap_hwmod omap44xx_dss_dispc_hwmod = { 743 static struct omap_hwmod omap44xx_dss_dispc_hwmod = {
744 .name = "dss_dispc", 744 .name = "dss_dispc",
745 .class = &omap44xx_dispc_hwmod_class, 745 .class = &omap44xx_dispc_hwmod_class,
746 .clkdm_name = "l3_dss_clkdm", 746 .clkdm_name = "l3_dss_clkdm",
747 .mpu_irqs = omap44xx_dss_dispc_irqs, 747 .mpu_irqs = omap44xx_dss_dispc_irqs,
748 .sdma_reqs = omap44xx_dss_dispc_sdma_reqs, 748 .sdma_reqs = omap44xx_dss_dispc_sdma_reqs,
749 .main_clk = "dss_dss_clk", 749 .main_clk = "dss_dss_clk",
750 .prcm = { 750 .prcm = {
751 .omap4 = { 751 .omap4 = {
752 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET, 752 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
753 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET, 753 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
754 }, 754 },
755 }, 755 },
756 .dev_attr = &omap44xx_dss_dispc_dev_attr 756 .dev_attr = &omap44xx_dss_dispc_dev_attr
757 }; 757 };
758 758
759 /* 759 /*
760 * 'dsi' class 760 * 'dsi' class
761 * display serial interface controller 761 * display serial interface controller
762 */ 762 */
763 763
764 static struct omap_hwmod_class_sysconfig omap44xx_dsi_sysc = { 764 static struct omap_hwmod_class_sysconfig omap44xx_dsi_sysc = {
765 .rev_offs = 0x0000, 765 .rev_offs = 0x0000,
766 .sysc_offs = 0x0010, 766 .sysc_offs = 0x0010,
767 .syss_offs = 0x0014, 767 .syss_offs = 0x0014,
768 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY | 768 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
769 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE | 769 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
770 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 770 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
771 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 771 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
772 .sysc_fields = &omap_hwmod_sysc_type1, 772 .sysc_fields = &omap_hwmod_sysc_type1,
773 }; 773 };
774 774
775 static struct omap_hwmod_class omap44xx_dsi_hwmod_class = { 775 static struct omap_hwmod_class omap44xx_dsi_hwmod_class = {
776 .name = "dsi", 776 .name = "dsi",
777 .sysc = &omap44xx_dsi_sysc, 777 .sysc = &omap44xx_dsi_sysc,
778 }; 778 };
779 779
780 /* dss_dsi1 */ 780 /* dss_dsi1 */
781 static struct omap_hwmod_irq_info omap44xx_dss_dsi1_irqs[] = { 781 static struct omap_hwmod_irq_info omap44xx_dss_dsi1_irqs[] = {
782 { .irq = 53 + OMAP44XX_IRQ_GIC_START }, 782 { .irq = 53 + OMAP44XX_IRQ_GIC_START },
783 { .irq = -1 } 783 { .irq = -1 }
784 }; 784 };
785 785
786 static struct omap_hwmod_dma_info omap44xx_dss_dsi1_sdma_reqs[] = { 786 static struct omap_hwmod_dma_info omap44xx_dss_dsi1_sdma_reqs[] = {
787 { .dma_req = 74 + OMAP44XX_DMA_REQ_START }, 787 { .dma_req = 74 + OMAP44XX_DMA_REQ_START },
788 { .dma_req = -1 } 788 { .dma_req = -1 }
789 }; 789 };
790 790
791 static struct omap_hwmod_opt_clk dss_dsi1_opt_clks[] = { 791 static struct omap_hwmod_opt_clk dss_dsi1_opt_clks[] = {
792 { .role = "sys_clk", .clk = "dss_sys_clk" }, 792 { .role = "sys_clk", .clk = "dss_sys_clk" },
793 }; 793 };
794 794
795 static struct omap_hwmod omap44xx_dss_dsi1_hwmod = { 795 static struct omap_hwmod omap44xx_dss_dsi1_hwmod = {
796 .name = "dss_dsi1", 796 .name = "dss_dsi1",
797 .class = &omap44xx_dsi_hwmod_class, 797 .class = &omap44xx_dsi_hwmod_class,
798 .clkdm_name = "l3_dss_clkdm", 798 .clkdm_name = "l3_dss_clkdm",
799 .mpu_irqs = omap44xx_dss_dsi1_irqs, 799 .mpu_irqs = omap44xx_dss_dsi1_irqs,
800 .sdma_reqs = omap44xx_dss_dsi1_sdma_reqs, 800 .sdma_reqs = omap44xx_dss_dsi1_sdma_reqs,
801 .main_clk = "dss_dss_clk", 801 .main_clk = "dss_dss_clk",
802 .prcm = { 802 .prcm = {
803 .omap4 = { 803 .omap4 = {
804 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET, 804 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
805 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET, 805 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
806 }, 806 },
807 }, 807 },
808 .opt_clks = dss_dsi1_opt_clks, 808 .opt_clks = dss_dsi1_opt_clks,
809 .opt_clks_cnt = ARRAY_SIZE(dss_dsi1_opt_clks), 809 .opt_clks_cnt = ARRAY_SIZE(dss_dsi1_opt_clks),
810 }; 810 };
811 811
812 /* dss_dsi2 */ 812 /* dss_dsi2 */
813 static struct omap_hwmod_irq_info omap44xx_dss_dsi2_irqs[] = { 813 static struct omap_hwmod_irq_info omap44xx_dss_dsi2_irqs[] = {
814 { .irq = 84 + OMAP44XX_IRQ_GIC_START }, 814 { .irq = 84 + OMAP44XX_IRQ_GIC_START },
815 { .irq = -1 } 815 { .irq = -1 }
816 }; 816 };
817 817
818 static struct omap_hwmod_dma_info omap44xx_dss_dsi2_sdma_reqs[] = { 818 static struct omap_hwmod_dma_info omap44xx_dss_dsi2_sdma_reqs[] = {
819 { .dma_req = 83 + OMAP44XX_DMA_REQ_START }, 819 { .dma_req = 83 + OMAP44XX_DMA_REQ_START },
820 { .dma_req = -1 } 820 { .dma_req = -1 }
821 }; 821 };
822 822
823 static struct omap_hwmod_opt_clk dss_dsi2_opt_clks[] = { 823 static struct omap_hwmod_opt_clk dss_dsi2_opt_clks[] = {
824 { .role = "sys_clk", .clk = "dss_sys_clk" }, 824 { .role = "sys_clk", .clk = "dss_sys_clk" },
825 }; 825 };
826 826
827 static struct omap_hwmod omap44xx_dss_dsi2_hwmod = { 827 static struct omap_hwmod omap44xx_dss_dsi2_hwmod = {
828 .name = "dss_dsi2", 828 .name = "dss_dsi2",
829 .class = &omap44xx_dsi_hwmod_class, 829 .class = &omap44xx_dsi_hwmod_class,
830 .clkdm_name = "l3_dss_clkdm", 830 .clkdm_name = "l3_dss_clkdm",
831 .mpu_irqs = omap44xx_dss_dsi2_irqs, 831 .mpu_irqs = omap44xx_dss_dsi2_irqs,
832 .sdma_reqs = omap44xx_dss_dsi2_sdma_reqs, 832 .sdma_reqs = omap44xx_dss_dsi2_sdma_reqs,
833 .main_clk = "dss_dss_clk", 833 .main_clk = "dss_dss_clk",
834 .prcm = { 834 .prcm = {
835 .omap4 = { 835 .omap4 = {
836 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET, 836 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
837 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET, 837 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
838 }, 838 },
839 }, 839 },
840 .opt_clks = dss_dsi2_opt_clks, 840 .opt_clks = dss_dsi2_opt_clks,
841 .opt_clks_cnt = ARRAY_SIZE(dss_dsi2_opt_clks), 841 .opt_clks_cnt = ARRAY_SIZE(dss_dsi2_opt_clks),
842 }; 842 };
843 843
844 /* 844 /*
845 * 'hdmi' class 845 * 'hdmi' class
846 * hdmi controller 846 * hdmi controller
847 */ 847 */
848 848
849 static struct omap_hwmod_class_sysconfig omap44xx_hdmi_sysc = { 849 static struct omap_hwmod_class_sysconfig omap44xx_hdmi_sysc = {
850 .rev_offs = 0x0000, 850 .rev_offs = 0x0000,
851 .sysc_offs = 0x0010, 851 .sysc_offs = 0x0010,
852 .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE | 852 .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
853 SYSC_HAS_SOFTRESET), 853 SYSC_HAS_SOFTRESET),
854 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 854 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
855 SIDLE_SMART_WKUP), 855 SIDLE_SMART_WKUP),
856 .sysc_fields = &omap_hwmod_sysc_type2, 856 .sysc_fields = &omap_hwmod_sysc_type2,
857 }; 857 };
858 858
859 static struct omap_hwmod_class omap44xx_hdmi_hwmod_class = { 859 static struct omap_hwmod_class omap44xx_hdmi_hwmod_class = {
860 .name = "hdmi", 860 .name = "hdmi",
861 .sysc = &omap44xx_hdmi_sysc, 861 .sysc = &omap44xx_hdmi_sysc,
862 }; 862 };
863 863
864 /* dss_hdmi */ 864 /* dss_hdmi */
865 static struct omap_hwmod_irq_info omap44xx_dss_hdmi_irqs[] = { 865 static struct omap_hwmod_irq_info omap44xx_dss_hdmi_irqs[] = {
866 { .irq = 101 + OMAP44XX_IRQ_GIC_START }, 866 { .irq = 101 + OMAP44XX_IRQ_GIC_START },
867 { .irq = -1 } 867 { .irq = -1 }
868 }; 868 };
869 869
870 static struct omap_hwmod_dma_info omap44xx_dss_hdmi_sdma_reqs[] = { 870 static struct omap_hwmod_dma_info omap44xx_dss_hdmi_sdma_reqs[] = {
871 { .dma_req = 75 + OMAP44XX_DMA_REQ_START }, 871 { .dma_req = 75 + OMAP44XX_DMA_REQ_START },
872 { .dma_req = -1 } 872 { .dma_req = -1 }
873 }; 873 };
874 874
875 static struct omap_hwmod_opt_clk dss_hdmi_opt_clks[] = { 875 static struct omap_hwmod_opt_clk dss_hdmi_opt_clks[] = {
876 { .role = "sys_clk", .clk = "dss_sys_clk" }, 876 { .role = "sys_clk", .clk = "dss_sys_clk" },
877 }; 877 };
878 878
879 static struct omap_hwmod omap44xx_dss_hdmi_hwmod = { 879 static struct omap_hwmod omap44xx_dss_hdmi_hwmod = {
880 .name = "dss_hdmi", 880 .name = "dss_hdmi",
881 .class = &omap44xx_hdmi_hwmod_class, 881 .class = &omap44xx_hdmi_hwmod_class,
882 .clkdm_name = "l3_dss_clkdm", 882 .clkdm_name = "l3_dss_clkdm",
883 /* 883 /*
884 * HDMI audio requires to use no-idle mode. Hence, 884 * HDMI audio requires to use no-idle mode. Hence,
885 * set idle mode by software. 885 * set idle mode by software.
886 */ 886 */
887 .flags = HWMOD_SWSUP_SIDLE, 887 .flags = HWMOD_SWSUP_SIDLE,
888 .mpu_irqs = omap44xx_dss_hdmi_irqs, 888 .mpu_irqs = omap44xx_dss_hdmi_irqs,
889 .sdma_reqs = omap44xx_dss_hdmi_sdma_reqs, 889 .sdma_reqs = omap44xx_dss_hdmi_sdma_reqs,
890 .main_clk = "dss_48mhz_clk", 890 .main_clk = "dss_48mhz_clk",
891 .prcm = { 891 .prcm = {
892 .omap4 = { 892 .omap4 = {
893 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET, 893 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
894 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET, 894 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
895 }, 895 },
896 }, 896 },
897 .opt_clks = dss_hdmi_opt_clks, 897 .opt_clks = dss_hdmi_opt_clks,
898 .opt_clks_cnt = ARRAY_SIZE(dss_hdmi_opt_clks), 898 .opt_clks_cnt = ARRAY_SIZE(dss_hdmi_opt_clks),
899 }; 899 };
900 900
901 /* 901 /*
902 * 'rfbi' class 902 * 'rfbi' class
903 * remote frame buffer interface 903 * remote frame buffer interface
904 */ 904 */
905 905
906 static struct omap_hwmod_class_sysconfig omap44xx_rfbi_sysc = { 906 static struct omap_hwmod_class_sysconfig omap44xx_rfbi_sysc = {
907 .rev_offs = 0x0000, 907 .rev_offs = 0x0000,
908 .sysc_offs = 0x0010, 908 .sysc_offs = 0x0010,
909 .syss_offs = 0x0014, 909 .syss_offs = 0x0014,
910 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE | 910 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
911 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 911 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
912 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 912 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
913 .sysc_fields = &omap_hwmod_sysc_type1, 913 .sysc_fields = &omap_hwmod_sysc_type1,
914 }; 914 };
915 915
916 static struct omap_hwmod_class omap44xx_rfbi_hwmod_class = { 916 static struct omap_hwmod_class omap44xx_rfbi_hwmod_class = {
917 .name = "rfbi", 917 .name = "rfbi",
918 .sysc = &omap44xx_rfbi_sysc, 918 .sysc = &omap44xx_rfbi_sysc,
919 }; 919 };
920 920
921 /* dss_rfbi */ 921 /* dss_rfbi */
922 static struct omap_hwmod_dma_info omap44xx_dss_rfbi_sdma_reqs[] = { 922 static struct omap_hwmod_dma_info omap44xx_dss_rfbi_sdma_reqs[] = {
923 { .dma_req = 13 + OMAP44XX_DMA_REQ_START }, 923 { .dma_req = 13 + OMAP44XX_DMA_REQ_START },
924 { .dma_req = -1 } 924 { .dma_req = -1 }
925 }; 925 };
926 926
927 static struct omap_hwmod_opt_clk dss_rfbi_opt_clks[] = { 927 static struct omap_hwmod_opt_clk dss_rfbi_opt_clks[] = {
928 { .role = "ick", .clk = "dss_fck" }, 928 { .role = "ick", .clk = "dss_fck" },
929 }; 929 };
930 930
931 static struct omap_hwmod omap44xx_dss_rfbi_hwmod = { 931 static struct omap_hwmod omap44xx_dss_rfbi_hwmod = {
932 .name = "dss_rfbi", 932 .name = "dss_rfbi",
933 .class = &omap44xx_rfbi_hwmod_class, 933 .class = &omap44xx_rfbi_hwmod_class,
934 .clkdm_name = "l3_dss_clkdm", 934 .clkdm_name = "l3_dss_clkdm",
935 .sdma_reqs = omap44xx_dss_rfbi_sdma_reqs, 935 .sdma_reqs = omap44xx_dss_rfbi_sdma_reqs,
936 .main_clk = "dss_dss_clk", 936 .main_clk = "dss_dss_clk",
937 .prcm = { 937 .prcm = {
938 .omap4 = { 938 .omap4 = {
939 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET, 939 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
940 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET, 940 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
941 }, 941 },
942 }, 942 },
943 .opt_clks = dss_rfbi_opt_clks, 943 .opt_clks = dss_rfbi_opt_clks,
944 .opt_clks_cnt = ARRAY_SIZE(dss_rfbi_opt_clks), 944 .opt_clks_cnt = ARRAY_SIZE(dss_rfbi_opt_clks),
945 }; 945 };
946 946
947 /* 947 /*
948 * 'venc' class 948 * 'venc' class
949 * video encoder 949 * video encoder
950 */ 950 */
951 951
952 static struct omap_hwmod_class omap44xx_venc_hwmod_class = { 952 static struct omap_hwmod_class omap44xx_venc_hwmod_class = {
953 .name = "venc", 953 .name = "venc",
954 }; 954 };
955 955
956 /* dss_venc */ 956 /* dss_venc */
957 static struct omap_hwmod omap44xx_dss_venc_hwmod = { 957 static struct omap_hwmod omap44xx_dss_venc_hwmod = {
958 .name = "dss_venc", 958 .name = "dss_venc",
959 .class = &omap44xx_venc_hwmod_class, 959 .class = &omap44xx_venc_hwmod_class,
960 .clkdm_name = "l3_dss_clkdm", 960 .clkdm_name = "l3_dss_clkdm",
961 .main_clk = "dss_tv_clk", 961 .main_clk = "dss_tv_clk",
962 .prcm = { 962 .prcm = {
963 .omap4 = { 963 .omap4 = {
964 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET, 964 .clkctrl_offs = OMAP4_CM_DSS_DSS_CLKCTRL_OFFSET,
965 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET, 965 .context_offs = OMAP4_RM_DSS_DSS_CONTEXT_OFFSET,
966 }, 966 },
967 }, 967 },
968 }; 968 };
969 969
970 /* 970 /*
971 * 'elm' class 971 * 'elm' class
972 * bch error location module 972 * bch error location module
973 */ 973 */
974 974
975 static struct omap_hwmod_class_sysconfig omap44xx_elm_sysc = { 975 static struct omap_hwmod_class_sysconfig omap44xx_elm_sysc = {
976 .rev_offs = 0x0000, 976 .rev_offs = 0x0000,
977 .sysc_offs = 0x0010, 977 .sysc_offs = 0x0010,
978 .syss_offs = 0x0014, 978 .syss_offs = 0x0014,
979 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY | 979 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
980 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET | 980 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
981 SYSS_HAS_RESET_STATUS), 981 SYSS_HAS_RESET_STATUS),
982 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 982 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
983 .sysc_fields = &omap_hwmod_sysc_type1, 983 .sysc_fields = &omap_hwmod_sysc_type1,
984 }; 984 };
985 985
986 static struct omap_hwmod_class omap44xx_elm_hwmod_class = { 986 static struct omap_hwmod_class omap44xx_elm_hwmod_class = {
987 .name = "elm", 987 .name = "elm",
988 .sysc = &omap44xx_elm_sysc, 988 .sysc = &omap44xx_elm_sysc,
989 }; 989 };
990 990
991 /* elm */ 991 /* elm */
992 static struct omap_hwmod_irq_info omap44xx_elm_irqs[] = { 992 static struct omap_hwmod_irq_info omap44xx_elm_irqs[] = {
993 { .irq = 4 + OMAP44XX_IRQ_GIC_START }, 993 { .irq = 4 + OMAP44XX_IRQ_GIC_START },
994 { .irq = -1 } 994 { .irq = -1 }
995 }; 995 };
996 996
997 static struct omap_hwmod omap44xx_elm_hwmod = { 997 static struct omap_hwmod omap44xx_elm_hwmod = {
998 .name = "elm", 998 .name = "elm",
999 .class = &omap44xx_elm_hwmod_class, 999 .class = &omap44xx_elm_hwmod_class,
1000 .clkdm_name = "l4_per_clkdm", 1000 .clkdm_name = "l4_per_clkdm",
1001 .mpu_irqs = omap44xx_elm_irqs, 1001 .mpu_irqs = omap44xx_elm_irqs,
1002 .prcm = { 1002 .prcm = {
1003 .omap4 = { 1003 .omap4 = {
1004 .clkctrl_offs = OMAP4_CM_L4PER_ELM_CLKCTRL_OFFSET, 1004 .clkctrl_offs = OMAP4_CM_L4PER_ELM_CLKCTRL_OFFSET,
1005 .context_offs = OMAP4_RM_L4PER_ELM_CONTEXT_OFFSET, 1005 .context_offs = OMAP4_RM_L4PER_ELM_CONTEXT_OFFSET,
1006 }, 1006 },
1007 }, 1007 },
1008 }; 1008 };
1009 1009
1010 /* 1010 /*
1011 * 'emif' class 1011 * 'emif' class
1012 * external memory interface no1 1012 * external memory interface no1
1013 */ 1013 */
1014 1014
1015 static struct omap_hwmod_class_sysconfig omap44xx_emif_sysc = { 1015 static struct omap_hwmod_class_sysconfig omap44xx_emif_sysc = {
1016 .rev_offs = 0x0000, 1016 .rev_offs = 0x0000,
1017 }; 1017 };
1018 1018
1019 static struct omap_hwmod_class omap44xx_emif_hwmod_class = { 1019 static struct omap_hwmod_class omap44xx_emif_hwmod_class = {
1020 .name = "emif", 1020 .name = "emif",
1021 .sysc = &omap44xx_emif_sysc, 1021 .sysc = &omap44xx_emif_sysc,
1022 }; 1022 };
1023 1023
1024 /* emif1 */ 1024 /* emif1 */
1025 static struct omap_hwmod_irq_info omap44xx_emif1_irqs[] = { 1025 static struct omap_hwmod_irq_info omap44xx_emif1_irqs[] = {
1026 { .irq = 110 + OMAP44XX_IRQ_GIC_START }, 1026 { .irq = 110 + OMAP44XX_IRQ_GIC_START },
1027 { .irq = -1 } 1027 { .irq = -1 }
1028 }; 1028 };
1029 1029
1030 static struct omap_hwmod omap44xx_emif1_hwmod = { 1030 static struct omap_hwmod omap44xx_emif1_hwmod = {
1031 .name = "emif1", 1031 .name = "emif1",
1032 .class = &omap44xx_emif_hwmod_class, 1032 .class = &omap44xx_emif_hwmod_class,
1033 .clkdm_name = "l3_emif_clkdm", 1033 .clkdm_name = "l3_emif_clkdm",
1034 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET, 1034 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET,
1035 .mpu_irqs = omap44xx_emif1_irqs, 1035 .mpu_irqs = omap44xx_emif1_irqs,
1036 .main_clk = "ddrphy_ck", 1036 .main_clk = "ddrphy_ck",
1037 .prcm = { 1037 .prcm = {
1038 .omap4 = { 1038 .omap4 = {
1039 .clkctrl_offs = OMAP4_CM_MEMIF_EMIF_1_CLKCTRL_OFFSET, 1039 .clkctrl_offs = OMAP4_CM_MEMIF_EMIF_1_CLKCTRL_OFFSET,
1040 .context_offs = OMAP4_RM_MEMIF_EMIF_1_CONTEXT_OFFSET, 1040 .context_offs = OMAP4_RM_MEMIF_EMIF_1_CONTEXT_OFFSET,
1041 .modulemode = MODULEMODE_HWCTRL, 1041 .modulemode = MODULEMODE_HWCTRL,
1042 }, 1042 },
1043 }, 1043 },
1044 }; 1044 };
1045 1045
1046 /* emif2 */ 1046 /* emif2 */
1047 static struct omap_hwmod_irq_info omap44xx_emif2_irqs[] = { 1047 static struct omap_hwmod_irq_info omap44xx_emif2_irqs[] = {
1048 { .irq = 111 + OMAP44XX_IRQ_GIC_START }, 1048 { .irq = 111 + OMAP44XX_IRQ_GIC_START },
1049 { .irq = -1 } 1049 { .irq = -1 }
1050 }; 1050 };
1051 1051
1052 static struct omap_hwmod omap44xx_emif2_hwmod = { 1052 static struct omap_hwmod omap44xx_emif2_hwmod = {
1053 .name = "emif2", 1053 .name = "emif2",
1054 .class = &omap44xx_emif_hwmod_class, 1054 .class = &omap44xx_emif_hwmod_class,
1055 .clkdm_name = "l3_emif_clkdm", 1055 .clkdm_name = "l3_emif_clkdm",
1056 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET, 1056 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET,
1057 .mpu_irqs = omap44xx_emif2_irqs, 1057 .mpu_irqs = omap44xx_emif2_irqs,
1058 .main_clk = "ddrphy_ck", 1058 .main_clk = "ddrphy_ck",
1059 .prcm = { 1059 .prcm = {
1060 .omap4 = { 1060 .omap4 = {
1061 .clkctrl_offs = OMAP4_CM_MEMIF_EMIF_2_CLKCTRL_OFFSET, 1061 .clkctrl_offs = OMAP4_CM_MEMIF_EMIF_2_CLKCTRL_OFFSET,
1062 .context_offs = OMAP4_RM_MEMIF_EMIF_2_CONTEXT_OFFSET, 1062 .context_offs = OMAP4_RM_MEMIF_EMIF_2_CONTEXT_OFFSET,
1063 .modulemode = MODULEMODE_HWCTRL, 1063 .modulemode = MODULEMODE_HWCTRL,
1064 }, 1064 },
1065 }, 1065 },
1066 }; 1066 };
1067 1067
1068 /* 1068 /*
1069 * 'fdif' class 1069 * 'fdif' class
1070 * face detection hw accelerator module 1070 * face detection hw accelerator module
1071 */ 1071 */
1072 1072
1073 static struct omap_hwmod_class_sysconfig omap44xx_fdif_sysc = { 1073 static struct omap_hwmod_class_sysconfig omap44xx_fdif_sysc = {
1074 .rev_offs = 0x0000, 1074 .rev_offs = 0x0000,
1075 .sysc_offs = 0x0010, 1075 .sysc_offs = 0x0010,
1076 /* 1076 /*
1077 * FDIF needs 100 OCP clk cycles delay after a softreset before 1077 * FDIF needs 100 OCP clk cycles delay after a softreset before
1078 * accessing sysconfig again. 1078 * accessing sysconfig again.
1079 * The lowest frequency at the moment for L3 bus is 100 MHz, so 1079 * The lowest frequency at the moment for L3 bus is 100 MHz, so
1080 * 1usec delay is needed. Add an x2 margin to be safe (2 usecs). 1080 * 1usec delay is needed. Add an x2 margin to be safe (2 usecs).
1081 * 1081 *
1082 * TODO: Indicate errata when available. 1082 * TODO: Indicate errata when available.
1083 */ 1083 */
1084 .srst_udelay = 2, 1084 .srst_udelay = 2,
1085 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS | 1085 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS |
1086 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET), 1086 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
1087 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1087 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1088 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART), 1088 MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
1089 .sysc_fields = &omap_hwmod_sysc_type2, 1089 .sysc_fields = &omap_hwmod_sysc_type2,
1090 }; 1090 };
1091 1091
1092 static struct omap_hwmod_class omap44xx_fdif_hwmod_class = { 1092 static struct omap_hwmod_class omap44xx_fdif_hwmod_class = {
1093 .name = "fdif", 1093 .name = "fdif",
1094 .sysc = &omap44xx_fdif_sysc, 1094 .sysc = &omap44xx_fdif_sysc,
1095 }; 1095 };
1096 1096
1097 /* fdif */ 1097 /* fdif */
1098 static struct omap_hwmod_irq_info omap44xx_fdif_irqs[] = { 1098 static struct omap_hwmod_irq_info omap44xx_fdif_irqs[] = {
1099 { .irq = 69 + OMAP44XX_IRQ_GIC_START }, 1099 { .irq = 69 + OMAP44XX_IRQ_GIC_START },
1100 { .irq = -1 } 1100 { .irq = -1 }
1101 }; 1101 };
1102 1102
1103 static struct omap_hwmod omap44xx_fdif_hwmod = { 1103 static struct omap_hwmod omap44xx_fdif_hwmod = {
1104 .name = "fdif", 1104 .name = "fdif",
1105 .class = &omap44xx_fdif_hwmod_class, 1105 .class = &omap44xx_fdif_hwmod_class,
1106 .clkdm_name = "iss_clkdm", 1106 .clkdm_name = "iss_clkdm",
1107 .mpu_irqs = omap44xx_fdif_irqs, 1107 .mpu_irqs = omap44xx_fdif_irqs,
1108 .main_clk = "fdif_fck", 1108 .main_clk = "fdif_fck",
1109 .prcm = { 1109 .prcm = {
1110 .omap4 = { 1110 .omap4 = {
1111 .clkctrl_offs = OMAP4_CM_CAM_FDIF_CLKCTRL_OFFSET, 1111 .clkctrl_offs = OMAP4_CM_CAM_FDIF_CLKCTRL_OFFSET,
1112 .context_offs = OMAP4_RM_CAM_FDIF_CONTEXT_OFFSET, 1112 .context_offs = OMAP4_RM_CAM_FDIF_CONTEXT_OFFSET,
1113 .modulemode = MODULEMODE_SWCTRL, 1113 .modulemode = MODULEMODE_SWCTRL,
1114 }, 1114 },
1115 }, 1115 },
1116 }; 1116 };
1117 1117
1118 /* 1118 /*
1119 * 'gpio' class 1119 * 'gpio' class
1120 * general purpose io module 1120 * general purpose io module
1121 */ 1121 */
1122 1122
1123 static struct omap_hwmod_class_sysconfig omap44xx_gpio_sysc = { 1123 static struct omap_hwmod_class_sysconfig omap44xx_gpio_sysc = {
1124 .rev_offs = 0x0000, 1124 .rev_offs = 0x0000,
1125 .sysc_offs = 0x0010, 1125 .sysc_offs = 0x0010,
1126 .syss_offs = 0x0114, 1126 .syss_offs = 0x0114,
1127 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP | 1127 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
1128 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET | 1128 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
1129 SYSS_HAS_RESET_STATUS), 1129 SYSS_HAS_RESET_STATUS),
1130 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1130 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1131 SIDLE_SMART_WKUP), 1131 SIDLE_SMART_WKUP),
1132 .sysc_fields = &omap_hwmod_sysc_type1, 1132 .sysc_fields = &omap_hwmod_sysc_type1,
1133 }; 1133 };
1134 1134
1135 static struct omap_hwmod_class omap44xx_gpio_hwmod_class = { 1135 static struct omap_hwmod_class omap44xx_gpio_hwmod_class = {
1136 .name = "gpio", 1136 .name = "gpio",
1137 .sysc = &omap44xx_gpio_sysc, 1137 .sysc = &omap44xx_gpio_sysc,
1138 .rev = 2, 1138 .rev = 2,
1139 }; 1139 };
1140 1140
1141 /* gpio dev_attr */ 1141 /* gpio dev_attr */
1142 static struct omap_gpio_dev_attr gpio_dev_attr = { 1142 static struct omap_gpio_dev_attr gpio_dev_attr = {
1143 .bank_width = 32, 1143 .bank_width = 32,
1144 .dbck_flag = true, 1144 .dbck_flag = true,
1145 }; 1145 };
1146 1146
1147 /* gpio1 */ 1147 /* gpio1 */
1148 static struct omap_hwmod_irq_info omap44xx_gpio1_irqs[] = { 1148 static struct omap_hwmod_irq_info omap44xx_gpio1_irqs[] = {
1149 { .irq = 29 + OMAP44XX_IRQ_GIC_START }, 1149 { .irq = 29 + OMAP44XX_IRQ_GIC_START },
1150 { .irq = -1 } 1150 { .irq = -1 }
1151 }; 1151 };
1152 1152
1153 static struct omap_hwmod_opt_clk gpio1_opt_clks[] = { 1153 static struct omap_hwmod_opt_clk gpio1_opt_clks[] = {
1154 { .role = "dbclk", .clk = "gpio1_dbclk" }, 1154 { .role = "dbclk", .clk = "gpio1_dbclk" },
1155 }; 1155 };
1156 1156
1157 static struct omap_hwmod omap44xx_gpio1_hwmod = { 1157 static struct omap_hwmod omap44xx_gpio1_hwmod = {
1158 .name = "gpio1", 1158 .name = "gpio1",
1159 .class = &omap44xx_gpio_hwmod_class, 1159 .class = &omap44xx_gpio_hwmod_class,
1160 .clkdm_name = "l4_wkup_clkdm", 1160 .clkdm_name = "l4_wkup_clkdm",
1161 .mpu_irqs = omap44xx_gpio1_irqs, 1161 .mpu_irqs = omap44xx_gpio1_irqs,
1162 .main_clk = "gpio1_ick", 1162 .main_clk = "gpio1_ick",
1163 .prcm = { 1163 .prcm = {
1164 .omap4 = { 1164 .omap4 = {
1165 .clkctrl_offs = OMAP4_CM_WKUP_GPIO1_CLKCTRL_OFFSET, 1165 .clkctrl_offs = OMAP4_CM_WKUP_GPIO1_CLKCTRL_OFFSET,
1166 .context_offs = OMAP4_RM_WKUP_GPIO1_CONTEXT_OFFSET, 1166 .context_offs = OMAP4_RM_WKUP_GPIO1_CONTEXT_OFFSET,
1167 .modulemode = MODULEMODE_HWCTRL, 1167 .modulemode = MODULEMODE_HWCTRL,
1168 }, 1168 },
1169 }, 1169 },
1170 .opt_clks = gpio1_opt_clks, 1170 .opt_clks = gpio1_opt_clks,
1171 .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks), 1171 .opt_clks_cnt = ARRAY_SIZE(gpio1_opt_clks),
1172 .dev_attr = &gpio_dev_attr, 1172 .dev_attr = &gpio_dev_attr,
1173 }; 1173 };
1174 1174
1175 /* gpio2 */ 1175 /* gpio2 */
1176 static struct omap_hwmod_irq_info omap44xx_gpio2_irqs[] = { 1176 static struct omap_hwmod_irq_info omap44xx_gpio2_irqs[] = {
1177 { .irq = 30 + OMAP44XX_IRQ_GIC_START }, 1177 { .irq = 30 + OMAP44XX_IRQ_GIC_START },
1178 { .irq = -1 } 1178 { .irq = -1 }
1179 }; 1179 };
1180 1180
1181 static struct omap_hwmod_opt_clk gpio2_opt_clks[] = { 1181 static struct omap_hwmod_opt_clk gpio2_opt_clks[] = {
1182 { .role = "dbclk", .clk = "gpio2_dbclk" }, 1182 { .role = "dbclk", .clk = "gpio2_dbclk" },
1183 }; 1183 };
1184 1184
1185 static struct omap_hwmod omap44xx_gpio2_hwmod = { 1185 static struct omap_hwmod omap44xx_gpio2_hwmod = {
1186 .name = "gpio2", 1186 .name = "gpio2",
1187 .class = &omap44xx_gpio_hwmod_class, 1187 .class = &omap44xx_gpio_hwmod_class,
1188 .clkdm_name = "l4_per_clkdm", 1188 .clkdm_name = "l4_per_clkdm",
1189 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 1189 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
1190 .mpu_irqs = omap44xx_gpio2_irqs, 1190 .mpu_irqs = omap44xx_gpio2_irqs,
1191 .main_clk = "gpio2_ick", 1191 .main_clk = "gpio2_ick",
1192 .prcm = { 1192 .prcm = {
1193 .omap4 = { 1193 .omap4 = {
1194 .clkctrl_offs = OMAP4_CM_L4PER_GPIO2_CLKCTRL_OFFSET, 1194 .clkctrl_offs = OMAP4_CM_L4PER_GPIO2_CLKCTRL_OFFSET,
1195 .context_offs = OMAP4_RM_L4PER_GPIO2_CONTEXT_OFFSET, 1195 .context_offs = OMAP4_RM_L4PER_GPIO2_CONTEXT_OFFSET,
1196 .modulemode = MODULEMODE_HWCTRL, 1196 .modulemode = MODULEMODE_HWCTRL,
1197 }, 1197 },
1198 }, 1198 },
1199 .opt_clks = gpio2_opt_clks, 1199 .opt_clks = gpio2_opt_clks,
1200 .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks), 1200 .opt_clks_cnt = ARRAY_SIZE(gpio2_opt_clks),
1201 .dev_attr = &gpio_dev_attr, 1201 .dev_attr = &gpio_dev_attr,
1202 }; 1202 };
1203 1203
1204 /* gpio3 */ 1204 /* gpio3 */
1205 static struct omap_hwmod_irq_info omap44xx_gpio3_irqs[] = { 1205 static struct omap_hwmod_irq_info omap44xx_gpio3_irqs[] = {
1206 { .irq = 31 + OMAP44XX_IRQ_GIC_START }, 1206 { .irq = 31 + OMAP44XX_IRQ_GIC_START },
1207 { .irq = -1 } 1207 { .irq = -1 }
1208 }; 1208 };
1209 1209
1210 static struct omap_hwmod_opt_clk gpio3_opt_clks[] = { 1210 static struct omap_hwmod_opt_clk gpio3_opt_clks[] = {
1211 { .role = "dbclk", .clk = "gpio3_dbclk" }, 1211 { .role = "dbclk", .clk = "gpio3_dbclk" },
1212 }; 1212 };
1213 1213
1214 static struct omap_hwmod omap44xx_gpio3_hwmod = { 1214 static struct omap_hwmod omap44xx_gpio3_hwmod = {
1215 .name = "gpio3", 1215 .name = "gpio3",
1216 .class = &omap44xx_gpio_hwmod_class, 1216 .class = &omap44xx_gpio_hwmod_class,
1217 .clkdm_name = "l4_per_clkdm", 1217 .clkdm_name = "l4_per_clkdm",
1218 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 1218 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
1219 .mpu_irqs = omap44xx_gpio3_irqs, 1219 .mpu_irqs = omap44xx_gpio3_irqs,
1220 .main_clk = "gpio3_ick", 1220 .main_clk = "gpio3_ick",
1221 .prcm = { 1221 .prcm = {
1222 .omap4 = { 1222 .omap4 = {
1223 .clkctrl_offs = OMAP4_CM_L4PER_GPIO3_CLKCTRL_OFFSET, 1223 .clkctrl_offs = OMAP4_CM_L4PER_GPIO3_CLKCTRL_OFFSET,
1224 .context_offs = OMAP4_RM_L4PER_GPIO3_CONTEXT_OFFSET, 1224 .context_offs = OMAP4_RM_L4PER_GPIO3_CONTEXT_OFFSET,
1225 .modulemode = MODULEMODE_HWCTRL, 1225 .modulemode = MODULEMODE_HWCTRL,
1226 }, 1226 },
1227 }, 1227 },
1228 .opt_clks = gpio3_opt_clks, 1228 .opt_clks = gpio3_opt_clks,
1229 .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks), 1229 .opt_clks_cnt = ARRAY_SIZE(gpio3_opt_clks),
1230 .dev_attr = &gpio_dev_attr, 1230 .dev_attr = &gpio_dev_attr,
1231 }; 1231 };
1232 1232
1233 /* gpio4 */ 1233 /* gpio4 */
1234 static struct omap_hwmod_irq_info omap44xx_gpio4_irqs[] = { 1234 static struct omap_hwmod_irq_info omap44xx_gpio4_irqs[] = {
1235 { .irq = 32 + OMAP44XX_IRQ_GIC_START }, 1235 { .irq = 32 + OMAP44XX_IRQ_GIC_START },
1236 { .irq = -1 } 1236 { .irq = -1 }
1237 }; 1237 };
1238 1238
1239 static struct omap_hwmod_opt_clk gpio4_opt_clks[] = { 1239 static struct omap_hwmod_opt_clk gpio4_opt_clks[] = {
1240 { .role = "dbclk", .clk = "gpio4_dbclk" }, 1240 { .role = "dbclk", .clk = "gpio4_dbclk" },
1241 }; 1241 };
1242 1242
1243 static struct omap_hwmod omap44xx_gpio4_hwmod = { 1243 static struct omap_hwmod omap44xx_gpio4_hwmod = {
1244 .name = "gpio4", 1244 .name = "gpio4",
1245 .class = &omap44xx_gpio_hwmod_class, 1245 .class = &omap44xx_gpio_hwmod_class,
1246 .clkdm_name = "l4_per_clkdm", 1246 .clkdm_name = "l4_per_clkdm",
1247 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 1247 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
1248 .mpu_irqs = omap44xx_gpio4_irqs, 1248 .mpu_irqs = omap44xx_gpio4_irqs,
1249 .main_clk = "gpio4_ick", 1249 .main_clk = "gpio4_ick",
1250 .prcm = { 1250 .prcm = {
1251 .omap4 = { 1251 .omap4 = {
1252 .clkctrl_offs = OMAP4_CM_L4PER_GPIO4_CLKCTRL_OFFSET, 1252 .clkctrl_offs = OMAP4_CM_L4PER_GPIO4_CLKCTRL_OFFSET,
1253 .context_offs = OMAP4_RM_L4PER_GPIO4_CONTEXT_OFFSET, 1253 .context_offs = OMAP4_RM_L4PER_GPIO4_CONTEXT_OFFSET,
1254 .modulemode = MODULEMODE_HWCTRL, 1254 .modulemode = MODULEMODE_HWCTRL,
1255 }, 1255 },
1256 }, 1256 },
1257 .opt_clks = gpio4_opt_clks, 1257 .opt_clks = gpio4_opt_clks,
1258 .opt_clks_cnt = ARRAY_SIZE(gpio4_opt_clks), 1258 .opt_clks_cnt = ARRAY_SIZE(gpio4_opt_clks),
1259 .dev_attr = &gpio_dev_attr, 1259 .dev_attr = &gpio_dev_attr,
1260 }; 1260 };
1261 1261
1262 /* gpio5 */ 1262 /* gpio5 */
1263 static struct omap_hwmod_irq_info omap44xx_gpio5_irqs[] = { 1263 static struct omap_hwmod_irq_info omap44xx_gpio5_irqs[] = {
1264 { .irq = 33 + OMAP44XX_IRQ_GIC_START }, 1264 { .irq = 33 + OMAP44XX_IRQ_GIC_START },
1265 { .irq = -1 } 1265 { .irq = -1 }
1266 }; 1266 };
1267 1267
1268 static struct omap_hwmod_opt_clk gpio5_opt_clks[] = { 1268 static struct omap_hwmod_opt_clk gpio5_opt_clks[] = {
1269 { .role = "dbclk", .clk = "gpio5_dbclk" }, 1269 { .role = "dbclk", .clk = "gpio5_dbclk" },
1270 }; 1270 };
1271 1271
1272 static struct omap_hwmod omap44xx_gpio5_hwmod = { 1272 static struct omap_hwmod omap44xx_gpio5_hwmod = {
1273 .name = "gpio5", 1273 .name = "gpio5",
1274 .class = &omap44xx_gpio_hwmod_class, 1274 .class = &omap44xx_gpio_hwmod_class,
1275 .clkdm_name = "l4_per_clkdm", 1275 .clkdm_name = "l4_per_clkdm",
1276 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 1276 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
1277 .mpu_irqs = omap44xx_gpio5_irqs, 1277 .mpu_irqs = omap44xx_gpio5_irqs,
1278 .main_clk = "gpio5_ick", 1278 .main_clk = "gpio5_ick",
1279 .prcm = { 1279 .prcm = {
1280 .omap4 = { 1280 .omap4 = {
1281 .clkctrl_offs = OMAP4_CM_L4PER_GPIO5_CLKCTRL_OFFSET, 1281 .clkctrl_offs = OMAP4_CM_L4PER_GPIO5_CLKCTRL_OFFSET,
1282 .context_offs = OMAP4_RM_L4PER_GPIO5_CONTEXT_OFFSET, 1282 .context_offs = OMAP4_RM_L4PER_GPIO5_CONTEXT_OFFSET,
1283 .modulemode = MODULEMODE_HWCTRL, 1283 .modulemode = MODULEMODE_HWCTRL,
1284 }, 1284 },
1285 }, 1285 },
1286 .opt_clks = gpio5_opt_clks, 1286 .opt_clks = gpio5_opt_clks,
1287 .opt_clks_cnt = ARRAY_SIZE(gpio5_opt_clks), 1287 .opt_clks_cnt = ARRAY_SIZE(gpio5_opt_clks),
1288 .dev_attr = &gpio_dev_attr, 1288 .dev_attr = &gpio_dev_attr,
1289 }; 1289 };
1290 1290
1291 /* gpio6 */ 1291 /* gpio6 */
1292 static struct omap_hwmod_irq_info omap44xx_gpio6_irqs[] = { 1292 static struct omap_hwmod_irq_info omap44xx_gpio6_irqs[] = {
1293 { .irq = 34 + OMAP44XX_IRQ_GIC_START }, 1293 { .irq = 34 + OMAP44XX_IRQ_GIC_START },
1294 { .irq = -1 } 1294 { .irq = -1 }
1295 }; 1295 };
1296 1296
1297 static struct omap_hwmod_opt_clk gpio6_opt_clks[] = { 1297 static struct omap_hwmod_opt_clk gpio6_opt_clks[] = {
1298 { .role = "dbclk", .clk = "gpio6_dbclk" }, 1298 { .role = "dbclk", .clk = "gpio6_dbclk" },
1299 }; 1299 };
1300 1300
1301 static struct omap_hwmod omap44xx_gpio6_hwmod = { 1301 static struct omap_hwmod omap44xx_gpio6_hwmod = {
1302 .name = "gpio6", 1302 .name = "gpio6",
1303 .class = &omap44xx_gpio_hwmod_class, 1303 .class = &omap44xx_gpio_hwmod_class,
1304 .clkdm_name = "l4_per_clkdm", 1304 .clkdm_name = "l4_per_clkdm",
1305 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET, 1305 .flags = HWMOD_CONTROL_OPT_CLKS_IN_RESET,
1306 .mpu_irqs = omap44xx_gpio6_irqs, 1306 .mpu_irqs = omap44xx_gpio6_irqs,
1307 .main_clk = "gpio6_ick", 1307 .main_clk = "gpio6_ick",
1308 .prcm = { 1308 .prcm = {
1309 .omap4 = { 1309 .omap4 = {
1310 .clkctrl_offs = OMAP4_CM_L4PER_GPIO6_CLKCTRL_OFFSET, 1310 .clkctrl_offs = OMAP4_CM_L4PER_GPIO6_CLKCTRL_OFFSET,
1311 .context_offs = OMAP4_RM_L4PER_GPIO6_CONTEXT_OFFSET, 1311 .context_offs = OMAP4_RM_L4PER_GPIO6_CONTEXT_OFFSET,
1312 .modulemode = MODULEMODE_HWCTRL, 1312 .modulemode = MODULEMODE_HWCTRL,
1313 }, 1313 },
1314 }, 1314 },
1315 .opt_clks = gpio6_opt_clks, 1315 .opt_clks = gpio6_opt_clks,
1316 .opt_clks_cnt = ARRAY_SIZE(gpio6_opt_clks), 1316 .opt_clks_cnt = ARRAY_SIZE(gpio6_opt_clks),
1317 .dev_attr = &gpio_dev_attr, 1317 .dev_attr = &gpio_dev_attr,
1318 }; 1318 };
1319 1319
1320 /* 1320 /*
1321 * 'gpmc' class 1321 * 'gpmc' class
1322 * general purpose memory controller 1322 * general purpose memory controller
1323 */ 1323 */
1324 1324
1325 static struct omap_hwmod_class_sysconfig omap44xx_gpmc_sysc = { 1325 static struct omap_hwmod_class_sysconfig omap44xx_gpmc_sysc = {
1326 .rev_offs = 0x0000, 1326 .rev_offs = 0x0000,
1327 .sysc_offs = 0x0010, 1327 .sysc_offs = 0x0010,
1328 .syss_offs = 0x0014, 1328 .syss_offs = 0x0014,
1329 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE | 1329 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
1330 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 1330 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
1331 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1331 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1332 .sysc_fields = &omap_hwmod_sysc_type1, 1332 .sysc_fields = &omap_hwmod_sysc_type1,
1333 }; 1333 };
1334 1334
1335 static struct omap_hwmod_class omap44xx_gpmc_hwmod_class = { 1335 static struct omap_hwmod_class omap44xx_gpmc_hwmod_class = {
1336 .name = "gpmc", 1336 .name = "gpmc",
1337 .sysc = &omap44xx_gpmc_sysc, 1337 .sysc = &omap44xx_gpmc_sysc,
1338 }; 1338 };
1339 1339
1340 /* gpmc */ 1340 /* gpmc */
1341 static struct omap_hwmod_irq_info omap44xx_gpmc_irqs[] = { 1341 static struct omap_hwmod_irq_info omap44xx_gpmc_irqs[] = {
1342 { .irq = 20 + OMAP44XX_IRQ_GIC_START }, 1342 { .irq = 20 + OMAP44XX_IRQ_GIC_START },
1343 { .irq = -1 } 1343 { .irq = -1 }
1344 }; 1344 };
1345 1345
1346 static struct omap_hwmod_dma_info omap44xx_gpmc_sdma_reqs[] = { 1346 static struct omap_hwmod_dma_info omap44xx_gpmc_sdma_reqs[] = {
1347 { .dma_req = 3 + OMAP44XX_DMA_REQ_START }, 1347 { .dma_req = 3 + OMAP44XX_DMA_REQ_START },
1348 { .dma_req = -1 } 1348 { .dma_req = -1 }
1349 }; 1349 };
1350 1350
1351 static struct omap_hwmod omap44xx_gpmc_hwmod = { 1351 static struct omap_hwmod omap44xx_gpmc_hwmod = {
1352 .name = "gpmc", 1352 .name = "gpmc",
1353 .class = &omap44xx_gpmc_hwmod_class, 1353 .class = &omap44xx_gpmc_hwmod_class,
1354 .clkdm_name = "l3_2_clkdm", 1354 .clkdm_name = "l3_2_clkdm",
1355 /* 1355 /*
1356 * XXX HWMOD_INIT_NO_RESET should not be needed for this IP 1356 * XXX HWMOD_INIT_NO_RESET should not be needed for this IP
1357 * block. It is not being added due to any known bugs with 1357 * block. It is not being added due to any known bugs with
1358 * resetting the GPMC IP block, but rather because any timings 1358 * resetting the GPMC IP block, but rather because any timings
1359 * set by the bootloader are not being correctly programmed by 1359 * set by the bootloader are not being correctly programmed by
1360 * the kernel from the board file or DT data. 1360 * the kernel from the board file or DT data.
1361 * HWMOD_INIT_NO_RESET should be removed ASAP. 1361 * HWMOD_INIT_NO_RESET should be removed ASAP.
1362 */ 1362 */
1363 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET, 1363 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET,
1364 .mpu_irqs = omap44xx_gpmc_irqs, 1364 .mpu_irqs = omap44xx_gpmc_irqs,
1365 .sdma_reqs = omap44xx_gpmc_sdma_reqs, 1365 .sdma_reqs = omap44xx_gpmc_sdma_reqs,
1366 .prcm = { 1366 .prcm = {
1367 .omap4 = { 1367 .omap4 = {
1368 .clkctrl_offs = OMAP4_CM_L3_2_GPMC_CLKCTRL_OFFSET, 1368 .clkctrl_offs = OMAP4_CM_L3_2_GPMC_CLKCTRL_OFFSET,
1369 .context_offs = OMAP4_RM_L3_2_GPMC_CONTEXT_OFFSET, 1369 .context_offs = OMAP4_RM_L3_2_GPMC_CONTEXT_OFFSET,
1370 .modulemode = MODULEMODE_HWCTRL, 1370 .modulemode = MODULEMODE_HWCTRL,
1371 }, 1371 },
1372 }, 1372 },
1373 }; 1373 };
1374 1374
1375 /* 1375 /*
1376 * 'gpu' class 1376 * 'gpu' class
1377 * 2d/3d graphics accelerator 1377 * 2d/3d graphics accelerator
1378 */ 1378 */
1379 1379
1380 static struct omap_hwmod_class_sysconfig omap44xx_gpu_sysc = { 1380 static struct omap_hwmod_class_sysconfig omap44xx_gpu_sysc = {
1381 .rev_offs = 0x1fc00, 1381 .rev_offs = 0x1fc00,
1382 .sysc_offs = 0x1fc10, 1382 .sysc_offs = 0x1fc10,
1383 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE), 1383 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
1384 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1384 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1385 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO | 1385 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
1386 MSTANDBY_SMART | MSTANDBY_SMART_WKUP), 1386 MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
1387 .sysc_fields = &omap_hwmod_sysc_type2, 1387 .sysc_fields = &omap_hwmod_sysc_type2,
1388 }; 1388 };
1389 1389
1390 static struct omap_hwmod_class omap44xx_gpu_hwmod_class = { 1390 static struct omap_hwmod_class omap44xx_gpu_hwmod_class = {
1391 .name = "gpu", 1391 .name = "gpu",
1392 .sysc = &omap44xx_gpu_sysc, 1392 .sysc = &omap44xx_gpu_sysc,
1393 }; 1393 };
1394 1394
1395 /* gpu */ 1395 /* gpu */
1396 static struct omap_hwmod_irq_info omap44xx_gpu_irqs[] = { 1396 static struct omap_hwmod_irq_info omap44xx_gpu_irqs[] = {
1397 { .irq = 21 + OMAP44XX_IRQ_GIC_START }, 1397 { .irq = 21 + OMAP44XX_IRQ_GIC_START },
1398 { .irq = -1 } 1398 { .irq = -1 }
1399 }; 1399 };
1400 1400
1401 static struct omap_hwmod omap44xx_gpu_hwmod = { 1401 static struct omap_hwmod omap44xx_gpu_hwmod = {
1402 .name = "gpu", 1402 .name = "gpu",
1403 .class = &omap44xx_gpu_hwmod_class, 1403 .class = &omap44xx_gpu_hwmod_class,
1404 .clkdm_name = "l3_gfx_clkdm", 1404 .clkdm_name = "l3_gfx_clkdm",
1405 .mpu_irqs = omap44xx_gpu_irqs, 1405 .mpu_irqs = omap44xx_gpu_irqs,
1406 .main_clk = "gpu_fck", 1406 .main_clk = "gpu_fck",
1407 .prcm = { 1407 .prcm = {
1408 .omap4 = { 1408 .omap4 = {
1409 .clkctrl_offs = OMAP4_CM_GFX_GFX_CLKCTRL_OFFSET, 1409 .clkctrl_offs = OMAP4_CM_GFX_GFX_CLKCTRL_OFFSET,
1410 .context_offs = OMAP4_RM_GFX_GFX_CONTEXT_OFFSET, 1410 .context_offs = OMAP4_RM_GFX_GFX_CONTEXT_OFFSET,
1411 .modulemode = MODULEMODE_SWCTRL, 1411 .modulemode = MODULEMODE_SWCTRL,
1412 }, 1412 },
1413 }, 1413 },
1414 }; 1414 };
1415 1415
1416 /* 1416 /*
1417 * 'hdq1w' class 1417 * 'hdq1w' class
1418 * hdq / 1-wire serial interface controller 1418 * hdq / 1-wire serial interface controller
1419 */ 1419 */
1420 1420
1421 static struct omap_hwmod_class_sysconfig omap44xx_hdq1w_sysc = { 1421 static struct omap_hwmod_class_sysconfig omap44xx_hdq1w_sysc = {
1422 .rev_offs = 0x0000, 1422 .rev_offs = 0x0000,
1423 .sysc_offs = 0x0014, 1423 .sysc_offs = 0x0014,
1424 .syss_offs = 0x0018, 1424 .syss_offs = 0x0018,
1425 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SOFTRESET | 1425 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SOFTRESET |
1426 SYSS_HAS_RESET_STATUS), 1426 SYSS_HAS_RESET_STATUS),
1427 .sysc_fields = &omap_hwmod_sysc_type1, 1427 .sysc_fields = &omap_hwmod_sysc_type1,
1428 }; 1428 };
1429 1429
1430 static struct omap_hwmod_class omap44xx_hdq1w_hwmod_class = { 1430 static struct omap_hwmod_class omap44xx_hdq1w_hwmod_class = {
1431 .name = "hdq1w", 1431 .name = "hdq1w",
1432 .sysc = &omap44xx_hdq1w_sysc, 1432 .sysc = &omap44xx_hdq1w_sysc,
1433 }; 1433 };
1434 1434
1435 /* hdq1w */ 1435 /* hdq1w */
1436 static struct omap_hwmod_irq_info omap44xx_hdq1w_irqs[] = { 1436 static struct omap_hwmod_irq_info omap44xx_hdq1w_irqs[] = {
1437 { .irq = 58 + OMAP44XX_IRQ_GIC_START }, 1437 { .irq = 58 + OMAP44XX_IRQ_GIC_START },
1438 { .irq = -1 } 1438 { .irq = -1 }
1439 }; 1439 };
1440 1440
1441 static struct omap_hwmod omap44xx_hdq1w_hwmod = { 1441 static struct omap_hwmod omap44xx_hdq1w_hwmod = {
1442 .name = "hdq1w", 1442 .name = "hdq1w",
1443 .class = &omap44xx_hdq1w_hwmod_class, 1443 .class = &omap44xx_hdq1w_hwmod_class,
1444 .clkdm_name = "l4_per_clkdm", 1444 .clkdm_name = "l4_per_clkdm",
1445 .flags = HWMOD_INIT_NO_RESET, /* XXX temporary */ 1445 .flags = HWMOD_INIT_NO_RESET, /* XXX temporary */
1446 .mpu_irqs = omap44xx_hdq1w_irqs, 1446 .mpu_irqs = omap44xx_hdq1w_irqs,
1447 .main_clk = "hdq1w_fck", 1447 .main_clk = "hdq1w_fck",
1448 .prcm = { 1448 .prcm = {
1449 .omap4 = { 1449 .omap4 = {
1450 .clkctrl_offs = OMAP4_CM_L4PER_HDQ1W_CLKCTRL_OFFSET, 1450 .clkctrl_offs = OMAP4_CM_L4PER_HDQ1W_CLKCTRL_OFFSET,
1451 .context_offs = OMAP4_RM_L4PER_HDQ1W_CONTEXT_OFFSET, 1451 .context_offs = OMAP4_RM_L4PER_HDQ1W_CONTEXT_OFFSET,
1452 .modulemode = MODULEMODE_SWCTRL, 1452 .modulemode = MODULEMODE_SWCTRL,
1453 }, 1453 },
1454 }, 1454 },
1455 }; 1455 };
1456 1456
1457 /* 1457 /*
1458 * 'hsi' class 1458 * 'hsi' class
1459 * mipi high-speed synchronous serial interface (multichannel and full-duplex 1459 * mipi high-speed synchronous serial interface (multichannel and full-duplex
1460 * serial if) 1460 * serial if)
1461 */ 1461 */
1462 1462
1463 static struct omap_hwmod_class_sysconfig omap44xx_hsi_sysc = { 1463 static struct omap_hwmod_class_sysconfig omap44xx_hsi_sysc = {
1464 .rev_offs = 0x0000, 1464 .rev_offs = 0x0000,
1465 .sysc_offs = 0x0010, 1465 .sysc_offs = 0x0010,
1466 .syss_offs = 0x0014, 1466 .syss_offs = 0x0014,
1467 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_EMUFREE | 1467 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_EMUFREE |
1468 SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE | 1468 SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
1469 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 1469 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
1470 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1470 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1471 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO | 1471 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
1472 MSTANDBY_SMART | MSTANDBY_SMART_WKUP), 1472 MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
1473 .sysc_fields = &omap_hwmod_sysc_type1, 1473 .sysc_fields = &omap_hwmod_sysc_type1,
1474 }; 1474 };
1475 1475
1476 static struct omap_hwmod_class omap44xx_hsi_hwmod_class = { 1476 static struct omap_hwmod_class omap44xx_hsi_hwmod_class = {
1477 .name = "hsi", 1477 .name = "hsi",
1478 .sysc = &omap44xx_hsi_sysc, 1478 .sysc = &omap44xx_hsi_sysc,
1479 }; 1479 };
1480 1480
1481 /* hsi */ 1481 /* hsi */
1482 static struct omap_hwmod_irq_info omap44xx_hsi_irqs[] = { 1482 static struct omap_hwmod_irq_info omap44xx_hsi_irqs[] = {
1483 { .name = "mpu_p1", .irq = 67 + OMAP44XX_IRQ_GIC_START }, 1483 { .name = "mpu_p1", .irq = 67 + OMAP44XX_IRQ_GIC_START },
1484 { .name = "mpu_p2", .irq = 68 + OMAP44XX_IRQ_GIC_START }, 1484 { .name = "mpu_p2", .irq = 68 + OMAP44XX_IRQ_GIC_START },
1485 { .name = "mpu_dma", .irq = 71 + OMAP44XX_IRQ_GIC_START }, 1485 { .name = "mpu_dma", .irq = 71 + OMAP44XX_IRQ_GIC_START },
1486 { .irq = -1 } 1486 { .irq = -1 }
1487 }; 1487 };
1488 1488
1489 static struct omap_hwmod omap44xx_hsi_hwmod = { 1489 static struct omap_hwmod omap44xx_hsi_hwmod = {
1490 .name = "hsi", 1490 .name = "hsi",
1491 .class = &omap44xx_hsi_hwmod_class, 1491 .class = &omap44xx_hsi_hwmod_class,
1492 .clkdm_name = "l3_init_clkdm", 1492 .clkdm_name = "l3_init_clkdm",
1493 .mpu_irqs = omap44xx_hsi_irqs, 1493 .mpu_irqs = omap44xx_hsi_irqs,
1494 .main_clk = "hsi_fck", 1494 .main_clk = "hsi_fck",
1495 .prcm = { 1495 .prcm = {
1496 .omap4 = { 1496 .omap4 = {
1497 .clkctrl_offs = OMAP4_CM_L3INIT_HSI_CLKCTRL_OFFSET, 1497 .clkctrl_offs = OMAP4_CM_L3INIT_HSI_CLKCTRL_OFFSET,
1498 .context_offs = OMAP4_RM_L3INIT_HSI_CONTEXT_OFFSET, 1498 .context_offs = OMAP4_RM_L3INIT_HSI_CONTEXT_OFFSET,
1499 .modulemode = MODULEMODE_HWCTRL, 1499 .modulemode = MODULEMODE_HWCTRL,
1500 }, 1500 },
1501 }, 1501 },
1502 }; 1502 };
1503 1503
1504 /* 1504 /*
1505 * 'i2c' class 1505 * 'i2c' class
1506 * multimaster high-speed i2c controller 1506 * multimaster high-speed i2c controller
1507 */ 1507 */
1508 1508
1509 static struct omap_hwmod_class_sysconfig omap44xx_i2c_sysc = { 1509 static struct omap_hwmod_class_sysconfig omap44xx_i2c_sysc = {
1510 .sysc_offs = 0x0010, 1510 .sysc_offs = 0x0010,
1511 .syss_offs = 0x0090, 1511 .syss_offs = 0x0090,
1512 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY | 1512 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
1513 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE | 1513 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
1514 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 1514 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
1515 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1515 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1516 SIDLE_SMART_WKUP), 1516 SIDLE_SMART_WKUP),
1517 .clockact = CLOCKACT_TEST_ICLK, 1517 .clockact = CLOCKACT_TEST_ICLK,
1518 .sysc_fields = &omap_hwmod_sysc_type1, 1518 .sysc_fields = &omap_hwmod_sysc_type1,
1519 }; 1519 };
1520 1520
1521 static struct omap_hwmod_class omap44xx_i2c_hwmod_class = { 1521 static struct omap_hwmod_class omap44xx_i2c_hwmod_class = {
1522 .name = "i2c", 1522 .name = "i2c",
1523 .sysc = &omap44xx_i2c_sysc, 1523 .sysc = &omap44xx_i2c_sysc,
1524 .rev = OMAP_I2C_IP_VERSION_2, 1524 .rev = OMAP_I2C_IP_VERSION_2,
1525 .reset = &omap_i2c_reset, 1525 .reset = &omap_i2c_reset,
1526 }; 1526 };
1527 1527
1528 static struct omap_i2c_dev_attr i2c_dev_attr = { 1528 static struct omap_i2c_dev_attr i2c_dev_attr = {
1529 .flags = OMAP_I2C_FLAG_BUS_SHIFT_NONE | 1529 .flags = OMAP_I2C_FLAG_BUS_SHIFT_NONE,
1530 OMAP_I2C_FLAG_RESET_REGS_POSTIDLE,
1531 }; 1530 };
1532 1531
1533 /* i2c1 */ 1532 /* i2c1 */
1534 static struct omap_hwmod_irq_info omap44xx_i2c1_irqs[] = { 1533 static struct omap_hwmod_irq_info omap44xx_i2c1_irqs[] = {
1535 { .irq = 56 + OMAP44XX_IRQ_GIC_START }, 1534 { .irq = 56 + OMAP44XX_IRQ_GIC_START },
1536 { .irq = -1 } 1535 { .irq = -1 }
1537 }; 1536 };
1538 1537
1539 static struct omap_hwmod_dma_info omap44xx_i2c1_sdma_reqs[] = { 1538 static struct omap_hwmod_dma_info omap44xx_i2c1_sdma_reqs[] = {
1540 { .name = "tx", .dma_req = 26 + OMAP44XX_DMA_REQ_START }, 1539 { .name = "tx", .dma_req = 26 + OMAP44XX_DMA_REQ_START },
1541 { .name = "rx", .dma_req = 27 + OMAP44XX_DMA_REQ_START }, 1540 { .name = "rx", .dma_req = 27 + OMAP44XX_DMA_REQ_START },
1542 { .dma_req = -1 } 1541 { .dma_req = -1 }
1543 }; 1542 };
1544 1543
1545 static struct omap_hwmod omap44xx_i2c1_hwmod = { 1544 static struct omap_hwmod omap44xx_i2c1_hwmod = {
1546 .name = "i2c1", 1545 .name = "i2c1",
1547 .class = &omap44xx_i2c_hwmod_class, 1546 .class = &omap44xx_i2c_hwmod_class,
1548 .clkdm_name = "l4_per_clkdm", 1547 .clkdm_name = "l4_per_clkdm",
1549 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT, 1548 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
1550 .mpu_irqs = omap44xx_i2c1_irqs, 1549 .mpu_irqs = omap44xx_i2c1_irqs,
1551 .sdma_reqs = omap44xx_i2c1_sdma_reqs, 1550 .sdma_reqs = omap44xx_i2c1_sdma_reqs,
1552 .main_clk = "i2c1_fck", 1551 .main_clk = "i2c1_fck",
1553 .prcm = { 1552 .prcm = {
1554 .omap4 = { 1553 .omap4 = {
1555 .clkctrl_offs = OMAP4_CM_L4PER_I2C1_CLKCTRL_OFFSET, 1554 .clkctrl_offs = OMAP4_CM_L4PER_I2C1_CLKCTRL_OFFSET,
1556 .context_offs = OMAP4_RM_L4PER_I2C1_CONTEXT_OFFSET, 1555 .context_offs = OMAP4_RM_L4PER_I2C1_CONTEXT_OFFSET,
1557 .modulemode = MODULEMODE_SWCTRL, 1556 .modulemode = MODULEMODE_SWCTRL,
1558 }, 1557 },
1559 }, 1558 },
1560 .dev_attr = &i2c_dev_attr, 1559 .dev_attr = &i2c_dev_attr,
1561 }; 1560 };
1562 1561
1563 /* i2c2 */ 1562 /* i2c2 */
1564 static struct omap_hwmod_irq_info omap44xx_i2c2_irqs[] = { 1563 static struct omap_hwmod_irq_info omap44xx_i2c2_irqs[] = {
1565 { .irq = 57 + OMAP44XX_IRQ_GIC_START }, 1564 { .irq = 57 + OMAP44XX_IRQ_GIC_START },
1566 { .irq = -1 } 1565 { .irq = -1 }
1567 }; 1566 };
1568 1567
1569 static struct omap_hwmod_dma_info omap44xx_i2c2_sdma_reqs[] = { 1568 static struct omap_hwmod_dma_info omap44xx_i2c2_sdma_reqs[] = {
1570 { .name = "tx", .dma_req = 28 + OMAP44XX_DMA_REQ_START }, 1569 { .name = "tx", .dma_req = 28 + OMAP44XX_DMA_REQ_START },
1571 { .name = "rx", .dma_req = 29 + OMAP44XX_DMA_REQ_START }, 1570 { .name = "rx", .dma_req = 29 + OMAP44XX_DMA_REQ_START },
1572 { .dma_req = -1 } 1571 { .dma_req = -1 }
1573 }; 1572 };
1574 1573
1575 static struct omap_hwmod omap44xx_i2c2_hwmod = { 1574 static struct omap_hwmod omap44xx_i2c2_hwmod = {
1576 .name = "i2c2", 1575 .name = "i2c2",
1577 .class = &omap44xx_i2c_hwmod_class, 1576 .class = &omap44xx_i2c_hwmod_class,
1578 .clkdm_name = "l4_per_clkdm", 1577 .clkdm_name = "l4_per_clkdm",
1579 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT, 1578 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
1580 .mpu_irqs = omap44xx_i2c2_irqs, 1579 .mpu_irqs = omap44xx_i2c2_irqs,
1581 .sdma_reqs = omap44xx_i2c2_sdma_reqs, 1580 .sdma_reqs = omap44xx_i2c2_sdma_reqs,
1582 .main_clk = "i2c2_fck", 1581 .main_clk = "i2c2_fck",
1583 .prcm = { 1582 .prcm = {
1584 .omap4 = { 1583 .omap4 = {
1585 .clkctrl_offs = OMAP4_CM_L4PER_I2C2_CLKCTRL_OFFSET, 1584 .clkctrl_offs = OMAP4_CM_L4PER_I2C2_CLKCTRL_OFFSET,
1586 .context_offs = OMAP4_RM_L4PER_I2C2_CONTEXT_OFFSET, 1585 .context_offs = OMAP4_RM_L4PER_I2C2_CONTEXT_OFFSET,
1587 .modulemode = MODULEMODE_SWCTRL, 1586 .modulemode = MODULEMODE_SWCTRL,
1588 }, 1587 },
1589 }, 1588 },
1590 .dev_attr = &i2c_dev_attr, 1589 .dev_attr = &i2c_dev_attr,
1591 }; 1590 };
1592 1591
1593 /* i2c3 */ 1592 /* i2c3 */
1594 static struct omap_hwmod_irq_info omap44xx_i2c3_irqs[] = { 1593 static struct omap_hwmod_irq_info omap44xx_i2c3_irqs[] = {
1595 { .irq = 61 + OMAP44XX_IRQ_GIC_START }, 1594 { .irq = 61 + OMAP44XX_IRQ_GIC_START },
1596 { .irq = -1 } 1595 { .irq = -1 }
1597 }; 1596 };
1598 1597
1599 static struct omap_hwmod_dma_info omap44xx_i2c3_sdma_reqs[] = { 1598 static struct omap_hwmod_dma_info omap44xx_i2c3_sdma_reqs[] = {
1600 { .name = "tx", .dma_req = 24 + OMAP44XX_DMA_REQ_START }, 1599 { .name = "tx", .dma_req = 24 + OMAP44XX_DMA_REQ_START },
1601 { .name = "rx", .dma_req = 25 + OMAP44XX_DMA_REQ_START }, 1600 { .name = "rx", .dma_req = 25 + OMAP44XX_DMA_REQ_START },
1602 { .dma_req = -1 } 1601 { .dma_req = -1 }
1603 }; 1602 };
1604 1603
1605 static struct omap_hwmod omap44xx_i2c3_hwmod = { 1604 static struct omap_hwmod omap44xx_i2c3_hwmod = {
1606 .name = "i2c3", 1605 .name = "i2c3",
1607 .class = &omap44xx_i2c_hwmod_class, 1606 .class = &omap44xx_i2c_hwmod_class,
1608 .clkdm_name = "l4_per_clkdm", 1607 .clkdm_name = "l4_per_clkdm",
1609 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT, 1608 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
1610 .mpu_irqs = omap44xx_i2c3_irqs, 1609 .mpu_irqs = omap44xx_i2c3_irqs,
1611 .sdma_reqs = omap44xx_i2c3_sdma_reqs, 1610 .sdma_reqs = omap44xx_i2c3_sdma_reqs,
1612 .main_clk = "i2c3_fck", 1611 .main_clk = "i2c3_fck",
1613 .prcm = { 1612 .prcm = {
1614 .omap4 = { 1613 .omap4 = {
1615 .clkctrl_offs = OMAP4_CM_L4PER_I2C3_CLKCTRL_OFFSET, 1614 .clkctrl_offs = OMAP4_CM_L4PER_I2C3_CLKCTRL_OFFSET,
1616 .context_offs = OMAP4_RM_L4PER_I2C3_CONTEXT_OFFSET, 1615 .context_offs = OMAP4_RM_L4PER_I2C3_CONTEXT_OFFSET,
1617 .modulemode = MODULEMODE_SWCTRL, 1616 .modulemode = MODULEMODE_SWCTRL,
1618 }, 1617 },
1619 }, 1618 },
1620 .dev_attr = &i2c_dev_attr, 1619 .dev_attr = &i2c_dev_attr,
1621 }; 1620 };
1622 1621
1623 /* i2c4 */ 1622 /* i2c4 */
1624 static struct omap_hwmod_irq_info omap44xx_i2c4_irqs[] = { 1623 static struct omap_hwmod_irq_info omap44xx_i2c4_irqs[] = {
1625 { .irq = 62 + OMAP44XX_IRQ_GIC_START }, 1624 { .irq = 62 + OMAP44XX_IRQ_GIC_START },
1626 { .irq = -1 } 1625 { .irq = -1 }
1627 }; 1626 };
1628 1627
1629 static struct omap_hwmod_dma_info omap44xx_i2c4_sdma_reqs[] = { 1628 static struct omap_hwmod_dma_info omap44xx_i2c4_sdma_reqs[] = {
1630 { .name = "tx", .dma_req = 123 + OMAP44XX_DMA_REQ_START }, 1629 { .name = "tx", .dma_req = 123 + OMAP44XX_DMA_REQ_START },
1631 { .name = "rx", .dma_req = 124 + OMAP44XX_DMA_REQ_START }, 1630 { .name = "rx", .dma_req = 124 + OMAP44XX_DMA_REQ_START },
1632 { .dma_req = -1 } 1631 { .dma_req = -1 }
1633 }; 1632 };
1634 1633
1635 static struct omap_hwmod omap44xx_i2c4_hwmod = { 1634 static struct omap_hwmod omap44xx_i2c4_hwmod = {
1636 .name = "i2c4", 1635 .name = "i2c4",
1637 .class = &omap44xx_i2c_hwmod_class, 1636 .class = &omap44xx_i2c_hwmod_class,
1638 .clkdm_name = "l4_per_clkdm", 1637 .clkdm_name = "l4_per_clkdm",
1639 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT, 1638 .flags = HWMOD_16BIT_REG | HWMOD_SET_DEFAULT_CLOCKACT,
1640 .mpu_irqs = omap44xx_i2c4_irqs, 1639 .mpu_irqs = omap44xx_i2c4_irqs,
1641 .sdma_reqs = omap44xx_i2c4_sdma_reqs, 1640 .sdma_reqs = omap44xx_i2c4_sdma_reqs,
1642 .main_clk = "i2c4_fck", 1641 .main_clk = "i2c4_fck",
1643 .prcm = { 1642 .prcm = {
1644 .omap4 = { 1643 .omap4 = {
1645 .clkctrl_offs = OMAP4_CM_L4PER_I2C4_CLKCTRL_OFFSET, 1644 .clkctrl_offs = OMAP4_CM_L4PER_I2C4_CLKCTRL_OFFSET,
1646 .context_offs = OMAP4_RM_L4PER_I2C4_CONTEXT_OFFSET, 1645 .context_offs = OMAP4_RM_L4PER_I2C4_CONTEXT_OFFSET,
1647 .modulemode = MODULEMODE_SWCTRL, 1646 .modulemode = MODULEMODE_SWCTRL,
1648 }, 1647 },
1649 }, 1648 },
1650 .dev_attr = &i2c_dev_attr, 1649 .dev_attr = &i2c_dev_attr,
1651 }; 1650 };
1652 1651
1653 /* 1652 /*
1654 * 'ipu' class 1653 * 'ipu' class
1655 * imaging processor unit 1654 * imaging processor unit
1656 */ 1655 */
1657 1656
1658 static struct omap_hwmod_class omap44xx_ipu_hwmod_class = { 1657 static struct omap_hwmod_class omap44xx_ipu_hwmod_class = {
1659 .name = "ipu", 1658 .name = "ipu",
1660 }; 1659 };
1661 1660
1662 /* ipu */ 1661 /* ipu */
1663 static struct omap_hwmod_irq_info omap44xx_ipu_irqs[] = { 1662 static struct omap_hwmod_irq_info omap44xx_ipu_irqs[] = {
1664 { .irq = 100 + OMAP44XX_IRQ_GIC_START }, 1663 { .irq = 100 + OMAP44XX_IRQ_GIC_START },
1665 { .irq = -1 } 1664 { .irq = -1 }
1666 }; 1665 };
1667 1666
1668 static struct omap_hwmod_rst_info omap44xx_ipu_resets[] = { 1667 static struct omap_hwmod_rst_info omap44xx_ipu_resets[] = {
1669 { .name = "cpu0", .rst_shift = 0 }, 1668 { .name = "cpu0", .rst_shift = 0 },
1670 { .name = "cpu1", .rst_shift = 1 }, 1669 { .name = "cpu1", .rst_shift = 1 },
1671 }; 1670 };
1672 1671
1673 static struct omap_hwmod omap44xx_ipu_hwmod = { 1672 static struct omap_hwmod omap44xx_ipu_hwmod = {
1674 .name = "ipu", 1673 .name = "ipu",
1675 .class = &omap44xx_ipu_hwmod_class, 1674 .class = &omap44xx_ipu_hwmod_class,
1676 .clkdm_name = "ducati_clkdm", 1675 .clkdm_name = "ducati_clkdm",
1677 .mpu_irqs = omap44xx_ipu_irqs, 1676 .mpu_irqs = omap44xx_ipu_irqs,
1678 .rst_lines = omap44xx_ipu_resets, 1677 .rst_lines = omap44xx_ipu_resets,
1679 .rst_lines_cnt = ARRAY_SIZE(omap44xx_ipu_resets), 1678 .rst_lines_cnt = ARRAY_SIZE(omap44xx_ipu_resets),
1680 .main_clk = "ipu_fck", 1679 .main_clk = "ipu_fck",
1681 .prcm = { 1680 .prcm = {
1682 .omap4 = { 1681 .omap4 = {
1683 .clkctrl_offs = OMAP4_CM_DUCATI_DUCATI_CLKCTRL_OFFSET, 1682 .clkctrl_offs = OMAP4_CM_DUCATI_DUCATI_CLKCTRL_OFFSET,
1684 .rstctrl_offs = OMAP4_RM_DUCATI_RSTCTRL_OFFSET, 1683 .rstctrl_offs = OMAP4_RM_DUCATI_RSTCTRL_OFFSET,
1685 .context_offs = OMAP4_RM_DUCATI_DUCATI_CONTEXT_OFFSET, 1684 .context_offs = OMAP4_RM_DUCATI_DUCATI_CONTEXT_OFFSET,
1686 .modulemode = MODULEMODE_HWCTRL, 1685 .modulemode = MODULEMODE_HWCTRL,
1687 }, 1686 },
1688 }, 1687 },
1689 }; 1688 };
1690 1689
1691 /* 1690 /*
1692 * 'iss' class 1691 * 'iss' class
1693 * external images sensor pixel data processor 1692 * external images sensor pixel data processor
1694 */ 1693 */
1695 1694
1696 static struct omap_hwmod_class_sysconfig omap44xx_iss_sysc = { 1695 static struct omap_hwmod_class_sysconfig omap44xx_iss_sysc = {
1697 .rev_offs = 0x0000, 1696 .rev_offs = 0x0000,
1698 .sysc_offs = 0x0010, 1697 .sysc_offs = 0x0010,
1699 /* 1698 /*
1700 * ISS needs 100 OCP clk cycles delay after a softreset before 1699 * ISS needs 100 OCP clk cycles delay after a softreset before
1701 * accessing sysconfig again. 1700 * accessing sysconfig again.
1702 * The lowest frequency at the moment for L3 bus is 100 MHz, so 1701 * The lowest frequency at the moment for L3 bus is 100 MHz, so
1703 * 1usec delay is needed. Add an x2 margin to be safe (2 usecs). 1702 * 1usec delay is needed. Add an x2 margin to be safe (2 usecs).
1704 * 1703 *
1705 * TODO: Indicate errata when available. 1704 * TODO: Indicate errata when available.
1706 */ 1705 */
1707 .srst_udelay = 2, 1706 .srst_udelay = 2,
1708 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS | 1707 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS |
1709 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET), 1708 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
1710 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1709 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1711 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO | 1710 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
1712 MSTANDBY_SMART | MSTANDBY_SMART_WKUP), 1711 MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
1713 .sysc_fields = &omap_hwmod_sysc_type2, 1712 .sysc_fields = &omap_hwmod_sysc_type2,
1714 }; 1713 };
1715 1714
1716 static struct omap_hwmod_class omap44xx_iss_hwmod_class = { 1715 static struct omap_hwmod_class omap44xx_iss_hwmod_class = {
1717 .name = "iss", 1716 .name = "iss",
1718 .sysc = &omap44xx_iss_sysc, 1717 .sysc = &omap44xx_iss_sysc,
1719 }; 1718 };
1720 1719
1721 /* iss */ 1720 /* iss */
1722 static struct omap_hwmod_irq_info omap44xx_iss_irqs[] = { 1721 static struct omap_hwmod_irq_info omap44xx_iss_irqs[] = {
1723 { .irq = 24 + OMAP44XX_IRQ_GIC_START }, 1722 { .irq = 24 + OMAP44XX_IRQ_GIC_START },
1724 { .irq = -1 } 1723 { .irq = -1 }
1725 }; 1724 };
1726 1725
1727 static struct omap_hwmod_dma_info omap44xx_iss_sdma_reqs[] = { 1726 static struct omap_hwmod_dma_info omap44xx_iss_sdma_reqs[] = {
1728 { .name = "1", .dma_req = 8 + OMAP44XX_DMA_REQ_START }, 1727 { .name = "1", .dma_req = 8 + OMAP44XX_DMA_REQ_START },
1729 { .name = "2", .dma_req = 9 + OMAP44XX_DMA_REQ_START }, 1728 { .name = "2", .dma_req = 9 + OMAP44XX_DMA_REQ_START },
1730 { .name = "3", .dma_req = 11 + OMAP44XX_DMA_REQ_START }, 1729 { .name = "3", .dma_req = 11 + OMAP44XX_DMA_REQ_START },
1731 { .name = "4", .dma_req = 12 + OMAP44XX_DMA_REQ_START }, 1730 { .name = "4", .dma_req = 12 + OMAP44XX_DMA_REQ_START },
1732 { .dma_req = -1 } 1731 { .dma_req = -1 }
1733 }; 1732 };
1734 1733
1735 static struct omap_hwmod_opt_clk iss_opt_clks[] = { 1734 static struct omap_hwmod_opt_clk iss_opt_clks[] = {
1736 { .role = "ctrlclk", .clk = "iss_ctrlclk" }, 1735 { .role = "ctrlclk", .clk = "iss_ctrlclk" },
1737 }; 1736 };
1738 1737
1739 static struct omap_hwmod omap44xx_iss_hwmod = { 1738 static struct omap_hwmod omap44xx_iss_hwmod = {
1740 .name = "iss", 1739 .name = "iss",
1741 .class = &omap44xx_iss_hwmod_class, 1740 .class = &omap44xx_iss_hwmod_class,
1742 .clkdm_name = "iss_clkdm", 1741 .clkdm_name = "iss_clkdm",
1743 .mpu_irqs = omap44xx_iss_irqs, 1742 .mpu_irqs = omap44xx_iss_irqs,
1744 .sdma_reqs = omap44xx_iss_sdma_reqs, 1743 .sdma_reqs = omap44xx_iss_sdma_reqs,
1745 .main_clk = "iss_fck", 1744 .main_clk = "iss_fck",
1746 .prcm = { 1745 .prcm = {
1747 .omap4 = { 1746 .omap4 = {
1748 .clkctrl_offs = OMAP4_CM_CAM_ISS_CLKCTRL_OFFSET, 1747 .clkctrl_offs = OMAP4_CM_CAM_ISS_CLKCTRL_OFFSET,
1749 .context_offs = OMAP4_RM_CAM_ISS_CONTEXT_OFFSET, 1748 .context_offs = OMAP4_RM_CAM_ISS_CONTEXT_OFFSET,
1750 .modulemode = MODULEMODE_SWCTRL, 1749 .modulemode = MODULEMODE_SWCTRL,
1751 }, 1750 },
1752 }, 1751 },
1753 .opt_clks = iss_opt_clks, 1752 .opt_clks = iss_opt_clks,
1754 .opt_clks_cnt = ARRAY_SIZE(iss_opt_clks), 1753 .opt_clks_cnt = ARRAY_SIZE(iss_opt_clks),
1755 }; 1754 };
1756 1755
1757 /* 1756 /*
1758 * 'iva' class 1757 * 'iva' class
1759 * multi-standard video encoder/decoder hardware accelerator 1758 * multi-standard video encoder/decoder hardware accelerator
1760 */ 1759 */
1761 1760
1762 static struct omap_hwmod_class omap44xx_iva_hwmod_class = { 1761 static struct omap_hwmod_class omap44xx_iva_hwmod_class = {
1763 .name = "iva", 1762 .name = "iva",
1764 }; 1763 };
1765 1764
1766 /* iva */ 1765 /* iva */
1767 static struct omap_hwmod_irq_info omap44xx_iva_irqs[] = { 1766 static struct omap_hwmod_irq_info omap44xx_iva_irqs[] = {
1768 { .name = "sync_1", .irq = 103 + OMAP44XX_IRQ_GIC_START }, 1767 { .name = "sync_1", .irq = 103 + OMAP44XX_IRQ_GIC_START },
1769 { .name = "sync_0", .irq = 104 + OMAP44XX_IRQ_GIC_START }, 1768 { .name = "sync_0", .irq = 104 + OMAP44XX_IRQ_GIC_START },
1770 { .name = "mailbox_0", .irq = 107 + OMAP44XX_IRQ_GIC_START }, 1769 { .name = "mailbox_0", .irq = 107 + OMAP44XX_IRQ_GIC_START },
1771 { .irq = -1 } 1770 { .irq = -1 }
1772 }; 1771 };
1773 1772
1774 static struct omap_hwmod_rst_info omap44xx_iva_resets[] = { 1773 static struct omap_hwmod_rst_info omap44xx_iva_resets[] = {
1775 { .name = "seq0", .rst_shift = 0 }, 1774 { .name = "seq0", .rst_shift = 0 },
1776 { .name = "seq1", .rst_shift = 1 }, 1775 { .name = "seq1", .rst_shift = 1 },
1777 { .name = "logic", .rst_shift = 2 }, 1776 { .name = "logic", .rst_shift = 2 },
1778 }; 1777 };
1779 1778
1780 static struct omap_hwmod omap44xx_iva_hwmod = { 1779 static struct omap_hwmod omap44xx_iva_hwmod = {
1781 .name = "iva", 1780 .name = "iva",
1782 .class = &omap44xx_iva_hwmod_class, 1781 .class = &omap44xx_iva_hwmod_class,
1783 .clkdm_name = "ivahd_clkdm", 1782 .clkdm_name = "ivahd_clkdm",
1784 .mpu_irqs = omap44xx_iva_irqs, 1783 .mpu_irqs = omap44xx_iva_irqs,
1785 .rst_lines = omap44xx_iva_resets, 1784 .rst_lines = omap44xx_iva_resets,
1786 .rst_lines_cnt = ARRAY_SIZE(omap44xx_iva_resets), 1785 .rst_lines_cnt = ARRAY_SIZE(omap44xx_iva_resets),
1787 .main_clk = "iva_fck", 1786 .main_clk = "iva_fck",
1788 .prcm = { 1787 .prcm = {
1789 .omap4 = { 1788 .omap4 = {
1790 .clkctrl_offs = OMAP4_CM_IVAHD_IVAHD_CLKCTRL_OFFSET, 1789 .clkctrl_offs = OMAP4_CM_IVAHD_IVAHD_CLKCTRL_OFFSET,
1791 .rstctrl_offs = OMAP4_RM_IVAHD_RSTCTRL_OFFSET, 1790 .rstctrl_offs = OMAP4_RM_IVAHD_RSTCTRL_OFFSET,
1792 .context_offs = OMAP4_RM_IVAHD_IVAHD_CONTEXT_OFFSET, 1791 .context_offs = OMAP4_RM_IVAHD_IVAHD_CONTEXT_OFFSET,
1793 .modulemode = MODULEMODE_HWCTRL, 1792 .modulemode = MODULEMODE_HWCTRL,
1794 }, 1793 },
1795 }, 1794 },
1796 }; 1795 };
1797 1796
1798 /* 1797 /*
1799 * 'kbd' class 1798 * 'kbd' class
1800 * keyboard controller 1799 * keyboard controller
1801 */ 1800 */
1802 1801
1803 static struct omap_hwmod_class_sysconfig omap44xx_kbd_sysc = { 1802 static struct omap_hwmod_class_sysconfig omap44xx_kbd_sysc = {
1804 .rev_offs = 0x0000, 1803 .rev_offs = 0x0000,
1805 .sysc_offs = 0x0010, 1804 .sysc_offs = 0x0010,
1806 .syss_offs = 0x0014, 1805 .syss_offs = 0x0014,
1807 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY | 1806 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
1808 SYSC_HAS_EMUFREE | SYSC_HAS_ENAWAKEUP | 1807 SYSC_HAS_EMUFREE | SYSC_HAS_ENAWAKEUP |
1809 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET | 1808 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
1810 SYSS_HAS_RESET_STATUS), 1809 SYSS_HAS_RESET_STATUS),
1811 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1810 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1812 .sysc_fields = &omap_hwmod_sysc_type1, 1811 .sysc_fields = &omap_hwmod_sysc_type1,
1813 }; 1812 };
1814 1813
1815 static struct omap_hwmod_class omap44xx_kbd_hwmod_class = { 1814 static struct omap_hwmod_class omap44xx_kbd_hwmod_class = {
1816 .name = "kbd", 1815 .name = "kbd",
1817 .sysc = &omap44xx_kbd_sysc, 1816 .sysc = &omap44xx_kbd_sysc,
1818 }; 1817 };
1819 1818
1820 /* kbd */ 1819 /* kbd */
1821 static struct omap_hwmod_irq_info omap44xx_kbd_irqs[] = { 1820 static struct omap_hwmod_irq_info omap44xx_kbd_irqs[] = {
1822 { .irq = 120 + OMAP44XX_IRQ_GIC_START }, 1821 { .irq = 120 + OMAP44XX_IRQ_GIC_START },
1823 { .irq = -1 } 1822 { .irq = -1 }
1824 }; 1823 };
1825 1824
1826 static struct omap_hwmod omap44xx_kbd_hwmod = { 1825 static struct omap_hwmod omap44xx_kbd_hwmod = {
1827 .name = "kbd", 1826 .name = "kbd",
1828 .class = &omap44xx_kbd_hwmod_class, 1827 .class = &omap44xx_kbd_hwmod_class,
1829 .clkdm_name = "l4_wkup_clkdm", 1828 .clkdm_name = "l4_wkup_clkdm",
1830 .mpu_irqs = omap44xx_kbd_irqs, 1829 .mpu_irqs = omap44xx_kbd_irqs,
1831 .main_clk = "kbd_fck", 1830 .main_clk = "kbd_fck",
1832 .prcm = { 1831 .prcm = {
1833 .omap4 = { 1832 .omap4 = {
1834 .clkctrl_offs = OMAP4_CM_WKUP_KEYBOARD_CLKCTRL_OFFSET, 1833 .clkctrl_offs = OMAP4_CM_WKUP_KEYBOARD_CLKCTRL_OFFSET,
1835 .context_offs = OMAP4_RM_WKUP_KEYBOARD_CONTEXT_OFFSET, 1834 .context_offs = OMAP4_RM_WKUP_KEYBOARD_CONTEXT_OFFSET,
1836 .modulemode = MODULEMODE_SWCTRL, 1835 .modulemode = MODULEMODE_SWCTRL,
1837 }, 1836 },
1838 }, 1837 },
1839 }; 1838 };
1840 1839
1841 /* 1840 /*
1842 * 'mailbox' class 1841 * 'mailbox' class
1843 * mailbox module allowing communication between the on-chip processors using a 1842 * mailbox module allowing communication between the on-chip processors using a
1844 * queued mailbox-interrupt mechanism. 1843 * queued mailbox-interrupt mechanism.
1845 */ 1844 */
1846 1845
1847 static struct omap_hwmod_class_sysconfig omap44xx_mailbox_sysc = { 1846 static struct omap_hwmod_class_sysconfig omap44xx_mailbox_sysc = {
1848 .rev_offs = 0x0000, 1847 .rev_offs = 0x0000,
1849 .sysc_offs = 0x0010, 1848 .sysc_offs = 0x0010,
1850 .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE | 1849 .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
1851 SYSC_HAS_SOFTRESET), 1850 SYSC_HAS_SOFTRESET),
1852 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1851 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1853 .sysc_fields = &omap_hwmod_sysc_type2, 1852 .sysc_fields = &omap_hwmod_sysc_type2,
1854 }; 1853 };
1855 1854
1856 static struct omap_hwmod_class omap44xx_mailbox_hwmod_class = { 1855 static struct omap_hwmod_class omap44xx_mailbox_hwmod_class = {
1857 .name = "mailbox", 1856 .name = "mailbox",
1858 .sysc = &omap44xx_mailbox_sysc, 1857 .sysc = &omap44xx_mailbox_sysc,
1859 }; 1858 };
1860 1859
1861 /* mailbox */ 1860 /* mailbox */
1862 static struct omap_hwmod_irq_info omap44xx_mailbox_irqs[] = { 1861 static struct omap_hwmod_irq_info omap44xx_mailbox_irqs[] = {
1863 { .irq = 26 + OMAP44XX_IRQ_GIC_START }, 1862 { .irq = 26 + OMAP44XX_IRQ_GIC_START },
1864 { .irq = -1 } 1863 { .irq = -1 }
1865 }; 1864 };
1866 1865
1867 static struct omap_hwmod omap44xx_mailbox_hwmod = { 1866 static struct omap_hwmod omap44xx_mailbox_hwmod = {
1868 .name = "mailbox", 1867 .name = "mailbox",
1869 .class = &omap44xx_mailbox_hwmod_class, 1868 .class = &omap44xx_mailbox_hwmod_class,
1870 .clkdm_name = "l4_cfg_clkdm", 1869 .clkdm_name = "l4_cfg_clkdm",
1871 .mpu_irqs = omap44xx_mailbox_irqs, 1870 .mpu_irqs = omap44xx_mailbox_irqs,
1872 .prcm = { 1871 .prcm = {
1873 .omap4 = { 1872 .omap4 = {
1874 .clkctrl_offs = OMAP4_CM_L4CFG_MAILBOX_CLKCTRL_OFFSET, 1873 .clkctrl_offs = OMAP4_CM_L4CFG_MAILBOX_CLKCTRL_OFFSET,
1875 .context_offs = OMAP4_RM_L4CFG_MAILBOX_CONTEXT_OFFSET, 1874 .context_offs = OMAP4_RM_L4CFG_MAILBOX_CONTEXT_OFFSET,
1876 }, 1875 },
1877 }, 1876 },
1878 }; 1877 };
1879 1878
1880 /* 1879 /*
1881 * 'mcasp' class 1880 * 'mcasp' class
1882 * multi-channel audio serial port controller 1881 * multi-channel audio serial port controller
1883 */ 1882 */
1884 1883
1885 /* The IP is not compliant to type1 / type2 scheme */ 1884 /* The IP is not compliant to type1 / type2 scheme */
1886 static struct omap_hwmod_sysc_fields omap_hwmod_sysc_type_mcasp = { 1885 static struct omap_hwmod_sysc_fields omap_hwmod_sysc_type_mcasp = {
1887 .sidle_shift = 0, 1886 .sidle_shift = 0,
1888 }; 1887 };
1889 1888
1890 static struct omap_hwmod_class_sysconfig omap44xx_mcasp_sysc = { 1889 static struct omap_hwmod_class_sysconfig omap44xx_mcasp_sysc = {
1891 .sysc_offs = 0x0004, 1890 .sysc_offs = 0x0004,
1892 .sysc_flags = SYSC_HAS_SIDLEMODE, 1891 .sysc_flags = SYSC_HAS_SIDLEMODE,
1893 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 1892 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
1894 SIDLE_SMART_WKUP), 1893 SIDLE_SMART_WKUP),
1895 .sysc_fields = &omap_hwmod_sysc_type_mcasp, 1894 .sysc_fields = &omap_hwmod_sysc_type_mcasp,
1896 }; 1895 };
1897 1896
1898 static struct omap_hwmod_class omap44xx_mcasp_hwmod_class = { 1897 static struct omap_hwmod_class omap44xx_mcasp_hwmod_class = {
1899 .name = "mcasp", 1898 .name = "mcasp",
1900 .sysc = &omap44xx_mcasp_sysc, 1899 .sysc = &omap44xx_mcasp_sysc,
1901 }; 1900 };
1902 1901
1903 /* mcasp */ 1902 /* mcasp */
1904 static struct omap_hwmod_irq_info omap44xx_mcasp_irqs[] = { 1903 static struct omap_hwmod_irq_info omap44xx_mcasp_irqs[] = {
1905 { .name = "arevt", .irq = 108 + OMAP44XX_IRQ_GIC_START }, 1904 { .name = "arevt", .irq = 108 + OMAP44XX_IRQ_GIC_START },
1906 { .name = "axevt", .irq = 109 + OMAP44XX_IRQ_GIC_START }, 1905 { .name = "axevt", .irq = 109 + OMAP44XX_IRQ_GIC_START },
1907 { .irq = -1 } 1906 { .irq = -1 }
1908 }; 1907 };
1909 1908
1910 static struct omap_hwmod_dma_info omap44xx_mcasp_sdma_reqs[] = { 1909 static struct omap_hwmod_dma_info omap44xx_mcasp_sdma_reqs[] = {
1911 { .name = "axevt", .dma_req = 7 + OMAP44XX_DMA_REQ_START }, 1910 { .name = "axevt", .dma_req = 7 + OMAP44XX_DMA_REQ_START },
1912 { .name = "arevt", .dma_req = 10 + OMAP44XX_DMA_REQ_START }, 1911 { .name = "arevt", .dma_req = 10 + OMAP44XX_DMA_REQ_START },
1913 { .dma_req = -1 } 1912 { .dma_req = -1 }
1914 }; 1913 };
1915 1914
1916 static struct omap_hwmod omap44xx_mcasp_hwmod = { 1915 static struct omap_hwmod omap44xx_mcasp_hwmod = {
1917 .name = "mcasp", 1916 .name = "mcasp",
1918 .class = &omap44xx_mcasp_hwmod_class, 1917 .class = &omap44xx_mcasp_hwmod_class,
1919 .clkdm_name = "abe_clkdm", 1918 .clkdm_name = "abe_clkdm",
1920 .mpu_irqs = omap44xx_mcasp_irqs, 1919 .mpu_irqs = omap44xx_mcasp_irqs,
1921 .sdma_reqs = omap44xx_mcasp_sdma_reqs, 1920 .sdma_reqs = omap44xx_mcasp_sdma_reqs,
1922 .main_clk = "mcasp_fck", 1921 .main_clk = "mcasp_fck",
1923 .prcm = { 1922 .prcm = {
1924 .omap4 = { 1923 .omap4 = {
1925 .clkctrl_offs = OMAP4_CM1_ABE_MCASP_CLKCTRL_OFFSET, 1924 .clkctrl_offs = OMAP4_CM1_ABE_MCASP_CLKCTRL_OFFSET,
1926 .context_offs = OMAP4_RM_ABE_MCASP_CONTEXT_OFFSET, 1925 .context_offs = OMAP4_RM_ABE_MCASP_CONTEXT_OFFSET,
1927 .modulemode = MODULEMODE_SWCTRL, 1926 .modulemode = MODULEMODE_SWCTRL,
1928 }, 1927 },
1929 }, 1928 },
1930 }; 1929 };
1931 1930
1932 /* 1931 /*
1933 * 'mcbsp' class 1932 * 'mcbsp' class
1934 * multi channel buffered serial port controller 1933 * multi channel buffered serial port controller
1935 */ 1934 */
1936 1935
1937 static struct omap_hwmod_class_sysconfig omap44xx_mcbsp_sysc = { 1936 static struct omap_hwmod_class_sysconfig omap44xx_mcbsp_sysc = {
1938 .sysc_offs = 0x008c, 1937 .sysc_offs = 0x008c,
1939 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_ENAWAKEUP | 1938 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_ENAWAKEUP |
1940 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET), 1939 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
1941 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 1940 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
1942 .sysc_fields = &omap_hwmod_sysc_type1, 1941 .sysc_fields = &omap_hwmod_sysc_type1,
1943 }; 1942 };
1944 1943
1945 static struct omap_hwmod_class omap44xx_mcbsp_hwmod_class = { 1944 static struct omap_hwmod_class omap44xx_mcbsp_hwmod_class = {
1946 .name = "mcbsp", 1945 .name = "mcbsp",
1947 .sysc = &omap44xx_mcbsp_sysc, 1946 .sysc = &omap44xx_mcbsp_sysc,
1948 .rev = MCBSP_CONFIG_TYPE4, 1947 .rev = MCBSP_CONFIG_TYPE4,
1949 }; 1948 };
1950 1949
1951 /* mcbsp1 */ 1950 /* mcbsp1 */
1952 static struct omap_hwmod_irq_info omap44xx_mcbsp1_irqs[] = { 1951 static struct omap_hwmod_irq_info omap44xx_mcbsp1_irqs[] = {
1953 { .name = "common", .irq = 17 + OMAP44XX_IRQ_GIC_START }, 1952 { .name = "common", .irq = 17 + OMAP44XX_IRQ_GIC_START },
1954 { .irq = -1 } 1953 { .irq = -1 }
1955 }; 1954 };
1956 1955
1957 static struct omap_hwmod_dma_info omap44xx_mcbsp1_sdma_reqs[] = { 1956 static struct omap_hwmod_dma_info omap44xx_mcbsp1_sdma_reqs[] = {
1958 { .name = "tx", .dma_req = 32 + OMAP44XX_DMA_REQ_START }, 1957 { .name = "tx", .dma_req = 32 + OMAP44XX_DMA_REQ_START },
1959 { .name = "rx", .dma_req = 33 + OMAP44XX_DMA_REQ_START }, 1958 { .name = "rx", .dma_req = 33 + OMAP44XX_DMA_REQ_START },
1960 { .dma_req = -1 } 1959 { .dma_req = -1 }
1961 }; 1960 };
1962 1961
1963 static struct omap_hwmod_opt_clk mcbsp1_opt_clks[] = { 1962 static struct omap_hwmod_opt_clk mcbsp1_opt_clks[] = {
1964 { .role = "pad_fck", .clk = "pad_clks_ck" }, 1963 { .role = "pad_fck", .clk = "pad_clks_ck" },
1965 { .role = "prcm_fck", .clk = "mcbsp1_sync_mux_ck" }, 1964 { .role = "prcm_fck", .clk = "mcbsp1_sync_mux_ck" },
1966 }; 1965 };
1967 1966
1968 static struct omap_hwmod omap44xx_mcbsp1_hwmod = { 1967 static struct omap_hwmod omap44xx_mcbsp1_hwmod = {
1969 .name = "mcbsp1", 1968 .name = "mcbsp1",
1970 .class = &omap44xx_mcbsp_hwmod_class, 1969 .class = &omap44xx_mcbsp_hwmod_class,
1971 .clkdm_name = "abe_clkdm", 1970 .clkdm_name = "abe_clkdm",
1972 .mpu_irqs = omap44xx_mcbsp1_irqs, 1971 .mpu_irqs = omap44xx_mcbsp1_irqs,
1973 .sdma_reqs = omap44xx_mcbsp1_sdma_reqs, 1972 .sdma_reqs = omap44xx_mcbsp1_sdma_reqs,
1974 .main_clk = "mcbsp1_fck", 1973 .main_clk = "mcbsp1_fck",
1975 .prcm = { 1974 .prcm = {
1976 .omap4 = { 1975 .omap4 = {
1977 .clkctrl_offs = OMAP4_CM1_ABE_MCBSP1_CLKCTRL_OFFSET, 1976 .clkctrl_offs = OMAP4_CM1_ABE_MCBSP1_CLKCTRL_OFFSET,
1978 .context_offs = OMAP4_RM_ABE_MCBSP1_CONTEXT_OFFSET, 1977 .context_offs = OMAP4_RM_ABE_MCBSP1_CONTEXT_OFFSET,
1979 .modulemode = MODULEMODE_SWCTRL, 1978 .modulemode = MODULEMODE_SWCTRL,
1980 }, 1979 },
1981 }, 1980 },
1982 .opt_clks = mcbsp1_opt_clks, 1981 .opt_clks = mcbsp1_opt_clks,
1983 .opt_clks_cnt = ARRAY_SIZE(mcbsp1_opt_clks), 1982 .opt_clks_cnt = ARRAY_SIZE(mcbsp1_opt_clks),
1984 }; 1983 };
1985 1984
1986 /* mcbsp2 */ 1985 /* mcbsp2 */
1987 static struct omap_hwmod_irq_info omap44xx_mcbsp2_irqs[] = { 1986 static struct omap_hwmod_irq_info omap44xx_mcbsp2_irqs[] = {
1988 { .name = "common", .irq = 22 + OMAP44XX_IRQ_GIC_START }, 1987 { .name = "common", .irq = 22 + OMAP44XX_IRQ_GIC_START },
1989 { .irq = -1 } 1988 { .irq = -1 }
1990 }; 1989 };
1991 1990
1992 static struct omap_hwmod_dma_info omap44xx_mcbsp2_sdma_reqs[] = { 1991 static struct omap_hwmod_dma_info omap44xx_mcbsp2_sdma_reqs[] = {
1993 { .name = "tx", .dma_req = 16 + OMAP44XX_DMA_REQ_START }, 1992 { .name = "tx", .dma_req = 16 + OMAP44XX_DMA_REQ_START },
1994 { .name = "rx", .dma_req = 17 + OMAP44XX_DMA_REQ_START }, 1993 { .name = "rx", .dma_req = 17 + OMAP44XX_DMA_REQ_START },
1995 { .dma_req = -1 } 1994 { .dma_req = -1 }
1996 }; 1995 };
1997 1996
1998 static struct omap_hwmod_opt_clk mcbsp2_opt_clks[] = { 1997 static struct omap_hwmod_opt_clk mcbsp2_opt_clks[] = {
1999 { .role = "pad_fck", .clk = "pad_clks_ck" }, 1998 { .role = "pad_fck", .clk = "pad_clks_ck" },
2000 { .role = "prcm_fck", .clk = "mcbsp2_sync_mux_ck" }, 1999 { .role = "prcm_fck", .clk = "mcbsp2_sync_mux_ck" },
2001 }; 2000 };
2002 2001
2003 static struct omap_hwmod omap44xx_mcbsp2_hwmod = { 2002 static struct omap_hwmod omap44xx_mcbsp2_hwmod = {
2004 .name = "mcbsp2", 2003 .name = "mcbsp2",
2005 .class = &omap44xx_mcbsp_hwmod_class, 2004 .class = &omap44xx_mcbsp_hwmod_class,
2006 .clkdm_name = "abe_clkdm", 2005 .clkdm_name = "abe_clkdm",
2007 .mpu_irqs = omap44xx_mcbsp2_irqs, 2006 .mpu_irqs = omap44xx_mcbsp2_irqs,
2008 .sdma_reqs = omap44xx_mcbsp2_sdma_reqs, 2007 .sdma_reqs = omap44xx_mcbsp2_sdma_reqs,
2009 .main_clk = "mcbsp2_fck", 2008 .main_clk = "mcbsp2_fck",
2010 .prcm = { 2009 .prcm = {
2011 .omap4 = { 2010 .omap4 = {
2012 .clkctrl_offs = OMAP4_CM1_ABE_MCBSP2_CLKCTRL_OFFSET, 2011 .clkctrl_offs = OMAP4_CM1_ABE_MCBSP2_CLKCTRL_OFFSET,
2013 .context_offs = OMAP4_RM_ABE_MCBSP2_CONTEXT_OFFSET, 2012 .context_offs = OMAP4_RM_ABE_MCBSP2_CONTEXT_OFFSET,
2014 .modulemode = MODULEMODE_SWCTRL, 2013 .modulemode = MODULEMODE_SWCTRL,
2015 }, 2014 },
2016 }, 2015 },
2017 .opt_clks = mcbsp2_opt_clks, 2016 .opt_clks = mcbsp2_opt_clks,
2018 .opt_clks_cnt = ARRAY_SIZE(mcbsp2_opt_clks), 2017 .opt_clks_cnt = ARRAY_SIZE(mcbsp2_opt_clks),
2019 }; 2018 };
2020 2019
2021 /* mcbsp3 */ 2020 /* mcbsp3 */
2022 static struct omap_hwmod_irq_info omap44xx_mcbsp3_irqs[] = { 2021 static struct omap_hwmod_irq_info omap44xx_mcbsp3_irqs[] = {
2023 { .name = "common", .irq = 23 + OMAP44XX_IRQ_GIC_START }, 2022 { .name = "common", .irq = 23 + OMAP44XX_IRQ_GIC_START },
2024 { .irq = -1 } 2023 { .irq = -1 }
2025 }; 2024 };
2026 2025
2027 static struct omap_hwmod_dma_info omap44xx_mcbsp3_sdma_reqs[] = { 2026 static struct omap_hwmod_dma_info omap44xx_mcbsp3_sdma_reqs[] = {
2028 { .name = "tx", .dma_req = 18 + OMAP44XX_DMA_REQ_START }, 2027 { .name = "tx", .dma_req = 18 + OMAP44XX_DMA_REQ_START },
2029 { .name = "rx", .dma_req = 19 + OMAP44XX_DMA_REQ_START }, 2028 { .name = "rx", .dma_req = 19 + OMAP44XX_DMA_REQ_START },
2030 { .dma_req = -1 } 2029 { .dma_req = -1 }
2031 }; 2030 };
2032 2031
2033 static struct omap_hwmod_opt_clk mcbsp3_opt_clks[] = { 2032 static struct omap_hwmod_opt_clk mcbsp3_opt_clks[] = {
2034 { .role = "pad_fck", .clk = "pad_clks_ck" }, 2033 { .role = "pad_fck", .clk = "pad_clks_ck" },
2035 { .role = "prcm_fck", .clk = "mcbsp3_sync_mux_ck" }, 2034 { .role = "prcm_fck", .clk = "mcbsp3_sync_mux_ck" },
2036 }; 2035 };
2037 2036
2038 static struct omap_hwmod omap44xx_mcbsp3_hwmod = { 2037 static struct omap_hwmod omap44xx_mcbsp3_hwmod = {
2039 .name = "mcbsp3", 2038 .name = "mcbsp3",
2040 .class = &omap44xx_mcbsp_hwmod_class, 2039 .class = &omap44xx_mcbsp_hwmod_class,
2041 .clkdm_name = "abe_clkdm", 2040 .clkdm_name = "abe_clkdm",
2042 .mpu_irqs = omap44xx_mcbsp3_irqs, 2041 .mpu_irqs = omap44xx_mcbsp3_irqs,
2043 .sdma_reqs = omap44xx_mcbsp3_sdma_reqs, 2042 .sdma_reqs = omap44xx_mcbsp3_sdma_reqs,
2044 .main_clk = "mcbsp3_fck", 2043 .main_clk = "mcbsp3_fck",
2045 .prcm = { 2044 .prcm = {
2046 .omap4 = { 2045 .omap4 = {
2047 .clkctrl_offs = OMAP4_CM1_ABE_MCBSP3_CLKCTRL_OFFSET, 2046 .clkctrl_offs = OMAP4_CM1_ABE_MCBSP3_CLKCTRL_OFFSET,
2048 .context_offs = OMAP4_RM_ABE_MCBSP3_CONTEXT_OFFSET, 2047 .context_offs = OMAP4_RM_ABE_MCBSP3_CONTEXT_OFFSET,
2049 .modulemode = MODULEMODE_SWCTRL, 2048 .modulemode = MODULEMODE_SWCTRL,
2050 }, 2049 },
2051 }, 2050 },
2052 .opt_clks = mcbsp3_opt_clks, 2051 .opt_clks = mcbsp3_opt_clks,
2053 .opt_clks_cnt = ARRAY_SIZE(mcbsp3_opt_clks), 2052 .opt_clks_cnt = ARRAY_SIZE(mcbsp3_opt_clks),
2054 }; 2053 };
2055 2054
2056 /* mcbsp4 */ 2055 /* mcbsp4 */
2057 static struct omap_hwmod_irq_info omap44xx_mcbsp4_irqs[] = { 2056 static struct omap_hwmod_irq_info omap44xx_mcbsp4_irqs[] = {
2058 { .name = "common", .irq = 16 + OMAP44XX_IRQ_GIC_START }, 2057 { .name = "common", .irq = 16 + OMAP44XX_IRQ_GIC_START },
2059 { .irq = -1 } 2058 { .irq = -1 }
2060 }; 2059 };
2061 2060
2062 static struct omap_hwmod_dma_info omap44xx_mcbsp4_sdma_reqs[] = { 2061 static struct omap_hwmod_dma_info omap44xx_mcbsp4_sdma_reqs[] = {
2063 { .name = "tx", .dma_req = 30 + OMAP44XX_DMA_REQ_START }, 2062 { .name = "tx", .dma_req = 30 + OMAP44XX_DMA_REQ_START },
2064 { .name = "rx", .dma_req = 31 + OMAP44XX_DMA_REQ_START }, 2063 { .name = "rx", .dma_req = 31 + OMAP44XX_DMA_REQ_START },
2065 { .dma_req = -1 } 2064 { .dma_req = -1 }
2066 }; 2065 };
2067 2066
2068 static struct omap_hwmod_opt_clk mcbsp4_opt_clks[] = { 2067 static struct omap_hwmod_opt_clk mcbsp4_opt_clks[] = {
2069 { .role = "pad_fck", .clk = "pad_clks_ck" }, 2068 { .role = "pad_fck", .clk = "pad_clks_ck" },
2070 { .role = "prcm_fck", .clk = "mcbsp4_sync_mux_ck" }, 2069 { .role = "prcm_fck", .clk = "mcbsp4_sync_mux_ck" },
2071 }; 2070 };
2072 2071
2073 static struct omap_hwmod omap44xx_mcbsp4_hwmod = { 2072 static struct omap_hwmod omap44xx_mcbsp4_hwmod = {
2074 .name = "mcbsp4", 2073 .name = "mcbsp4",
2075 .class = &omap44xx_mcbsp_hwmod_class, 2074 .class = &omap44xx_mcbsp_hwmod_class,
2076 .clkdm_name = "l4_per_clkdm", 2075 .clkdm_name = "l4_per_clkdm",
2077 .mpu_irqs = omap44xx_mcbsp4_irqs, 2076 .mpu_irqs = omap44xx_mcbsp4_irqs,
2078 .sdma_reqs = omap44xx_mcbsp4_sdma_reqs, 2077 .sdma_reqs = omap44xx_mcbsp4_sdma_reqs,
2079 .main_clk = "mcbsp4_fck", 2078 .main_clk = "mcbsp4_fck",
2080 .prcm = { 2079 .prcm = {
2081 .omap4 = { 2080 .omap4 = {
2082 .clkctrl_offs = OMAP4_CM_L4PER_MCBSP4_CLKCTRL_OFFSET, 2081 .clkctrl_offs = OMAP4_CM_L4PER_MCBSP4_CLKCTRL_OFFSET,
2083 .context_offs = OMAP4_RM_L4PER_MCBSP4_CONTEXT_OFFSET, 2082 .context_offs = OMAP4_RM_L4PER_MCBSP4_CONTEXT_OFFSET,
2084 .modulemode = MODULEMODE_SWCTRL, 2083 .modulemode = MODULEMODE_SWCTRL,
2085 }, 2084 },
2086 }, 2085 },
2087 .opt_clks = mcbsp4_opt_clks, 2086 .opt_clks = mcbsp4_opt_clks,
2088 .opt_clks_cnt = ARRAY_SIZE(mcbsp4_opt_clks), 2087 .opt_clks_cnt = ARRAY_SIZE(mcbsp4_opt_clks),
2089 }; 2088 };
2090 2089
2091 /* 2090 /*
2092 * 'mcpdm' class 2091 * 'mcpdm' class
2093 * multi channel pdm controller (proprietary interface with phoenix power 2092 * multi channel pdm controller (proprietary interface with phoenix power
2094 * ic) 2093 * ic)
2095 */ 2094 */
2096 2095
2097 static struct omap_hwmod_class_sysconfig omap44xx_mcpdm_sysc = { 2096 static struct omap_hwmod_class_sysconfig omap44xx_mcpdm_sysc = {
2098 .rev_offs = 0x0000, 2097 .rev_offs = 0x0000,
2099 .sysc_offs = 0x0010, 2098 .sysc_offs = 0x0010,
2100 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS | 2099 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
2101 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET), 2100 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
2102 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 2101 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
2103 SIDLE_SMART_WKUP), 2102 SIDLE_SMART_WKUP),
2104 .sysc_fields = &omap_hwmod_sysc_type2, 2103 .sysc_fields = &omap_hwmod_sysc_type2,
2105 }; 2104 };
2106 2105
2107 static struct omap_hwmod_class omap44xx_mcpdm_hwmod_class = { 2106 static struct omap_hwmod_class omap44xx_mcpdm_hwmod_class = {
2108 .name = "mcpdm", 2107 .name = "mcpdm",
2109 .sysc = &omap44xx_mcpdm_sysc, 2108 .sysc = &omap44xx_mcpdm_sysc,
2110 }; 2109 };
2111 2110
2112 /* mcpdm */ 2111 /* mcpdm */
2113 static struct omap_hwmod_irq_info omap44xx_mcpdm_irqs[] = { 2112 static struct omap_hwmod_irq_info omap44xx_mcpdm_irqs[] = {
2114 { .irq = 112 + OMAP44XX_IRQ_GIC_START }, 2113 { .irq = 112 + OMAP44XX_IRQ_GIC_START },
2115 { .irq = -1 } 2114 { .irq = -1 }
2116 }; 2115 };
2117 2116
2118 static struct omap_hwmod_dma_info omap44xx_mcpdm_sdma_reqs[] = { 2117 static struct omap_hwmod_dma_info omap44xx_mcpdm_sdma_reqs[] = {
2119 { .name = "up_link", .dma_req = 64 + OMAP44XX_DMA_REQ_START }, 2118 { .name = "up_link", .dma_req = 64 + OMAP44XX_DMA_REQ_START },
2120 { .name = "dn_link", .dma_req = 65 + OMAP44XX_DMA_REQ_START }, 2119 { .name = "dn_link", .dma_req = 65 + OMAP44XX_DMA_REQ_START },
2121 { .dma_req = -1 } 2120 { .dma_req = -1 }
2122 }; 2121 };
2123 2122
2124 static struct omap_hwmod omap44xx_mcpdm_hwmod = { 2123 static struct omap_hwmod omap44xx_mcpdm_hwmod = {
2125 .name = "mcpdm", 2124 .name = "mcpdm",
2126 .class = &omap44xx_mcpdm_hwmod_class, 2125 .class = &omap44xx_mcpdm_hwmod_class,
2127 .clkdm_name = "abe_clkdm", 2126 .clkdm_name = "abe_clkdm",
2128 .mpu_irqs = omap44xx_mcpdm_irqs, 2127 .mpu_irqs = omap44xx_mcpdm_irqs,
2129 .sdma_reqs = omap44xx_mcpdm_sdma_reqs, 2128 .sdma_reqs = omap44xx_mcpdm_sdma_reqs,
2130 .main_clk = "mcpdm_fck", 2129 .main_clk = "mcpdm_fck",
2131 .prcm = { 2130 .prcm = {
2132 .omap4 = { 2131 .omap4 = {
2133 .clkctrl_offs = OMAP4_CM1_ABE_PDM_CLKCTRL_OFFSET, 2132 .clkctrl_offs = OMAP4_CM1_ABE_PDM_CLKCTRL_OFFSET,
2134 .context_offs = OMAP4_RM_ABE_PDM_CONTEXT_OFFSET, 2133 .context_offs = OMAP4_RM_ABE_PDM_CONTEXT_OFFSET,
2135 .modulemode = MODULEMODE_SWCTRL, 2134 .modulemode = MODULEMODE_SWCTRL,
2136 }, 2135 },
2137 }, 2136 },
2138 }; 2137 };
2139 2138
2140 /* 2139 /*
2141 * 'mcspi' class 2140 * 'mcspi' class
2142 * multichannel serial port interface (mcspi) / master/slave synchronous serial 2141 * multichannel serial port interface (mcspi) / master/slave synchronous serial
2143 * bus 2142 * bus
2144 */ 2143 */
2145 2144
2146 static struct omap_hwmod_class_sysconfig omap44xx_mcspi_sysc = { 2145 static struct omap_hwmod_class_sysconfig omap44xx_mcspi_sysc = {
2147 .rev_offs = 0x0000, 2146 .rev_offs = 0x0000,
2148 .sysc_offs = 0x0010, 2147 .sysc_offs = 0x0010,
2149 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS | 2148 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
2150 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET), 2149 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
2151 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 2150 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
2152 SIDLE_SMART_WKUP), 2151 SIDLE_SMART_WKUP),
2153 .sysc_fields = &omap_hwmod_sysc_type2, 2152 .sysc_fields = &omap_hwmod_sysc_type2,
2154 }; 2153 };
2155 2154
2156 static struct omap_hwmod_class omap44xx_mcspi_hwmod_class = { 2155 static struct omap_hwmod_class omap44xx_mcspi_hwmod_class = {
2157 .name = "mcspi", 2156 .name = "mcspi",
2158 .sysc = &omap44xx_mcspi_sysc, 2157 .sysc = &omap44xx_mcspi_sysc,
2159 .rev = OMAP4_MCSPI_REV, 2158 .rev = OMAP4_MCSPI_REV,
2160 }; 2159 };
2161 2160
2162 /* mcspi1 */ 2161 /* mcspi1 */
2163 static struct omap_hwmod_irq_info omap44xx_mcspi1_irqs[] = { 2162 static struct omap_hwmod_irq_info omap44xx_mcspi1_irqs[] = {
2164 { .irq = 65 + OMAP44XX_IRQ_GIC_START }, 2163 { .irq = 65 + OMAP44XX_IRQ_GIC_START },
2165 { .irq = -1 } 2164 { .irq = -1 }
2166 }; 2165 };
2167 2166
2168 static struct omap_hwmod_dma_info omap44xx_mcspi1_sdma_reqs[] = { 2167 static struct omap_hwmod_dma_info omap44xx_mcspi1_sdma_reqs[] = {
2169 { .name = "tx0", .dma_req = 34 + OMAP44XX_DMA_REQ_START }, 2168 { .name = "tx0", .dma_req = 34 + OMAP44XX_DMA_REQ_START },
2170 { .name = "rx0", .dma_req = 35 + OMAP44XX_DMA_REQ_START }, 2169 { .name = "rx0", .dma_req = 35 + OMAP44XX_DMA_REQ_START },
2171 { .name = "tx1", .dma_req = 36 + OMAP44XX_DMA_REQ_START }, 2170 { .name = "tx1", .dma_req = 36 + OMAP44XX_DMA_REQ_START },
2172 { .name = "rx1", .dma_req = 37 + OMAP44XX_DMA_REQ_START }, 2171 { .name = "rx1", .dma_req = 37 + OMAP44XX_DMA_REQ_START },
2173 { .name = "tx2", .dma_req = 38 + OMAP44XX_DMA_REQ_START }, 2172 { .name = "tx2", .dma_req = 38 + OMAP44XX_DMA_REQ_START },
2174 { .name = "rx2", .dma_req = 39 + OMAP44XX_DMA_REQ_START }, 2173 { .name = "rx2", .dma_req = 39 + OMAP44XX_DMA_REQ_START },
2175 { .name = "tx3", .dma_req = 40 + OMAP44XX_DMA_REQ_START }, 2174 { .name = "tx3", .dma_req = 40 + OMAP44XX_DMA_REQ_START },
2176 { .name = "rx3", .dma_req = 41 + OMAP44XX_DMA_REQ_START }, 2175 { .name = "rx3", .dma_req = 41 + OMAP44XX_DMA_REQ_START },
2177 { .dma_req = -1 } 2176 { .dma_req = -1 }
2178 }; 2177 };
2179 2178
2180 /* mcspi1 dev_attr */ 2179 /* mcspi1 dev_attr */
2181 static struct omap2_mcspi_dev_attr mcspi1_dev_attr = { 2180 static struct omap2_mcspi_dev_attr mcspi1_dev_attr = {
2182 .num_chipselect = 4, 2181 .num_chipselect = 4,
2183 }; 2182 };
2184 2183
2185 static struct omap_hwmod omap44xx_mcspi1_hwmod = { 2184 static struct omap_hwmod omap44xx_mcspi1_hwmod = {
2186 .name = "mcspi1", 2185 .name = "mcspi1",
2187 .class = &omap44xx_mcspi_hwmod_class, 2186 .class = &omap44xx_mcspi_hwmod_class,
2188 .clkdm_name = "l4_per_clkdm", 2187 .clkdm_name = "l4_per_clkdm",
2189 .mpu_irqs = omap44xx_mcspi1_irqs, 2188 .mpu_irqs = omap44xx_mcspi1_irqs,
2190 .sdma_reqs = omap44xx_mcspi1_sdma_reqs, 2189 .sdma_reqs = omap44xx_mcspi1_sdma_reqs,
2191 .main_clk = "mcspi1_fck", 2190 .main_clk = "mcspi1_fck",
2192 .prcm = { 2191 .prcm = {
2193 .omap4 = { 2192 .omap4 = {
2194 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI1_CLKCTRL_OFFSET, 2193 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI1_CLKCTRL_OFFSET,
2195 .context_offs = OMAP4_RM_L4PER_MCSPI1_CONTEXT_OFFSET, 2194 .context_offs = OMAP4_RM_L4PER_MCSPI1_CONTEXT_OFFSET,
2196 .modulemode = MODULEMODE_SWCTRL, 2195 .modulemode = MODULEMODE_SWCTRL,
2197 }, 2196 },
2198 }, 2197 },
2199 .dev_attr = &mcspi1_dev_attr, 2198 .dev_attr = &mcspi1_dev_attr,
2200 }; 2199 };
2201 2200
2202 /* mcspi2 */ 2201 /* mcspi2 */
2203 static struct omap_hwmod_irq_info omap44xx_mcspi2_irqs[] = { 2202 static struct omap_hwmod_irq_info omap44xx_mcspi2_irqs[] = {
2204 { .irq = 66 + OMAP44XX_IRQ_GIC_START }, 2203 { .irq = 66 + OMAP44XX_IRQ_GIC_START },
2205 { .irq = -1 } 2204 { .irq = -1 }
2206 }; 2205 };
2207 2206
2208 static struct omap_hwmod_dma_info omap44xx_mcspi2_sdma_reqs[] = { 2207 static struct omap_hwmod_dma_info omap44xx_mcspi2_sdma_reqs[] = {
2209 { .name = "tx0", .dma_req = 42 + OMAP44XX_DMA_REQ_START }, 2208 { .name = "tx0", .dma_req = 42 + OMAP44XX_DMA_REQ_START },
2210 { .name = "rx0", .dma_req = 43 + OMAP44XX_DMA_REQ_START }, 2209 { .name = "rx0", .dma_req = 43 + OMAP44XX_DMA_REQ_START },
2211 { .name = "tx1", .dma_req = 44 + OMAP44XX_DMA_REQ_START }, 2210 { .name = "tx1", .dma_req = 44 + OMAP44XX_DMA_REQ_START },
2212 { .name = "rx1", .dma_req = 45 + OMAP44XX_DMA_REQ_START }, 2211 { .name = "rx1", .dma_req = 45 + OMAP44XX_DMA_REQ_START },
2213 { .dma_req = -1 } 2212 { .dma_req = -1 }
2214 }; 2213 };
2215 2214
2216 /* mcspi2 dev_attr */ 2215 /* mcspi2 dev_attr */
2217 static struct omap2_mcspi_dev_attr mcspi2_dev_attr = { 2216 static struct omap2_mcspi_dev_attr mcspi2_dev_attr = {
2218 .num_chipselect = 2, 2217 .num_chipselect = 2,
2219 }; 2218 };
2220 2219
2221 static struct omap_hwmod omap44xx_mcspi2_hwmod = { 2220 static struct omap_hwmod omap44xx_mcspi2_hwmod = {
2222 .name = "mcspi2", 2221 .name = "mcspi2",
2223 .class = &omap44xx_mcspi_hwmod_class, 2222 .class = &omap44xx_mcspi_hwmod_class,
2224 .clkdm_name = "l4_per_clkdm", 2223 .clkdm_name = "l4_per_clkdm",
2225 .mpu_irqs = omap44xx_mcspi2_irqs, 2224 .mpu_irqs = omap44xx_mcspi2_irqs,
2226 .sdma_reqs = omap44xx_mcspi2_sdma_reqs, 2225 .sdma_reqs = omap44xx_mcspi2_sdma_reqs,
2227 .main_clk = "mcspi2_fck", 2226 .main_clk = "mcspi2_fck",
2228 .prcm = { 2227 .prcm = {
2229 .omap4 = { 2228 .omap4 = {
2230 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI2_CLKCTRL_OFFSET, 2229 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI2_CLKCTRL_OFFSET,
2231 .context_offs = OMAP4_RM_L4PER_MCSPI2_CONTEXT_OFFSET, 2230 .context_offs = OMAP4_RM_L4PER_MCSPI2_CONTEXT_OFFSET,
2232 .modulemode = MODULEMODE_SWCTRL, 2231 .modulemode = MODULEMODE_SWCTRL,
2233 }, 2232 },
2234 }, 2233 },
2235 .dev_attr = &mcspi2_dev_attr, 2234 .dev_attr = &mcspi2_dev_attr,
2236 }; 2235 };
2237 2236
2238 /* mcspi3 */ 2237 /* mcspi3 */
2239 static struct omap_hwmod_irq_info omap44xx_mcspi3_irqs[] = { 2238 static struct omap_hwmod_irq_info omap44xx_mcspi3_irqs[] = {
2240 { .irq = 91 + OMAP44XX_IRQ_GIC_START }, 2239 { .irq = 91 + OMAP44XX_IRQ_GIC_START },
2241 { .irq = -1 } 2240 { .irq = -1 }
2242 }; 2241 };
2243 2242
2244 static struct omap_hwmod_dma_info omap44xx_mcspi3_sdma_reqs[] = { 2243 static struct omap_hwmod_dma_info omap44xx_mcspi3_sdma_reqs[] = {
2245 { .name = "tx0", .dma_req = 14 + OMAP44XX_DMA_REQ_START }, 2244 { .name = "tx0", .dma_req = 14 + OMAP44XX_DMA_REQ_START },
2246 { .name = "rx0", .dma_req = 15 + OMAP44XX_DMA_REQ_START }, 2245 { .name = "rx0", .dma_req = 15 + OMAP44XX_DMA_REQ_START },
2247 { .name = "tx1", .dma_req = 22 + OMAP44XX_DMA_REQ_START }, 2246 { .name = "tx1", .dma_req = 22 + OMAP44XX_DMA_REQ_START },
2248 { .name = "rx1", .dma_req = 23 + OMAP44XX_DMA_REQ_START }, 2247 { .name = "rx1", .dma_req = 23 + OMAP44XX_DMA_REQ_START },
2249 { .dma_req = -1 } 2248 { .dma_req = -1 }
2250 }; 2249 };
2251 2250
2252 /* mcspi3 dev_attr */ 2251 /* mcspi3 dev_attr */
2253 static struct omap2_mcspi_dev_attr mcspi3_dev_attr = { 2252 static struct omap2_mcspi_dev_attr mcspi3_dev_attr = {
2254 .num_chipselect = 2, 2253 .num_chipselect = 2,
2255 }; 2254 };
2256 2255
2257 static struct omap_hwmod omap44xx_mcspi3_hwmod = { 2256 static struct omap_hwmod omap44xx_mcspi3_hwmod = {
2258 .name = "mcspi3", 2257 .name = "mcspi3",
2259 .class = &omap44xx_mcspi_hwmod_class, 2258 .class = &omap44xx_mcspi_hwmod_class,
2260 .clkdm_name = "l4_per_clkdm", 2259 .clkdm_name = "l4_per_clkdm",
2261 .mpu_irqs = omap44xx_mcspi3_irqs, 2260 .mpu_irqs = omap44xx_mcspi3_irqs,
2262 .sdma_reqs = omap44xx_mcspi3_sdma_reqs, 2261 .sdma_reqs = omap44xx_mcspi3_sdma_reqs,
2263 .main_clk = "mcspi3_fck", 2262 .main_clk = "mcspi3_fck",
2264 .prcm = { 2263 .prcm = {
2265 .omap4 = { 2264 .omap4 = {
2266 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI3_CLKCTRL_OFFSET, 2265 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI3_CLKCTRL_OFFSET,
2267 .context_offs = OMAP4_RM_L4PER_MCSPI3_CONTEXT_OFFSET, 2266 .context_offs = OMAP4_RM_L4PER_MCSPI3_CONTEXT_OFFSET,
2268 .modulemode = MODULEMODE_SWCTRL, 2267 .modulemode = MODULEMODE_SWCTRL,
2269 }, 2268 },
2270 }, 2269 },
2271 .dev_attr = &mcspi3_dev_attr, 2270 .dev_attr = &mcspi3_dev_attr,
2272 }; 2271 };
2273 2272
2274 /* mcspi4 */ 2273 /* mcspi4 */
2275 static struct omap_hwmod_irq_info omap44xx_mcspi4_irqs[] = { 2274 static struct omap_hwmod_irq_info omap44xx_mcspi4_irqs[] = {
2276 { .irq = 48 + OMAP44XX_IRQ_GIC_START }, 2275 { .irq = 48 + OMAP44XX_IRQ_GIC_START },
2277 { .irq = -1 } 2276 { .irq = -1 }
2278 }; 2277 };
2279 2278
2280 static struct omap_hwmod_dma_info omap44xx_mcspi4_sdma_reqs[] = { 2279 static struct omap_hwmod_dma_info omap44xx_mcspi4_sdma_reqs[] = {
2281 { .name = "tx0", .dma_req = 69 + OMAP44XX_DMA_REQ_START }, 2280 { .name = "tx0", .dma_req = 69 + OMAP44XX_DMA_REQ_START },
2282 { .name = "rx0", .dma_req = 70 + OMAP44XX_DMA_REQ_START }, 2281 { .name = "rx0", .dma_req = 70 + OMAP44XX_DMA_REQ_START },
2283 { .dma_req = -1 } 2282 { .dma_req = -1 }
2284 }; 2283 };
2285 2284
2286 /* mcspi4 dev_attr */ 2285 /* mcspi4 dev_attr */
2287 static struct omap2_mcspi_dev_attr mcspi4_dev_attr = { 2286 static struct omap2_mcspi_dev_attr mcspi4_dev_attr = {
2288 .num_chipselect = 1, 2287 .num_chipselect = 1,
2289 }; 2288 };
2290 2289
2291 static struct omap_hwmod omap44xx_mcspi4_hwmod = { 2290 static struct omap_hwmod omap44xx_mcspi4_hwmod = {
2292 .name = "mcspi4", 2291 .name = "mcspi4",
2293 .class = &omap44xx_mcspi_hwmod_class, 2292 .class = &omap44xx_mcspi_hwmod_class,
2294 .clkdm_name = "l4_per_clkdm", 2293 .clkdm_name = "l4_per_clkdm",
2295 .mpu_irqs = omap44xx_mcspi4_irqs, 2294 .mpu_irqs = omap44xx_mcspi4_irqs,
2296 .sdma_reqs = omap44xx_mcspi4_sdma_reqs, 2295 .sdma_reqs = omap44xx_mcspi4_sdma_reqs,
2297 .main_clk = "mcspi4_fck", 2296 .main_clk = "mcspi4_fck",
2298 .prcm = { 2297 .prcm = {
2299 .omap4 = { 2298 .omap4 = {
2300 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI4_CLKCTRL_OFFSET, 2299 .clkctrl_offs = OMAP4_CM_L4PER_MCSPI4_CLKCTRL_OFFSET,
2301 .context_offs = OMAP4_RM_L4PER_MCSPI4_CONTEXT_OFFSET, 2300 .context_offs = OMAP4_RM_L4PER_MCSPI4_CONTEXT_OFFSET,
2302 .modulemode = MODULEMODE_SWCTRL, 2301 .modulemode = MODULEMODE_SWCTRL,
2303 }, 2302 },
2304 }, 2303 },
2305 .dev_attr = &mcspi4_dev_attr, 2304 .dev_attr = &mcspi4_dev_attr,
2306 }; 2305 };
2307 2306
2308 /* 2307 /*
2309 * 'mmc' class 2308 * 'mmc' class
2310 * multimedia card high-speed/sd/sdio (mmc/sd/sdio) host controller 2309 * multimedia card high-speed/sd/sdio (mmc/sd/sdio) host controller
2311 */ 2310 */
2312 2311
2313 static struct omap_hwmod_class_sysconfig omap44xx_mmc_sysc = { 2312 static struct omap_hwmod_class_sysconfig omap44xx_mmc_sysc = {
2314 .rev_offs = 0x0000, 2313 .rev_offs = 0x0000,
2315 .sysc_offs = 0x0010, 2314 .sysc_offs = 0x0010,
2316 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE | 2315 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_MIDLEMODE |
2317 SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE | 2316 SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
2318 SYSC_HAS_SOFTRESET), 2317 SYSC_HAS_SOFTRESET),
2319 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 2318 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
2320 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO | 2319 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
2321 MSTANDBY_SMART | MSTANDBY_SMART_WKUP), 2320 MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
2322 .sysc_fields = &omap_hwmod_sysc_type2, 2321 .sysc_fields = &omap_hwmod_sysc_type2,
2323 }; 2322 };
2324 2323
2325 static struct omap_hwmod_class omap44xx_mmc_hwmod_class = { 2324 static struct omap_hwmod_class omap44xx_mmc_hwmod_class = {
2326 .name = "mmc", 2325 .name = "mmc",
2327 .sysc = &omap44xx_mmc_sysc, 2326 .sysc = &omap44xx_mmc_sysc,
2328 }; 2327 };
2329 2328
2330 /* mmc1 */ 2329 /* mmc1 */
2331 static struct omap_hwmod_irq_info omap44xx_mmc1_irqs[] = { 2330 static struct omap_hwmod_irq_info omap44xx_mmc1_irqs[] = {
2332 { .irq = 83 + OMAP44XX_IRQ_GIC_START }, 2331 { .irq = 83 + OMAP44XX_IRQ_GIC_START },
2333 { .irq = -1 } 2332 { .irq = -1 }
2334 }; 2333 };
2335 2334
2336 static struct omap_hwmod_dma_info omap44xx_mmc1_sdma_reqs[] = { 2335 static struct omap_hwmod_dma_info omap44xx_mmc1_sdma_reqs[] = {
2337 { .name = "tx", .dma_req = 60 + OMAP44XX_DMA_REQ_START }, 2336 { .name = "tx", .dma_req = 60 + OMAP44XX_DMA_REQ_START },
2338 { .name = "rx", .dma_req = 61 + OMAP44XX_DMA_REQ_START }, 2337 { .name = "rx", .dma_req = 61 + OMAP44XX_DMA_REQ_START },
2339 { .dma_req = -1 } 2338 { .dma_req = -1 }
2340 }; 2339 };
2341 2340
2342 /* mmc1 dev_attr */ 2341 /* mmc1 dev_attr */
2343 static struct omap_mmc_dev_attr mmc1_dev_attr = { 2342 static struct omap_mmc_dev_attr mmc1_dev_attr = {
2344 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT, 2343 .flags = OMAP_HSMMC_SUPPORTS_DUAL_VOLT,
2345 }; 2344 };
2346 2345
2347 static struct omap_hwmod omap44xx_mmc1_hwmod = { 2346 static struct omap_hwmod omap44xx_mmc1_hwmod = {
2348 .name = "mmc1", 2347 .name = "mmc1",
2349 .class = &omap44xx_mmc_hwmod_class, 2348 .class = &omap44xx_mmc_hwmod_class,
2350 .clkdm_name = "l3_init_clkdm", 2349 .clkdm_name = "l3_init_clkdm",
2351 .mpu_irqs = omap44xx_mmc1_irqs, 2350 .mpu_irqs = omap44xx_mmc1_irqs,
2352 .sdma_reqs = omap44xx_mmc1_sdma_reqs, 2351 .sdma_reqs = omap44xx_mmc1_sdma_reqs,
2353 .main_clk = "mmc1_fck", 2352 .main_clk = "mmc1_fck",
2354 .prcm = { 2353 .prcm = {
2355 .omap4 = { 2354 .omap4 = {
2356 .clkctrl_offs = OMAP4_CM_L3INIT_MMC1_CLKCTRL_OFFSET, 2355 .clkctrl_offs = OMAP4_CM_L3INIT_MMC1_CLKCTRL_OFFSET,
2357 .context_offs = OMAP4_RM_L3INIT_MMC1_CONTEXT_OFFSET, 2356 .context_offs = OMAP4_RM_L3INIT_MMC1_CONTEXT_OFFSET,
2358 .modulemode = MODULEMODE_SWCTRL, 2357 .modulemode = MODULEMODE_SWCTRL,
2359 }, 2358 },
2360 }, 2359 },
2361 .dev_attr = &mmc1_dev_attr, 2360 .dev_attr = &mmc1_dev_attr,
2362 }; 2361 };
2363 2362
2364 /* mmc2 */ 2363 /* mmc2 */
2365 static struct omap_hwmod_irq_info omap44xx_mmc2_irqs[] = { 2364 static struct omap_hwmod_irq_info omap44xx_mmc2_irqs[] = {
2366 { .irq = 86 + OMAP44XX_IRQ_GIC_START }, 2365 { .irq = 86 + OMAP44XX_IRQ_GIC_START },
2367 { .irq = -1 } 2366 { .irq = -1 }
2368 }; 2367 };
2369 2368
2370 static struct omap_hwmod_dma_info omap44xx_mmc2_sdma_reqs[] = { 2369 static struct omap_hwmod_dma_info omap44xx_mmc2_sdma_reqs[] = {
2371 { .name = "tx", .dma_req = 46 + OMAP44XX_DMA_REQ_START }, 2370 { .name = "tx", .dma_req = 46 + OMAP44XX_DMA_REQ_START },
2372 { .name = "rx", .dma_req = 47 + OMAP44XX_DMA_REQ_START }, 2371 { .name = "rx", .dma_req = 47 + OMAP44XX_DMA_REQ_START },
2373 { .dma_req = -1 } 2372 { .dma_req = -1 }
2374 }; 2373 };
2375 2374
2376 static struct omap_hwmod omap44xx_mmc2_hwmod = { 2375 static struct omap_hwmod omap44xx_mmc2_hwmod = {
2377 .name = "mmc2", 2376 .name = "mmc2",
2378 .class = &omap44xx_mmc_hwmod_class, 2377 .class = &omap44xx_mmc_hwmod_class,
2379 .clkdm_name = "l3_init_clkdm", 2378 .clkdm_name = "l3_init_clkdm",
2380 .mpu_irqs = omap44xx_mmc2_irqs, 2379 .mpu_irqs = omap44xx_mmc2_irqs,
2381 .sdma_reqs = omap44xx_mmc2_sdma_reqs, 2380 .sdma_reqs = omap44xx_mmc2_sdma_reqs,
2382 .main_clk = "mmc2_fck", 2381 .main_clk = "mmc2_fck",
2383 .prcm = { 2382 .prcm = {
2384 .omap4 = { 2383 .omap4 = {
2385 .clkctrl_offs = OMAP4_CM_L3INIT_MMC2_CLKCTRL_OFFSET, 2384 .clkctrl_offs = OMAP4_CM_L3INIT_MMC2_CLKCTRL_OFFSET,
2386 .context_offs = OMAP4_RM_L3INIT_MMC2_CONTEXT_OFFSET, 2385 .context_offs = OMAP4_RM_L3INIT_MMC2_CONTEXT_OFFSET,
2387 .modulemode = MODULEMODE_SWCTRL, 2386 .modulemode = MODULEMODE_SWCTRL,
2388 }, 2387 },
2389 }, 2388 },
2390 }; 2389 };
2391 2390
2392 /* mmc3 */ 2391 /* mmc3 */
2393 static struct omap_hwmod_irq_info omap44xx_mmc3_irqs[] = { 2392 static struct omap_hwmod_irq_info omap44xx_mmc3_irqs[] = {
2394 { .irq = 94 + OMAP44XX_IRQ_GIC_START }, 2393 { .irq = 94 + OMAP44XX_IRQ_GIC_START },
2395 { .irq = -1 } 2394 { .irq = -1 }
2396 }; 2395 };
2397 2396
2398 static struct omap_hwmod_dma_info omap44xx_mmc3_sdma_reqs[] = { 2397 static struct omap_hwmod_dma_info omap44xx_mmc3_sdma_reqs[] = {
2399 { .name = "tx", .dma_req = 76 + OMAP44XX_DMA_REQ_START }, 2398 { .name = "tx", .dma_req = 76 + OMAP44XX_DMA_REQ_START },
2400 { .name = "rx", .dma_req = 77 + OMAP44XX_DMA_REQ_START }, 2399 { .name = "rx", .dma_req = 77 + OMAP44XX_DMA_REQ_START },
2401 { .dma_req = -1 } 2400 { .dma_req = -1 }
2402 }; 2401 };
2403 2402
2404 static struct omap_hwmod omap44xx_mmc3_hwmod = { 2403 static struct omap_hwmod omap44xx_mmc3_hwmod = {
2405 .name = "mmc3", 2404 .name = "mmc3",
2406 .class = &omap44xx_mmc_hwmod_class, 2405 .class = &omap44xx_mmc_hwmod_class,
2407 .clkdm_name = "l4_per_clkdm", 2406 .clkdm_name = "l4_per_clkdm",
2408 .mpu_irqs = omap44xx_mmc3_irqs, 2407 .mpu_irqs = omap44xx_mmc3_irqs,
2409 .sdma_reqs = omap44xx_mmc3_sdma_reqs, 2408 .sdma_reqs = omap44xx_mmc3_sdma_reqs,
2410 .main_clk = "mmc3_fck", 2409 .main_clk = "mmc3_fck",
2411 .prcm = { 2410 .prcm = {
2412 .omap4 = { 2411 .omap4 = {
2413 .clkctrl_offs = OMAP4_CM_L4PER_MMCSD3_CLKCTRL_OFFSET, 2412 .clkctrl_offs = OMAP4_CM_L4PER_MMCSD3_CLKCTRL_OFFSET,
2414 .context_offs = OMAP4_RM_L4PER_MMCSD3_CONTEXT_OFFSET, 2413 .context_offs = OMAP4_RM_L4PER_MMCSD3_CONTEXT_OFFSET,
2415 .modulemode = MODULEMODE_SWCTRL, 2414 .modulemode = MODULEMODE_SWCTRL,
2416 }, 2415 },
2417 }, 2416 },
2418 }; 2417 };
2419 2418
2420 /* mmc4 */ 2419 /* mmc4 */
2421 static struct omap_hwmod_irq_info omap44xx_mmc4_irqs[] = { 2420 static struct omap_hwmod_irq_info omap44xx_mmc4_irqs[] = {
2422 { .irq = 96 + OMAP44XX_IRQ_GIC_START }, 2421 { .irq = 96 + OMAP44XX_IRQ_GIC_START },
2423 { .irq = -1 } 2422 { .irq = -1 }
2424 }; 2423 };
2425 2424
2426 static struct omap_hwmod_dma_info omap44xx_mmc4_sdma_reqs[] = { 2425 static struct omap_hwmod_dma_info omap44xx_mmc4_sdma_reqs[] = {
2427 { .name = "tx", .dma_req = 56 + OMAP44XX_DMA_REQ_START }, 2426 { .name = "tx", .dma_req = 56 + OMAP44XX_DMA_REQ_START },
2428 { .name = "rx", .dma_req = 57 + OMAP44XX_DMA_REQ_START }, 2427 { .name = "rx", .dma_req = 57 + OMAP44XX_DMA_REQ_START },
2429 { .dma_req = -1 } 2428 { .dma_req = -1 }
2430 }; 2429 };
2431 2430
2432 static struct omap_hwmod omap44xx_mmc4_hwmod = { 2431 static struct omap_hwmod omap44xx_mmc4_hwmod = {
2433 .name = "mmc4", 2432 .name = "mmc4",
2434 .class = &omap44xx_mmc_hwmod_class, 2433 .class = &omap44xx_mmc_hwmod_class,
2435 .clkdm_name = "l4_per_clkdm", 2434 .clkdm_name = "l4_per_clkdm",
2436 .mpu_irqs = omap44xx_mmc4_irqs, 2435 .mpu_irqs = omap44xx_mmc4_irqs,
2437 .sdma_reqs = omap44xx_mmc4_sdma_reqs, 2436 .sdma_reqs = omap44xx_mmc4_sdma_reqs,
2438 .main_clk = "mmc4_fck", 2437 .main_clk = "mmc4_fck",
2439 .prcm = { 2438 .prcm = {
2440 .omap4 = { 2439 .omap4 = {
2441 .clkctrl_offs = OMAP4_CM_L4PER_MMCSD4_CLKCTRL_OFFSET, 2440 .clkctrl_offs = OMAP4_CM_L4PER_MMCSD4_CLKCTRL_OFFSET,
2442 .context_offs = OMAP4_RM_L4PER_MMCSD4_CONTEXT_OFFSET, 2441 .context_offs = OMAP4_RM_L4PER_MMCSD4_CONTEXT_OFFSET,
2443 .modulemode = MODULEMODE_SWCTRL, 2442 .modulemode = MODULEMODE_SWCTRL,
2444 }, 2443 },
2445 }, 2444 },
2446 }; 2445 };
2447 2446
2448 /* mmc5 */ 2447 /* mmc5 */
2449 static struct omap_hwmod_irq_info omap44xx_mmc5_irqs[] = { 2448 static struct omap_hwmod_irq_info omap44xx_mmc5_irqs[] = {
2450 { .irq = 59 + OMAP44XX_IRQ_GIC_START }, 2449 { .irq = 59 + OMAP44XX_IRQ_GIC_START },
2451 { .irq = -1 } 2450 { .irq = -1 }
2452 }; 2451 };
2453 2452
2454 static struct omap_hwmod_dma_info omap44xx_mmc5_sdma_reqs[] = { 2453 static struct omap_hwmod_dma_info omap44xx_mmc5_sdma_reqs[] = {
2455 { .name = "tx", .dma_req = 58 + OMAP44XX_DMA_REQ_START }, 2454 { .name = "tx", .dma_req = 58 + OMAP44XX_DMA_REQ_START },
2456 { .name = "rx", .dma_req = 59 + OMAP44XX_DMA_REQ_START }, 2455 { .name = "rx", .dma_req = 59 + OMAP44XX_DMA_REQ_START },
2457 { .dma_req = -1 } 2456 { .dma_req = -1 }
2458 }; 2457 };
2459 2458
2460 static struct omap_hwmod omap44xx_mmc5_hwmod = { 2459 static struct omap_hwmod omap44xx_mmc5_hwmod = {
2461 .name = "mmc5", 2460 .name = "mmc5",
2462 .class = &omap44xx_mmc_hwmod_class, 2461 .class = &omap44xx_mmc_hwmod_class,
2463 .clkdm_name = "l4_per_clkdm", 2462 .clkdm_name = "l4_per_clkdm",
2464 .mpu_irqs = omap44xx_mmc5_irqs, 2463 .mpu_irqs = omap44xx_mmc5_irqs,
2465 .sdma_reqs = omap44xx_mmc5_sdma_reqs, 2464 .sdma_reqs = omap44xx_mmc5_sdma_reqs,
2466 .main_clk = "mmc5_fck", 2465 .main_clk = "mmc5_fck",
2467 .prcm = { 2466 .prcm = {
2468 .omap4 = { 2467 .omap4 = {
2469 .clkctrl_offs = OMAP4_CM_L4PER_MMCSD5_CLKCTRL_OFFSET, 2468 .clkctrl_offs = OMAP4_CM_L4PER_MMCSD5_CLKCTRL_OFFSET,
2470 .context_offs = OMAP4_RM_L4PER_MMCSD5_CONTEXT_OFFSET, 2469 .context_offs = OMAP4_RM_L4PER_MMCSD5_CONTEXT_OFFSET,
2471 .modulemode = MODULEMODE_SWCTRL, 2470 .modulemode = MODULEMODE_SWCTRL,
2472 }, 2471 },
2473 }, 2472 },
2474 }; 2473 };
2475 2474
2476 /* 2475 /*
2477 * 'mmu' class 2476 * 'mmu' class
2478 * The memory management unit performs virtual to physical address translation 2477 * The memory management unit performs virtual to physical address translation
2479 * for its requestors. 2478 * for its requestors.
2480 */ 2479 */
2481 2480
2482 static struct omap_hwmod_class_sysconfig mmu_sysc = { 2481 static struct omap_hwmod_class_sysconfig mmu_sysc = {
2483 .rev_offs = 0x000, 2482 .rev_offs = 0x000,
2484 .sysc_offs = 0x010, 2483 .sysc_offs = 0x010,
2485 .syss_offs = 0x014, 2484 .syss_offs = 0x014,
2486 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 2485 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
2487 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE), 2486 SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
2488 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 2487 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2489 .sysc_fields = &omap_hwmod_sysc_type1, 2488 .sysc_fields = &omap_hwmod_sysc_type1,
2490 }; 2489 };
2491 2490
2492 static struct omap_hwmod_class omap44xx_mmu_hwmod_class = { 2491 static struct omap_hwmod_class omap44xx_mmu_hwmod_class = {
2493 .name = "mmu", 2492 .name = "mmu",
2494 .sysc = &mmu_sysc, 2493 .sysc = &mmu_sysc,
2495 }; 2494 };
2496 2495
2497 /* mmu ipu */ 2496 /* mmu ipu */
2498 2497
2499 static struct omap_mmu_dev_attr mmu_ipu_dev_attr = { 2498 static struct omap_mmu_dev_attr mmu_ipu_dev_attr = {
2500 .da_start = 0x0, 2499 .da_start = 0x0,
2501 .da_end = 0xfffff000, 2500 .da_end = 0xfffff000,
2502 .nr_tlb_entries = 32, 2501 .nr_tlb_entries = 32,
2503 }; 2502 };
2504 2503
2505 static struct omap_hwmod omap44xx_mmu_ipu_hwmod; 2504 static struct omap_hwmod omap44xx_mmu_ipu_hwmod;
2506 static struct omap_hwmod_irq_info omap44xx_mmu_ipu_irqs[] = { 2505 static struct omap_hwmod_irq_info omap44xx_mmu_ipu_irqs[] = {
2507 { .irq = 100 + OMAP44XX_IRQ_GIC_START, }, 2506 { .irq = 100 + OMAP44XX_IRQ_GIC_START, },
2508 { .irq = -1 } 2507 { .irq = -1 }
2509 }; 2508 };
2510 2509
2511 static struct omap_hwmod_rst_info omap44xx_mmu_ipu_resets[] = { 2510 static struct omap_hwmod_rst_info omap44xx_mmu_ipu_resets[] = {
2512 { .name = "mmu_cache", .rst_shift = 2 }, 2511 { .name = "mmu_cache", .rst_shift = 2 },
2513 }; 2512 };
2514 2513
2515 static struct omap_hwmod_addr_space omap44xx_mmu_ipu_addrs[] = { 2514 static struct omap_hwmod_addr_space omap44xx_mmu_ipu_addrs[] = {
2516 { 2515 {
2517 .pa_start = 0x55082000, 2516 .pa_start = 0x55082000,
2518 .pa_end = 0x550820ff, 2517 .pa_end = 0x550820ff,
2519 .flags = ADDR_TYPE_RT, 2518 .flags = ADDR_TYPE_RT,
2520 }, 2519 },
2521 { } 2520 { }
2522 }; 2521 };
2523 2522
2524 /* l3_main_2 -> mmu_ipu */ 2523 /* l3_main_2 -> mmu_ipu */
2525 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__mmu_ipu = { 2524 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__mmu_ipu = {
2526 .master = &omap44xx_l3_main_2_hwmod, 2525 .master = &omap44xx_l3_main_2_hwmod,
2527 .slave = &omap44xx_mmu_ipu_hwmod, 2526 .slave = &omap44xx_mmu_ipu_hwmod,
2528 .clk = "l3_div_ck", 2527 .clk = "l3_div_ck",
2529 .addr = omap44xx_mmu_ipu_addrs, 2528 .addr = omap44xx_mmu_ipu_addrs,
2530 .user = OCP_USER_MPU | OCP_USER_SDMA, 2529 .user = OCP_USER_MPU | OCP_USER_SDMA,
2531 }; 2530 };
2532 2531
2533 static struct omap_hwmod omap44xx_mmu_ipu_hwmod = { 2532 static struct omap_hwmod omap44xx_mmu_ipu_hwmod = {
2534 .name = "mmu_ipu", 2533 .name = "mmu_ipu",
2535 .class = &omap44xx_mmu_hwmod_class, 2534 .class = &omap44xx_mmu_hwmod_class,
2536 .clkdm_name = "ducati_clkdm", 2535 .clkdm_name = "ducati_clkdm",
2537 .mpu_irqs = omap44xx_mmu_ipu_irqs, 2536 .mpu_irqs = omap44xx_mmu_ipu_irqs,
2538 .rst_lines = omap44xx_mmu_ipu_resets, 2537 .rst_lines = omap44xx_mmu_ipu_resets,
2539 .rst_lines_cnt = ARRAY_SIZE(omap44xx_mmu_ipu_resets), 2538 .rst_lines_cnt = ARRAY_SIZE(omap44xx_mmu_ipu_resets),
2540 .main_clk = "ducati_clk_mux_ck", 2539 .main_clk = "ducati_clk_mux_ck",
2541 .prcm = { 2540 .prcm = {
2542 .omap4 = { 2541 .omap4 = {
2543 .clkctrl_offs = OMAP4_CM_DUCATI_DUCATI_CLKCTRL_OFFSET, 2542 .clkctrl_offs = OMAP4_CM_DUCATI_DUCATI_CLKCTRL_OFFSET,
2544 .rstctrl_offs = OMAP4_RM_DUCATI_RSTCTRL_OFFSET, 2543 .rstctrl_offs = OMAP4_RM_DUCATI_RSTCTRL_OFFSET,
2545 .context_offs = OMAP4_RM_DUCATI_DUCATI_CONTEXT_OFFSET, 2544 .context_offs = OMAP4_RM_DUCATI_DUCATI_CONTEXT_OFFSET,
2546 .modulemode = MODULEMODE_HWCTRL, 2545 .modulemode = MODULEMODE_HWCTRL,
2547 }, 2546 },
2548 }, 2547 },
2549 .dev_attr = &mmu_ipu_dev_attr, 2548 .dev_attr = &mmu_ipu_dev_attr,
2550 }; 2549 };
2551 2550
2552 /* mmu dsp */ 2551 /* mmu dsp */
2553 2552
2554 static struct omap_mmu_dev_attr mmu_dsp_dev_attr = { 2553 static struct omap_mmu_dev_attr mmu_dsp_dev_attr = {
2555 .da_start = 0x0, 2554 .da_start = 0x0,
2556 .da_end = 0xfffff000, 2555 .da_end = 0xfffff000,
2557 .nr_tlb_entries = 32, 2556 .nr_tlb_entries = 32,
2558 }; 2557 };
2559 2558
2560 static struct omap_hwmod omap44xx_mmu_dsp_hwmod; 2559 static struct omap_hwmod omap44xx_mmu_dsp_hwmod;
2561 static struct omap_hwmod_irq_info omap44xx_mmu_dsp_irqs[] = { 2560 static struct omap_hwmod_irq_info omap44xx_mmu_dsp_irqs[] = {
2562 { .irq = 28 + OMAP44XX_IRQ_GIC_START }, 2561 { .irq = 28 + OMAP44XX_IRQ_GIC_START },
2563 { .irq = -1 } 2562 { .irq = -1 }
2564 }; 2563 };
2565 2564
2566 static struct omap_hwmod_rst_info omap44xx_mmu_dsp_resets[] = { 2565 static struct omap_hwmod_rst_info omap44xx_mmu_dsp_resets[] = {
2567 { .name = "mmu_cache", .rst_shift = 1 }, 2566 { .name = "mmu_cache", .rst_shift = 1 },
2568 }; 2567 };
2569 2568
2570 static struct omap_hwmod_addr_space omap44xx_mmu_dsp_addrs[] = { 2569 static struct omap_hwmod_addr_space omap44xx_mmu_dsp_addrs[] = {
2571 { 2570 {
2572 .pa_start = 0x4a066000, 2571 .pa_start = 0x4a066000,
2573 .pa_end = 0x4a0660ff, 2572 .pa_end = 0x4a0660ff,
2574 .flags = ADDR_TYPE_RT, 2573 .flags = ADDR_TYPE_RT,
2575 }, 2574 },
2576 { } 2575 { }
2577 }; 2576 };
2578 2577
2579 /* l4_cfg -> dsp */ 2578 /* l4_cfg -> dsp */
2580 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__mmu_dsp = { 2579 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__mmu_dsp = {
2581 .master = &omap44xx_l4_cfg_hwmod, 2580 .master = &omap44xx_l4_cfg_hwmod,
2582 .slave = &omap44xx_mmu_dsp_hwmod, 2581 .slave = &omap44xx_mmu_dsp_hwmod,
2583 .clk = "l4_div_ck", 2582 .clk = "l4_div_ck",
2584 .addr = omap44xx_mmu_dsp_addrs, 2583 .addr = omap44xx_mmu_dsp_addrs,
2585 .user = OCP_USER_MPU | OCP_USER_SDMA, 2584 .user = OCP_USER_MPU | OCP_USER_SDMA,
2586 }; 2585 };
2587 2586
2588 static struct omap_hwmod omap44xx_mmu_dsp_hwmod = { 2587 static struct omap_hwmod omap44xx_mmu_dsp_hwmod = {
2589 .name = "mmu_dsp", 2588 .name = "mmu_dsp",
2590 .class = &omap44xx_mmu_hwmod_class, 2589 .class = &omap44xx_mmu_hwmod_class,
2591 .clkdm_name = "tesla_clkdm", 2590 .clkdm_name = "tesla_clkdm",
2592 .mpu_irqs = omap44xx_mmu_dsp_irqs, 2591 .mpu_irqs = omap44xx_mmu_dsp_irqs,
2593 .rst_lines = omap44xx_mmu_dsp_resets, 2592 .rst_lines = omap44xx_mmu_dsp_resets,
2594 .rst_lines_cnt = ARRAY_SIZE(omap44xx_mmu_dsp_resets), 2593 .rst_lines_cnt = ARRAY_SIZE(omap44xx_mmu_dsp_resets),
2595 .main_clk = "dpll_iva_m4x2_ck", 2594 .main_clk = "dpll_iva_m4x2_ck",
2596 .prcm = { 2595 .prcm = {
2597 .omap4 = { 2596 .omap4 = {
2598 .clkctrl_offs = OMAP4_CM_TESLA_TESLA_CLKCTRL_OFFSET, 2597 .clkctrl_offs = OMAP4_CM_TESLA_TESLA_CLKCTRL_OFFSET,
2599 .rstctrl_offs = OMAP4_RM_TESLA_RSTCTRL_OFFSET, 2598 .rstctrl_offs = OMAP4_RM_TESLA_RSTCTRL_OFFSET,
2600 .context_offs = OMAP4_RM_TESLA_TESLA_CONTEXT_OFFSET, 2599 .context_offs = OMAP4_RM_TESLA_TESLA_CONTEXT_OFFSET,
2601 .modulemode = MODULEMODE_HWCTRL, 2600 .modulemode = MODULEMODE_HWCTRL,
2602 }, 2601 },
2603 }, 2602 },
2604 .dev_attr = &mmu_dsp_dev_attr, 2603 .dev_attr = &mmu_dsp_dev_attr,
2605 }; 2604 };
2606 2605
2607 /* 2606 /*
2608 * 'mpu' class 2607 * 'mpu' class
2609 * mpu sub-system 2608 * mpu sub-system
2610 */ 2609 */
2611 2610
2612 static struct omap_hwmod_class omap44xx_mpu_hwmod_class = { 2611 static struct omap_hwmod_class omap44xx_mpu_hwmod_class = {
2613 .name = "mpu", 2612 .name = "mpu",
2614 }; 2613 };
2615 2614
2616 /* mpu */ 2615 /* mpu */
2617 static struct omap_hwmod_irq_info omap44xx_mpu_irqs[] = { 2616 static struct omap_hwmod_irq_info omap44xx_mpu_irqs[] = {
2618 { .name = "pmu0", .irq = 54 + OMAP44XX_IRQ_GIC_START }, 2617 { .name = "pmu0", .irq = 54 + OMAP44XX_IRQ_GIC_START },
2619 { .name = "pmu1", .irq = 55 + OMAP44XX_IRQ_GIC_START }, 2618 { .name = "pmu1", .irq = 55 + OMAP44XX_IRQ_GIC_START },
2620 { .name = "pl310", .irq = 0 + OMAP44XX_IRQ_GIC_START }, 2619 { .name = "pl310", .irq = 0 + OMAP44XX_IRQ_GIC_START },
2621 { .name = "cti0", .irq = 1 + OMAP44XX_IRQ_GIC_START }, 2620 { .name = "cti0", .irq = 1 + OMAP44XX_IRQ_GIC_START },
2622 { .name = "cti1", .irq = 2 + OMAP44XX_IRQ_GIC_START }, 2621 { .name = "cti1", .irq = 2 + OMAP44XX_IRQ_GIC_START },
2623 { .irq = -1 } 2622 { .irq = -1 }
2624 }; 2623 };
2625 2624
2626 static struct omap_hwmod omap44xx_mpu_hwmod = { 2625 static struct omap_hwmod omap44xx_mpu_hwmod = {
2627 .name = "mpu", 2626 .name = "mpu",
2628 .class = &omap44xx_mpu_hwmod_class, 2627 .class = &omap44xx_mpu_hwmod_class,
2629 .clkdm_name = "mpuss_clkdm", 2628 .clkdm_name = "mpuss_clkdm",
2630 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET, 2629 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET,
2631 .mpu_irqs = omap44xx_mpu_irqs, 2630 .mpu_irqs = omap44xx_mpu_irqs,
2632 .main_clk = "dpll_mpu_m2_ck", 2631 .main_clk = "dpll_mpu_m2_ck",
2633 .prcm = { 2632 .prcm = {
2634 .omap4 = { 2633 .omap4 = {
2635 .clkctrl_offs = OMAP4_CM_MPU_MPU_CLKCTRL_OFFSET, 2634 .clkctrl_offs = OMAP4_CM_MPU_MPU_CLKCTRL_OFFSET,
2636 .context_offs = OMAP4_RM_MPU_MPU_CONTEXT_OFFSET, 2635 .context_offs = OMAP4_RM_MPU_MPU_CONTEXT_OFFSET,
2637 }, 2636 },
2638 }, 2637 },
2639 }; 2638 };
2640 2639
2641 /* 2640 /*
2642 * 'ocmc_ram' class 2641 * 'ocmc_ram' class
2643 * top-level core on-chip ram 2642 * top-level core on-chip ram
2644 */ 2643 */
2645 2644
2646 static struct omap_hwmod_class omap44xx_ocmc_ram_hwmod_class = { 2645 static struct omap_hwmod_class omap44xx_ocmc_ram_hwmod_class = {
2647 .name = "ocmc_ram", 2646 .name = "ocmc_ram",
2648 }; 2647 };
2649 2648
2650 /* ocmc_ram */ 2649 /* ocmc_ram */
2651 static struct omap_hwmod omap44xx_ocmc_ram_hwmod = { 2650 static struct omap_hwmod omap44xx_ocmc_ram_hwmod = {
2652 .name = "ocmc_ram", 2651 .name = "ocmc_ram",
2653 .class = &omap44xx_ocmc_ram_hwmod_class, 2652 .class = &omap44xx_ocmc_ram_hwmod_class,
2654 .clkdm_name = "l3_2_clkdm", 2653 .clkdm_name = "l3_2_clkdm",
2655 .prcm = { 2654 .prcm = {
2656 .omap4 = { 2655 .omap4 = {
2657 .clkctrl_offs = OMAP4_CM_L3_2_OCMC_RAM_CLKCTRL_OFFSET, 2656 .clkctrl_offs = OMAP4_CM_L3_2_OCMC_RAM_CLKCTRL_OFFSET,
2658 .context_offs = OMAP4_RM_L3_2_OCMC_RAM_CONTEXT_OFFSET, 2657 .context_offs = OMAP4_RM_L3_2_OCMC_RAM_CONTEXT_OFFSET,
2659 }, 2658 },
2660 }, 2659 },
2661 }; 2660 };
2662 2661
2663 /* 2662 /*
2664 * 'ocp2scp' class 2663 * 'ocp2scp' class
2665 * bridge to transform ocp interface protocol to scp (serial control port) 2664 * bridge to transform ocp interface protocol to scp (serial control port)
2666 * protocol 2665 * protocol
2667 */ 2666 */
2668 2667
2669 static struct omap_hwmod_class_sysconfig omap44xx_ocp2scp_sysc = { 2668 static struct omap_hwmod_class_sysconfig omap44xx_ocp2scp_sysc = {
2670 .rev_offs = 0x0000, 2669 .rev_offs = 0x0000,
2671 .sysc_offs = 0x0010, 2670 .sysc_offs = 0x0010,
2672 .syss_offs = 0x0014, 2671 .syss_offs = 0x0014,
2673 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE | 2672 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_SIDLEMODE |
2674 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 2673 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
2675 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 2674 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
2676 .sysc_fields = &omap_hwmod_sysc_type1, 2675 .sysc_fields = &omap_hwmod_sysc_type1,
2677 }; 2676 };
2678 2677
2679 static struct omap_hwmod_class omap44xx_ocp2scp_hwmod_class = { 2678 static struct omap_hwmod_class omap44xx_ocp2scp_hwmod_class = {
2680 .name = "ocp2scp", 2679 .name = "ocp2scp",
2681 .sysc = &omap44xx_ocp2scp_sysc, 2680 .sysc = &omap44xx_ocp2scp_sysc,
2682 }; 2681 };
2683 2682
2684 /* ocp2scp_usb_phy */ 2683 /* ocp2scp_usb_phy */
2685 static struct omap_hwmod omap44xx_ocp2scp_usb_phy_hwmod = { 2684 static struct omap_hwmod omap44xx_ocp2scp_usb_phy_hwmod = {
2686 .name = "ocp2scp_usb_phy", 2685 .name = "ocp2scp_usb_phy",
2687 .class = &omap44xx_ocp2scp_hwmod_class, 2686 .class = &omap44xx_ocp2scp_hwmod_class,
2688 .clkdm_name = "l3_init_clkdm", 2687 .clkdm_name = "l3_init_clkdm",
2689 .main_clk = "ocp2scp_usb_phy_phy_48m", 2688 .main_clk = "ocp2scp_usb_phy_phy_48m",
2690 .prcm = { 2689 .prcm = {
2691 .omap4 = { 2690 .omap4 = {
2692 .clkctrl_offs = OMAP4_CM_L3INIT_USBPHYOCP2SCP_CLKCTRL_OFFSET, 2691 .clkctrl_offs = OMAP4_CM_L3INIT_USBPHYOCP2SCP_CLKCTRL_OFFSET,
2693 .context_offs = OMAP4_RM_L3INIT_USBPHYOCP2SCP_CONTEXT_OFFSET, 2692 .context_offs = OMAP4_RM_L3INIT_USBPHYOCP2SCP_CONTEXT_OFFSET,
2694 .modulemode = MODULEMODE_HWCTRL, 2693 .modulemode = MODULEMODE_HWCTRL,
2695 }, 2694 },
2696 }, 2695 },
2697 }; 2696 };
2698 2697
2699 /* 2698 /*
2700 * 'prcm' class 2699 * 'prcm' class
2701 * power and reset manager (part of the prcm infrastructure) + clock manager 2 2700 * power and reset manager (part of the prcm infrastructure) + clock manager 2
2702 * + clock manager 1 (in always on power domain) + local prm in mpu 2701 * + clock manager 1 (in always on power domain) + local prm in mpu
2703 */ 2702 */
2704 2703
2705 static struct omap_hwmod_class omap44xx_prcm_hwmod_class = { 2704 static struct omap_hwmod_class omap44xx_prcm_hwmod_class = {
2706 .name = "prcm", 2705 .name = "prcm",
2707 }; 2706 };
2708 2707
2709 /* prcm_mpu */ 2708 /* prcm_mpu */
2710 static struct omap_hwmod omap44xx_prcm_mpu_hwmod = { 2709 static struct omap_hwmod omap44xx_prcm_mpu_hwmod = {
2711 .name = "prcm_mpu", 2710 .name = "prcm_mpu",
2712 .class = &omap44xx_prcm_hwmod_class, 2711 .class = &omap44xx_prcm_hwmod_class,
2713 .clkdm_name = "l4_wkup_clkdm", 2712 .clkdm_name = "l4_wkup_clkdm",
2714 .flags = HWMOD_NO_IDLEST, 2713 .flags = HWMOD_NO_IDLEST,
2715 .prcm = { 2714 .prcm = {
2716 .omap4 = { 2715 .omap4 = {
2717 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 2716 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
2718 }, 2717 },
2719 }, 2718 },
2720 }; 2719 };
2721 2720
2722 /* cm_core_aon */ 2721 /* cm_core_aon */
2723 static struct omap_hwmod omap44xx_cm_core_aon_hwmod = { 2722 static struct omap_hwmod omap44xx_cm_core_aon_hwmod = {
2724 .name = "cm_core_aon", 2723 .name = "cm_core_aon",
2725 .class = &omap44xx_prcm_hwmod_class, 2724 .class = &omap44xx_prcm_hwmod_class,
2726 .flags = HWMOD_NO_IDLEST, 2725 .flags = HWMOD_NO_IDLEST,
2727 .prcm = { 2726 .prcm = {
2728 .omap4 = { 2727 .omap4 = {
2729 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 2728 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
2730 }, 2729 },
2731 }, 2730 },
2732 }; 2731 };
2733 2732
2734 /* cm_core */ 2733 /* cm_core */
2735 static struct omap_hwmod omap44xx_cm_core_hwmod = { 2734 static struct omap_hwmod omap44xx_cm_core_hwmod = {
2736 .name = "cm_core", 2735 .name = "cm_core",
2737 .class = &omap44xx_prcm_hwmod_class, 2736 .class = &omap44xx_prcm_hwmod_class,
2738 .flags = HWMOD_NO_IDLEST, 2737 .flags = HWMOD_NO_IDLEST,
2739 .prcm = { 2738 .prcm = {
2740 .omap4 = { 2739 .omap4 = {
2741 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 2740 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
2742 }, 2741 },
2743 }, 2742 },
2744 }; 2743 };
2745 2744
2746 /* prm */ 2745 /* prm */
2747 static struct omap_hwmod_irq_info omap44xx_prm_irqs[] = { 2746 static struct omap_hwmod_irq_info omap44xx_prm_irqs[] = {
2748 { .irq = 11 + OMAP44XX_IRQ_GIC_START }, 2747 { .irq = 11 + OMAP44XX_IRQ_GIC_START },
2749 { .irq = -1 } 2748 { .irq = -1 }
2750 }; 2749 };
2751 2750
2752 static struct omap_hwmod_rst_info omap44xx_prm_resets[] = { 2751 static struct omap_hwmod_rst_info omap44xx_prm_resets[] = {
2753 { .name = "rst_global_warm_sw", .rst_shift = 0 }, 2752 { .name = "rst_global_warm_sw", .rst_shift = 0 },
2754 { .name = "rst_global_cold_sw", .rst_shift = 1 }, 2753 { .name = "rst_global_cold_sw", .rst_shift = 1 },
2755 }; 2754 };
2756 2755
2757 static struct omap_hwmod omap44xx_prm_hwmod = { 2756 static struct omap_hwmod omap44xx_prm_hwmod = {
2758 .name = "prm", 2757 .name = "prm",
2759 .class = &omap44xx_prcm_hwmod_class, 2758 .class = &omap44xx_prcm_hwmod_class,
2760 .mpu_irqs = omap44xx_prm_irqs, 2759 .mpu_irqs = omap44xx_prm_irqs,
2761 .rst_lines = omap44xx_prm_resets, 2760 .rst_lines = omap44xx_prm_resets,
2762 .rst_lines_cnt = ARRAY_SIZE(omap44xx_prm_resets), 2761 .rst_lines_cnt = ARRAY_SIZE(omap44xx_prm_resets),
2763 }; 2762 };
2764 2763
2765 /* 2764 /*
2766 * 'scrm' class 2765 * 'scrm' class
2767 * system clock and reset manager 2766 * system clock and reset manager
2768 */ 2767 */
2769 2768
2770 static struct omap_hwmod_class omap44xx_scrm_hwmod_class = { 2769 static struct omap_hwmod_class omap44xx_scrm_hwmod_class = {
2771 .name = "scrm", 2770 .name = "scrm",
2772 }; 2771 };
2773 2772
2774 /* scrm */ 2773 /* scrm */
2775 static struct omap_hwmod omap44xx_scrm_hwmod = { 2774 static struct omap_hwmod omap44xx_scrm_hwmod = {
2776 .name = "scrm", 2775 .name = "scrm",
2777 .class = &omap44xx_scrm_hwmod_class, 2776 .class = &omap44xx_scrm_hwmod_class,
2778 .clkdm_name = "l4_wkup_clkdm", 2777 .clkdm_name = "l4_wkup_clkdm",
2779 .prcm = { 2778 .prcm = {
2780 .omap4 = { 2779 .omap4 = {
2781 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 2780 .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT,
2782 }, 2781 },
2783 }, 2782 },
2784 }; 2783 };
2785 2784
2786 /* 2785 /*
2787 * 'sl2if' class 2786 * 'sl2if' class
2788 * shared level 2 memory interface 2787 * shared level 2 memory interface
2789 */ 2788 */
2790 2789
2791 static struct omap_hwmod_class omap44xx_sl2if_hwmod_class = { 2790 static struct omap_hwmod_class omap44xx_sl2if_hwmod_class = {
2792 .name = "sl2if", 2791 .name = "sl2if",
2793 }; 2792 };
2794 2793
2795 /* sl2if */ 2794 /* sl2if */
2796 static struct omap_hwmod omap44xx_sl2if_hwmod = { 2795 static struct omap_hwmod omap44xx_sl2if_hwmod = {
2797 .name = "sl2if", 2796 .name = "sl2if",
2798 .class = &omap44xx_sl2if_hwmod_class, 2797 .class = &omap44xx_sl2if_hwmod_class,
2799 .clkdm_name = "ivahd_clkdm", 2798 .clkdm_name = "ivahd_clkdm",
2800 .prcm = { 2799 .prcm = {
2801 .omap4 = { 2800 .omap4 = {
2802 .clkctrl_offs = OMAP4_CM_IVAHD_SL2_CLKCTRL_OFFSET, 2801 .clkctrl_offs = OMAP4_CM_IVAHD_SL2_CLKCTRL_OFFSET,
2803 .context_offs = OMAP4_RM_IVAHD_SL2_CONTEXT_OFFSET, 2802 .context_offs = OMAP4_RM_IVAHD_SL2_CONTEXT_OFFSET,
2804 .modulemode = MODULEMODE_HWCTRL, 2803 .modulemode = MODULEMODE_HWCTRL,
2805 }, 2804 },
2806 }, 2805 },
2807 }; 2806 };
2808 2807
2809 /* 2808 /*
2810 * 'slimbus' class 2809 * 'slimbus' class
2811 * bidirectional, multi-drop, multi-channel two-line serial interface between 2810 * bidirectional, multi-drop, multi-channel two-line serial interface between
2812 * the device and external components 2811 * the device and external components
2813 */ 2812 */
2814 2813
2815 static struct omap_hwmod_class_sysconfig omap44xx_slimbus_sysc = { 2814 static struct omap_hwmod_class_sysconfig omap44xx_slimbus_sysc = {
2816 .rev_offs = 0x0000, 2815 .rev_offs = 0x0000,
2817 .sysc_offs = 0x0010, 2816 .sysc_offs = 0x0010,
2818 .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE | 2817 .sysc_flags = (SYSC_HAS_RESET_STATUS | SYSC_HAS_SIDLEMODE |
2819 SYSC_HAS_SOFTRESET), 2818 SYSC_HAS_SOFTRESET),
2820 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 2819 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
2821 SIDLE_SMART_WKUP), 2820 SIDLE_SMART_WKUP),
2822 .sysc_fields = &omap_hwmod_sysc_type2, 2821 .sysc_fields = &omap_hwmod_sysc_type2,
2823 }; 2822 };
2824 2823
2825 static struct omap_hwmod_class omap44xx_slimbus_hwmod_class = { 2824 static struct omap_hwmod_class omap44xx_slimbus_hwmod_class = {
2826 .name = "slimbus", 2825 .name = "slimbus",
2827 .sysc = &omap44xx_slimbus_sysc, 2826 .sysc = &omap44xx_slimbus_sysc,
2828 }; 2827 };
2829 2828
2830 /* slimbus1 */ 2829 /* slimbus1 */
2831 static struct omap_hwmod_irq_info omap44xx_slimbus1_irqs[] = { 2830 static struct omap_hwmod_irq_info omap44xx_slimbus1_irqs[] = {
2832 { .irq = 97 + OMAP44XX_IRQ_GIC_START }, 2831 { .irq = 97 + OMAP44XX_IRQ_GIC_START },
2833 { .irq = -1 } 2832 { .irq = -1 }
2834 }; 2833 };
2835 2834
2836 static struct omap_hwmod_dma_info omap44xx_slimbus1_sdma_reqs[] = { 2835 static struct omap_hwmod_dma_info omap44xx_slimbus1_sdma_reqs[] = {
2837 { .name = "tx0", .dma_req = 84 + OMAP44XX_DMA_REQ_START }, 2836 { .name = "tx0", .dma_req = 84 + OMAP44XX_DMA_REQ_START },
2838 { .name = "tx1", .dma_req = 85 + OMAP44XX_DMA_REQ_START }, 2837 { .name = "tx1", .dma_req = 85 + OMAP44XX_DMA_REQ_START },
2839 { .name = "tx2", .dma_req = 86 + OMAP44XX_DMA_REQ_START }, 2838 { .name = "tx2", .dma_req = 86 + OMAP44XX_DMA_REQ_START },
2840 { .name = "tx3", .dma_req = 87 + OMAP44XX_DMA_REQ_START }, 2839 { .name = "tx3", .dma_req = 87 + OMAP44XX_DMA_REQ_START },
2841 { .name = "rx0", .dma_req = 88 + OMAP44XX_DMA_REQ_START }, 2840 { .name = "rx0", .dma_req = 88 + OMAP44XX_DMA_REQ_START },
2842 { .name = "rx1", .dma_req = 89 + OMAP44XX_DMA_REQ_START }, 2841 { .name = "rx1", .dma_req = 89 + OMAP44XX_DMA_REQ_START },
2843 { .name = "rx2", .dma_req = 90 + OMAP44XX_DMA_REQ_START }, 2842 { .name = "rx2", .dma_req = 90 + OMAP44XX_DMA_REQ_START },
2844 { .name = "rx3", .dma_req = 91 + OMAP44XX_DMA_REQ_START }, 2843 { .name = "rx3", .dma_req = 91 + OMAP44XX_DMA_REQ_START },
2845 { .dma_req = -1 } 2844 { .dma_req = -1 }
2846 }; 2845 };
2847 2846
2848 static struct omap_hwmod_opt_clk slimbus1_opt_clks[] = { 2847 static struct omap_hwmod_opt_clk slimbus1_opt_clks[] = {
2849 { .role = "fclk_1", .clk = "slimbus1_fclk_1" }, 2848 { .role = "fclk_1", .clk = "slimbus1_fclk_1" },
2850 { .role = "fclk_0", .clk = "slimbus1_fclk_0" }, 2849 { .role = "fclk_0", .clk = "slimbus1_fclk_0" },
2851 { .role = "fclk_2", .clk = "slimbus1_fclk_2" }, 2850 { .role = "fclk_2", .clk = "slimbus1_fclk_2" },
2852 { .role = "slimbus_clk", .clk = "slimbus1_slimbus_clk" }, 2851 { .role = "slimbus_clk", .clk = "slimbus1_slimbus_clk" },
2853 }; 2852 };
2854 2853
2855 static struct omap_hwmod omap44xx_slimbus1_hwmod = { 2854 static struct omap_hwmod omap44xx_slimbus1_hwmod = {
2856 .name = "slimbus1", 2855 .name = "slimbus1",
2857 .class = &omap44xx_slimbus_hwmod_class, 2856 .class = &omap44xx_slimbus_hwmod_class,
2858 .clkdm_name = "abe_clkdm", 2857 .clkdm_name = "abe_clkdm",
2859 .mpu_irqs = omap44xx_slimbus1_irqs, 2858 .mpu_irqs = omap44xx_slimbus1_irqs,
2860 .sdma_reqs = omap44xx_slimbus1_sdma_reqs, 2859 .sdma_reqs = omap44xx_slimbus1_sdma_reqs,
2861 .prcm = { 2860 .prcm = {
2862 .omap4 = { 2861 .omap4 = {
2863 .clkctrl_offs = OMAP4_CM1_ABE_SLIMBUS_CLKCTRL_OFFSET, 2862 .clkctrl_offs = OMAP4_CM1_ABE_SLIMBUS_CLKCTRL_OFFSET,
2864 .context_offs = OMAP4_RM_ABE_SLIMBUS_CONTEXT_OFFSET, 2863 .context_offs = OMAP4_RM_ABE_SLIMBUS_CONTEXT_OFFSET,
2865 .modulemode = MODULEMODE_SWCTRL, 2864 .modulemode = MODULEMODE_SWCTRL,
2866 }, 2865 },
2867 }, 2866 },
2868 .opt_clks = slimbus1_opt_clks, 2867 .opt_clks = slimbus1_opt_clks,
2869 .opt_clks_cnt = ARRAY_SIZE(slimbus1_opt_clks), 2868 .opt_clks_cnt = ARRAY_SIZE(slimbus1_opt_clks),
2870 }; 2869 };
2871 2870
2872 /* slimbus2 */ 2871 /* slimbus2 */
2873 static struct omap_hwmod_irq_info omap44xx_slimbus2_irqs[] = { 2872 static struct omap_hwmod_irq_info omap44xx_slimbus2_irqs[] = {
2874 { .irq = 98 + OMAP44XX_IRQ_GIC_START }, 2873 { .irq = 98 + OMAP44XX_IRQ_GIC_START },
2875 { .irq = -1 } 2874 { .irq = -1 }
2876 }; 2875 };
2877 2876
2878 static struct omap_hwmod_dma_info omap44xx_slimbus2_sdma_reqs[] = { 2877 static struct omap_hwmod_dma_info omap44xx_slimbus2_sdma_reqs[] = {
2879 { .name = "tx0", .dma_req = 92 + OMAP44XX_DMA_REQ_START }, 2878 { .name = "tx0", .dma_req = 92 + OMAP44XX_DMA_REQ_START },
2880 { .name = "tx1", .dma_req = 93 + OMAP44XX_DMA_REQ_START }, 2879 { .name = "tx1", .dma_req = 93 + OMAP44XX_DMA_REQ_START },
2881 { .name = "tx2", .dma_req = 94 + OMAP44XX_DMA_REQ_START }, 2880 { .name = "tx2", .dma_req = 94 + OMAP44XX_DMA_REQ_START },
2882 { .name = "tx3", .dma_req = 95 + OMAP44XX_DMA_REQ_START }, 2881 { .name = "tx3", .dma_req = 95 + OMAP44XX_DMA_REQ_START },
2883 { .name = "rx0", .dma_req = 96 + OMAP44XX_DMA_REQ_START }, 2882 { .name = "rx0", .dma_req = 96 + OMAP44XX_DMA_REQ_START },
2884 { .name = "rx1", .dma_req = 97 + OMAP44XX_DMA_REQ_START }, 2883 { .name = "rx1", .dma_req = 97 + OMAP44XX_DMA_REQ_START },
2885 { .name = "rx2", .dma_req = 98 + OMAP44XX_DMA_REQ_START }, 2884 { .name = "rx2", .dma_req = 98 + OMAP44XX_DMA_REQ_START },
2886 { .name = "rx3", .dma_req = 99 + OMAP44XX_DMA_REQ_START }, 2885 { .name = "rx3", .dma_req = 99 + OMAP44XX_DMA_REQ_START },
2887 { .dma_req = -1 } 2886 { .dma_req = -1 }
2888 }; 2887 };
2889 2888
2890 static struct omap_hwmod_opt_clk slimbus2_opt_clks[] = { 2889 static struct omap_hwmod_opt_clk slimbus2_opt_clks[] = {
2891 { .role = "fclk_1", .clk = "slimbus2_fclk_1" }, 2890 { .role = "fclk_1", .clk = "slimbus2_fclk_1" },
2892 { .role = "fclk_0", .clk = "slimbus2_fclk_0" }, 2891 { .role = "fclk_0", .clk = "slimbus2_fclk_0" },
2893 { .role = "slimbus_clk", .clk = "slimbus2_slimbus_clk" }, 2892 { .role = "slimbus_clk", .clk = "slimbus2_slimbus_clk" },
2894 }; 2893 };
2895 2894
2896 static struct omap_hwmod omap44xx_slimbus2_hwmod = { 2895 static struct omap_hwmod omap44xx_slimbus2_hwmod = {
2897 .name = "slimbus2", 2896 .name = "slimbus2",
2898 .class = &omap44xx_slimbus_hwmod_class, 2897 .class = &omap44xx_slimbus_hwmod_class,
2899 .clkdm_name = "l4_per_clkdm", 2898 .clkdm_name = "l4_per_clkdm",
2900 .mpu_irqs = omap44xx_slimbus2_irqs, 2899 .mpu_irqs = omap44xx_slimbus2_irqs,
2901 .sdma_reqs = omap44xx_slimbus2_sdma_reqs, 2900 .sdma_reqs = omap44xx_slimbus2_sdma_reqs,
2902 .prcm = { 2901 .prcm = {
2903 .omap4 = { 2902 .omap4 = {
2904 .clkctrl_offs = OMAP4_CM_L4PER_SLIMBUS2_CLKCTRL_OFFSET, 2903 .clkctrl_offs = OMAP4_CM_L4PER_SLIMBUS2_CLKCTRL_OFFSET,
2905 .context_offs = OMAP4_RM_L4PER_SLIMBUS2_CONTEXT_OFFSET, 2904 .context_offs = OMAP4_RM_L4PER_SLIMBUS2_CONTEXT_OFFSET,
2906 .modulemode = MODULEMODE_SWCTRL, 2905 .modulemode = MODULEMODE_SWCTRL,
2907 }, 2906 },
2908 }, 2907 },
2909 .opt_clks = slimbus2_opt_clks, 2908 .opt_clks = slimbus2_opt_clks,
2910 .opt_clks_cnt = ARRAY_SIZE(slimbus2_opt_clks), 2909 .opt_clks_cnt = ARRAY_SIZE(slimbus2_opt_clks),
2911 }; 2910 };
2912 2911
2913 /* 2912 /*
2914 * 'smartreflex' class 2913 * 'smartreflex' class
2915 * smartreflex module (monitor silicon performance and outputs a measure of 2914 * smartreflex module (monitor silicon performance and outputs a measure of
2916 * performance error) 2915 * performance error)
2917 */ 2916 */
2918 2917
2919 /* The IP is not compliant to type1 / type2 scheme */ 2918 /* The IP is not compliant to type1 / type2 scheme */
2920 static struct omap_hwmod_sysc_fields omap_hwmod_sysc_type_smartreflex = { 2919 static struct omap_hwmod_sysc_fields omap_hwmod_sysc_type_smartreflex = {
2921 .sidle_shift = 24, 2920 .sidle_shift = 24,
2922 .enwkup_shift = 26, 2921 .enwkup_shift = 26,
2923 }; 2922 };
2924 2923
2925 static struct omap_hwmod_class_sysconfig omap44xx_smartreflex_sysc = { 2924 static struct omap_hwmod_class_sysconfig omap44xx_smartreflex_sysc = {
2926 .sysc_offs = 0x0038, 2925 .sysc_offs = 0x0038,
2927 .sysc_flags = (SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE), 2926 .sysc_flags = (SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE),
2928 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 2927 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
2929 SIDLE_SMART_WKUP), 2928 SIDLE_SMART_WKUP),
2930 .sysc_fields = &omap_hwmod_sysc_type_smartreflex, 2929 .sysc_fields = &omap_hwmod_sysc_type_smartreflex,
2931 }; 2930 };
2932 2931
2933 static struct omap_hwmod_class omap44xx_smartreflex_hwmod_class = { 2932 static struct omap_hwmod_class omap44xx_smartreflex_hwmod_class = {
2934 .name = "smartreflex", 2933 .name = "smartreflex",
2935 .sysc = &omap44xx_smartreflex_sysc, 2934 .sysc = &omap44xx_smartreflex_sysc,
2936 .rev = 2, 2935 .rev = 2,
2937 }; 2936 };
2938 2937
2939 /* smartreflex_core */ 2938 /* smartreflex_core */
2940 static struct omap_smartreflex_dev_attr smartreflex_core_dev_attr = { 2939 static struct omap_smartreflex_dev_attr smartreflex_core_dev_attr = {
2941 .sensor_voltdm_name = "core", 2940 .sensor_voltdm_name = "core",
2942 }; 2941 };
2943 2942
2944 static struct omap_hwmod_irq_info omap44xx_smartreflex_core_irqs[] = { 2943 static struct omap_hwmod_irq_info omap44xx_smartreflex_core_irqs[] = {
2945 { .irq = 19 + OMAP44XX_IRQ_GIC_START }, 2944 { .irq = 19 + OMAP44XX_IRQ_GIC_START },
2946 { .irq = -1 } 2945 { .irq = -1 }
2947 }; 2946 };
2948 2947
2949 static struct omap_hwmod omap44xx_smartreflex_core_hwmod = { 2948 static struct omap_hwmod omap44xx_smartreflex_core_hwmod = {
2950 .name = "smartreflex_core", 2949 .name = "smartreflex_core",
2951 .class = &omap44xx_smartreflex_hwmod_class, 2950 .class = &omap44xx_smartreflex_hwmod_class,
2952 .clkdm_name = "l4_ao_clkdm", 2951 .clkdm_name = "l4_ao_clkdm",
2953 .mpu_irqs = omap44xx_smartreflex_core_irqs, 2952 .mpu_irqs = omap44xx_smartreflex_core_irqs,
2954 2953
2955 .main_clk = "smartreflex_core_fck", 2954 .main_clk = "smartreflex_core_fck",
2956 .prcm = { 2955 .prcm = {
2957 .omap4 = { 2956 .omap4 = {
2958 .clkctrl_offs = OMAP4_CM_ALWON_SR_CORE_CLKCTRL_OFFSET, 2957 .clkctrl_offs = OMAP4_CM_ALWON_SR_CORE_CLKCTRL_OFFSET,
2959 .context_offs = OMAP4_RM_ALWON_SR_CORE_CONTEXT_OFFSET, 2958 .context_offs = OMAP4_RM_ALWON_SR_CORE_CONTEXT_OFFSET,
2960 .modulemode = MODULEMODE_SWCTRL, 2959 .modulemode = MODULEMODE_SWCTRL,
2961 }, 2960 },
2962 }, 2961 },
2963 .dev_attr = &smartreflex_core_dev_attr, 2962 .dev_attr = &smartreflex_core_dev_attr,
2964 }; 2963 };
2965 2964
2966 /* smartreflex_iva */ 2965 /* smartreflex_iva */
2967 static struct omap_smartreflex_dev_attr smartreflex_iva_dev_attr = { 2966 static struct omap_smartreflex_dev_attr smartreflex_iva_dev_attr = {
2968 .sensor_voltdm_name = "iva", 2967 .sensor_voltdm_name = "iva",
2969 }; 2968 };
2970 2969
2971 static struct omap_hwmod_irq_info omap44xx_smartreflex_iva_irqs[] = { 2970 static struct omap_hwmod_irq_info omap44xx_smartreflex_iva_irqs[] = {
2972 { .irq = 102 + OMAP44XX_IRQ_GIC_START }, 2971 { .irq = 102 + OMAP44XX_IRQ_GIC_START },
2973 { .irq = -1 } 2972 { .irq = -1 }
2974 }; 2973 };
2975 2974
2976 static struct omap_hwmod omap44xx_smartreflex_iva_hwmod = { 2975 static struct omap_hwmod omap44xx_smartreflex_iva_hwmod = {
2977 .name = "smartreflex_iva", 2976 .name = "smartreflex_iva",
2978 .class = &omap44xx_smartreflex_hwmod_class, 2977 .class = &omap44xx_smartreflex_hwmod_class,
2979 .clkdm_name = "l4_ao_clkdm", 2978 .clkdm_name = "l4_ao_clkdm",
2980 .mpu_irqs = omap44xx_smartreflex_iva_irqs, 2979 .mpu_irqs = omap44xx_smartreflex_iva_irqs,
2981 .main_clk = "smartreflex_iva_fck", 2980 .main_clk = "smartreflex_iva_fck",
2982 .prcm = { 2981 .prcm = {
2983 .omap4 = { 2982 .omap4 = {
2984 .clkctrl_offs = OMAP4_CM_ALWON_SR_IVA_CLKCTRL_OFFSET, 2983 .clkctrl_offs = OMAP4_CM_ALWON_SR_IVA_CLKCTRL_OFFSET,
2985 .context_offs = OMAP4_RM_ALWON_SR_IVA_CONTEXT_OFFSET, 2984 .context_offs = OMAP4_RM_ALWON_SR_IVA_CONTEXT_OFFSET,
2986 .modulemode = MODULEMODE_SWCTRL, 2985 .modulemode = MODULEMODE_SWCTRL,
2987 }, 2986 },
2988 }, 2987 },
2989 .dev_attr = &smartreflex_iva_dev_attr, 2988 .dev_attr = &smartreflex_iva_dev_attr,
2990 }; 2989 };
2991 2990
2992 /* smartreflex_mpu */ 2991 /* smartreflex_mpu */
2993 static struct omap_smartreflex_dev_attr smartreflex_mpu_dev_attr = { 2992 static struct omap_smartreflex_dev_attr smartreflex_mpu_dev_attr = {
2994 .sensor_voltdm_name = "mpu", 2993 .sensor_voltdm_name = "mpu",
2995 }; 2994 };
2996 2995
2997 static struct omap_hwmod_irq_info omap44xx_smartreflex_mpu_irqs[] = { 2996 static struct omap_hwmod_irq_info omap44xx_smartreflex_mpu_irqs[] = {
2998 { .irq = 18 + OMAP44XX_IRQ_GIC_START }, 2997 { .irq = 18 + OMAP44XX_IRQ_GIC_START },
2999 { .irq = -1 } 2998 { .irq = -1 }
3000 }; 2999 };
3001 3000
3002 static struct omap_hwmod omap44xx_smartreflex_mpu_hwmod = { 3001 static struct omap_hwmod omap44xx_smartreflex_mpu_hwmod = {
3003 .name = "smartreflex_mpu", 3002 .name = "smartreflex_mpu",
3004 .class = &omap44xx_smartreflex_hwmod_class, 3003 .class = &omap44xx_smartreflex_hwmod_class,
3005 .clkdm_name = "l4_ao_clkdm", 3004 .clkdm_name = "l4_ao_clkdm",
3006 .mpu_irqs = omap44xx_smartreflex_mpu_irqs, 3005 .mpu_irqs = omap44xx_smartreflex_mpu_irqs,
3007 .main_clk = "smartreflex_mpu_fck", 3006 .main_clk = "smartreflex_mpu_fck",
3008 .prcm = { 3007 .prcm = {
3009 .omap4 = { 3008 .omap4 = {
3010 .clkctrl_offs = OMAP4_CM_ALWON_SR_MPU_CLKCTRL_OFFSET, 3009 .clkctrl_offs = OMAP4_CM_ALWON_SR_MPU_CLKCTRL_OFFSET,
3011 .context_offs = OMAP4_RM_ALWON_SR_MPU_CONTEXT_OFFSET, 3010 .context_offs = OMAP4_RM_ALWON_SR_MPU_CONTEXT_OFFSET,
3012 .modulemode = MODULEMODE_SWCTRL, 3011 .modulemode = MODULEMODE_SWCTRL,
3013 }, 3012 },
3014 }, 3013 },
3015 .dev_attr = &smartreflex_mpu_dev_attr, 3014 .dev_attr = &smartreflex_mpu_dev_attr,
3016 }; 3015 };
3017 3016
3018 /* 3017 /*
3019 * 'spinlock' class 3018 * 'spinlock' class
3020 * spinlock provides hardware assistance for synchronizing the processes 3019 * spinlock provides hardware assistance for synchronizing the processes
3021 * running on multiple processors 3020 * running on multiple processors
3022 */ 3021 */
3023 3022
3024 static struct omap_hwmod_class_sysconfig omap44xx_spinlock_sysc = { 3023 static struct omap_hwmod_class_sysconfig omap44xx_spinlock_sysc = {
3025 .rev_offs = 0x0000, 3024 .rev_offs = 0x0000,
3026 .sysc_offs = 0x0010, 3025 .sysc_offs = 0x0010,
3027 .syss_offs = 0x0014, 3026 .syss_offs = 0x0014,
3028 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY | 3027 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
3029 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE | 3028 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SIDLEMODE |
3030 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 3029 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
3031 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 3030 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
3032 SIDLE_SMART_WKUP), 3031 SIDLE_SMART_WKUP),
3033 .sysc_fields = &omap_hwmod_sysc_type1, 3032 .sysc_fields = &omap_hwmod_sysc_type1,
3034 }; 3033 };
3035 3034
3036 static struct omap_hwmod_class omap44xx_spinlock_hwmod_class = { 3035 static struct omap_hwmod_class omap44xx_spinlock_hwmod_class = {
3037 .name = "spinlock", 3036 .name = "spinlock",
3038 .sysc = &omap44xx_spinlock_sysc, 3037 .sysc = &omap44xx_spinlock_sysc,
3039 }; 3038 };
3040 3039
3041 /* spinlock */ 3040 /* spinlock */
3042 static struct omap_hwmod omap44xx_spinlock_hwmod = { 3041 static struct omap_hwmod omap44xx_spinlock_hwmod = {
3043 .name = "spinlock", 3042 .name = "spinlock",
3044 .class = &omap44xx_spinlock_hwmod_class, 3043 .class = &omap44xx_spinlock_hwmod_class,
3045 .clkdm_name = "l4_cfg_clkdm", 3044 .clkdm_name = "l4_cfg_clkdm",
3046 .prcm = { 3045 .prcm = {
3047 .omap4 = { 3046 .omap4 = {
3048 .clkctrl_offs = OMAP4_CM_L4CFG_HW_SEM_CLKCTRL_OFFSET, 3047 .clkctrl_offs = OMAP4_CM_L4CFG_HW_SEM_CLKCTRL_OFFSET,
3049 .context_offs = OMAP4_RM_L4CFG_HW_SEM_CONTEXT_OFFSET, 3048 .context_offs = OMAP4_RM_L4CFG_HW_SEM_CONTEXT_OFFSET,
3050 }, 3049 },
3051 }, 3050 },
3052 }; 3051 };
3053 3052
3054 /* 3053 /*
3055 * 'timer' class 3054 * 'timer' class
3056 * general purpose timer module with accurate 1ms tick 3055 * general purpose timer module with accurate 1ms tick
3057 * This class contains several variants: ['timer_1ms', 'timer'] 3056 * This class contains several variants: ['timer_1ms', 'timer']
3058 */ 3057 */
3059 3058
3060 static struct omap_hwmod_class_sysconfig omap44xx_timer_1ms_sysc = { 3059 static struct omap_hwmod_class_sysconfig omap44xx_timer_1ms_sysc = {
3061 .rev_offs = 0x0000, 3060 .rev_offs = 0x0000,
3062 .sysc_offs = 0x0010, 3061 .sysc_offs = 0x0010,
3063 .syss_offs = 0x0014, 3062 .syss_offs = 0x0014,
3064 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY | 3063 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_CLOCKACTIVITY |
3065 SYSC_HAS_EMUFREE | SYSC_HAS_ENAWAKEUP | 3064 SYSC_HAS_EMUFREE | SYSC_HAS_ENAWAKEUP |
3066 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET | 3065 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
3067 SYSS_HAS_RESET_STATUS), 3066 SYSS_HAS_RESET_STATUS),
3068 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 3067 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
3069 .sysc_fields = &omap_hwmod_sysc_type1, 3068 .sysc_fields = &omap_hwmod_sysc_type1,
3070 }; 3069 };
3071 3070
3072 static struct omap_hwmod_class omap44xx_timer_1ms_hwmod_class = { 3071 static struct omap_hwmod_class omap44xx_timer_1ms_hwmod_class = {
3073 .name = "timer", 3072 .name = "timer",
3074 .sysc = &omap44xx_timer_1ms_sysc, 3073 .sysc = &omap44xx_timer_1ms_sysc,
3075 }; 3074 };
3076 3075
3077 static struct omap_hwmod_class_sysconfig omap44xx_timer_sysc = { 3076 static struct omap_hwmod_class_sysconfig omap44xx_timer_sysc = {
3078 .rev_offs = 0x0000, 3077 .rev_offs = 0x0000,
3079 .sysc_offs = 0x0010, 3078 .sysc_offs = 0x0010,
3080 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS | 3079 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_RESET_STATUS |
3081 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET), 3080 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
3082 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 3081 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
3083 SIDLE_SMART_WKUP), 3082 SIDLE_SMART_WKUP),
3084 .sysc_fields = &omap_hwmod_sysc_type2, 3083 .sysc_fields = &omap_hwmod_sysc_type2,
3085 }; 3084 };
3086 3085
3087 static struct omap_hwmod_class omap44xx_timer_hwmod_class = { 3086 static struct omap_hwmod_class omap44xx_timer_hwmod_class = {
3088 .name = "timer", 3087 .name = "timer",
3089 .sysc = &omap44xx_timer_sysc, 3088 .sysc = &omap44xx_timer_sysc,
3090 }; 3089 };
3091 3090
3092 /* always-on timers dev attribute */ 3091 /* always-on timers dev attribute */
3093 static struct omap_timer_capability_dev_attr capability_alwon_dev_attr = { 3092 static struct omap_timer_capability_dev_attr capability_alwon_dev_attr = {
3094 .timer_capability = OMAP_TIMER_ALWON, 3093 .timer_capability = OMAP_TIMER_ALWON,
3095 }; 3094 };
3096 3095
3097 /* pwm timers dev attribute */ 3096 /* pwm timers dev attribute */
3098 static struct omap_timer_capability_dev_attr capability_pwm_dev_attr = { 3097 static struct omap_timer_capability_dev_attr capability_pwm_dev_attr = {
3099 .timer_capability = OMAP_TIMER_HAS_PWM, 3098 .timer_capability = OMAP_TIMER_HAS_PWM,
3100 }; 3099 };
3101 3100
3102 /* timers with DSP interrupt dev attribute */ 3101 /* timers with DSP interrupt dev attribute */
3103 static struct omap_timer_capability_dev_attr capability_dsp_dev_attr = { 3102 static struct omap_timer_capability_dev_attr capability_dsp_dev_attr = {
3104 .timer_capability = OMAP_TIMER_HAS_DSP_IRQ, 3103 .timer_capability = OMAP_TIMER_HAS_DSP_IRQ,
3105 }; 3104 };
3106 3105
3107 /* pwm timers with DSP interrupt dev attribute */ 3106 /* pwm timers with DSP interrupt dev attribute */
3108 static struct omap_timer_capability_dev_attr capability_dsp_pwm_dev_attr = { 3107 static struct omap_timer_capability_dev_attr capability_dsp_pwm_dev_attr = {
3109 .timer_capability = OMAP_TIMER_HAS_DSP_IRQ | OMAP_TIMER_HAS_PWM, 3108 .timer_capability = OMAP_TIMER_HAS_DSP_IRQ | OMAP_TIMER_HAS_PWM,
3110 }; 3109 };
3111 3110
3112 /* timer1 */ 3111 /* timer1 */
3113 static struct omap_hwmod_irq_info omap44xx_timer1_irqs[] = { 3112 static struct omap_hwmod_irq_info omap44xx_timer1_irqs[] = {
3114 { .irq = 37 + OMAP44XX_IRQ_GIC_START }, 3113 { .irq = 37 + OMAP44XX_IRQ_GIC_START },
3115 { .irq = -1 } 3114 { .irq = -1 }
3116 }; 3115 };
3117 3116
3118 static struct omap_hwmod omap44xx_timer1_hwmod = { 3117 static struct omap_hwmod omap44xx_timer1_hwmod = {
3119 .name = "timer1", 3118 .name = "timer1",
3120 .class = &omap44xx_timer_1ms_hwmod_class, 3119 .class = &omap44xx_timer_1ms_hwmod_class,
3121 .clkdm_name = "l4_wkup_clkdm", 3120 .clkdm_name = "l4_wkup_clkdm",
3122 .mpu_irqs = omap44xx_timer1_irqs, 3121 .mpu_irqs = omap44xx_timer1_irqs,
3123 .main_clk = "timer1_fck", 3122 .main_clk = "timer1_fck",
3124 .prcm = { 3123 .prcm = {
3125 .omap4 = { 3124 .omap4 = {
3126 .clkctrl_offs = OMAP4_CM_WKUP_TIMER1_CLKCTRL_OFFSET, 3125 .clkctrl_offs = OMAP4_CM_WKUP_TIMER1_CLKCTRL_OFFSET,
3127 .context_offs = OMAP4_RM_WKUP_TIMER1_CONTEXT_OFFSET, 3126 .context_offs = OMAP4_RM_WKUP_TIMER1_CONTEXT_OFFSET,
3128 .modulemode = MODULEMODE_SWCTRL, 3127 .modulemode = MODULEMODE_SWCTRL,
3129 }, 3128 },
3130 }, 3129 },
3131 .dev_attr = &capability_alwon_dev_attr, 3130 .dev_attr = &capability_alwon_dev_attr,
3132 }; 3131 };
3133 3132
3134 /* timer2 */ 3133 /* timer2 */
3135 static struct omap_hwmod_irq_info omap44xx_timer2_irqs[] = { 3134 static struct omap_hwmod_irq_info omap44xx_timer2_irqs[] = {
3136 { .irq = 38 + OMAP44XX_IRQ_GIC_START }, 3135 { .irq = 38 + OMAP44XX_IRQ_GIC_START },
3137 { .irq = -1 } 3136 { .irq = -1 }
3138 }; 3137 };
3139 3138
3140 static struct omap_hwmod omap44xx_timer2_hwmod = { 3139 static struct omap_hwmod omap44xx_timer2_hwmod = {
3141 .name = "timer2", 3140 .name = "timer2",
3142 .class = &omap44xx_timer_1ms_hwmod_class, 3141 .class = &omap44xx_timer_1ms_hwmod_class,
3143 .clkdm_name = "l4_per_clkdm", 3142 .clkdm_name = "l4_per_clkdm",
3144 .mpu_irqs = omap44xx_timer2_irqs, 3143 .mpu_irqs = omap44xx_timer2_irqs,
3145 .main_clk = "timer2_fck", 3144 .main_clk = "timer2_fck",
3146 .prcm = { 3145 .prcm = {
3147 .omap4 = { 3146 .omap4 = {
3148 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER2_CLKCTRL_OFFSET, 3147 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER2_CLKCTRL_OFFSET,
3149 .context_offs = OMAP4_RM_L4PER_DMTIMER2_CONTEXT_OFFSET, 3148 .context_offs = OMAP4_RM_L4PER_DMTIMER2_CONTEXT_OFFSET,
3150 .modulemode = MODULEMODE_SWCTRL, 3149 .modulemode = MODULEMODE_SWCTRL,
3151 }, 3150 },
3152 }, 3151 },
3153 }; 3152 };
3154 3153
3155 /* timer3 */ 3154 /* timer3 */
3156 static struct omap_hwmod_irq_info omap44xx_timer3_irqs[] = { 3155 static struct omap_hwmod_irq_info omap44xx_timer3_irqs[] = {
3157 { .irq = 39 + OMAP44XX_IRQ_GIC_START }, 3156 { .irq = 39 + OMAP44XX_IRQ_GIC_START },
3158 { .irq = -1 } 3157 { .irq = -1 }
3159 }; 3158 };
3160 3159
3161 static struct omap_hwmod omap44xx_timer3_hwmod = { 3160 static struct omap_hwmod omap44xx_timer3_hwmod = {
3162 .name = "timer3", 3161 .name = "timer3",
3163 .class = &omap44xx_timer_hwmod_class, 3162 .class = &omap44xx_timer_hwmod_class,
3164 .clkdm_name = "l4_per_clkdm", 3163 .clkdm_name = "l4_per_clkdm",
3165 .mpu_irqs = omap44xx_timer3_irqs, 3164 .mpu_irqs = omap44xx_timer3_irqs,
3166 .main_clk = "timer3_fck", 3165 .main_clk = "timer3_fck",
3167 .prcm = { 3166 .prcm = {
3168 .omap4 = { 3167 .omap4 = {
3169 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER3_CLKCTRL_OFFSET, 3168 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER3_CLKCTRL_OFFSET,
3170 .context_offs = OMAP4_RM_L4PER_DMTIMER3_CONTEXT_OFFSET, 3169 .context_offs = OMAP4_RM_L4PER_DMTIMER3_CONTEXT_OFFSET,
3171 .modulemode = MODULEMODE_SWCTRL, 3170 .modulemode = MODULEMODE_SWCTRL,
3172 }, 3171 },
3173 }, 3172 },
3174 }; 3173 };
3175 3174
3176 /* timer4 */ 3175 /* timer4 */
3177 static struct omap_hwmod_irq_info omap44xx_timer4_irqs[] = { 3176 static struct omap_hwmod_irq_info omap44xx_timer4_irqs[] = {
3178 { .irq = 40 + OMAP44XX_IRQ_GIC_START }, 3177 { .irq = 40 + OMAP44XX_IRQ_GIC_START },
3179 { .irq = -1 } 3178 { .irq = -1 }
3180 }; 3179 };
3181 3180
3182 static struct omap_hwmod omap44xx_timer4_hwmod = { 3181 static struct omap_hwmod omap44xx_timer4_hwmod = {
3183 .name = "timer4", 3182 .name = "timer4",
3184 .class = &omap44xx_timer_hwmod_class, 3183 .class = &omap44xx_timer_hwmod_class,
3185 .clkdm_name = "l4_per_clkdm", 3184 .clkdm_name = "l4_per_clkdm",
3186 .mpu_irqs = omap44xx_timer4_irqs, 3185 .mpu_irqs = omap44xx_timer4_irqs,
3187 .main_clk = "timer4_fck", 3186 .main_clk = "timer4_fck",
3188 .prcm = { 3187 .prcm = {
3189 .omap4 = { 3188 .omap4 = {
3190 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER4_CLKCTRL_OFFSET, 3189 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER4_CLKCTRL_OFFSET,
3191 .context_offs = OMAP4_RM_L4PER_DMTIMER4_CONTEXT_OFFSET, 3190 .context_offs = OMAP4_RM_L4PER_DMTIMER4_CONTEXT_OFFSET,
3192 .modulemode = MODULEMODE_SWCTRL, 3191 .modulemode = MODULEMODE_SWCTRL,
3193 }, 3192 },
3194 }, 3193 },
3195 }; 3194 };
3196 3195
3197 /* timer5 */ 3196 /* timer5 */
3198 static struct omap_hwmod_irq_info omap44xx_timer5_irqs[] = { 3197 static struct omap_hwmod_irq_info omap44xx_timer5_irqs[] = {
3199 { .irq = 41 + OMAP44XX_IRQ_GIC_START }, 3198 { .irq = 41 + OMAP44XX_IRQ_GIC_START },
3200 { .irq = -1 } 3199 { .irq = -1 }
3201 }; 3200 };
3202 3201
3203 static struct omap_hwmod omap44xx_timer5_hwmod = { 3202 static struct omap_hwmod omap44xx_timer5_hwmod = {
3204 .name = "timer5", 3203 .name = "timer5",
3205 .class = &omap44xx_timer_hwmod_class, 3204 .class = &omap44xx_timer_hwmod_class,
3206 .clkdm_name = "abe_clkdm", 3205 .clkdm_name = "abe_clkdm",
3207 .mpu_irqs = omap44xx_timer5_irqs, 3206 .mpu_irqs = omap44xx_timer5_irqs,
3208 .main_clk = "timer5_fck", 3207 .main_clk = "timer5_fck",
3209 .prcm = { 3208 .prcm = {
3210 .omap4 = { 3209 .omap4 = {
3211 .clkctrl_offs = OMAP4_CM1_ABE_TIMER5_CLKCTRL_OFFSET, 3210 .clkctrl_offs = OMAP4_CM1_ABE_TIMER5_CLKCTRL_OFFSET,
3212 .context_offs = OMAP4_RM_ABE_TIMER5_CONTEXT_OFFSET, 3211 .context_offs = OMAP4_RM_ABE_TIMER5_CONTEXT_OFFSET,
3213 .modulemode = MODULEMODE_SWCTRL, 3212 .modulemode = MODULEMODE_SWCTRL,
3214 }, 3213 },
3215 }, 3214 },
3216 .dev_attr = &capability_dsp_dev_attr, 3215 .dev_attr = &capability_dsp_dev_attr,
3217 }; 3216 };
3218 3217
3219 /* timer6 */ 3218 /* timer6 */
3220 static struct omap_hwmod_irq_info omap44xx_timer6_irqs[] = { 3219 static struct omap_hwmod_irq_info omap44xx_timer6_irqs[] = {
3221 { .irq = 42 + OMAP44XX_IRQ_GIC_START }, 3220 { .irq = 42 + OMAP44XX_IRQ_GIC_START },
3222 { .irq = -1 } 3221 { .irq = -1 }
3223 }; 3222 };
3224 3223
3225 static struct omap_hwmod omap44xx_timer6_hwmod = { 3224 static struct omap_hwmod omap44xx_timer6_hwmod = {
3226 .name = "timer6", 3225 .name = "timer6",
3227 .class = &omap44xx_timer_hwmod_class, 3226 .class = &omap44xx_timer_hwmod_class,
3228 .clkdm_name = "abe_clkdm", 3227 .clkdm_name = "abe_clkdm",
3229 .mpu_irqs = omap44xx_timer6_irqs, 3228 .mpu_irqs = omap44xx_timer6_irqs,
3230 3229
3231 .main_clk = "timer6_fck", 3230 .main_clk = "timer6_fck",
3232 .prcm = { 3231 .prcm = {
3233 .omap4 = { 3232 .omap4 = {
3234 .clkctrl_offs = OMAP4_CM1_ABE_TIMER6_CLKCTRL_OFFSET, 3233 .clkctrl_offs = OMAP4_CM1_ABE_TIMER6_CLKCTRL_OFFSET,
3235 .context_offs = OMAP4_RM_ABE_TIMER6_CONTEXT_OFFSET, 3234 .context_offs = OMAP4_RM_ABE_TIMER6_CONTEXT_OFFSET,
3236 .modulemode = MODULEMODE_SWCTRL, 3235 .modulemode = MODULEMODE_SWCTRL,
3237 }, 3236 },
3238 }, 3237 },
3239 .dev_attr = &capability_dsp_dev_attr, 3238 .dev_attr = &capability_dsp_dev_attr,
3240 }; 3239 };
3241 3240
3242 /* timer7 */ 3241 /* timer7 */
3243 static struct omap_hwmod_irq_info omap44xx_timer7_irqs[] = { 3242 static struct omap_hwmod_irq_info omap44xx_timer7_irqs[] = {
3244 { .irq = 43 + OMAP44XX_IRQ_GIC_START }, 3243 { .irq = 43 + OMAP44XX_IRQ_GIC_START },
3245 { .irq = -1 } 3244 { .irq = -1 }
3246 }; 3245 };
3247 3246
3248 static struct omap_hwmod omap44xx_timer7_hwmod = { 3247 static struct omap_hwmod omap44xx_timer7_hwmod = {
3249 .name = "timer7", 3248 .name = "timer7",
3250 .class = &omap44xx_timer_hwmod_class, 3249 .class = &omap44xx_timer_hwmod_class,
3251 .clkdm_name = "abe_clkdm", 3250 .clkdm_name = "abe_clkdm",
3252 .mpu_irqs = omap44xx_timer7_irqs, 3251 .mpu_irqs = omap44xx_timer7_irqs,
3253 .main_clk = "timer7_fck", 3252 .main_clk = "timer7_fck",
3254 .prcm = { 3253 .prcm = {
3255 .omap4 = { 3254 .omap4 = {
3256 .clkctrl_offs = OMAP4_CM1_ABE_TIMER7_CLKCTRL_OFFSET, 3255 .clkctrl_offs = OMAP4_CM1_ABE_TIMER7_CLKCTRL_OFFSET,
3257 .context_offs = OMAP4_RM_ABE_TIMER7_CONTEXT_OFFSET, 3256 .context_offs = OMAP4_RM_ABE_TIMER7_CONTEXT_OFFSET,
3258 .modulemode = MODULEMODE_SWCTRL, 3257 .modulemode = MODULEMODE_SWCTRL,
3259 }, 3258 },
3260 }, 3259 },
3261 .dev_attr = &capability_dsp_dev_attr, 3260 .dev_attr = &capability_dsp_dev_attr,
3262 }; 3261 };
3263 3262
3264 /* timer8 */ 3263 /* timer8 */
3265 static struct omap_hwmod_irq_info omap44xx_timer8_irqs[] = { 3264 static struct omap_hwmod_irq_info omap44xx_timer8_irqs[] = {
3266 { .irq = 44 + OMAP44XX_IRQ_GIC_START }, 3265 { .irq = 44 + OMAP44XX_IRQ_GIC_START },
3267 { .irq = -1 } 3266 { .irq = -1 }
3268 }; 3267 };
3269 3268
3270 static struct omap_hwmod omap44xx_timer8_hwmod = { 3269 static struct omap_hwmod omap44xx_timer8_hwmod = {
3271 .name = "timer8", 3270 .name = "timer8",
3272 .class = &omap44xx_timer_hwmod_class, 3271 .class = &omap44xx_timer_hwmod_class,
3273 .clkdm_name = "abe_clkdm", 3272 .clkdm_name = "abe_clkdm",
3274 .mpu_irqs = omap44xx_timer8_irqs, 3273 .mpu_irqs = omap44xx_timer8_irqs,
3275 .main_clk = "timer8_fck", 3274 .main_clk = "timer8_fck",
3276 .prcm = { 3275 .prcm = {
3277 .omap4 = { 3276 .omap4 = {
3278 .clkctrl_offs = OMAP4_CM1_ABE_TIMER8_CLKCTRL_OFFSET, 3277 .clkctrl_offs = OMAP4_CM1_ABE_TIMER8_CLKCTRL_OFFSET,
3279 .context_offs = OMAP4_RM_ABE_TIMER8_CONTEXT_OFFSET, 3278 .context_offs = OMAP4_RM_ABE_TIMER8_CONTEXT_OFFSET,
3280 .modulemode = MODULEMODE_SWCTRL, 3279 .modulemode = MODULEMODE_SWCTRL,
3281 }, 3280 },
3282 }, 3281 },
3283 .dev_attr = &capability_dsp_pwm_dev_attr, 3282 .dev_attr = &capability_dsp_pwm_dev_attr,
3284 }; 3283 };
3285 3284
3286 /* timer9 */ 3285 /* timer9 */
3287 static struct omap_hwmod_irq_info omap44xx_timer9_irqs[] = { 3286 static struct omap_hwmod_irq_info omap44xx_timer9_irqs[] = {
3288 { .irq = 45 + OMAP44XX_IRQ_GIC_START }, 3287 { .irq = 45 + OMAP44XX_IRQ_GIC_START },
3289 { .irq = -1 } 3288 { .irq = -1 }
3290 }; 3289 };
3291 3290
3292 static struct omap_hwmod omap44xx_timer9_hwmod = { 3291 static struct omap_hwmod omap44xx_timer9_hwmod = {
3293 .name = "timer9", 3292 .name = "timer9",
3294 .class = &omap44xx_timer_hwmod_class, 3293 .class = &omap44xx_timer_hwmod_class,
3295 .clkdm_name = "l4_per_clkdm", 3294 .clkdm_name = "l4_per_clkdm",
3296 .mpu_irqs = omap44xx_timer9_irqs, 3295 .mpu_irqs = omap44xx_timer9_irqs,
3297 .main_clk = "timer9_fck", 3296 .main_clk = "timer9_fck",
3298 .prcm = { 3297 .prcm = {
3299 .omap4 = { 3298 .omap4 = {
3300 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER9_CLKCTRL_OFFSET, 3299 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER9_CLKCTRL_OFFSET,
3301 .context_offs = OMAP4_RM_L4PER_DMTIMER9_CONTEXT_OFFSET, 3300 .context_offs = OMAP4_RM_L4PER_DMTIMER9_CONTEXT_OFFSET,
3302 .modulemode = MODULEMODE_SWCTRL, 3301 .modulemode = MODULEMODE_SWCTRL,
3303 }, 3302 },
3304 }, 3303 },
3305 .dev_attr = &capability_pwm_dev_attr, 3304 .dev_attr = &capability_pwm_dev_attr,
3306 }; 3305 };
3307 3306
3308 /* timer10 */ 3307 /* timer10 */
3309 static struct omap_hwmod_irq_info omap44xx_timer10_irqs[] = { 3308 static struct omap_hwmod_irq_info omap44xx_timer10_irqs[] = {
3310 { .irq = 46 + OMAP44XX_IRQ_GIC_START }, 3309 { .irq = 46 + OMAP44XX_IRQ_GIC_START },
3311 { .irq = -1 } 3310 { .irq = -1 }
3312 }; 3311 };
3313 3312
3314 static struct omap_hwmod omap44xx_timer10_hwmod = { 3313 static struct omap_hwmod omap44xx_timer10_hwmod = {
3315 .name = "timer10", 3314 .name = "timer10",
3316 .class = &omap44xx_timer_1ms_hwmod_class, 3315 .class = &omap44xx_timer_1ms_hwmod_class,
3317 .clkdm_name = "l4_per_clkdm", 3316 .clkdm_name = "l4_per_clkdm",
3318 .mpu_irqs = omap44xx_timer10_irqs, 3317 .mpu_irqs = omap44xx_timer10_irqs,
3319 .main_clk = "timer10_fck", 3318 .main_clk = "timer10_fck",
3320 .prcm = { 3319 .prcm = {
3321 .omap4 = { 3320 .omap4 = {
3322 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER10_CLKCTRL_OFFSET, 3321 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER10_CLKCTRL_OFFSET,
3323 .context_offs = OMAP4_RM_L4PER_DMTIMER10_CONTEXT_OFFSET, 3322 .context_offs = OMAP4_RM_L4PER_DMTIMER10_CONTEXT_OFFSET,
3324 .modulemode = MODULEMODE_SWCTRL, 3323 .modulemode = MODULEMODE_SWCTRL,
3325 }, 3324 },
3326 }, 3325 },
3327 .dev_attr = &capability_pwm_dev_attr, 3326 .dev_attr = &capability_pwm_dev_attr,
3328 }; 3327 };
3329 3328
3330 /* timer11 */ 3329 /* timer11 */
3331 static struct omap_hwmod_irq_info omap44xx_timer11_irqs[] = { 3330 static struct omap_hwmod_irq_info omap44xx_timer11_irqs[] = {
3332 { .irq = 47 + OMAP44XX_IRQ_GIC_START }, 3331 { .irq = 47 + OMAP44XX_IRQ_GIC_START },
3333 { .irq = -1 } 3332 { .irq = -1 }
3334 }; 3333 };
3335 3334
3336 static struct omap_hwmod omap44xx_timer11_hwmod = { 3335 static struct omap_hwmod omap44xx_timer11_hwmod = {
3337 .name = "timer11", 3336 .name = "timer11",
3338 .class = &omap44xx_timer_hwmod_class, 3337 .class = &omap44xx_timer_hwmod_class,
3339 .clkdm_name = "l4_per_clkdm", 3338 .clkdm_name = "l4_per_clkdm",
3340 .mpu_irqs = omap44xx_timer11_irqs, 3339 .mpu_irqs = omap44xx_timer11_irqs,
3341 .main_clk = "timer11_fck", 3340 .main_clk = "timer11_fck",
3342 .prcm = { 3341 .prcm = {
3343 .omap4 = { 3342 .omap4 = {
3344 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER11_CLKCTRL_OFFSET, 3343 .clkctrl_offs = OMAP4_CM_L4PER_DMTIMER11_CLKCTRL_OFFSET,
3345 .context_offs = OMAP4_RM_L4PER_DMTIMER11_CONTEXT_OFFSET, 3344 .context_offs = OMAP4_RM_L4PER_DMTIMER11_CONTEXT_OFFSET,
3346 .modulemode = MODULEMODE_SWCTRL, 3345 .modulemode = MODULEMODE_SWCTRL,
3347 }, 3346 },
3348 }, 3347 },
3349 .dev_attr = &capability_pwm_dev_attr, 3348 .dev_attr = &capability_pwm_dev_attr,
3350 }; 3349 };
3351 3350
3352 /* 3351 /*
3353 * 'uart' class 3352 * 'uart' class
3354 * universal asynchronous receiver/transmitter (uart) 3353 * universal asynchronous receiver/transmitter (uart)
3355 */ 3354 */
3356 3355
3357 static struct omap_hwmod_class_sysconfig omap44xx_uart_sysc = { 3356 static struct omap_hwmod_class_sysconfig omap44xx_uart_sysc = {
3358 .rev_offs = 0x0050, 3357 .rev_offs = 0x0050,
3359 .sysc_offs = 0x0054, 3358 .sysc_offs = 0x0054,
3360 .syss_offs = 0x0058, 3359 .syss_offs = 0x0058,
3361 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP | 3360 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
3362 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET | 3361 SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
3363 SYSS_HAS_RESET_STATUS), 3362 SYSS_HAS_RESET_STATUS),
3364 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 3363 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
3365 SIDLE_SMART_WKUP), 3364 SIDLE_SMART_WKUP),
3366 .sysc_fields = &omap_hwmod_sysc_type1, 3365 .sysc_fields = &omap_hwmod_sysc_type1,
3367 }; 3366 };
3368 3367
3369 static struct omap_hwmod_class omap44xx_uart_hwmod_class = { 3368 static struct omap_hwmod_class omap44xx_uart_hwmod_class = {
3370 .name = "uart", 3369 .name = "uart",
3371 .sysc = &omap44xx_uart_sysc, 3370 .sysc = &omap44xx_uart_sysc,
3372 }; 3371 };
3373 3372
3374 /* uart1 */ 3373 /* uart1 */
3375 static struct omap_hwmod_irq_info omap44xx_uart1_irqs[] = { 3374 static struct omap_hwmod_irq_info omap44xx_uart1_irqs[] = {
3376 { .irq = 72 + OMAP44XX_IRQ_GIC_START }, 3375 { .irq = 72 + OMAP44XX_IRQ_GIC_START },
3377 { .irq = -1 } 3376 { .irq = -1 }
3378 }; 3377 };
3379 3378
3380 static struct omap_hwmod_dma_info omap44xx_uart1_sdma_reqs[] = { 3379 static struct omap_hwmod_dma_info omap44xx_uart1_sdma_reqs[] = {
3381 { .name = "tx", .dma_req = 48 + OMAP44XX_DMA_REQ_START }, 3380 { .name = "tx", .dma_req = 48 + OMAP44XX_DMA_REQ_START },
3382 { .name = "rx", .dma_req = 49 + OMAP44XX_DMA_REQ_START }, 3381 { .name = "rx", .dma_req = 49 + OMAP44XX_DMA_REQ_START },
3383 { .dma_req = -1 } 3382 { .dma_req = -1 }
3384 }; 3383 };
3385 3384
3386 static struct omap_hwmod omap44xx_uart1_hwmod = { 3385 static struct omap_hwmod omap44xx_uart1_hwmod = {
3387 .name = "uart1", 3386 .name = "uart1",
3388 .class = &omap44xx_uart_hwmod_class, 3387 .class = &omap44xx_uart_hwmod_class,
3389 .clkdm_name = "l4_per_clkdm", 3388 .clkdm_name = "l4_per_clkdm",
3390 .mpu_irqs = omap44xx_uart1_irqs, 3389 .mpu_irqs = omap44xx_uart1_irqs,
3391 .sdma_reqs = omap44xx_uart1_sdma_reqs, 3390 .sdma_reqs = omap44xx_uart1_sdma_reqs,
3392 .main_clk = "uart1_fck", 3391 .main_clk = "uart1_fck",
3393 .prcm = { 3392 .prcm = {
3394 .omap4 = { 3393 .omap4 = {
3395 .clkctrl_offs = OMAP4_CM_L4PER_UART1_CLKCTRL_OFFSET, 3394 .clkctrl_offs = OMAP4_CM_L4PER_UART1_CLKCTRL_OFFSET,
3396 .context_offs = OMAP4_RM_L4PER_UART1_CONTEXT_OFFSET, 3395 .context_offs = OMAP4_RM_L4PER_UART1_CONTEXT_OFFSET,
3397 .modulemode = MODULEMODE_SWCTRL, 3396 .modulemode = MODULEMODE_SWCTRL,
3398 }, 3397 },
3399 }, 3398 },
3400 }; 3399 };
3401 3400
3402 /* uart2 */ 3401 /* uart2 */
3403 static struct omap_hwmod_irq_info omap44xx_uart2_irqs[] = { 3402 static struct omap_hwmod_irq_info omap44xx_uart2_irqs[] = {
3404 { .irq = 73 + OMAP44XX_IRQ_GIC_START }, 3403 { .irq = 73 + OMAP44XX_IRQ_GIC_START },
3405 { .irq = -1 } 3404 { .irq = -1 }
3406 }; 3405 };
3407 3406
3408 static struct omap_hwmod_dma_info omap44xx_uart2_sdma_reqs[] = { 3407 static struct omap_hwmod_dma_info omap44xx_uart2_sdma_reqs[] = {
3409 { .name = "tx", .dma_req = 50 + OMAP44XX_DMA_REQ_START }, 3408 { .name = "tx", .dma_req = 50 + OMAP44XX_DMA_REQ_START },
3410 { .name = "rx", .dma_req = 51 + OMAP44XX_DMA_REQ_START }, 3409 { .name = "rx", .dma_req = 51 + OMAP44XX_DMA_REQ_START },
3411 { .dma_req = -1 } 3410 { .dma_req = -1 }
3412 }; 3411 };
3413 3412
3414 static struct omap_hwmod omap44xx_uart2_hwmod = { 3413 static struct omap_hwmod omap44xx_uart2_hwmod = {
3415 .name = "uart2", 3414 .name = "uart2",
3416 .class = &omap44xx_uart_hwmod_class, 3415 .class = &omap44xx_uart_hwmod_class,
3417 .clkdm_name = "l4_per_clkdm", 3416 .clkdm_name = "l4_per_clkdm",
3418 .mpu_irqs = omap44xx_uart2_irqs, 3417 .mpu_irqs = omap44xx_uart2_irqs,
3419 .sdma_reqs = omap44xx_uart2_sdma_reqs, 3418 .sdma_reqs = omap44xx_uart2_sdma_reqs,
3420 .main_clk = "uart2_fck", 3419 .main_clk = "uart2_fck",
3421 .prcm = { 3420 .prcm = {
3422 .omap4 = { 3421 .omap4 = {
3423 .clkctrl_offs = OMAP4_CM_L4PER_UART2_CLKCTRL_OFFSET, 3422 .clkctrl_offs = OMAP4_CM_L4PER_UART2_CLKCTRL_OFFSET,
3424 .context_offs = OMAP4_RM_L4PER_UART2_CONTEXT_OFFSET, 3423 .context_offs = OMAP4_RM_L4PER_UART2_CONTEXT_OFFSET,
3425 .modulemode = MODULEMODE_SWCTRL, 3424 .modulemode = MODULEMODE_SWCTRL,
3426 }, 3425 },
3427 }, 3426 },
3428 }; 3427 };
3429 3428
3430 /* uart3 */ 3429 /* uart3 */
3431 static struct omap_hwmod_irq_info omap44xx_uart3_irqs[] = { 3430 static struct omap_hwmod_irq_info omap44xx_uart3_irqs[] = {
3432 { .irq = 74 + OMAP44XX_IRQ_GIC_START }, 3431 { .irq = 74 + OMAP44XX_IRQ_GIC_START },
3433 { .irq = -1 } 3432 { .irq = -1 }
3434 }; 3433 };
3435 3434
3436 static struct omap_hwmod_dma_info omap44xx_uart3_sdma_reqs[] = { 3435 static struct omap_hwmod_dma_info omap44xx_uart3_sdma_reqs[] = {
3437 { .name = "tx", .dma_req = 52 + OMAP44XX_DMA_REQ_START }, 3436 { .name = "tx", .dma_req = 52 + OMAP44XX_DMA_REQ_START },
3438 { .name = "rx", .dma_req = 53 + OMAP44XX_DMA_REQ_START }, 3437 { .name = "rx", .dma_req = 53 + OMAP44XX_DMA_REQ_START },
3439 { .dma_req = -1 } 3438 { .dma_req = -1 }
3440 }; 3439 };
3441 3440
3442 static struct omap_hwmod omap44xx_uart3_hwmod = { 3441 static struct omap_hwmod omap44xx_uart3_hwmod = {
3443 .name = "uart3", 3442 .name = "uart3",
3444 .class = &omap44xx_uart_hwmod_class, 3443 .class = &omap44xx_uart_hwmod_class,
3445 .clkdm_name = "l4_per_clkdm", 3444 .clkdm_name = "l4_per_clkdm",
3446 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET, 3445 .flags = HWMOD_INIT_NO_IDLE | HWMOD_INIT_NO_RESET,
3447 .mpu_irqs = omap44xx_uart3_irqs, 3446 .mpu_irqs = omap44xx_uart3_irqs,
3448 .sdma_reqs = omap44xx_uart3_sdma_reqs, 3447 .sdma_reqs = omap44xx_uart3_sdma_reqs,
3449 .main_clk = "uart3_fck", 3448 .main_clk = "uart3_fck",
3450 .prcm = { 3449 .prcm = {
3451 .omap4 = { 3450 .omap4 = {
3452 .clkctrl_offs = OMAP4_CM_L4PER_UART3_CLKCTRL_OFFSET, 3451 .clkctrl_offs = OMAP4_CM_L4PER_UART3_CLKCTRL_OFFSET,
3453 .context_offs = OMAP4_RM_L4PER_UART3_CONTEXT_OFFSET, 3452 .context_offs = OMAP4_RM_L4PER_UART3_CONTEXT_OFFSET,
3454 .modulemode = MODULEMODE_SWCTRL, 3453 .modulemode = MODULEMODE_SWCTRL,
3455 }, 3454 },
3456 }, 3455 },
3457 }; 3456 };
3458 3457
3459 /* uart4 */ 3458 /* uart4 */
3460 static struct omap_hwmod_irq_info omap44xx_uart4_irqs[] = { 3459 static struct omap_hwmod_irq_info omap44xx_uart4_irqs[] = {
3461 { .irq = 70 + OMAP44XX_IRQ_GIC_START }, 3460 { .irq = 70 + OMAP44XX_IRQ_GIC_START },
3462 { .irq = -1 } 3461 { .irq = -1 }
3463 }; 3462 };
3464 3463
3465 static struct omap_hwmod_dma_info omap44xx_uart4_sdma_reqs[] = { 3464 static struct omap_hwmod_dma_info omap44xx_uart4_sdma_reqs[] = {
3466 { .name = "tx", .dma_req = 54 + OMAP44XX_DMA_REQ_START }, 3465 { .name = "tx", .dma_req = 54 + OMAP44XX_DMA_REQ_START },
3467 { .name = "rx", .dma_req = 55 + OMAP44XX_DMA_REQ_START }, 3466 { .name = "rx", .dma_req = 55 + OMAP44XX_DMA_REQ_START },
3468 { .dma_req = -1 } 3467 { .dma_req = -1 }
3469 }; 3468 };
3470 3469
3471 static struct omap_hwmod omap44xx_uart4_hwmod = { 3470 static struct omap_hwmod omap44xx_uart4_hwmod = {
3472 .name = "uart4", 3471 .name = "uart4",
3473 .class = &omap44xx_uart_hwmod_class, 3472 .class = &omap44xx_uart_hwmod_class,
3474 .clkdm_name = "l4_per_clkdm", 3473 .clkdm_name = "l4_per_clkdm",
3475 .mpu_irqs = omap44xx_uart4_irqs, 3474 .mpu_irqs = omap44xx_uart4_irqs,
3476 .sdma_reqs = omap44xx_uart4_sdma_reqs, 3475 .sdma_reqs = omap44xx_uart4_sdma_reqs,
3477 .main_clk = "uart4_fck", 3476 .main_clk = "uart4_fck",
3478 .prcm = { 3477 .prcm = {
3479 .omap4 = { 3478 .omap4 = {
3480 .clkctrl_offs = OMAP4_CM_L4PER_UART4_CLKCTRL_OFFSET, 3479 .clkctrl_offs = OMAP4_CM_L4PER_UART4_CLKCTRL_OFFSET,
3481 .context_offs = OMAP4_RM_L4PER_UART4_CONTEXT_OFFSET, 3480 .context_offs = OMAP4_RM_L4PER_UART4_CONTEXT_OFFSET,
3482 .modulemode = MODULEMODE_SWCTRL, 3481 .modulemode = MODULEMODE_SWCTRL,
3483 }, 3482 },
3484 }, 3483 },
3485 }; 3484 };
3486 3485
3487 /* 3486 /*
3488 * 'usb_host_fs' class 3487 * 'usb_host_fs' class
3489 * full-speed usb host controller 3488 * full-speed usb host controller
3490 */ 3489 */
3491 3490
3492 /* The IP is not compliant to type1 / type2 scheme */ 3491 /* The IP is not compliant to type1 / type2 scheme */
3493 static struct omap_hwmod_sysc_fields omap_hwmod_sysc_type_usb_host_fs = { 3492 static struct omap_hwmod_sysc_fields omap_hwmod_sysc_type_usb_host_fs = {
3494 .midle_shift = 4, 3493 .midle_shift = 4,
3495 .sidle_shift = 2, 3494 .sidle_shift = 2,
3496 .srst_shift = 1, 3495 .srst_shift = 1,
3497 }; 3496 };
3498 3497
3499 static struct omap_hwmod_class_sysconfig omap44xx_usb_host_fs_sysc = { 3498 static struct omap_hwmod_class_sysconfig omap44xx_usb_host_fs_sysc = {
3500 .rev_offs = 0x0000, 3499 .rev_offs = 0x0000,
3501 .sysc_offs = 0x0210, 3500 .sysc_offs = 0x0210,
3502 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE | 3501 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
3503 SYSC_HAS_SOFTRESET), 3502 SYSC_HAS_SOFTRESET),
3504 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 3503 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
3505 SIDLE_SMART_WKUP), 3504 SIDLE_SMART_WKUP),
3506 .sysc_fields = &omap_hwmod_sysc_type_usb_host_fs, 3505 .sysc_fields = &omap_hwmod_sysc_type_usb_host_fs,
3507 }; 3506 };
3508 3507
3509 static struct omap_hwmod_class omap44xx_usb_host_fs_hwmod_class = { 3508 static struct omap_hwmod_class omap44xx_usb_host_fs_hwmod_class = {
3510 .name = "usb_host_fs", 3509 .name = "usb_host_fs",
3511 .sysc = &omap44xx_usb_host_fs_sysc, 3510 .sysc = &omap44xx_usb_host_fs_sysc,
3512 }; 3511 };
3513 3512
3514 /* usb_host_fs */ 3513 /* usb_host_fs */
3515 static struct omap_hwmod_irq_info omap44xx_usb_host_fs_irqs[] = { 3514 static struct omap_hwmod_irq_info omap44xx_usb_host_fs_irqs[] = {
3516 { .name = "std", .irq = 89 + OMAP44XX_IRQ_GIC_START }, 3515 { .name = "std", .irq = 89 + OMAP44XX_IRQ_GIC_START },
3517 { .name = "smi", .irq = 90 + OMAP44XX_IRQ_GIC_START }, 3516 { .name = "smi", .irq = 90 + OMAP44XX_IRQ_GIC_START },
3518 { .irq = -1 } 3517 { .irq = -1 }
3519 }; 3518 };
3520 3519
3521 static struct omap_hwmod omap44xx_usb_host_fs_hwmod = { 3520 static struct omap_hwmod omap44xx_usb_host_fs_hwmod = {
3522 .name = "usb_host_fs", 3521 .name = "usb_host_fs",
3523 .class = &omap44xx_usb_host_fs_hwmod_class, 3522 .class = &omap44xx_usb_host_fs_hwmod_class,
3524 .clkdm_name = "l3_init_clkdm", 3523 .clkdm_name = "l3_init_clkdm",
3525 .mpu_irqs = omap44xx_usb_host_fs_irqs, 3524 .mpu_irqs = omap44xx_usb_host_fs_irqs,
3526 .main_clk = "usb_host_fs_fck", 3525 .main_clk = "usb_host_fs_fck",
3527 .prcm = { 3526 .prcm = {
3528 .omap4 = { 3527 .omap4 = {
3529 .clkctrl_offs = OMAP4_CM_L3INIT_USB_HOST_FS_CLKCTRL_OFFSET, 3528 .clkctrl_offs = OMAP4_CM_L3INIT_USB_HOST_FS_CLKCTRL_OFFSET,
3530 .context_offs = OMAP4_RM_L3INIT_USB_HOST_FS_CONTEXT_OFFSET, 3529 .context_offs = OMAP4_RM_L3INIT_USB_HOST_FS_CONTEXT_OFFSET,
3531 .modulemode = MODULEMODE_SWCTRL, 3530 .modulemode = MODULEMODE_SWCTRL,
3532 }, 3531 },
3533 }, 3532 },
3534 }; 3533 };
3535 3534
3536 /* 3535 /*
3537 * 'usb_host_hs' class 3536 * 'usb_host_hs' class
3538 * high-speed multi-port usb host controller 3537 * high-speed multi-port usb host controller
3539 */ 3538 */
3540 3539
3541 static struct omap_hwmod_class_sysconfig omap44xx_usb_host_hs_sysc = { 3540 static struct omap_hwmod_class_sysconfig omap44xx_usb_host_hs_sysc = {
3542 .rev_offs = 0x0000, 3541 .rev_offs = 0x0000,
3543 .sysc_offs = 0x0010, 3542 .sysc_offs = 0x0010,
3544 .syss_offs = 0x0014, 3543 .syss_offs = 0x0014,
3545 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE | 3544 .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
3546 SYSC_HAS_SOFTRESET), 3545 SYSC_HAS_SOFTRESET),
3547 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 3546 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
3548 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO | 3547 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
3549 MSTANDBY_SMART | MSTANDBY_SMART_WKUP), 3548 MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
3550 .sysc_fields = &omap_hwmod_sysc_type2, 3549 .sysc_fields = &omap_hwmod_sysc_type2,
3551 }; 3550 };
3552 3551
3553 static struct omap_hwmod_class omap44xx_usb_host_hs_hwmod_class = { 3552 static struct omap_hwmod_class omap44xx_usb_host_hs_hwmod_class = {
3554 .name = "usb_host_hs", 3553 .name = "usb_host_hs",
3555 .sysc = &omap44xx_usb_host_hs_sysc, 3554 .sysc = &omap44xx_usb_host_hs_sysc,
3556 }; 3555 };
3557 3556
3558 /* usb_host_hs */ 3557 /* usb_host_hs */
3559 static struct omap_hwmod_irq_info omap44xx_usb_host_hs_irqs[] = { 3558 static struct omap_hwmod_irq_info omap44xx_usb_host_hs_irqs[] = {
3560 { .name = "ohci-irq", .irq = 76 + OMAP44XX_IRQ_GIC_START }, 3559 { .name = "ohci-irq", .irq = 76 + OMAP44XX_IRQ_GIC_START },
3561 { .name = "ehci-irq", .irq = 77 + OMAP44XX_IRQ_GIC_START }, 3560 { .name = "ehci-irq", .irq = 77 + OMAP44XX_IRQ_GIC_START },
3562 { .irq = -1 } 3561 { .irq = -1 }
3563 }; 3562 };
3564 3563
3565 static struct omap_hwmod omap44xx_usb_host_hs_hwmod = { 3564 static struct omap_hwmod omap44xx_usb_host_hs_hwmod = {
3566 .name = "usb_host_hs", 3565 .name = "usb_host_hs",
3567 .class = &omap44xx_usb_host_hs_hwmod_class, 3566 .class = &omap44xx_usb_host_hs_hwmod_class,
3568 .clkdm_name = "l3_init_clkdm", 3567 .clkdm_name = "l3_init_clkdm",
3569 .main_clk = "usb_host_hs_fck", 3568 .main_clk = "usb_host_hs_fck",
3570 .prcm = { 3569 .prcm = {
3571 .omap4 = { 3570 .omap4 = {
3572 .clkctrl_offs = OMAP4_CM_L3INIT_USB_HOST_CLKCTRL_OFFSET, 3571 .clkctrl_offs = OMAP4_CM_L3INIT_USB_HOST_CLKCTRL_OFFSET,
3573 .context_offs = OMAP4_RM_L3INIT_USB_HOST_CONTEXT_OFFSET, 3572 .context_offs = OMAP4_RM_L3INIT_USB_HOST_CONTEXT_OFFSET,
3574 .modulemode = MODULEMODE_SWCTRL, 3573 .modulemode = MODULEMODE_SWCTRL,
3575 }, 3574 },
3576 }, 3575 },
3577 .mpu_irqs = omap44xx_usb_host_hs_irqs, 3576 .mpu_irqs = omap44xx_usb_host_hs_irqs,
3578 3577
3579 /* 3578 /*
3580 * Errata: USBHOST Configured In Smart-Idle Can Lead To a Deadlock 3579 * Errata: USBHOST Configured In Smart-Idle Can Lead To a Deadlock
3581 * id: i660 3580 * id: i660
3582 * 3581 *
3583 * Description: 3582 * Description:
3584 * In the following configuration : 3583 * In the following configuration :
3585 * - USBHOST module is set to smart-idle mode 3584 * - USBHOST module is set to smart-idle mode
3586 * - PRCM asserts idle_req to the USBHOST module ( This typically 3585 * - PRCM asserts idle_req to the USBHOST module ( This typically
3587 * happens when the system is going to a low power mode : all ports 3586 * happens when the system is going to a low power mode : all ports
3588 * have been suspended, the master part of the USBHOST module has 3587 * have been suspended, the master part of the USBHOST module has
3589 * entered the standby state, and SW has cut the functional clocks) 3588 * entered the standby state, and SW has cut the functional clocks)
3590 * - an USBHOST interrupt occurs before the module is able to answer 3589 * - an USBHOST interrupt occurs before the module is able to answer
3591 * idle_ack, typically a remote wakeup IRQ. 3590 * idle_ack, typically a remote wakeup IRQ.
3592 * Then the USB HOST module will enter a deadlock situation where it 3591 * Then the USB HOST module will enter a deadlock situation where it
3593 * is no more accessible nor functional. 3592 * is no more accessible nor functional.
3594 * 3593 *
3595 * Workaround: 3594 * Workaround:
3596 * Don't use smart idle; use only force idle, hence HWMOD_SWSUP_SIDLE 3595 * Don't use smart idle; use only force idle, hence HWMOD_SWSUP_SIDLE
3597 */ 3596 */
3598 3597
3599 /* 3598 /*
3600 * Errata: USB host EHCI may stall when entering smart-standby mode 3599 * Errata: USB host EHCI may stall when entering smart-standby mode
3601 * Id: i571 3600 * Id: i571
3602 * 3601 *
3603 * Description: 3602 * Description:
3604 * When the USBHOST module is set to smart-standby mode, and when it is 3603 * When the USBHOST module is set to smart-standby mode, and when it is
3605 * ready to enter the standby state (i.e. all ports are suspended and 3604 * ready to enter the standby state (i.e. all ports are suspended and
3606 * all attached devices are in suspend mode), then it can wrongly assert 3605 * all attached devices are in suspend mode), then it can wrongly assert
3607 * the Mstandby signal too early while there are still some residual OCP 3606 * the Mstandby signal too early while there are still some residual OCP
3608 * transactions ongoing. If this condition occurs, the internal state 3607 * transactions ongoing. If this condition occurs, the internal state
3609 * machine may go to an undefined state and the USB link may be stuck 3608 * machine may go to an undefined state and the USB link may be stuck
3610 * upon the next resume. 3609 * upon the next resume.
3611 * 3610 *
3612 * Workaround: 3611 * Workaround:
3613 * Don't use smart standby; use only force standby, 3612 * Don't use smart standby; use only force standby,
3614 * hence HWMOD_SWSUP_MSTANDBY 3613 * hence HWMOD_SWSUP_MSTANDBY
3615 */ 3614 */
3616 3615
3617 /* 3616 /*
3618 * During system boot; If the hwmod framework resets the module 3617 * During system boot; If the hwmod framework resets the module
3619 * the module will have smart idle settings; which can lead to deadlock 3618 * the module will have smart idle settings; which can lead to deadlock
3620 * (above Errata Id:i660); so, dont reset the module during boot; 3619 * (above Errata Id:i660); so, dont reset the module during boot;
3621 * Use HWMOD_INIT_NO_RESET. 3620 * Use HWMOD_INIT_NO_RESET.
3622 */ 3621 */
3623 3622
3624 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY | 3623 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
3625 HWMOD_INIT_NO_RESET, 3624 HWMOD_INIT_NO_RESET,
3626 }; 3625 };
3627 3626
3628 /* 3627 /*
3629 * 'usb_otg_hs' class 3628 * 'usb_otg_hs' class
3630 * high-speed on-the-go universal serial bus (usb_otg_hs) controller 3629 * high-speed on-the-go universal serial bus (usb_otg_hs) controller
3631 */ 3630 */
3632 3631
3633 static struct omap_hwmod_class_sysconfig omap44xx_usb_otg_hs_sysc = { 3632 static struct omap_hwmod_class_sysconfig omap44xx_usb_otg_hs_sysc = {
3634 .rev_offs = 0x0400, 3633 .rev_offs = 0x0400,
3635 .sysc_offs = 0x0404, 3634 .sysc_offs = 0x0404,
3636 .syss_offs = 0x0408, 3635 .syss_offs = 0x0408,
3637 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP | 3636 .sysc_flags = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
3638 SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE | 3637 SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
3639 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 3638 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
3640 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 3639 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
3641 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO | 3640 SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
3642 MSTANDBY_SMART), 3641 MSTANDBY_SMART),
3643 .sysc_fields = &omap_hwmod_sysc_type1, 3642 .sysc_fields = &omap_hwmod_sysc_type1,
3644 }; 3643 };
3645 3644
3646 static struct omap_hwmod_class omap44xx_usb_otg_hs_hwmod_class = { 3645 static struct omap_hwmod_class omap44xx_usb_otg_hs_hwmod_class = {
3647 .name = "usb_otg_hs", 3646 .name = "usb_otg_hs",
3648 .sysc = &omap44xx_usb_otg_hs_sysc, 3647 .sysc = &omap44xx_usb_otg_hs_sysc,
3649 }; 3648 };
3650 3649
3651 /* usb_otg_hs */ 3650 /* usb_otg_hs */
3652 static struct omap_hwmod_irq_info omap44xx_usb_otg_hs_irqs[] = { 3651 static struct omap_hwmod_irq_info omap44xx_usb_otg_hs_irqs[] = {
3653 { .name = "mc", .irq = 92 + OMAP44XX_IRQ_GIC_START }, 3652 { .name = "mc", .irq = 92 + OMAP44XX_IRQ_GIC_START },
3654 { .name = "dma", .irq = 93 + OMAP44XX_IRQ_GIC_START }, 3653 { .name = "dma", .irq = 93 + OMAP44XX_IRQ_GIC_START },
3655 { .irq = -1 } 3654 { .irq = -1 }
3656 }; 3655 };
3657 3656
3658 static struct omap_hwmod_opt_clk usb_otg_hs_opt_clks[] = { 3657 static struct omap_hwmod_opt_clk usb_otg_hs_opt_clks[] = {
3659 { .role = "xclk", .clk = "usb_otg_hs_xclk" }, 3658 { .role = "xclk", .clk = "usb_otg_hs_xclk" },
3660 }; 3659 };
3661 3660
3662 static struct omap_hwmod omap44xx_usb_otg_hs_hwmod = { 3661 static struct omap_hwmod omap44xx_usb_otg_hs_hwmod = {
3663 .name = "usb_otg_hs", 3662 .name = "usb_otg_hs",
3664 .class = &omap44xx_usb_otg_hs_hwmod_class, 3663 .class = &omap44xx_usb_otg_hs_hwmod_class,
3665 .clkdm_name = "l3_init_clkdm", 3664 .clkdm_name = "l3_init_clkdm",
3666 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY, 3665 .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
3667 .mpu_irqs = omap44xx_usb_otg_hs_irqs, 3666 .mpu_irqs = omap44xx_usb_otg_hs_irqs,
3668 .main_clk = "usb_otg_hs_ick", 3667 .main_clk = "usb_otg_hs_ick",
3669 .prcm = { 3668 .prcm = {
3670 .omap4 = { 3669 .omap4 = {
3671 .clkctrl_offs = OMAP4_CM_L3INIT_USB_OTG_CLKCTRL_OFFSET, 3670 .clkctrl_offs = OMAP4_CM_L3INIT_USB_OTG_CLKCTRL_OFFSET,
3672 .context_offs = OMAP4_RM_L3INIT_USB_OTG_CONTEXT_OFFSET, 3671 .context_offs = OMAP4_RM_L3INIT_USB_OTG_CONTEXT_OFFSET,
3673 .modulemode = MODULEMODE_HWCTRL, 3672 .modulemode = MODULEMODE_HWCTRL,
3674 }, 3673 },
3675 }, 3674 },
3676 .opt_clks = usb_otg_hs_opt_clks, 3675 .opt_clks = usb_otg_hs_opt_clks,
3677 .opt_clks_cnt = ARRAY_SIZE(usb_otg_hs_opt_clks), 3676 .opt_clks_cnt = ARRAY_SIZE(usb_otg_hs_opt_clks),
3678 }; 3677 };
3679 3678
3680 /* 3679 /*
3681 * 'usb_tll_hs' class 3680 * 'usb_tll_hs' class
3682 * usb_tll_hs module is the adapter on the usb_host_hs ports 3681 * usb_tll_hs module is the adapter on the usb_host_hs ports
3683 */ 3682 */
3684 3683
3685 static struct omap_hwmod_class_sysconfig omap44xx_usb_tll_hs_sysc = { 3684 static struct omap_hwmod_class_sysconfig omap44xx_usb_tll_hs_sysc = {
3686 .rev_offs = 0x0000, 3685 .rev_offs = 0x0000,
3687 .sysc_offs = 0x0010, 3686 .sysc_offs = 0x0010,
3688 .syss_offs = 0x0014, 3687 .syss_offs = 0x0014,
3689 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE | 3688 .sysc_flags = (SYSC_HAS_CLOCKACTIVITY | SYSC_HAS_SIDLEMODE |
3690 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET | 3689 SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
3691 SYSC_HAS_AUTOIDLE), 3690 SYSC_HAS_AUTOIDLE),
3692 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART), 3691 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
3693 .sysc_fields = &omap_hwmod_sysc_type1, 3692 .sysc_fields = &omap_hwmod_sysc_type1,
3694 }; 3693 };
3695 3694
3696 static struct omap_hwmod_class omap44xx_usb_tll_hs_hwmod_class = { 3695 static struct omap_hwmod_class omap44xx_usb_tll_hs_hwmod_class = {
3697 .name = "usb_tll_hs", 3696 .name = "usb_tll_hs",
3698 .sysc = &omap44xx_usb_tll_hs_sysc, 3697 .sysc = &omap44xx_usb_tll_hs_sysc,
3699 }; 3698 };
3700 3699
3701 static struct omap_hwmod_irq_info omap44xx_usb_tll_hs_irqs[] = { 3700 static struct omap_hwmod_irq_info omap44xx_usb_tll_hs_irqs[] = {
3702 { .name = "tll-irq", .irq = 78 + OMAP44XX_IRQ_GIC_START }, 3701 { .name = "tll-irq", .irq = 78 + OMAP44XX_IRQ_GIC_START },
3703 { .irq = -1 } 3702 { .irq = -1 }
3704 }; 3703 };
3705 3704
3706 static struct omap_hwmod omap44xx_usb_tll_hs_hwmod = { 3705 static struct omap_hwmod omap44xx_usb_tll_hs_hwmod = {
3707 .name = "usb_tll_hs", 3706 .name = "usb_tll_hs",
3708 .class = &omap44xx_usb_tll_hs_hwmod_class, 3707 .class = &omap44xx_usb_tll_hs_hwmod_class,
3709 .clkdm_name = "l3_init_clkdm", 3708 .clkdm_name = "l3_init_clkdm",
3710 .mpu_irqs = omap44xx_usb_tll_hs_irqs, 3709 .mpu_irqs = omap44xx_usb_tll_hs_irqs,
3711 .main_clk = "usb_tll_hs_ick", 3710 .main_clk = "usb_tll_hs_ick",
3712 .prcm = { 3711 .prcm = {
3713 .omap4 = { 3712 .omap4 = {
3714 .clkctrl_offs = OMAP4_CM_L3INIT_USB_TLL_CLKCTRL_OFFSET, 3713 .clkctrl_offs = OMAP4_CM_L3INIT_USB_TLL_CLKCTRL_OFFSET,
3715 .context_offs = OMAP4_RM_L3INIT_USB_TLL_CONTEXT_OFFSET, 3714 .context_offs = OMAP4_RM_L3INIT_USB_TLL_CONTEXT_OFFSET,
3716 .modulemode = MODULEMODE_HWCTRL, 3715 .modulemode = MODULEMODE_HWCTRL,
3717 }, 3716 },
3718 }, 3717 },
3719 }; 3718 };
3720 3719
3721 /* 3720 /*
3722 * 'wd_timer' class 3721 * 'wd_timer' class
3723 * 32-bit watchdog upward counter that generates a pulse on the reset pin on 3722 * 32-bit watchdog upward counter that generates a pulse on the reset pin on
3724 * overflow condition 3723 * overflow condition
3725 */ 3724 */
3726 3725
3727 static struct omap_hwmod_class_sysconfig omap44xx_wd_timer_sysc = { 3726 static struct omap_hwmod_class_sysconfig omap44xx_wd_timer_sysc = {
3728 .rev_offs = 0x0000, 3727 .rev_offs = 0x0000,
3729 .sysc_offs = 0x0010, 3728 .sysc_offs = 0x0010,
3730 .syss_offs = 0x0014, 3729 .syss_offs = 0x0014,
3731 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_SIDLEMODE | 3730 .sysc_flags = (SYSC_HAS_EMUFREE | SYSC_HAS_SIDLEMODE |
3732 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS), 3731 SYSC_HAS_SOFTRESET | SYSS_HAS_RESET_STATUS),
3733 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 3732 .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
3734 SIDLE_SMART_WKUP), 3733 SIDLE_SMART_WKUP),
3735 .sysc_fields = &omap_hwmod_sysc_type1, 3734 .sysc_fields = &omap_hwmod_sysc_type1,
3736 }; 3735 };
3737 3736
3738 static struct omap_hwmod_class omap44xx_wd_timer_hwmod_class = { 3737 static struct omap_hwmod_class omap44xx_wd_timer_hwmod_class = {
3739 .name = "wd_timer", 3738 .name = "wd_timer",
3740 .sysc = &omap44xx_wd_timer_sysc, 3739 .sysc = &omap44xx_wd_timer_sysc,
3741 .pre_shutdown = &omap2_wd_timer_disable, 3740 .pre_shutdown = &omap2_wd_timer_disable,
3742 .reset = &omap2_wd_timer_reset, 3741 .reset = &omap2_wd_timer_reset,
3743 }; 3742 };
3744 3743
3745 /* wd_timer2 */ 3744 /* wd_timer2 */
3746 static struct omap_hwmod_irq_info omap44xx_wd_timer2_irqs[] = { 3745 static struct omap_hwmod_irq_info omap44xx_wd_timer2_irqs[] = {
3747 { .irq = 80 + OMAP44XX_IRQ_GIC_START }, 3746 { .irq = 80 + OMAP44XX_IRQ_GIC_START },
3748 { .irq = -1 } 3747 { .irq = -1 }
3749 }; 3748 };
3750 3749
3751 static struct omap_hwmod omap44xx_wd_timer2_hwmod = { 3750 static struct omap_hwmod omap44xx_wd_timer2_hwmod = {
3752 .name = "wd_timer2", 3751 .name = "wd_timer2",
3753 .class = &omap44xx_wd_timer_hwmod_class, 3752 .class = &omap44xx_wd_timer_hwmod_class,
3754 .clkdm_name = "l4_wkup_clkdm", 3753 .clkdm_name = "l4_wkup_clkdm",
3755 .mpu_irqs = omap44xx_wd_timer2_irqs, 3754 .mpu_irqs = omap44xx_wd_timer2_irqs,
3756 .main_clk = "wd_timer2_fck", 3755 .main_clk = "wd_timer2_fck",
3757 .prcm = { 3756 .prcm = {
3758 .omap4 = { 3757 .omap4 = {
3759 .clkctrl_offs = OMAP4_CM_WKUP_WDT2_CLKCTRL_OFFSET, 3758 .clkctrl_offs = OMAP4_CM_WKUP_WDT2_CLKCTRL_OFFSET,
3760 .context_offs = OMAP4_RM_WKUP_WDT2_CONTEXT_OFFSET, 3759 .context_offs = OMAP4_RM_WKUP_WDT2_CONTEXT_OFFSET,
3761 .modulemode = MODULEMODE_SWCTRL, 3760 .modulemode = MODULEMODE_SWCTRL,
3762 }, 3761 },
3763 }, 3762 },
3764 }; 3763 };
3765 3764
3766 /* wd_timer3 */ 3765 /* wd_timer3 */
3767 static struct omap_hwmod_irq_info omap44xx_wd_timer3_irqs[] = { 3766 static struct omap_hwmod_irq_info omap44xx_wd_timer3_irqs[] = {
3768 { .irq = 36 + OMAP44XX_IRQ_GIC_START }, 3767 { .irq = 36 + OMAP44XX_IRQ_GIC_START },
3769 { .irq = -1 } 3768 { .irq = -1 }
3770 }; 3769 };
3771 3770
3772 static struct omap_hwmod omap44xx_wd_timer3_hwmod = { 3771 static struct omap_hwmod omap44xx_wd_timer3_hwmod = {
3773 .name = "wd_timer3", 3772 .name = "wd_timer3",
3774 .class = &omap44xx_wd_timer_hwmod_class, 3773 .class = &omap44xx_wd_timer_hwmod_class,
3775 .clkdm_name = "abe_clkdm", 3774 .clkdm_name = "abe_clkdm",
3776 .mpu_irqs = omap44xx_wd_timer3_irqs, 3775 .mpu_irqs = omap44xx_wd_timer3_irqs,
3777 .main_clk = "wd_timer3_fck", 3776 .main_clk = "wd_timer3_fck",
3778 .prcm = { 3777 .prcm = {
3779 .omap4 = { 3778 .omap4 = {
3780 .clkctrl_offs = OMAP4_CM1_ABE_WDT3_CLKCTRL_OFFSET, 3779 .clkctrl_offs = OMAP4_CM1_ABE_WDT3_CLKCTRL_OFFSET,
3781 .context_offs = OMAP4_RM_ABE_WDT3_CONTEXT_OFFSET, 3780 .context_offs = OMAP4_RM_ABE_WDT3_CONTEXT_OFFSET,
3782 .modulemode = MODULEMODE_SWCTRL, 3781 .modulemode = MODULEMODE_SWCTRL,
3783 }, 3782 },
3784 }, 3783 },
3785 }; 3784 };
3786 3785
3787 3786
3788 /* 3787 /*
3789 * interfaces 3788 * interfaces
3790 */ 3789 */
3791 3790
3792 static struct omap_hwmod_addr_space omap44xx_c2c_target_fw_addrs[] = { 3791 static struct omap_hwmod_addr_space omap44xx_c2c_target_fw_addrs[] = {
3793 { 3792 {
3794 .pa_start = 0x4a204000, 3793 .pa_start = 0x4a204000,
3795 .pa_end = 0x4a2040ff, 3794 .pa_end = 0x4a2040ff,
3796 .flags = ADDR_TYPE_RT 3795 .flags = ADDR_TYPE_RT
3797 }, 3796 },
3798 { } 3797 { }
3799 }; 3798 };
3800 3799
3801 /* c2c -> c2c_target_fw */ 3800 /* c2c -> c2c_target_fw */
3802 static struct omap_hwmod_ocp_if omap44xx_c2c__c2c_target_fw = { 3801 static struct omap_hwmod_ocp_if omap44xx_c2c__c2c_target_fw = {
3803 .master = &omap44xx_c2c_hwmod, 3802 .master = &omap44xx_c2c_hwmod,
3804 .slave = &omap44xx_c2c_target_fw_hwmod, 3803 .slave = &omap44xx_c2c_target_fw_hwmod,
3805 .clk = "div_core_ck", 3804 .clk = "div_core_ck",
3806 .addr = omap44xx_c2c_target_fw_addrs, 3805 .addr = omap44xx_c2c_target_fw_addrs,
3807 .user = OCP_USER_MPU, 3806 .user = OCP_USER_MPU,
3808 }; 3807 };
3809 3808
3810 /* l4_cfg -> c2c_target_fw */ 3809 /* l4_cfg -> c2c_target_fw */
3811 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__c2c_target_fw = { 3810 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__c2c_target_fw = {
3812 .master = &omap44xx_l4_cfg_hwmod, 3811 .master = &omap44xx_l4_cfg_hwmod,
3813 .slave = &omap44xx_c2c_target_fw_hwmod, 3812 .slave = &omap44xx_c2c_target_fw_hwmod,
3814 .clk = "l4_div_ck", 3813 .clk = "l4_div_ck",
3815 .user = OCP_USER_MPU | OCP_USER_SDMA, 3814 .user = OCP_USER_MPU | OCP_USER_SDMA,
3816 }; 3815 };
3817 3816
3818 /* l3_main_1 -> dmm */ 3817 /* l3_main_1 -> dmm */
3819 static struct omap_hwmod_ocp_if omap44xx_l3_main_1__dmm = { 3818 static struct omap_hwmod_ocp_if omap44xx_l3_main_1__dmm = {
3820 .master = &omap44xx_l3_main_1_hwmod, 3819 .master = &omap44xx_l3_main_1_hwmod,
3821 .slave = &omap44xx_dmm_hwmod, 3820 .slave = &omap44xx_dmm_hwmod,
3822 .clk = "l3_div_ck", 3821 .clk = "l3_div_ck",
3823 .user = OCP_USER_SDMA, 3822 .user = OCP_USER_SDMA,
3824 }; 3823 };
3825 3824
3826 static struct omap_hwmod_addr_space omap44xx_dmm_addrs[] = { 3825 static struct omap_hwmod_addr_space omap44xx_dmm_addrs[] = {
3827 { 3826 {
3828 .pa_start = 0x4e000000, 3827 .pa_start = 0x4e000000,
3829 .pa_end = 0x4e0007ff, 3828 .pa_end = 0x4e0007ff,
3830 .flags = ADDR_TYPE_RT 3829 .flags = ADDR_TYPE_RT
3831 }, 3830 },
3832 { } 3831 { }
3833 }; 3832 };
3834 3833
3835 /* mpu -> dmm */ 3834 /* mpu -> dmm */
3836 static struct omap_hwmod_ocp_if omap44xx_mpu__dmm = { 3835 static struct omap_hwmod_ocp_if omap44xx_mpu__dmm = {
3837 .master = &omap44xx_mpu_hwmod, 3836 .master = &omap44xx_mpu_hwmod,
3838 .slave = &omap44xx_dmm_hwmod, 3837 .slave = &omap44xx_dmm_hwmod,
3839 .clk = "l3_div_ck", 3838 .clk = "l3_div_ck",
3840 .addr = omap44xx_dmm_addrs, 3839 .addr = omap44xx_dmm_addrs,
3841 .user = OCP_USER_MPU, 3840 .user = OCP_USER_MPU,
3842 }; 3841 };
3843 3842
3844 /* c2c -> emif_fw */ 3843 /* c2c -> emif_fw */
3845 static struct omap_hwmod_ocp_if omap44xx_c2c__emif_fw = { 3844 static struct omap_hwmod_ocp_if omap44xx_c2c__emif_fw = {
3846 .master = &omap44xx_c2c_hwmod, 3845 .master = &omap44xx_c2c_hwmod,
3847 .slave = &omap44xx_emif_fw_hwmod, 3846 .slave = &omap44xx_emif_fw_hwmod,
3848 .clk = "div_core_ck", 3847 .clk = "div_core_ck",
3849 .user = OCP_USER_MPU | OCP_USER_SDMA, 3848 .user = OCP_USER_MPU | OCP_USER_SDMA,
3850 }; 3849 };
3851 3850
3852 /* dmm -> emif_fw */ 3851 /* dmm -> emif_fw */
3853 static struct omap_hwmod_ocp_if omap44xx_dmm__emif_fw = { 3852 static struct omap_hwmod_ocp_if omap44xx_dmm__emif_fw = {
3854 .master = &omap44xx_dmm_hwmod, 3853 .master = &omap44xx_dmm_hwmod,
3855 .slave = &omap44xx_emif_fw_hwmod, 3854 .slave = &omap44xx_emif_fw_hwmod,
3856 .clk = "l3_div_ck", 3855 .clk = "l3_div_ck",
3857 .user = OCP_USER_MPU | OCP_USER_SDMA, 3856 .user = OCP_USER_MPU | OCP_USER_SDMA,
3858 }; 3857 };
3859 3858
3860 static struct omap_hwmod_addr_space omap44xx_emif_fw_addrs[] = { 3859 static struct omap_hwmod_addr_space omap44xx_emif_fw_addrs[] = {
3861 { 3860 {
3862 .pa_start = 0x4a20c000, 3861 .pa_start = 0x4a20c000,
3863 .pa_end = 0x4a20c0ff, 3862 .pa_end = 0x4a20c0ff,
3864 .flags = ADDR_TYPE_RT 3863 .flags = ADDR_TYPE_RT
3865 }, 3864 },
3866 { } 3865 { }
3867 }; 3866 };
3868 3867
3869 /* l4_cfg -> emif_fw */ 3868 /* l4_cfg -> emif_fw */
3870 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__emif_fw = { 3869 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__emif_fw = {
3871 .master = &omap44xx_l4_cfg_hwmod, 3870 .master = &omap44xx_l4_cfg_hwmod,
3872 .slave = &omap44xx_emif_fw_hwmod, 3871 .slave = &omap44xx_emif_fw_hwmod,
3873 .clk = "l4_div_ck", 3872 .clk = "l4_div_ck",
3874 .addr = omap44xx_emif_fw_addrs, 3873 .addr = omap44xx_emif_fw_addrs,
3875 .user = OCP_USER_MPU, 3874 .user = OCP_USER_MPU,
3876 }; 3875 };
3877 3876
3878 /* iva -> l3_instr */ 3877 /* iva -> l3_instr */
3879 static struct omap_hwmod_ocp_if omap44xx_iva__l3_instr = { 3878 static struct omap_hwmod_ocp_if omap44xx_iva__l3_instr = {
3880 .master = &omap44xx_iva_hwmod, 3879 .master = &omap44xx_iva_hwmod,
3881 .slave = &omap44xx_l3_instr_hwmod, 3880 .slave = &omap44xx_l3_instr_hwmod,
3882 .clk = "l3_div_ck", 3881 .clk = "l3_div_ck",
3883 .user = OCP_USER_MPU | OCP_USER_SDMA, 3882 .user = OCP_USER_MPU | OCP_USER_SDMA,
3884 }; 3883 };
3885 3884
3886 /* l3_main_3 -> l3_instr */ 3885 /* l3_main_3 -> l3_instr */
3887 static struct omap_hwmod_ocp_if omap44xx_l3_main_3__l3_instr = { 3886 static struct omap_hwmod_ocp_if omap44xx_l3_main_3__l3_instr = {
3888 .master = &omap44xx_l3_main_3_hwmod, 3887 .master = &omap44xx_l3_main_3_hwmod,
3889 .slave = &omap44xx_l3_instr_hwmod, 3888 .slave = &omap44xx_l3_instr_hwmod,
3890 .clk = "l3_div_ck", 3889 .clk = "l3_div_ck",
3891 .user = OCP_USER_MPU | OCP_USER_SDMA, 3890 .user = OCP_USER_MPU | OCP_USER_SDMA,
3892 }; 3891 };
3893 3892
3894 /* ocp_wp_noc -> l3_instr */ 3893 /* ocp_wp_noc -> l3_instr */
3895 static struct omap_hwmod_ocp_if omap44xx_ocp_wp_noc__l3_instr = { 3894 static struct omap_hwmod_ocp_if omap44xx_ocp_wp_noc__l3_instr = {
3896 .master = &omap44xx_ocp_wp_noc_hwmod, 3895 .master = &omap44xx_ocp_wp_noc_hwmod,
3897 .slave = &omap44xx_l3_instr_hwmod, 3896 .slave = &omap44xx_l3_instr_hwmod,
3898 .clk = "l3_div_ck", 3897 .clk = "l3_div_ck",
3899 .user = OCP_USER_MPU | OCP_USER_SDMA, 3898 .user = OCP_USER_MPU | OCP_USER_SDMA,
3900 }; 3899 };
3901 3900
3902 /* dsp -> l3_main_1 */ 3901 /* dsp -> l3_main_1 */
3903 static struct omap_hwmod_ocp_if omap44xx_dsp__l3_main_1 = { 3902 static struct omap_hwmod_ocp_if omap44xx_dsp__l3_main_1 = {
3904 .master = &omap44xx_dsp_hwmod, 3903 .master = &omap44xx_dsp_hwmod,
3905 .slave = &omap44xx_l3_main_1_hwmod, 3904 .slave = &omap44xx_l3_main_1_hwmod,
3906 .clk = "l3_div_ck", 3905 .clk = "l3_div_ck",
3907 .user = OCP_USER_MPU | OCP_USER_SDMA, 3906 .user = OCP_USER_MPU | OCP_USER_SDMA,
3908 }; 3907 };
3909 3908
3910 /* dss -> l3_main_1 */ 3909 /* dss -> l3_main_1 */
3911 static struct omap_hwmod_ocp_if omap44xx_dss__l3_main_1 = { 3910 static struct omap_hwmod_ocp_if omap44xx_dss__l3_main_1 = {
3912 .master = &omap44xx_dss_hwmod, 3911 .master = &omap44xx_dss_hwmod,
3913 .slave = &omap44xx_l3_main_1_hwmod, 3912 .slave = &omap44xx_l3_main_1_hwmod,
3914 .clk = "l3_div_ck", 3913 .clk = "l3_div_ck",
3915 .user = OCP_USER_MPU | OCP_USER_SDMA, 3914 .user = OCP_USER_MPU | OCP_USER_SDMA,
3916 }; 3915 };
3917 3916
3918 /* l3_main_2 -> l3_main_1 */ 3917 /* l3_main_2 -> l3_main_1 */
3919 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__l3_main_1 = { 3918 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__l3_main_1 = {
3920 .master = &omap44xx_l3_main_2_hwmod, 3919 .master = &omap44xx_l3_main_2_hwmod,
3921 .slave = &omap44xx_l3_main_1_hwmod, 3920 .slave = &omap44xx_l3_main_1_hwmod,
3922 .clk = "l3_div_ck", 3921 .clk = "l3_div_ck",
3923 .user = OCP_USER_MPU | OCP_USER_SDMA, 3922 .user = OCP_USER_MPU | OCP_USER_SDMA,
3924 }; 3923 };
3925 3924
3926 /* l4_cfg -> l3_main_1 */ 3925 /* l4_cfg -> l3_main_1 */
3927 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l3_main_1 = { 3926 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l3_main_1 = {
3928 .master = &omap44xx_l4_cfg_hwmod, 3927 .master = &omap44xx_l4_cfg_hwmod,
3929 .slave = &omap44xx_l3_main_1_hwmod, 3928 .slave = &omap44xx_l3_main_1_hwmod,
3930 .clk = "l4_div_ck", 3929 .clk = "l4_div_ck",
3931 .user = OCP_USER_MPU | OCP_USER_SDMA, 3930 .user = OCP_USER_MPU | OCP_USER_SDMA,
3932 }; 3931 };
3933 3932
3934 /* mmc1 -> l3_main_1 */ 3933 /* mmc1 -> l3_main_1 */
3935 static struct omap_hwmod_ocp_if omap44xx_mmc1__l3_main_1 = { 3934 static struct omap_hwmod_ocp_if omap44xx_mmc1__l3_main_1 = {
3936 .master = &omap44xx_mmc1_hwmod, 3935 .master = &omap44xx_mmc1_hwmod,
3937 .slave = &omap44xx_l3_main_1_hwmod, 3936 .slave = &omap44xx_l3_main_1_hwmod,
3938 .clk = "l3_div_ck", 3937 .clk = "l3_div_ck",
3939 .user = OCP_USER_MPU | OCP_USER_SDMA, 3938 .user = OCP_USER_MPU | OCP_USER_SDMA,
3940 }; 3939 };
3941 3940
3942 /* mmc2 -> l3_main_1 */ 3941 /* mmc2 -> l3_main_1 */
3943 static struct omap_hwmod_ocp_if omap44xx_mmc2__l3_main_1 = { 3942 static struct omap_hwmod_ocp_if omap44xx_mmc2__l3_main_1 = {
3944 .master = &omap44xx_mmc2_hwmod, 3943 .master = &omap44xx_mmc2_hwmod,
3945 .slave = &omap44xx_l3_main_1_hwmod, 3944 .slave = &omap44xx_l3_main_1_hwmod,
3946 .clk = "l3_div_ck", 3945 .clk = "l3_div_ck",
3947 .user = OCP_USER_MPU | OCP_USER_SDMA, 3946 .user = OCP_USER_MPU | OCP_USER_SDMA,
3948 }; 3947 };
3949 3948
3950 static struct omap_hwmod_addr_space omap44xx_l3_main_1_addrs[] = { 3949 static struct omap_hwmod_addr_space omap44xx_l3_main_1_addrs[] = {
3951 { 3950 {
3952 .pa_start = 0x44000000, 3951 .pa_start = 0x44000000,
3953 .pa_end = 0x44000fff, 3952 .pa_end = 0x44000fff,
3954 .flags = ADDR_TYPE_RT 3953 .flags = ADDR_TYPE_RT
3955 }, 3954 },
3956 { } 3955 { }
3957 }; 3956 };
3958 3957
3959 /* mpu -> l3_main_1 */ 3958 /* mpu -> l3_main_1 */
3960 static struct omap_hwmod_ocp_if omap44xx_mpu__l3_main_1 = { 3959 static struct omap_hwmod_ocp_if omap44xx_mpu__l3_main_1 = {
3961 .master = &omap44xx_mpu_hwmod, 3960 .master = &omap44xx_mpu_hwmod,
3962 .slave = &omap44xx_l3_main_1_hwmod, 3961 .slave = &omap44xx_l3_main_1_hwmod,
3963 .clk = "l3_div_ck", 3962 .clk = "l3_div_ck",
3964 .addr = omap44xx_l3_main_1_addrs, 3963 .addr = omap44xx_l3_main_1_addrs,
3965 .user = OCP_USER_MPU, 3964 .user = OCP_USER_MPU,
3966 }; 3965 };
3967 3966
3968 /* c2c_target_fw -> l3_main_2 */ 3967 /* c2c_target_fw -> l3_main_2 */
3969 static struct omap_hwmod_ocp_if omap44xx_c2c_target_fw__l3_main_2 = { 3968 static struct omap_hwmod_ocp_if omap44xx_c2c_target_fw__l3_main_2 = {
3970 .master = &omap44xx_c2c_target_fw_hwmod, 3969 .master = &omap44xx_c2c_target_fw_hwmod,
3971 .slave = &omap44xx_l3_main_2_hwmod, 3970 .slave = &omap44xx_l3_main_2_hwmod,
3972 .clk = "l3_div_ck", 3971 .clk = "l3_div_ck",
3973 .user = OCP_USER_MPU | OCP_USER_SDMA, 3972 .user = OCP_USER_MPU | OCP_USER_SDMA,
3974 }; 3973 };
3975 3974
3976 /* debugss -> l3_main_2 */ 3975 /* debugss -> l3_main_2 */
3977 static struct omap_hwmod_ocp_if omap44xx_debugss__l3_main_2 = { 3976 static struct omap_hwmod_ocp_if omap44xx_debugss__l3_main_2 = {
3978 .master = &omap44xx_debugss_hwmod, 3977 .master = &omap44xx_debugss_hwmod,
3979 .slave = &omap44xx_l3_main_2_hwmod, 3978 .slave = &omap44xx_l3_main_2_hwmod,
3980 .clk = "dbgclk_mux_ck", 3979 .clk = "dbgclk_mux_ck",
3981 .user = OCP_USER_MPU | OCP_USER_SDMA, 3980 .user = OCP_USER_MPU | OCP_USER_SDMA,
3982 }; 3981 };
3983 3982
3984 /* dma_system -> l3_main_2 */ 3983 /* dma_system -> l3_main_2 */
3985 static struct omap_hwmod_ocp_if omap44xx_dma_system__l3_main_2 = { 3984 static struct omap_hwmod_ocp_if omap44xx_dma_system__l3_main_2 = {
3986 .master = &omap44xx_dma_system_hwmod, 3985 .master = &omap44xx_dma_system_hwmod,
3987 .slave = &omap44xx_l3_main_2_hwmod, 3986 .slave = &omap44xx_l3_main_2_hwmod,
3988 .clk = "l3_div_ck", 3987 .clk = "l3_div_ck",
3989 .user = OCP_USER_MPU | OCP_USER_SDMA, 3988 .user = OCP_USER_MPU | OCP_USER_SDMA,
3990 }; 3989 };
3991 3990
3992 /* fdif -> l3_main_2 */ 3991 /* fdif -> l3_main_2 */
3993 static struct omap_hwmod_ocp_if omap44xx_fdif__l3_main_2 = { 3992 static struct omap_hwmod_ocp_if omap44xx_fdif__l3_main_2 = {
3994 .master = &omap44xx_fdif_hwmod, 3993 .master = &omap44xx_fdif_hwmod,
3995 .slave = &omap44xx_l3_main_2_hwmod, 3994 .slave = &omap44xx_l3_main_2_hwmod,
3996 .clk = "l3_div_ck", 3995 .clk = "l3_div_ck",
3997 .user = OCP_USER_MPU | OCP_USER_SDMA, 3996 .user = OCP_USER_MPU | OCP_USER_SDMA,
3998 }; 3997 };
3999 3998
4000 /* gpu -> l3_main_2 */ 3999 /* gpu -> l3_main_2 */
4001 static struct omap_hwmod_ocp_if omap44xx_gpu__l3_main_2 = { 4000 static struct omap_hwmod_ocp_if omap44xx_gpu__l3_main_2 = {
4002 .master = &omap44xx_gpu_hwmod, 4001 .master = &omap44xx_gpu_hwmod,
4003 .slave = &omap44xx_l3_main_2_hwmod, 4002 .slave = &omap44xx_l3_main_2_hwmod,
4004 .clk = "l3_div_ck", 4003 .clk = "l3_div_ck",
4005 .user = OCP_USER_MPU | OCP_USER_SDMA, 4004 .user = OCP_USER_MPU | OCP_USER_SDMA,
4006 }; 4005 };
4007 4006
4008 /* hsi -> l3_main_2 */ 4007 /* hsi -> l3_main_2 */
4009 static struct omap_hwmod_ocp_if omap44xx_hsi__l3_main_2 = { 4008 static struct omap_hwmod_ocp_if omap44xx_hsi__l3_main_2 = {
4010 .master = &omap44xx_hsi_hwmod, 4009 .master = &omap44xx_hsi_hwmod,
4011 .slave = &omap44xx_l3_main_2_hwmod, 4010 .slave = &omap44xx_l3_main_2_hwmod,
4012 .clk = "l3_div_ck", 4011 .clk = "l3_div_ck",
4013 .user = OCP_USER_MPU | OCP_USER_SDMA, 4012 .user = OCP_USER_MPU | OCP_USER_SDMA,
4014 }; 4013 };
4015 4014
4016 /* ipu -> l3_main_2 */ 4015 /* ipu -> l3_main_2 */
4017 static struct omap_hwmod_ocp_if omap44xx_ipu__l3_main_2 = { 4016 static struct omap_hwmod_ocp_if omap44xx_ipu__l3_main_2 = {
4018 .master = &omap44xx_ipu_hwmod, 4017 .master = &omap44xx_ipu_hwmod,
4019 .slave = &omap44xx_l3_main_2_hwmod, 4018 .slave = &omap44xx_l3_main_2_hwmod,
4020 .clk = "l3_div_ck", 4019 .clk = "l3_div_ck",
4021 .user = OCP_USER_MPU | OCP_USER_SDMA, 4020 .user = OCP_USER_MPU | OCP_USER_SDMA,
4022 }; 4021 };
4023 4022
4024 /* iss -> l3_main_2 */ 4023 /* iss -> l3_main_2 */
4025 static struct omap_hwmod_ocp_if omap44xx_iss__l3_main_2 = { 4024 static struct omap_hwmod_ocp_if omap44xx_iss__l3_main_2 = {
4026 .master = &omap44xx_iss_hwmod, 4025 .master = &omap44xx_iss_hwmod,
4027 .slave = &omap44xx_l3_main_2_hwmod, 4026 .slave = &omap44xx_l3_main_2_hwmod,
4028 .clk = "l3_div_ck", 4027 .clk = "l3_div_ck",
4029 .user = OCP_USER_MPU | OCP_USER_SDMA, 4028 .user = OCP_USER_MPU | OCP_USER_SDMA,
4030 }; 4029 };
4031 4030
4032 /* iva -> l3_main_2 */ 4031 /* iva -> l3_main_2 */
4033 static struct omap_hwmod_ocp_if omap44xx_iva__l3_main_2 = { 4032 static struct omap_hwmod_ocp_if omap44xx_iva__l3_main_2 = {
4034 .master = &omap44xx_iva_hwmod, 4033 .master = &omap44xx_iva_hwmod,
4035 .slave = &omap44xx_l3_main_2_hwmod, 4034 .slave = &omap44xx_l3_main_2_hwmod,
4036 .clk = "l3_div_ck", 4035 .clk = "l3_div_ck",
4037 .user = OCP_USER_MPU | OCP_USER_SDMA, 4036 .user = OCP_USER_MPU | OCP_USER_SDMA,
4038 }; 4037 };
4039 4038
4040 static struct omap_hwmod_addr_space omap44xx_l3_main_2_addrs[] = { 4039 static struct omap_hwmod_addr_space omap44xx_l3_main_2_addrs[] = {
4041 { 4040 {
4042 .pa_start = 0x44800000, 4041 .pa_start = 0x44800000,
4043 .pa_end = 0x44801fff, 4042 .pa_end = 0x44801fff,
4044 .flags = ADDR_TYPE_RT 4043 .flags = ADDR_TYPE_RT
4045 }, 4044 },
4046 { } 4045 { }
4047 }; 4046 };
4048 4047
4049 /* l3_main_1 -> l3_main_2 */ 4048 /* l3_main_1 -> l3_main_2 */
4050 static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l3_main_2 = { 4049 static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l3_main_2 = {
4051 .master = &omap44xx_l3_main_1_hwmod, 4050 .master = &omap44xx_l3_main_1_hwmod,
4052 .slave = &omap44xx_l3_main_2_hwmod, 4051 .slave = &omap44xx_l3_main_2_hwmod,
4053 .clk = "l3_div_ck", 4052 .clk = "l3_div_ck",
4054 .addr = omap44xx_l3_main_2_addrs, 4053 .addr = omap44xx_l3_main_2_addrs,
4055 .user = OCP_USER_MPU, 4054 .user = OCP_USER_MPU,
4056 }; 4055 };
4057 4056
4058 /* l4_cfg -> l3_main_2 */ 4057 /* l4_cfg -> l3_main_2 */
4059 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l3_main_2 = { 4058 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l3_main_2 = {
4060 .master = &omap44xx_l4_cfg_hwmod, 4059 .master = &omap44xx_l4_cfg_hwmod,
4061 .slave = &omap44xx_l3_main_2_hwmod, 4060 .slave = &omap44xx_l3_main_2_hwmod,
4062 .clk = "l4_div_ck", 4061 .clk = "l4_div_ck",
4063 .user = OCP_USER_MPU | OCP_USER_SDMA, 4062 .user = OCP_USER_MPU | OCP_USER_SDMA,
4064 }; 4063 };
4065 4064
4066 /* usb_host_fs -> l3_main_2 */ 4065 /* usb_host_fs -> l3_main_2 */
4067 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_usb_host_fs__l3_main_2 = { 4066 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_usb_host_fs__l3_main_2 = {
4068 .master = &omap44xx_usb_host_fs_hwmod, 4067 .master = &omap44xx_usb_host_fs_hwmod,
4069 .slave = &omap44xx_l3_main_2_hwmod, 4068 .slave = &omap44xx_l3_main_2_hwmod,
4070 .clk = "l3_div_ck", 4069 .clk = "l3_div_ck",
4071 .user = OCP_USER_MPU | OCP_USER_SDMA, 4070 .user = OCP_USER_MPU | OCP_USER_SDMA,
4072 }; 4071 };
4073 4072
4074 /* usb_host_hs -> l3_main_2 */ 4073 /* usb_host_hs -> l3_main_2 */
4075 static struct omap_hwmod_ocp_if omap44xx_usb_host_hs__l3_main_2 = { 4074 static struct omap_hwmod_ocp_if omap44xx_usb_host_hs__l3_main_2 = {
4076 .master = &omap44xx_usb_host_hs_hwmod, 4075 .master = &omap44xx_usb_host_hs_hwmod,
4077 .slave = &omap44xx_l3_main_2_hwmod, 4076 .slave = &omap44xx_l3_main_2_hwmod,
4078 .clk = "l3_div_ck", 4077 .clk = "l3_div_ck",
4079 .user = OCP_USER_MPU | OCP_USER_SDMA, 4078 .user = OCP_USER_MPU | OCP_USER_SDMA,
4080 }; 4079 };
4081 4080
4082 /* usb_otg_hs -> l3_main_2 */ 4081 /* usb_otg_hs -> l3_main_2 */
4083 static struct omap_hwmod_ocp_if omap44xx_usb_otg_hs__l3_main_2 = { 4082 static struct omap_hwmod_ocp_if omap44xx_usb_otg_hs__l3_main_2 = {
4084 .master = &omap44xx_usb_otg_hs_hwmod, 4083 .master = &omap44xx_usb_otg_hs_hwmod,
4085 .slave = &omap44xx_l3_main_2_hwmod, 4084 .slave = &omap44xx_l3_main_2_hwmod,
4086 .clk = "l3_div_ck", 4085 .clk = "l3_div_ck",
4087 .user = OCP_USER_MPU | OCP_USER_SDMA, 4086 .user = OCP_USER_MPU | OCP_USER_SDMA,
4088 }; 4087 };
4089 4088
4090 static struct omap_hwmod_addr_space omap44xx_l3_main_3_addrs[] = { 4089 static struct omap_hwmod_addr_space omap44xx_l3_main_3_addrs[] = {
4091 { 4090 {
4092 .pa_start = 0x45000000, 4091 .pa_start = 0x45000000,
4093 .pa_end = 0x45000fff, 4092 .pa_end = 0x45000fff,
4094 .flags = ADDR_TYPE_RT 4093 .flags = ADDR_TYPE_RT
4095 }, 4094 },
4096 { } 4095 { }
4097 }; 4096 };
4098 4097
4099 /* l3_main_1 -> l3_main_3 */ 4098 /* l3_main_1 -> l3_main_3 */
4100 static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l3_main_3 = { 4099 static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l3_main_3 = {
4101 .master = &omap44xx_l3_main_1_hwmod, 4100 .master = &omap44xx_l3_main_1_hwmod,
4102 .slave = &omap44xx_l3_main_3_hwmod, 4101 .slave = &omap44xx_l3_main_3_hwmod,
4103 .clk = "l3_div_ck", 4102 .clk = "l3_div_ck",
4104 .addr = omap44xx_l3_main_3_addrs, 4103 .addr = omap44xx_l3_main_3_addrs,
4105 .user = OCP_USER_MPU, 4104 .user = OCP_USER_MPU,
4106 }; 4105 };
4107 4106
4108 /* l3_main_2 -> l3_main_3 */ 4107 /* l3_main_2 -> l3_main_3 */
4109 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__l3_main_3 = { 4108 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__l3_main_3 = {
4110 .master = &omap44xx_l3_main_2_hwmod, 4109 .master = &omap44xx_l3_main_2_hwmod,
4111 .slave = &omap44xx_l3_main_3_hwmod, 4110 .slave = &omap44xx_l3_main_3_hwmod,
4112 .clk = "l3_div_ck", 4111 .clk = "l3_div_ck",
4113 .user = OCP_USER_MPU | OCP_USER_SDMA, 4112 .user = OCP_USER_MPU | OCP_USER_SDMA,
4114 }; 4113 };
4115 4114
4116 /* l4_cfg -> l3_main_3 */ 4115 /* l4_cfg -> l3_main_3 */
4117 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l3_main_3 = { 4116 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l3_main_3 = {
4118 .master = &omap44xx_l4_cfg_hwmod, 4117 .master = &omap44xx_l4_cfg_hwmod,
4119 .slave = &omap44xx_l3_main_3_hwmod, 4118 .slave = &omap44xx_l3_main_3_hwmod,
4120 .clk = "l4_div_ck", 4119 .clk = "l4_div_ck",
4121 .user = OCP_USER_MPU | OCP_USER_SDMA, 4120 .user = OCP_USER_MPU | OCP_USER_SDMA,
4122 }; 4121 };
4123 4122
4124 /* aess -> l4_abe */ 4123 /* aess -> l4_abe */
4125 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_aess__l4_abe = { 4124 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_aess__l4_abe = {
4126 .master = &omap44xx_aess_hwmod, 4125 .master = &omap44xx_aess_hwmod,
4127 .slave = &omap44xx_l4_abe_hwmod, 4126 .slave = &omap44xx_l4_abe_hwmod,
4128 .clk = "ocp_abe_iclk", 4127 .clk = "ocp_abe_iclk",
4129 .user = OCP_USER_MPU | OCP_USER_SDMA, 4128 .user = OCP_USER_MPU | OCP_USER_SDMA,
4130 }; 4129 };
4131 4130
4132 /* dsp -> l4_abe */ 4131 /* dsp -> l4_abe */
4133 static struct omap_hwmod_ocp_if omap44xx_dsp__l4_abe = { 4132 static struct omap_hwmod_ocp_if omap44xx_dsp__l4_abe = {
4134 .master = &omap44xx_dsp_hwmod, 4133 .master = &omap44xx_dsp_hwmod,
4135 .slave = &omap44xx_l4_abe_hwmod, 4134 .slave = &omap44xx_l4_abe_hwmod,
4136 .clk = "ocp_abe_iclk", 4135 .clk = "ocp_abe_iclk",
4137 .user = OCP_USER_MPU | OCP_USER_SDMA, 4136 .user = OCP_USER_MPU | OCP_USER_SDMA,
4138 }; 4137 };
4139 4138
4140 /* l3_main_1 -> l4_abe */ 4139 /* l3_main_1 -> l4_abe */
4141 static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l4_abe = { 4140 static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l4_abe = {
4142 .master = &omap44xx_l3_main_1_hwmod, 4141 .master = &omap44xx_l3_main_1_hwmod,
4143 .slave = &omap44xx_l4_abe_hwmod, 4142 .slave = &omap44xx_l4_abe_hwmod,
4144 .clk = "l3_div_ck", 4143 .clk = "l3_div_ck",
4145 .user = OCP_USER_MPU | OCP_USER_SDMA, 4144 .user = OCP_USER_MPU | OCP_USER_SDMA,
4146 }; 4145 };
4147 4146
4148 /* mpu -> l4_abe */ 4147 /* mpu -> l4_abe */
4149 static struct omap_hwmod_ocp_if omap44xx_mpu__l4_abe = { 4148 static struct omap_hwmod_ocp_if omap44xx_mpu__l4_abe = {
4150 .master = &omap44xx_mpu_hwmod, 4149 .master = &omap44xx_mpu_hwmod,
4151 .slave = &omap44xx_l4_abe_hwmod, 4150 .slave = &omap44xx_l4_abe_hwmod,
4152 .clk = "ocp_abe_iclk", 4151 .clk = "ocp_abe_iclk",
4153 .user = OCP_USER_MPU | OCP_USER_SDMA, 4152 .user = OCP_USER_MPU | OCP_USER_SDMA,
4154 }; 4153 };
4155 4154
4156 /* l3_main_1 -> l4_cfg */ 4155 /* l3_main_1 -> l4_cfg */
4157 static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l4_cfg = { 4156 static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l4_cfg = {
4158 .master = &omap44xx_l3_main_1_hwmod, 4157 .master = &omap44xx_l3_main_1_hwmod,
4159 .slave = &omap44xx_l4_cfg_hwmod, 4158 .slave = &omap44xx_l4_cfg_hwmod,
4160 .clk = "l3_div_ck", 4159 .clk = "l3_div_ck",
4161 .user = OCP_USER_MPU | OCP_USER_SDMA, 4160 .user = OCP_USER_MPU | OCP_USER_SDMA,
4162 }; 4161 };
4163 4162
4164 /* l3_main_2 -> l4_per */ 4163 /* l3_main_2 -> l4_per */
4165 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__l4_per = { 4164 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__l4_per = {
4166 .master = &omap44xx_l3_main_2_hwmod, 4165 .master = &omap44xx_l3_main_2_hwmod,
4167 .slave = &omap44xx_l4_per_hwmod, 4166 .slave = &omap44xx_l4_per_hwmod,
4168 .clk = "l3_div_ck", 4167 .clk = "l3_div_ck",
4169 .user = OCP_USER_MPU | OCP_USER_SDMA, 4168 .user = OCP_USER_MPU | OCP_USER_SDMA,
4170 }; 4169 };
4171 4170
4172 /* l4_cfg -> l4_wkup */ 4171 /* l4_cfg -> l4_wkup */
4173 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l4_wkup = { 4172 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__l4_wkup = {
4174 .master = &omap44xx_l4_cfg_hwmod, 4173 .master = &omap44xx_l4_cfg_hwmod,
4175 .slave = &omap44xx_l4_wkup_hwmod, 4174 .slave = &omap44xx_l4_wkup_hwmod,
4176 .clk = "l4_div_ck", 4175 .clk = "l4_div_ck",
4177 .user = OCP_USER_MPU | OCP_USER_SDMA, 4176 .user = OCP_USER_MPU | OCP_USER_SDMA,
4178 }; 4177 };
4179 4178
4180 /* mpu -> mpu_private */ 4179 /* mpu -> mpu_private */
4181 static struct omap_hwmod_ocp_if omap44xx_mpu__mpu_private = { 4180 static struct omap_hwmod_ocp_if omap44xx_mpu__mpu_private = {
4182 .master = &omap44xx_mpu_hwmod, 4181 .master = &omap44xx_mpu_hwmod,
4183 .slave = &omap44xx_mpu_private_hwmod, 4182 .slave = &omap44xx_mpu_private_hwmod,
4184 .clk = "l3_div_ck", 4183 .clk = "l3_div_ck",
4185 .user = OCP_USER_MPU | OCP_USER_SDMA, 4184 .user = OCP_USER_MPU | OCP_USER_SDMA,
4186 }; 4185 };
4187 4186
4188 static struct omap_hwmod_addr_space omap44xx_ocp_wp_noc_addrs[] = { 4187 static struct omap_hwmod_addr_space omap44xx_ocp_wp_noc_addrs[] = {
4189 { 4188 {
4190 .pa_start = 0x4a102000, 4189 .pa_start = 0x4a102000,
4191 .pa_end = 0x4a10207f, 4190 .pa_end = 0x4a10207f,
4192 .flags = ADDR_TYPE_RT 4191 .flags = ADDR_TYPE_RT
4193 }, 4192 },
4194 { } 4193 { }
4195 }; 4194 };
4196 4195
4197 /* l4_cfg -> ocp_wp_noc */ 4196 /* l4_cfg -> ocp_wp_noc */
4198 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__ocp_wp_noc = { 4197 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__ocp_wp_noc = {
4199 .master = &omap44xx_l4_cfg_hwmod, 4198 .master = &omap44xx_l4_cfg_hwmod,
4200 .slave = &omap44xx_ocp_wp_noc_hwmod, 4199 .slave = &omap44xx_ocp_wp_noc_hwmod,
4201 .clk = "l4_div_ck", 4200 .clk = "l4_div_ck",
4202 .addr = omap44xx_ocp_wp_noc_addrs, 4201 .addr = omap44xx_ocp_wp_noc_addrs,
4203 .user = OCP_USER_MPU | OCP_USER_SDMA, 4202 .user = OCP_USER_MPU | OCP_USER_SDMA,
4204 }; 4203 };
4205 4204
4206 static struct omap_hwmod_addr_space omap44xx_aess_addrs[] = { 4205 static struct omap_hwmod_addr_space omap44xx_aess_addrs[] = {
4207 { 4206 {
4208 .pa_start = 0x401f1000, 4207 .pa_start = 0x401f1000,
4209 .pa_end = 0x401f13ff, 4208 .pa_end = 0x401f13ff,
4210 .flags = ADDR_TYPE_RT 4209 .flags = ADDR_TYPE_RT
4211 }, 4210 },
4212 { } 4211 { }
4213 }; 4212 };
4214 4213
4215 /* l4_abe -> aess */ 4214 /* l4_abe -> aess */
4216 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_l4_abe__aess = { 4215 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_l4_abe__aess = {
4217 .master = &omap44xx_l4_abe_hwmod, 4216 .master = &omap44xx_l4_abe_hwmod,
4218 .slave = &omap44xx_aess_hwmod, 4217 .slave = &omap44xx_aess_hwmod,
4219 .clk = "ocp_abe_iclk", 4218 .clk = "ocp_abe_iclk",
4220 .addr = omap44xx_aess_addrs, 4219 .addr = omap44xx_aess_addrs,
4221 .user = OCP_USER_MPU, 4220 .user = OCP_USER_MPU,
4222 }; 4221 };
4223 4222
4224 static struct omap_hwmod_addr_space omap44xx_aess_dma_addrs[] = { 4223 static struct omap_hwmod_addr_space omap44xx_aess_dma_addrs[] = {
4225 { 4224 {
4226 .pa_start = 0x490f1000, 4225 .pa_start = 0x490f1000,
4227 .pa_end = 0x490f13ff, 4226 .pa_end = 0x490f13ff,
4228 .flags = ADDR_TYPE_RT 4227 .flags = ADDR_TYPE_RT
4229 }, 4228 },
4230 { } 4229 { }
4231 }; 4230 };
4232 4231
4233 /* l4_abe -> aess (dma) */ 4232 /* l4_abe -> aess (dma) */
4234 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_l4_abe__aess_dma = { 4233 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_l4_abe__aess_dma = {
4235 .master = &omap44xx_l4_abe_hwmod, 4234 .master = &omap44xx_l4_abe_hwmod,
4236 .slave = &omap44xx_aess_hwmod, 4235 .slave = &omap44xx_aess_hwmod,
4237 .clk = "ocp_abe_iclk", 4236 .clk = "ocp_abe_iclk",
4238 .addr = omap44xx_aess_dma_addrs, 4237 .addr = omap44xx_aess_dma_addrs,
4239 .user = OCP_USER_SDMA, 4238 .user = OCP_USER_SDMA,
4240 }; 4239 };
4241 4240
4242 /* l3_main_2 -> c2c */ 4241 /* l3_main_2 -> c2c */
4243 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__c2c = { 4242 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__c2c = {
4244 .master = &omap44xx_l3_main_2_hwmod, 4243 .master = &omap44xx_l3_main_2_hwmod,
4245 .slave = &omap44xx_c2c_hwmod, 4244 .slave = &omap44xx_c2c_hwmod,
4246 .clk = "l3_div_ck", 4245 .clk = "l3_div_ck",
4247 .user = OCP_USER_MPU | OCP_USER_SDMA, 4246 .user = OCP_USER_MPU | OCP_USER_SDMA,
4248 }; 4247 };
4249 4248
4250 static struct omap_hwmod_addr_space omap44xx_counter_32k_addrs[] = { 4249 static struct omap_hwmod_addr_space omap44xx_counter_32k_addrs[] = {
4251 { 4250 {
4252 .pa_start = 0x4a304000, 4251 .pa_start = 0x4a304000,
4253 .pa_end = 0x4a30401f, 4252 .pa_end = 0x4a30401f,
4254 .flags = ADDR_TYPE_RT 4253 .flags = ADDR_TYPE_RT
4255 }, 4254 },
4256 { } 4255 { }
4257 }; 4256 };
4258 4257
4259 /* l4_wkup -> counter_32k */ 4258 /* l4_wkup -> counter_32k */
4260 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__counter_32k = { 4259 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__counter_32k = {
4261 .master = &omap44xx_l4_wkup_hwmod, 4260 .master = &omap44xx_l4_wkup_hwmod,
4262 .slave = &omap44xx_counter_32k_hwmod, 4261 .slave = &omap44xx_counter_32k_hwmod,
4263 .clk = "l4_wkup_clk_mux_ck", 4262 .clk = "l4_wkup_clk_mux_ck",
4264 .addr = omap44xx_counter_32k_addrs, 4263 .addr = omap44xx_counter_32k_addrs,
4265 .user = OCP_USER_MPU | OCP_USER_SDMA, 4264 .user = OCP_USER_MPU | OCP_USER_SDMA,
4266 }; 4265 };
4267 4266
4268 static struct omap_hwmod_addr_space omap44xx_ctrl_module_core_addrs[] = { 4267 static struct omap_hwmod_addr_space omap44xx_ctrl_module_core_addrs[] = {
4269 { 4268 {
4270 .pa_start = 0x4a002000, 4269 .pa_start = 0x4a002000,
4271 .pa_end = 0x4a0027ff, 4270 .pa_end = 0x4a0027ff,
4272 .flags = ADDR_TYPE_RT 4271 .flags = ADDR_TYPE_RT
4273 }, 4272 },
4274 { } 4273 { }
4275 }; 4274 };
4276 4275
4277 /* l4_cfg -> ctrl_module_core */ 4276 /* l4_cfg -> ctrl_module_core */
4278 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__ctrl_module_core = { 4277 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__ctrl_module_core = {
4279 .master = &omap44xx_l4_cfg_hwmod, 4278 .master = &omap44xx_l4_cfg_hwmod,
4280 .slave = &omap44xx_ctrl_module_core_hwmod, 4279 .slave = &omap44xx_ctrl_module_core_hwmod,
4281 .clk = "l4_div_ck", 4280 .clk = "l4_div_ck",
4282 .addr = omap44xx_ctrl_module_core_addrs, 4281 .addr = omap44xx_ctrl_module_core_addrs,
4283 .user = OCP_USER_MPU | OCP_USER_SDMA, 4282 .user = OCP_USER_MPU | OCP_USER_SDMA,
4284 }; 4283 };
4285 4284
4286 static struct omap_hwmod_addr_space omap44xx_ctrl_module_pad_core_addrs[] = { 4285 static struct omap_hwmod_addr_space omap44xx_ctrl_module_pad_core_addrs[] = {
4287 { 4286 {
4288 .pa_start = 0x4a100000, 4287 .pa_start = 0x4a100000,
4289 .pa_end = 0x4a1007ff, 4288 .pa_end = 0x4a1007ff,
4290 .flags = ADDR_TYPE_RT 4289 .flags = ADDR_TYPE_RT
4291 }, 4290 },
4292 { } 4291 { }
4293 }; 4292 };
4294 4293
4295 /* l4_cfg -> ctrl_module_pad_core */ 4294 /* l4_cfg -> ctrl_module_pad_core */
4296 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__ctrl_module_pad_core = { 4295 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__ctrl_module_pad_core = {
4297 .master = &omap44xx_l4_cfg_hwmod, 4296 .master = &omap44xx_l4_cfg_hwmod,
4298 .slave = &omap44xx_ctrl_module_pad_core_hwmod, 4297 .slave = &omap44xx_ctrl_module_pad_core_hwmod,
4299 .clk = "l4_div_ck", 4298 .clk = "l4_div_ck",
4300 .addr = omap44xx_ctrl_module_pad_core_addrs, 4299 .addr = omap44xx_ctrl_module_pad_core_addrs,
4301 .user = OCP_USER_MPU | OCP_USER_SDMA, 4300 .user = OCP_USER_MPU | OCP_USER_SDMA,
4302 }; 4301 };
4303 4302
4304 static struct omap_hwmod_addr_space omap44xx_ctrl_module_wkup_addrs[] = { 4303 static struct omap_hwmod_addr_space omap44xx_ctrl_module_wkup_addrs[] = {
4305 { 4304 {
4306 .pa_start = 0x4a30c000, 4305 .pa_start = 0x4a30c000,
4307 .pa_end = 0x4a30c7ff, 4306 .pa_end = 0x4a30c7ff,
4308 .flags = ADDR_TYPE_RT 4307 .flags = ADDR_TYPE_RT
4309 }, 4308 },
4310 { } 4309 { }
4311 }; 4310 };
4312 4311
4313 /* l4_wkup -> ctrl_module_wkup */ 4312 /* l4_wkup -> ctrl_module_wkup */
4314 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__ctrl_module_wkup = { 4313 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__ctrl_module_wkup = {
4315 .master = &omap44xx_l4_wkup_hwmod, 4314 .master = &omap44xx_l4_wkup_hwmod,
4316 .slave = &omap44xx_ctrl_module_wkup_hwmod, 4315 .slave = &omap44xx_ctrl_module_wkup_hwmod,
4317 .clk = "l4_wkup_clk_mux_ck", 4316 .clk = "l4_wkup_clk_mux_ck",
4318 .addr = omap44xx_ctrl_module_wkup_addrs, 4317 .addr = omap44xx_ctrl_module_wkup_addrs,
4319 .user = OCP_USER_MPU | OCP_USER_SDMA, 4318 .user = OCP_USER_MPU | OCP_USER_SDMA,
4320 }; 4319 };
4321 4320
4322 static struct omap_hwmod_addr_space omap44xx_ctrl_module_pad_wkup_addrs[] = { 4321 static struct omap_hwmod_addr_space omap44xx_ctrl_module_pad_wkup_addrs[] = {
4323 { 4322 {
4324 .pa_start = 0x4a31e000, 4323 .pa_start = 0x4a31e000,
4325 .pa_end = 0x4a31e7ff, 4324 .pa_end = 0x4a31e7ff,
4326 .flags = ADDR_TYPE_RT 4325 .flags = ADDR_TYPE_RT
4327 }, 4326 },
4328 { } 4327 { }
4329 }; 4328 };
4330 4329
4331 /* l4_wkup -> ctrl_module_pad_wkup */ 4330 /* l4_wkup -> ctrl_module_pad_wkup */
4332 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__ctrl_module_pad_wkup = { 4331 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__ctrl_module_pad_wkup = {
4333 .master = &omap44xx_l4_wkup_hwmod, 4332 .master = &omap44xx_l4_wkup_hwmod,
4334 .slave = &omap44xx_ctrl_module_pad_wkup_hwmod, 4333 .slave = &omap44xx_ctrl_module_pad_wkup_hwmod,
4335 .clk = "l4_wkup_clk_mux_ck", 4334 .clk = "l4_wkup_clk_mux_ck",
4336 .addr = omap44xx_ctrl_module_pad_wkup_addrs, 4335 .addr = omap44xx_ctrl_module_pad_wkup_addrs,
4337 .user = OCP_USER_MPU | OCP_USER_SDMA, 4336 .user = OCP_USER_MPU | OCP_USER_SDMA,
4338 }; 4337 };
4339 4338
4340 static struct omap_hwmod_addr_space omap44xx_debugss_addrs[] = { 4339 static struct omap_hwmod_addr_space omap44xx_debugss_addrs[] = {
4341 { 4340 {
4342 .pa_start = 0x54160000, 4341 .pa_start = 0x54160000,
4343 .pa_end = 0x54167fff, 4342 .pa_end = 0x54167fff,
4344 .flags = ADDR_TYPE_RT 4343 .flags = ADDR_TYPE_RT
4345 }, 4344 },
4346 { } 4345 { }
4347 }; 4346 };
4348 4347
4349 /* l3_instr -> debugss */ 4348 /* l3_instr -> debugss */
4350 static struct omap_hwmod_ocp_if omap44xx_l3_instr__debugss = { 4349 static struct omap_hwmod_ocp_if omap44xx_l3_instr__debugss = {
4351 .master = &omap44xx_l3_instr_hwmod, 4350 .master = &omap44xx_l3_instr_hwmod,
4352 .slave = &omap44xx_debugss_hwmod, 4351 .slave = &omap44xx_debugss_hwmod,
4353 .clk = "l3_div_ck", 4352 .clk = "l3_div_ck",
4354 .addr = omap44xx_debugss_addrs, 4353 .addr = omap44xx_debugss_addrs,
4355 .user = OCP_USER_MPU | OCP_USER_SDMA, 4354 .user = OCP_USER_MPU | OCP_USER_SDMA,
4356 }; 4355 };
4357 4356
4358 static struct omap_hwmod_addr_space omap44xx_dma_system_addrs[] = { 4357 static struct omap_hwmod_addr_space omap44xx_dma_system_addrs[] = {
4359 { 4358 {
4360 .pa_start = 0x4a056000, 4359 .pa_start = 0x4a056000,
4361 .pa_end = 0x4a056fff, 4360 .pa_end = 0x4a056fff,
4362 .flags = ADDR_TYPE_RT 4361 .flags = ADDR_TYPE_RT
4363 }, 4362 },
4364 { } 4363 { }
4365 }; 4364 };
4366 4365
4367 /* l4_cfg -> dma_system */ 4366 /* l4_cfg -> dma_system */
4368 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__dma_system = { 4367 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__dma_system = {
4369 .master = &omap44xx_l4_cfg_hwmod, 4368 .master = &omap44xx_l4_cfg_hwmod,
4370 .slave = &omap44xx_dma_system_hwmod, 4369 .slave = &omap44xx_dma_system_hwmod,
4371 .clk = "l4_div_ck", 4370 .clk = "l4_div_ck",
4372 .addr = omap44xx_dma_system_addrs, 4371 .addr = omap44xx_dma_system_addrs,
4373 .user = OCP_USER_MPU | OCP_USER_SDMA, 4372 .user = OCP_USER_MPU | OCP_USER_SDMA,
4374 }; 4373 };
4375 4374
4376 static struct omap_hwmod_addr_space omap44xx_dmic_addrs[] = { 4375 static struct omap_hwmod_addr_space omap44xx_dmic_addrs[] = {
4377 { 4376 {
4378 .name = "mpu", 4377 .name = "mpu",
4379 .pa_start = 0x4012e000, 4378 .pa_start = 0x4012e000,
4380 .pa_end = 0x4012e07f, 4379 .pa_end = 0x4012e07f,
4381 .flags = ADDR_TYPE_RT 4380 .flags = ADDR_TYPE_RT
4382 }, 4381 },
4383 { } 4382 { }
4384 }; 4383 };
4385 4384
4386 /* l4_abe -> dmic */ 4385 /* l4_abe -> dmic */
4387 static struct omap_hwmod_ocp_if omap44xx_l4_abe__dmic = { 4386 static struct omap_hwmod_ocp_if omap44xx_l4_abe__dmic = {
4388 .master = &omap44xx_l4_abe_hwmod, 4387 .master = &omap44xx_l4_abe_hwmod,
4389 .slave = &omap44xx_dmic_hwmod, 4388 .slave = &omap44xx_dmic_hwmod,
4390 .clk = "ocp_abe_iclk", 4389 .clk = "ocp_abe_iclk",
4391 .addr = omap44xx_dmic_addrs, 4390 .addr = omap44xx_dmic_addrs,
4392 .user = OCP_USER_MPU, 4391 .user = OCP_USER_MPU,
4393 }; 4392 };
4394 4393
4395 static struct omap_hwmod_addr_space omap44xx_dmic_dma_addrs[] = { 4394 static struct omap_hwmod_addr_space omap44xx_dmic_dma_addrs[] = {
4396 { 4395 {
4397 .name = "dma", 4396 .name = "dma",
4398 .pa_start = 0x4902e000, 4397 .pa_start = 0x4902e000,
4399 .pa_end = 0x4902e07f, 4398 .pa_end = 0x4902e07f,
4400 .flags = ADDR_TYPE_RT 4399 .flags = ADDR_TYPE_RT
4401 }, 4400 },
4402 { } 4401 { }
4403 }; 4402 };
4404 4403
4405 /* l4_abe -> dmic (dma) */ 4404 /* l4_abe -> dmic (dma) */
4406 static struct omap_hwmod_ocp_if omap44xx_l4_abe__dmic_dma = { 4405 static struct omap_hwmod_ocp_if omap44xx_l4_abe__dmic_dma = {
4407 .master = &omap44xx_l4_abe_hwmod, 4406 .master = &omap44xx_l4_abe_hwmod,
4408 .slave = &omap44xx_dmic_hwmod, 4407 .slave = &omap44xx_dmic_hwmod,
4409 .clk = "ocp_abe_iclk", 4408 .clk = "ocp_abe_iclk",
4410 .addr = omap44xx_dmic_dma_addrs, 4409 .addr = omap44xx_dmic_dma_addrs,
4411 .user = OCP_USER_SDMA, 4410 .user = OCP_USER_SDMA,
4412 }; 4411 };
4413 4412
4414 /* dsp -> iva */ 4413 /* dsp -> iva */
4415 static struct omap_hwmod_ocp_if omap44xx_dsp__iva = { 4414 static struct omap_hwmod_ocp_if omap44xx_dsp__iva = {
4416 .master = &omap44xx_dsp_hwmod, 4415 .master = &omap44xx_dsp_hwmod,
4417 .slave = &omap44xx_iva_hwmod, 4416 .slave = &omap44xx_iva_hwmod,
4418 .clk = "dpll_iva_m5x2_ck", 4417 .clk = "dpll_iva_m5x2_ck",
4419 .user = OCP_USER_DSP, 4418 .user = OCP_USER_DSP,
4420 }; 4419 };
4421 4420
4422 /* dsp -> sl2if */ 4421 /* dsp -> sl2if */
4423 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_dsp__sl2if = { 4422 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_dsp__sl2if = {
4424 .master = &omap44xx_dsp_hwmod, 4423 .master = &omap44xx_dsp_hwmod,
4425 .slave = &omap44xx_sl2if_hwmod, 4424 .slave = &omap44xx_sl2if_hwmod,
4426 .clk = "dpll_iva_m5x2_ck", 4425 .clk = "dpll_iva_m5x2_ck",
4427 .user = OCP_USER_DSP, 4426 .user = OCP_USER_DSP,
4428 }; 4427 };
4429 4428
4430 /* l4_cfg -> dsp */ 4429 /* l4_cfg -> dsp */
4431 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__dsp = { 4430 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__dsp = {
4432 .master = &omap44xx_l4_cfg_hwmod, 4431 .master = &omap44xx_l4_cfg_hwmod,
4433 .slave = &omap44xx_dsp_hwmod, 4432 .slave = &omap44xx_dsp_hwmod,
4434 .clk = "l4_div_ck", 4433 .clk = "l4_div_ck",
4435 .user = OCP_USER_MPU | OCP_USER_SDMA, 4434 .user = OCP_USER_MPU | OCP_USER_SDMA,
4436 }; 4435 };
4437 4436
4438 static struct omap_hwmod_addr_space omap44xx_dss_dma_addrs[] = { 4437 static struct omap_hwmod_addr_space omap44xx_dss_dma_addrs[] = {
4439 { 4438 {
4440 .pa_start = 0x58000000, 4439 .pa_start = 0x58000000,
4441 .pa_end = 0x5800007f, 4440 .pa_end = 0x5800007f,
4442 .flags = ADDR_TYPE_RT 4441 .flags = ADDR_TYPE_RT
4443 }, 4442 },
4444 { } 4443 { }
4445 }; 4444 };
4446 4445
4447 /* l3_main_2 -> dss */ 4446 /* l3_main_2 -> dss */
4448 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss = { 4447 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss = {
4449 .master = &omap44xx_l3_main_2_hwmod, 4448 .master = &omap44xx_l3_main_2_hwmod,
4450 .slave = &omap44xx_dss_hwmod, 4449 .slave = &omap44xx_dss_hwmod,
4451 .clk = "dss_fck", 4450 .clk = "dss_fck",
4452 .addr = omap44xx_dss_dma_addrs, 4451 .addr = omap44xx_dss_dma_addrs,
4453 .user = OCP_USER_SDMA, 4452 .user = OCP_USER_SDMA,
4454 }; 4453 };
4455 4454
4456 static struct omap_hwmod_addr_space omap44xx_dss_addrs[] = { 4455 static struct omap_hwmod_addr_space omap44xx_dss_addrs[] = {
4457 { 4456 {
4458 .pa_start = 0x48040000, 4457 .pa_start = 0x48040000,
4459 .pa_end = 0x4804007f, 4458 .pa_end = 0x4804007f,
4460 .flags = ADDR_TYPE_RT 4459 .flags = ADDR_TYPE_RT
4461 }, 4460 },
4462 { } 4461 { }
4463 }; 4462 };
4464 4463
4465 /* l4_per -> dss */ 4464 /* l4_per -> dss */
4466 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss = { 4465 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss = {
4467 .master = &omap44xx_l4_per_hwmod, 4466 .master = &omap44xx_l4_per_hwmod,
4468 .slave = &omap44xx_dss_hwmod, 4467 .slave = &omap44xx_dss_hwmod,
4469 .clk = "l4_div_ck", 4468 .clk = "l4_div_ck",
4470 .addr = omap44xx_dss_addrs, 4469 .addr = omap44xx_dss_addrs,
4471 .user = OCP_USER_MPU, 4470 .user = OCP_USER_MPU,
4472 }; 4471 };
4473 4472
4474 static struct omap_hwmod_addr_space omap44xx_dss_dispc_dma_addrs[] = { 4473 static struct omap_hwmod_addr_space omap44xx_dss_dispc_dma_addrs[] = {
4475 { 4474 {
4476 .pa_start = 0x58001000, 4475 .pa_start = 0x58001000,
4477 .pa_end = 0x58001fff, 4476 .pa_end = 0x58001fff,
4478 .flags = ADDR_TYPE_RT 4477 .flags = ADDR_TYPE_RT
4479 }, 4478 },
4480 { } 4479 { }
4481 }; 4480 };
4482 4481
4483 /* l3_main_2 -> dss_dispc */ 4482 /* l3_main_2 -> dss_dispc */
4484 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_dispc = { 4483 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_dispc = {
4485 .master = &omap44xx_l3_main_2_hwmod, 4484 .master = &omap44xx_l3_main_2_hwmod,
4486 .slave = &omap44xx_dss_dispc_hwmod, 4485 .slave = &omap44xx_dss_dispc_hwmod,
4487 .clk = "dss_fck", 4486 .clk = "dss_fck",
4488 .addr = omap44xx_dss_dispc_dma_addrs, 4487 .addr = omap44xx_dss_dispc_dma_addrs,
4489 .user = OCP_USER_SDMA, 4488 .user = OCP_USER_SDMA,
4490 }; 4489 };
4491 4490
4492 static struct omap_hwmod_addr_space omap44xx_dss_dispc_addrs[] = { 4491 static struct omap_hwmod_addr_space omap44xx_dss_dispc_addrs[] = {
4493 { 4492 {
4494 .pa_start = 0x48041000, 4493 .pa_start = 0x48041000,
4495 .pa_end = 0x48041fff, 4494 .pa_end = 0x48041fff,
4496 .flags = ADDR_TYPE_RT 4495 .flags = ADDR_TYPE_RT
4497 }, 4496 },
4498 { } 4497 { }
4499 }; 4498 };
4500 4499
4501 /* l4_per -> dss_dispc */ 4500 /* l4_per -> dss_dispc */
4502 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_dispc = { 4501 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_dispc = {
4503 .master = &omap44xx_l4_per_hwmod, 4502 .master = &omap44xx_l4_per_hwmod,
4504 .slave = &omap44xx_dss_dispc_hwmod, 4503 .slave = &omap44xx_dss_dispc_hwmod,
4505 .clk = "l4_div_ck", 4504 .clk = "l4_div_ck",
4506 .addr = omap44xx_dss_dispc_addrs, 4505 .addr = omap44xx_dss_dispc_addrs,
4507 .user = OCP_USER_MPU, 4506 .user = OCP_USER_MPU,
4508 }; 4507 };
4509 4508
4510 static struct omap_hwmod_addr_space omap44xx_dss_dsi1_dma_addrs[] = { 4509 static struct omap_hwmod_addr_space omap44xx_dss_dsi1_dma_addrs[] = {
4511 { 4510 {
4512 .pa_start = 0x58004000, 4511 .pa_start = 0x58004000,
4513 .pa_end = 0x580041ff, 4512 .pa_end = 0x580041ff,
4514 .flags = ADDR_TYPE_RT 4513 .flags = ADDR_TYPE_RT
4515 }, 4514 },
4516 { } 4515 { }
4517 }; 4516 };
4518 4517
4519 /* l3_main_2 -> dss_dsi1 */ 4518 /* l3_main_2 -> dss_dsi1 */
4520 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_dsi1 = { 4519 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_dsi1 = {
4521 .master = &omap44xx_l3_main_2_hwmod, 4520 .master = &omap44xx_l3_main_2_hwmod,
4522 .slave = &omap44xx_dss_dsi1_hwmod, 4521 .slave = &omap44xx_dss_dsi1_hwmod,
4523 .clk = "dss_fck", 4522 .clk = "dss_fck",
4524 .addr = omap44xx_dss_dsi1_dma_addrs, 4523 .addr = omap44xx_dss_dsi1_dma_addrs,
4525 .user = OCP_USER_SDMA, 4524 .user = OCP_USER_SDMA,
4526 }; 4525 };
4527 4526
4528 static struct omap_hwmod_addr_space omap44xx_dss_dsi1_addrs[] = { 4527 static struct omap_hwmod_addr_space omap44xx_dss_dsi1_addrs[] = {
4529 { 4528 {
4530 .pa_start = 0x48044000, 4529 .pa_start = 0x48044000,
4531 .pa_end = 0x480441ff, 4530 .pa_end = 0x480441ff,
4532 .flags = ADDR_TYPE_RT 4531 .flags = ADDR_TYPE_RT
4533 }, 4532 },
4534 { } 4533 { }
4535 }; 4534 };
4536 4535
4537 /* l4_per -> dss_dsi1 */ 4536 /* l4_per -> dss_dsi1 */
4538 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_dsi1 = { 4537 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_dsi1 = {
4539 .master = &omap44xx_l4_per_hwmod, 4538 .master = &omap44xx_l4_per_hwmod,
4540 .slave = &omap44xx_dss_dsi1_hwmod, 4539 .slave = &omap44xx_dss_dsi1_hwmod,
4541 .clk = "l4_div_ck", 4540 .clk = "l4_div_ck",
4542 .addr = omap44xx_dss_dsi1_addrs, 4541 .addr = omap44xx_dss_dsi1_addrs,
4543 .user = OCP_USER_MPU, 4542 .user = OCP_USER_MPU,
4544 }; 4543 };
4545 4544
4546 static struct omap_hwmod_addr_space omap44xx_dss_dsi2_dma_addrs[] = { 4545 static struct omap_hwmod_addr_space omap44xx_dss_dsi2_dma_addrs[] = {
4547 { 4546 {
4548 .pa_start = 0x58005000, 4547 .pa_start = 0x58005000,
4549 .pa_end = 0x580051ff, 4548 .pa_end = 0x580051ff,
4550 .flags = ADDR_TYPE_RT 4549 .flags = ADDR_TYPE_RT
4551 }, 4550 },
4552 { } 4551 { }
4553 }; 4552 };
4554 4553
4555 /* l3_main_2 -> dss_dsi2 */ 4554 /* l3_main_2 -> dss_dsi2 */
4556 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_dsi2 = { 4555 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_dsi2 = {
4557 .master = &omap44xx_l3_main_2_hwmod, 4556 .master = &omap44xx_l3_main_2_hwmod,
4558 .slave = &omap44xx_dss_dsi2_hwmod, 4557 .slave = &omap44xx_dss_dsi2_hwmod,
4559 .clk = "dss_fck", 4558 .clk = "dss_fck",
4560 .addr = omap44xx_dss_dsi2_dma_addrs, 4559 .addr = omap44xx_dss_dsi2_dma_addrs,
4561 .user = OCP_USER_SDMA, 4560 .user = OCP_USER_SDMA,
4562 }; 4561 };
4563 4562
4564 static struct omap_hwmod_addr_space omap44xx_dss_dsi2_addrs[] = { 4563 static struct omap_hwmod_addr_space omap44xx_dss_dsi2_addrs[] = {
4565 { 4564 {
4566 .pa_start = 0x48045000, 4565 .pa_start = 0x48045000,
4567 .pa_end = 0x480451ff, 4566 .pa_end = 0x480451ff,
4568 .flags = ADDR_TYPE_RT 4567 .flags = ADDR_TYPE_RT
4569 }, 4568 },
4570 { } 4569 { }
4571 }; 4570 };
4572 4571
4573 /* l4_per -> dss_dsi2 */ 4572 /* l4_per -> dss_dsi2 */
4574 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_dsi2 = { 4573 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_dsi2 = {
4575 .master = &omap44xx_l4_per_hwmod, 4574 .master = &omap44xx_l4_per_hwmod,
4576 .slave = &omap44xx_dss_dsi2_hwmod, 4575 .slave = &omap44xx_dss_dsi2_hwmod,
4577 .clk = "l4_div_ck", 4576 .clk = "l4_div_ck",
4578 .addr = omap44xx_dss_dsi2_addrs, 4577 .addr = omap44xx_dss_dsi2_addrs,
4579 .user = OCP_USER_MPU, 4578 .user = OCP_USER_MPU,
4580 }; 4579 };
4581 4580
4582 static struct omap_hwmod_addr_space omap44xx_dss_hdmi_dma_addrs[] = { 4581 static struct omap_hwmod_addr_space omap44xx_dss_hdmi_dma_addrs[] = {
4583 { 4582 {
4584 .pa_start = 0x58006000, 4583 .pa_start = 0x58006000,
4585 .pa_end = 0x58006fff, 4584 .pa_end = 0x58006fff,
4586 .flags = ADDR_TYPE_RT 4585 .flags = ADDR_TYPE_RT
4587 }, 4586 },
4588 { } 4587 { }
4589 }; 4588 };
4590 4589
4591 /* l3_main_2 -> dss_hdmi */ 4590 /* l3_main_2 -> dss_hdmi */
4592 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_hdmi = { 4591 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_hdmi = {
4593 .master = &omap44xx_l3_main_2_hwmod, 4592 .master = &omap44xx_l3_main_2_hwmod,
4594 .slave = &omap44xx_dss_hdmi_hwmod, 4593 .slave = &omap44xx_dss_hdmi_hwmod,
4595 .clk = "dss_fck", 4594 .clk = "dss_fck",
4596 .addr = omap44xx_dss_hdmi_dma_addrs, 4595 .addr = omap44xx_dss_hdmi_dma_addrs,
4597 .user = OCP_USER_SDMA, 4596 .user = OCP_USER_SDMA,
4598 }; 4597 };
4599 4598
4600 static struct omap_hwmod_addr_space omap44xx_dss_hdmi_addrs[] = { 4599 static struct omap_hwmod_addr_space omap44xx_dss_hdmi_addrs[] = {
4601 { 4600 {
4602 .pa_start = 0x48046000, 4601 .pa_start = 0x48046000,
4603 .pa_end = 0x48046fff, 4602 .pa_end = 0x48046fff,
4604 .flags = ADDR_TYPE_RT 4603 .flags = ADDR_TYPE_RT
4605 }, 4604 },
4606 { } 4605 { }
4607 }; 4606 };
4608 4607
4609 /* l4_per -> dss_hdmi */ 4608 /* l4_per -> dss_hdmi */
4610 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_hdmi = { 4609 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_hdmi = {
4611 .master = &omap44xx_l4_per_hwmod, 4610 .master = &omap44xx_l4_per_hwmod,
4612 .slave = &omap44xx_dss_hdmi_hwmod, 4611 .slave = &omap44xx_dss_hdmi_hwmod,
4613 .clk = "l4_div_ck", 4612 .clk = "l4_div_ck",
4614 .addr = omap44xx_dss_hdmi_addrs, 4613 .addr = omap44xx_dss_hdmi_addrs,
4615 .user = OCP_USER_MPU, 4614 .user = OCP_USER_MPU,
4616 }; 4615 };
4617 4616
4618 static struct omap_hwmod_addr_space omap44xx_dss_rfbi_dma_addrs[] = { 4617 static struct omap_hwmod_addr_space omap44xx_dss_rfbi_dma_addrs[] = {
4619 { 4618 {
4620 .pa_start = 0x58002000, 4619 .pa_start = 0x58002000,
4621 .pa_end = 0x580020ff, 4620 .pa_end = 0x580020ff,
4622 .flags = ADDR_TYPE_RT 4621 .flags = ADDR_TYPE_RT
4623 }, 4622 },
4624 { } 4623 { }
4625 }; 4624 };
4626 4625
4627 /* l3_main_2 -> dss_rfbi */ 4626 /* l3_main_2 -> dss_rfbi */
4628 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_rfbi = { 4627 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_rfbi = {
4629 .master = &omap44xx_l3_main_2_hwmod, 4628 .master = &omap44xx_l3_main_2_hwmod,
4630 .slave = &omap44xx_dss_rfbi_hwmod, 4629 .slave = &omap44xx_dss_rfbi_hwmod,
4631 .clk = "dss_fck", 4630 .clk = "dss_fck",
4632 .addr = omap44xx_dss_rfbi_dma_addrs, 4631 .addr = omap44xx_dss_rfbi_dma_addrs,
4633 .user = OCP_USER_SDMA, 4632 .user = OCP_USER_SDMA,
4634 }; 4633 };
4635 4634
4636 static struct omap_hwmod_addr_space omap44xx_dss_rfbi_addrs[] = { 4635 static struct omap_hwmod_addr_space omap44xx_dss_rfbi_addrs[] = {
4637 { 4636 {
4638 .pa_start = 0x48042000, 4637 .pa_start = 0x48042000,
4639 .pa_end = 0x480420ff, 4638 .pa_end = 0x480420ff,
4640 .flags = ADDR_TYPE_RT 4639 .flags = ADDR_TYPE_RT
4641 }, 4640 },
4642 { } 4641 { }
4643 }; 4642 };
4644 4643
4645 /* l4_per -> dss_rfbi */ 4644 /* l4_per -> dss_rfbi */
4646 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_rfbi = { 4645 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_rfbi = {
4647 .master = &omap44xx_l4_per_hwmod, 4646 .master = &omap44xx_l4_per_hwmod,
4648 .slave = &omap44xx_dss_rfbi_hwmod, 4647 .slave = &omap44xx_dss_rfbi_hwmod,
4649 .clk = "l4_div_ck", 4648 .clk = "l4_div_ck",
4650 .addr = omap44xx_dss_rfbi_addrs, 4649 .addr = omap44xx_dss_rfbi_addrs,
4651 .user = OCP_USER_MPU, 4650 .user = OCP_USER_MPU,
4652 }; 4651 };
4653 4652
4654 static struct omap_hwmod_addr_space omap44xx_dss_venc_dma_addrs[] = { 4653 static struct omap_hwmod_addr_space omap44xx_dss_venc_dma_addrs[] = {
4655 { 4654 {
4656 .pa_start = 0x58003000, 4655 .pa_start = 0x58003000,
4657 .pa_end = 0x580030ff, 4656 .pa_end = 0x580030ff,
4658 .flags = ADDR_TYPE_RT 4657 .flags = ADDR_TYPE_RT
4659 }, 4658 },
4660 { } 4659 { }
4661 }; 4660 };
4662 4661
4663 /* l3_main_2 -> dss_venc */ 4662 /* l3_main_2 -> dss_venc */
4664 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_venc = { 4663 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__dss_venc = {
4665 .master = &omap44xx_l3_main_2_hwmod, 4664 .master = &omap44xx_l3_main_2_hwmod,
4666 .slave = &omap44xx_dss_venc_hwmod, 4665 .slave = &omap44xx_dss_venc_hwmod,
4667 .clk = "dss_fck", 4666 .clk = "dss_fck",
4668 .addr = omap44xx_dss_venc_dma_addrs, 4667 .addr = omap44xx_dss_venc_dma_addrs,
4669 .user = OCP_USER_SDMA, 4668 .user = OCP_USER_SDMA,
4670 }; 4669 };
4671 4670
4672 static struct omap_hwmod_addr_space omap44xx_dss_venc_addrs[] = { 4671 static struct omap_hwmod_addr_space omap44xx_dss_venc_addrs[] = {
4673 { 4672 {
4674 .pa_start = 0x48043000, 4673 .pa_start = 0x48043000,
4675 .pa_end = 0x480430ff, 4674 .pa_end = 0x480430ff,
4676 .flags = ADDR_TYPE_RT 4675 .flags = ADDR_TYPE_RT
4677 }, 4676 },
4678 { } 4677 { }
4679 }; 4678 };
4680 4679
4681 /* l4_per -> dss_venc */ 4680 /* l4_per -> dss_venc */
4682 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_venc = { 4681 static struct omap_hwmod_ocp_if omap44xx_l4_per__dss_venc = {
4683 .master = &omap44xx_l4_per_hwmod, 4682 .master = &omap44xx_l4_per_hwmod,
4684 .slave = &omap44xx_dss_venc_hwmod, 4683 .slave = &omap44xx_dss_venc_hwmod,
4685 .clk = "l4_div_ck", 4684 .clk = "l4_div_ck",
4686 .addr = omap44xx_dss_venc_addrs, 4685 .addr = omap44xx_dss_venc_addrs,
4687 .user = OCP_USER_MPU, 4686 .user = OCP_USER_MPU,
4688 }; 4687 };
4689 4688
4690 static struct omap_hwmod_addr_space omap44xx_elm_addrs[] = { 4689 static struct omap_hwmod_addr_space omap44xx_elm_addrs[] = {
4691 { 4690 {
4692 .pa_start = 0x48078000, 4691 .pa_start = 0x48078000,
4693 .pa_end = 0x48078fff, 4692 .pa_end = 0x48078fff,
4694 .flags = ADDR_TYPE_RT 4693 .flags = ADDR_TYPE_RT
4695 }, 4694 },
4696 { } 4695 { }
4697 }; 4696 };
4698 4697
4699 /* l4_per -> elm */ 4698 /* l4_per -> elm */
4700 static struct omap_hwmod_ocp_if omap44xx_l4_per__elm = { 4699 static struct omap_hwmod_ocp_if omap44xx_l4_per__elm = {
4701 .master = &omap44xx_l4_per_hwmod, 4700 .master = &omap44xx_l4_per_hwmod,
4702 .slave = &omap44xx_elm_hwmod, 4701 .slave = &omap44xx_elm_hwmod,
4703 .clk = "l4_div_ck", 4702 .clk = "l4_div_ck",
4704 .addr = omap44xx_elm_addrs, 4703 .addr = omap44xx_elm_addrs,
4705 .user = OCP_USER_MPU | OCP_USER_SDMA, 4704 .user = OCP_USER_MPU | OCP_USER_SDMA,
4706 }; 4705 };
4707 4706
4708 static struct omap_hwmod_addr_space omap44xx_emif1_addrs[] = { 4707 static struct omap_hwmod_addr_space omap44xx_emif1_addrs[] = {
4709 { 4708 {
4710 .pa_start = 0x4c000000, 4709 .pa_start = 0x4c000000,
4711 .pa_end = 0x4c0000ff, 4710 .pa_end = 0x4c0000ff,
4712 .flags = ADDR_TYPE_RT 4711 .flags = ADDR_TYPE_RT
4713 }, 4712 },
4714 { } 4713 { }
4715 }; 4714 };
4716 4715
4717 /* emif_fw -> emif1 */ 4716 /* emif_fw -> emif1 */
4718 static struct omap_hwmod_ocp_if omap44xx_emif_fw__emif1 = { 4717 static struct omap_hwmod_ocp_if omap44xx_emif_fw__emif1 = {
4719 .master = &omap44xx_emif_fw_hwmod, 4718 .master = &omap44xx_emif_fw_hwmod,
4720 .slave = &omap44xx_emif1_hwmod, 4719 .slave = &omap44xx_emif1_hwmod,
4721 .clk = "l3_div_ck", 4720 .clk = "l3_div_ck",
4722 .addr = omap44xx_emif1_addrs, 4721 .addr = omap44xx_emif1_addrs,
4723 .user = OCP_USER_MPU | OCP_USER_SDMA, 4722 .user = OCP_USER_MPU | OCP_USER_SDMA,
4724 }; 4723 };
4725 4724
4726 static struct omap_hwmod_addr_space omap44xx_emif2_addrs[] = { 4725 static struct omap_hwmod_addr_space omap44xx_emif2_addrs[] = {
4727 { 4726 {
4728 .pa_start = 0x4d000000, 4727 .pa_start = 0x4d000000,
4729 .pa_end = 0x4d0000ff, 4728 .pa_end = 0x4d0000ff,
4730 .flags = ADDR_TYPE_RT 4729 .flags = ADDR_TYPE_RT
4731 }, 4730 },
4732 { } 4731 { }
4733 }; 4732 };
4734 4733
4735 /* emif_fw -> emif2 */ 4734 /* emif_fw -> emif2 */
4736 static struct omap_hwmod_ocp_if omap44xx_emif_fw__emif2 = { 4735 static struct omap_hwmod_ocp_if omap44xx_emif_fw__emif2 = {
4737 .master = &omap44xx_emif_fw_hwmod, 4736 .master = &omap44xx_emif_fw_hwmod,
4738 .slave = &omap44xx_emif2_hwmod, 4737 .slave = &omap44xx_emif2_hwmod,
4739 .clk = "l3_div_ck", 4738 .clk = "l3_div_ck",
4740 .addr = omap44xx_emif2_addrs, 4739 .addr = omap44xx_emif2_addrs,
4741 .user = OCP_USER_MPU | OCP_USER_SDMA, 4740 .user = OCP_USER_MPU | OCP_USER_SDMA,
4742 }; 4741 };
4743 4742
4744 static struct omap_hwmod_addr_space omap44xx_fdif_addrs[] = { 4743 static struct omap_hwmod_addr_space omap44xx_fdif_addrs[] = {
4745 { 4744 {
4746 .pa_start = 0x4a10a000, 4745 .pa_start = 0x4a10a000,
4747 .pa_end = 0x4a10a1ff, 4746 .pa_end = 0x4a10a1ff,
4748 .flags = ADDR_TYPE_RT 4747 .flags = ADDR_TYPE_RT
4749 }, 4748 },
4750 { } 4749 { }
4751 }; 4750 };
4752 4751
4753 /* l4_cfg -> fdif */ 4752 /* l4_cfg -> fdif */
4754 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__fdif = { 4753 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__fdif = {
4755 .master = &omap44xx_l4_cfg_hwmod, 4754 .master = &omap44xx_l4_cfg_hwmod,
4756 .slave = &omap44xx_fdif_hwmod, 4755 .slave = &omap44xx_fdif_hwmod,
4757 .clk = "l4_div_ck", 4756 .clk = "l4_div_ck",
4758 .addr = omap44xx_fdif_addrs, 4757 .addr = omap44xx_fdif_addrs,
4759 .user = OCP_USER_MPU | OCP_USER_SDMA, 4758 .user = OCP_USER_MPU | OCP_USER_SDMA,
4760 }; 4759 };
4761 4760
4762 static struct omap_hwmod_addr_space omap44xx_gpio1_addrs[] = { 4761 static struct omap_hwmod_addr_space omap44xx_gpio1_addrs[] = {
4763 { 4762 {
4764 .pa_start = 0x4a310000, 4763 .pa_start = 0x4a310000,
4765 .pa_end = 0x4a3101ff, 4764 .pa_end = 0x4a3101ff,
4766 .flags = ADDR_TYPE_RT 4765 .flags = ADDR_TYPE_RT
4767 }, 4766 },
4768 { } 4767 { }
4769 }; 4768 };
4770 4769
4771 /* l4_wkup -> gpio1 */ 4770 /* l4_wkup -> gpio1 */
4772 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__gpio1 = { 4771 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__gpio1 = {
4773 .master = &omap44xx_l4_wkup_hwmod, 4772 .master = &omap44xx_l4_wkup_hwmod,
4774 .slave = &omap44xx_gpio1_hwmod, 4773 .slave = &omap44xx_gpio1_hwmod,
4775 .clk = "l4_wkup_clk_mux_ck", 4774 .clk = "l4_wkup_clk_mux_ck",
4776 .addr = omap44xx_gpio1_addrs, 4775 .addr = omap44xx_gpio1_addrs,
4777 .user = OCP_USER_MPU | OCP_USER_SDMA, 4776 .user = OCP_USER_MPU | OCP_USER_SDMA,
4778 }; 4777 };
4779 4778
4780 static struct omap_hwmod_addr_space omap44xx_gpio2_addrs[] = { 4779 static struct omap_hwmod_addr_space omap44xx_gpio2_addrs[] = {
4781 { 4780 {
4782 .pa_start = 0x48055000, 4781 .pa_start = 0x48055000,
4783 .pa_end = 0x480551ff, 4782 .pa_end = 0x480551ff,
4784 .flags = ADDR_TYPE_RT 4783 .flags = ADDR_TYPE_RT
4785 }, 4784 },
4786 { } 4785 { }
4787 }; 4786 };
4788 4787
4789 /* l4_per -> gpio2 */ 4788 /* l4_per -> gpio2 */
4790 static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio2 = { 4789 static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio2 = {
4791 .master = &omap44xx_l4_per_hwmod, 4790 .master = &omap44xx_l4_per_hwmod,
4792 .slave = &omap44xx_gpio2_hwmod, 4791 .slave = &omap44xx_gpio2_hwmod,
4793 .clk = "l4_div_ck", 4792 .clk = "l4_div_ck",
4794 .addr = omap44xx_gpio2_addrs, 4793 .addr = omap44xx_gpio2_addrs,
4795 .user = OCP_USER_MPU | OCP_USER_SDMA, 4794 .user = OCP_USER_MPU | OCP_USER_SDMA,
4796 }; 4795 };
4797 4796
4798 static struct omap_hwmod_addr_space omap44xx_gpio3_addrs[] = { 4797 static struct omap_hwmod_addr_space omap44xx_gpio3_addrs[] = {
4799 { 4798 {
4800 .pa_start = 0x48057000, 4799 .pa_start = 0x48057000,
4801 .pa_end = 0x480571ff, 4800 .pa_end = 0x480571ff,
4802 .flags = ADDR_TYPE_RT 4801 .flags = ADDR_TYPE_RT
4803 }, 4802 },
4804 { } 4803 { }
4805 }; 4804 };
4806 4805
4807 /* l4_per -> gpio3 */ 4806 /* l4_per -> gpio3 */
4808 static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio3 = { 4807 static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio3 = {
4809 .master = &omap44xx_l4_per_hwmod, 4808 .master = &omap44xx_l4_per_hwmod,
4810 .slave = &omap44xx_gpio3_hwmod, 4809 .slave = &omap44xx_gpio3_hwmod,
4811 .clk = "l4_div_ck", 4810 .clk = "l4_div_ck",
4812 .addr = omap44xx_gpio3_addrs, 4811 .addr = omap44xx_gpio3_addrs,
4813 .user = OCP_USER_MPU | OCP_USER_SDMA, 4812 .user = OCP_USER_MPU | OCP_USER_SDMA,
4814 }; 4813 };
4815 4814
4816 static struct omap_hwmod_addr_space omap44xx_gpio4_addrs[] = { 4815 static struct omap_hwmod_addr_space omap44xx_gpio4_addrs[] = {
4817 { 4816 {
4818 .pa_start = 0x48059000, 4817 .pa_start = 0x48059000,
4819 .pa_end = 0x480591ff, 4818 .pa_end = 0x480591ff,
4820 .flags = ADDR_TYPE_RT 4819 .flags = ADDR_TYPE_RT
4821 }, 4820 },
4822 { } 4821 { }
4823 }; 4822 };
4824 4823
4825 /* l4_per -> gpio4 */ 4824 /* l4_per -> gpio4 */
4826 static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio4 = { 4825 static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio4 = {
4827 .master = &omap44xx_l4_per_hwmod, 4826 .master = &omap44xx_l4_per_hwmod,
4828 .slave = &omap44xx_gpio4_hwmod, 4827 .slave = &omap44xx_gpio4_hwmod,
4829 .clk = "l4_div_ck", 4828 .clk = "l4_div_ck",
4830 .addr = omap44xx_gpio4_addrs, 4829 .addr = omap44xx_gpio4_addrs,
4831 .user = OCP_USER_MPU | OCP_USER_SDMA, 4830 .user = OCP_USER_MPU | OCP_USER_SDMA,
4832 }; 4831 };
4833 4832
4834 static struct omap_hwmod_addr_space omap44xx_gpio5_addrs[] = { 4833 static struct omap_hwmod_addr_space omap44xx_gpio5_addrs[] = {
4835 { 4834 {
4836 .pa_start = 0x4805b000, 4835 .pa_start = 0x4805b000,
4837 .pa_end = 0x4805b1ff, 4836 .pa_end = 0x4805b1ff,
4838 .flags = ADDR_TYPE_RT 4837 .flags = ADDR_TYPE_RT
4839 }, 4838 },
4840 { } 4839 { }
4841 }; 4840 };
4842 4841
4843 /* l4_per -> gpio5 */ 4842 /* l4_per -> gpio5 */
4844 static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio5 = { 4843 static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio5 = {
4845 .master = &omap44xx_l4_per_hwmod, 4844 .master = &omap44xx_l4_per_hwmod,
4846 .slave = &omap44xx_gpio5_hwmod, 4845 .slave = &omap44xx_gpio5_hwmod,
4847 .clk = "l4_div_ck", 4846 .clk = "l4_div_ck",
4848 .addr = omap44xx_gpio5_addrs, 4847 .addr = omap44xx_gpio5_addrs,
4849 .user = OCP_USER_MPU | OCP_USER_SDMA, 4848 .user = OCP_USER_MPU | OCP_USER_SDMA,
4850 }; 4849 };
4851 4850
4852 static struct omap_hwmod_addr_space omap44xx_gpio6_addrs[] = { 4851 static struct omap_hwmod_addr_space omap44xx_gpio6_addrs[] = {
4853 { 4852 {
4854 .pa_start = 0x4805d000, 4853 .pa_start = 0x4805d000,
4855 .pa_end = 0x4805d1ff, 4854 .pa_end = 0x4805d1ff,
4856 .flags = ADDR_TYPE_RT 4855 .flags = ADDR_TYPE_RT
4857 }, 4856 },
4858 { } 4857 { }
4859 }; 4858 };
4860 4859
4861 /* l4_per -> gpio6 */ 4860 /* l4_per -> gpio6 */
4862 static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio6 = { 4861 static struct omap_hwmod_ocp_if omap44xx_l4_per__gpio6 = {
4863 .master = &omap44xx_l4_per_hwmod, 4862 .master = &omap44xx_l4_per_hwmod,
4864 .slave = &omap44xx_gpio6_hwmod, 4863 .slave = &omap44xx_gpio6_hwmod,
4865 .clk = "l4_div_ck", 4864 .clk = "l4_div_ck",
4866 .addr = omap44xx_gpio6_addrs, 4865 .addr = omap44xx_gpio6_addrs,
4867 .user = OCP_USER_MPU | OCP_USER_SDMA, 4866 .user = OCP_USER_MPU | OCP_USER_SDMA,
4868 }; 4867 };
4869 4868
4870 static struct omap_hwmod_addr_space omap44xx_gpmc_addrs[] = { 4869 static struct omap_hwmod_addr_space omap44xx_gpmc_addrs[] = {
4871 { 4870 {
4872 .pa_start = 0x50000000, 4871 .pa_start = 0x50000000,
4873 .pa_end = 0x500003ff, 4872 .pa_end = 0x500003ff,
4874 .flags = ADDR_TYPE_RT 4873 .flags = ADDR_TYPE_RT
4875 }, 4874 },
4876 { } 4875 { }
4877 }; 4876 };
4878 4877
4879 /* l3_main_2 -> gpmc */ 4878 /* l3_main_2 -> gpmc */
4880 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__gpmc = { 4879 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__gpmc = {
4881 .master = &omap44xx_l3_main_2_hwmod, 4880 .master = &omap44xx_l3_main_2_hwmod,
4882 .slave = &omap44xx_gpmc_hwmod, 4881 .slave = &omap44xx_gpmc_hwmod,
4883 .clk = "l3_div_ck", 4882 .clk = "l3_div_ck",
4884 .addr = omap44xx_gpmc_addrs, 4883 .addr = omap44xx_gpmc_addrs,
4885 .user = OCP_USER_MPU | OCP_USER_SDMA, 4884 .user = OCP_USER_MPU | OCP_USER_SDMA,
4886 }; 4885 };
4887 4886
4888 static struct omap_hwmod_addr_space omap44xx_gpu_addrs[] = { 4887 static struct omap_hwmod_addr_space omap44xx_gpu_addrs[] = {
4889 { 4888 {
4890 .pa_start = 0x56000000, 4889 .pa_start = 0x56000000,
4891 .pa_end = 0x5600ffff, 4890 .pa_end = 0x5600ffff,
4892 .flags = ADDR_TYPE_RT 4891 .flags = ADDR_TYPE_RT
4893 }, 4892 },
4894 { } 4893 { }
4895 }; 4894 };
4896 4895
4897 /* l3_main_2 -> gpu */ 4896 /* l3_main_2 -> gpu */
4898 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__gpu = { 4897 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__gpu = {
4899 .master = &omap44xx_l3_main_2_hwmod, 4898 .master = &omap44xx_l3_main_2_hwmod,
4900 .slave = &omap44xx_gpu_hwmod, 4899 .slave = &omap44xx_gpu_hwmod,
4901 .clk = "l3_div_ck", 4900 .clk = "l3_div_ck",
4902 .addr = omap44xx_gpu_addrs, 4901 .addr = omap44xx_gpu_addrs,
4903 .user = OCP_USER_MPU | OCP_USER_SDMA, 4902 .user = OCP_USER_MPU | OCP_USER_SDMA,
4904 }; 4903 };
4905 4904
4906 static struct omap_hwmod_addr_space omap44xx_hdq1w_addrs[] = { 4905 static struct omap_hwmod_addr_space omap44xx_hdq1w_addrs[] = {
4907 { 4906 {
4908 .pa_start = 0x480b2000, 4907 .pa_start = 0x480b2000,
4909 .pa_end = 0x480b201f, 4908 .pa_end = 0x480b201f,
4910 .flags = ADDR_TYPE_RT 4909 .flags = ADDR_TYPE_RT
4911 }, 4910 },
4912 { } 4911 { }
4913 }; 4912 };
4914 4913
4915 /* l4_per -> hdq1w */ 4914 /* l4_per -> hdq1w */
4916 static struct omap_hwmod_ocp_if omap44xx_l4_per__hdq1w = { 4915 static struct omap_hwmod_ocp_if omap44xx_l4_per__hdq1w = {
4917 .master = &omap44xx_l4_per_hwmod, 4916 .master = &omap44xx_l4_per_hwmod,
4918 .slave = &omap44xx_hdq1w_hwmod, 4917 .slave = &omap44xx_hdq1w_hwmod,
4919 .clk = "l4_div_ck", 4918 .clk = "l4_div_ck",
4920 .addr = omap44xx_hdq1w_addrs, 4919 .addr = omap44xx_hdq1w_addrs,
4921 .user = OCP_USER_MPU | OCP_USER_SDMA, 4920 .user = OCP_USER_MPU | OCP_USER_SDMA,
4922 }; 4921 };
4923 4922
4924 static struct omap_hwmod_addr_space omap44xx_hsi_addrs[] = { 4923 static struct omap_hwmod_addr_space omap44xx_hsi_addrs[] = {
4925 { 4924 {
4926 .pa_start = 0x4a058000, 4925 .pa_start = 0x4a058000,
4927 .pa_end = 0x4a05bfff, 4926 .pa_end = 0x4a05bfff,
4928 .flags = ADDR_TYPE_RT 4927 .flags = ADDR_TYPE_RT
4929 }, 4928 },
4930 { } 4929 { }
4931 }; 4930 };
4932 4931
4933 /* l4_cfg -> hsi */ 4932 /* l4_cfg -> hsi */
4934 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__hsi = { 4933 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__hsi = {
4935 .master = &omap44xx_l4_cfg_hwmod, 4934 .master = &omap44xx_l4_cfg_hwmod,
4936 .slave = &omap44xx_hsi_hwmod, 4935 .slave = &omap44xx_hsi_hwmod,
4937 .clk = "l4_div_ck", 4936 .clk = "l4_div_ck",
4938 .addr = omap44xx_hsi_addrs, 4937 .addr = omap44xx_hsi_addrs,
4939 .user = OCP_USER_MPU | OCP_USER_SDMA, 4938 .user = OCP_USER_MPU | OCP_USER_SDMA,
4940 }; 4939 };
4941 4940
4942 static struct omap_hwmod_addr_space omap44xx_i2c1_addrs[] = { 4941 static struct omap_hwmod_addr_space omap44xx_i2c1_addrs[] = {
4943 { 4942 {
4944 .pa_start = 0x48070000, 4943 .pa_start = 0x48070000,
4945 .pa_end = 0x480700ff, 4944 .pa_end = 0x480700ff,
4946 .flags = ADDR_TYPE_RT 4945 .flags = ADDR_TYPE_RT
4947 }, 4946 },
4948 { } 4947 { }
4949 }; 4948 };
4950 4949
4951 /* l4_per -> i2c1 */ 4950 /* l4_per -> i2c1 */
4952 static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c1 = { 4951 static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c1 = {
4953 .master = &omap44xx_l4_per_hwmod, 4952 .master = &omap44xx_l4_per_hwmod,
4954 .slave = &omap44xx_i2c1_hwmod, 4953 .slave = &omap44xx_i2c1_hwmod,
4955 .clk = "l4_div_ck", 4954 .clk = "l4_div_ck",
4956 .addr = omap44xx_i2c1_addrs, 4955 .addr = omap44xx_i2c1_addrs,
4957 .user = OCP_USER_MPU | OCP_USER_SDMA, 4956 .user = OCP_USER_MPU | OCP_USER_SDMA,
4958 }; 4957 };
4959 4958
4960 static struct omap_hwmod_addr_space omap44xx_i2c2_addrs[] = { 4959 static struct omap_hwmod_addr_space omap44xx_i2c2_addrs[] = {
4961 { 4960 {
4962 .pa_start = 0x48072000, 4961 .pa_start = 0x48072000,
4963 .pa_end = 0x480720ff, 4962 .pa_end = 0x480720ff,
4964 .flags = ADDR_TYPE_RT 4963 .flags = ADDR_TYPE_RT
4965 }, 4964 },
4966 { } 4965 { }
4967 }; 4966 };
4968 4967
4969 /* l4_per -> i2c2 */ 4968 /* l4_per -> i2c2 */
4970 static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c2 = { 4969 static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c2 = {
4971 .master = &omap44xx_l4_per_hwmod, 4970 .master = &omap44xx_l4_per_hwmod,
4972 .slave = &omap44xx_i2c2_hwmod, 4971 .slave = &omap44xx_i2c2_hwmod,
4973 .clk = "l4_div_ck", 4972 .clk = "l4_div_ck",
4974 .addr = omap44xx_i2c2_addrs, 4973 .addr = omap44xx_i2c2_addrs,
4975 .user = OCP_USER_MPU | OCP_USER_SDMA, 4974 .user = OCP_USER_MPU | OCP_USER_SDMA,
4976 }; 4975 };
4977 4976
4978 static struct omap_hwmod_addr_space omap44xx_i2c3_addrs[] = { 4977 static struct omap_hwmod_addr_space omap44xx_i2c3_addrs[] = {
4979 { 4978 {
4980 .pa_start = 0x48060000, 4979 .pa_start = 0x48060000,
4981 .pa_end = 0x480600ff, 4980 .pa_end = 0x480600ff,
4982 .flags = ADDR_TYPE_RT 4981 .flags = ADDR_TYPE_RT
4983 }, 4982 },
4984 { } 4983 { }
4985 }; 4984 };
4986 4985
4987 /* l4_per -> i2c3 */ 4986 /* l4_per -> i2c3 */
4988 static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c3 = { 4987 static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c3 = {
4989 .master = &omap44xx_l4_per_hwmod, 4988 .master = &omap44xx_l4_per_hwmod,
4990 .slave = &omap44xx_i2c3_hwmod, 4989 .slave = &omap44xx_i2c3_hwmod,
4991 .clk = "l4_div_ck", 4990 .clk = "l4_div_ck",
4992 .addr = omap44xx_i2c3_addrs, 4991 .addr = omap44xx_i2c3_addrs,
4993 .user = OCP_USER_MPU | OCP_USER_SDMA, 4992 .user = OCP_USER_MPU | OCP_USER_SDMA,
4994 }; 4993 };
4995 4994
4996 static struct omap_hwmod_addr_space omap44xx_i2c4_addrs[] = { 4995 static struct omap_hwmod_addr_space omap44xx_i2c4_addrs[] = {
4997 { 4996 {
4998 .pa_start = 0x48350000, 4997 .pa_start = 0x48350000,
4999 .pa_end = 0x483500ff, 4998 .pa_end = 0x483500ff,
5000 .flags = ADDR_TYPE_RT 4999 .flags = ADDR_TYPE_RT
5001 }, 5000 },
5002 { } 5001 { }
5003 }; 5002 };
5004 5003
5005 /* l4_per -> i2c4 */ 5004 /* l4_per -> i2c4 */
5006 static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c4 = { 5005 static struct omap_hwmod_ocp_if omap44xx_l4_per__i2c4 = {
5007 .master = &omap44xx_l4_per_hwmod, 5006 .master = &omap44xx_l4_per_hwmod,
5008 .slave = &omap44xx_i2c4_hwmod, 5007 .slave = &omap44xx_i2c4_hwmod,
5009 .clk = "l4_div_ck", 5008 .clk = "l4_div_ck",
5010 .addr = omap44xx_i2c4_addrs, 5009 .addr = omap44xx_i2c4_addrs,
5011 .user = OCP_USER_MPU | OCP_USER_SDMA, 5010 .user = OCP_USER_MPU | OCP_USER_SDMA,
5012 }; 5011 };
5013 5012
5014 /* l3_main_2 -> ipu */ 5013 /* l3_main_2 -> ipu */
5015 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__ipu = { 5014 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__ipu = {
5016 .master = &omap44xx_l3_main_2_hwmod, 5015 .master = &omap44xx_l3_main_2_hwmod,
5017 .slave = &omap44xx_ipu_hwmod, 5016 .slave = &omap44xx_ipu_hwmod,
5018 .clk = "l3_div_ck", 5017 .clk = "l3_div_ck",
5019 .user = OCP_USER_MPU | OCP_USER_SDMA, 5018 .user = OCP_USER_MPU | OCP_USER_SDMA,
5020 }; 5019 };
5021 5020
5022 static struct omap_hwmod_addr_space omap44xx_iss_addrs[] = { 5021 static struct omap_hwmod_addr_space omap44xx_iss_addrs[] = {
5023 { 5022 {
5024 .pa_start = 0x52000000, 5023 .pa_start = 0x52000000,
5025 .pa_end = 0x520000ff, 5024 .pa_end = 0x520000ff,
5026 .flags = ADDR_TYPE_RT 5025 .flags = ADDR_TYPE_RT
5027 }, 5026 },
5028 { } 5027 { }
5029 }; 5028 };
5030 5029
5031 /* l3_main_2 -> iss */ 5030 /* l3_main_2 -> iss */
5032 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__iss = { 5031 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__iss = {
5033 .master = &omap44xx_l3_main_2_hwmod, 5032 .master = &omap44xx_l3_main_2_hwmod,
5034 .slave = &omap44xx_iss_hwmod, 5033 .slave = &omap44xx_iss_hwmod,
5035 .clk = "l3_div_ck", 5034 .clk = "l3_div_ck",
5036 .addr = omap44xx_iss_addrs, 5035 .addr = omap44xx_iss_addrs,
5037 .user = OCP_USER_MPU | OCP_USER_SDMA, 5036 .user = OCP_USER_MPU | OCP_USER_SDMA,
5038 }; 5037 };
5039 5038
5040 /* iva -> sl2if */ 5039 /* iva -> sl2if */
5041 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_iva__sl2if = { 5040 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_iva__sl2if = {
5042 .master = &omap44xx_iva_hwmod, 5041 .master = &omap44xx_iva_hwmod,
5043 .slave = &omap44xx_sl2if_hwmod, 5042 .slave = &omap44xx_sl2if_hwmod,
5044 .clk = "dpll_iva_m5x2_ck", 5043 .clk = "dpll_iva_m5x2_ck",
5045 .user = OCP_USER_IVA, 5044 .user = OCP_USER_IVA,
5046 }; 5045 };
5047 5046
5048 static struct omap_hwmod_addr_space omap44xx_iva_addrs[] = { 5047 static struct omap_hwmod_addr_space omap44xx_iva_addrs[] = {
5049 { 5048 {
5050 .pa_start = 0x5a000000, 5049 .pa_start = 0x5a000000,
5051 .pa_end = 0x5a07ffff, 5050 .pa_end = 0x5a07ffff,
5052 .flags = ADDR_TYPE_RT 5051 .flags = ADDR_TYPE_RT
5053 }, 5052 },
5054 { } 5053 { }
5055 }; 5054 };
5056 5055
5057 /* l3_main_2 -> iva */ 5056 /* l3_main_2 -> iva */
5058 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__iva = { 5057 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__iva = {
5059 .master = &omap44xx_l3_main_2_hwmod, 5058 .master = &omap44xx_l3_main_2_hwmod,
5060 .slave = &omap44xx_iva_hwmod, 5059 .slave = &omap44xx_iva_hwmod,
5061 .clk = "l3_div_ck", 5060 .clk = "l3_div_ck",
5062 .addr = omap44xx_iva_addrs, 5061 .addr = omap44xx_iva_addrs,
5063 .user = OCP_USER_MPU, 5062 .user = OCP_USER_MPU,
5064 }; 5063 };
5065 5064
5066 static struct omap_hwmod_addr_space omap44xx_kbd_addrs[] = { 5065 static struct omap_hwmod_addr_space omap44xx_kbd_addrs[] = {
5067 { 5066 {
5068 .pa_start = 0x4a31c000, 5067 .pa_start = 0x4a31c000,
5069 .pa_end = 0x4a31c07f, 5068 .pa_end = 0x4a31c07f,
5070 .flags = ADDR_TYPE_RT 5069 .flags = ADDR_TYPE_RT
5071 }, 5070 },
5072 { } 5071 { }
5073 }; 5072 };
5074 5073
5075 /* l4_wkup -> kbd */ 5074 /* l4_wkup -> kbd */
5076 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__kbd = { 5075 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__kbd = {
5077 .master = &omap44xx_l4_wkup_hwmod, 5076 .master = &omap44xx_l4_wkup_hwmod,
5078 .slave = &omap44xx_kbd_hwmod, 5077 .slave = &omap44xx_kbd_hwmod,
5079 .clk = "l4_wkup_clk_mux_ck", 5078 .clk = "l4_wkup_clk_mux_ck",
5080 .addr = omap44xx_kbd_addrs, 5079 .addr = omap44xx_kbd_addrs,
5081 .user = OCP_USER_MPU | OCP_USER_SDMA, 5080 .user = OCP_USER_MPU | OCP_USER_SDMA,
5082 }; 5081 };
5083 5082
5084 static struct omap_hwmod_addr_space omap44xx_mailbox_addrs[] = { 5083 static struct omap_hwmod_addr_space omap44xx_mailbox_addrs[] = {
5085 { 5084 {
5086 .pa_start = 0x4a0f4000, 5085 .pa_start = 0x4a0f4000,
5087 .pa_end = 0x4a0f41ff, 5086 .pa_end = 0x4a0f41ff,
5088 .flags = ADDR_TYPE_RT 5087 .flags = ADDR_TYPE_RT
5089 }, 5088 },
5090 { } 5089 { }
5091 }; 5090 };
5092 5091
5093 /* l4_cfg -> mailbox */ 5092 /* l4_cfg -> mailbox */
5094 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__mailbox = { 5093 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__mailbox = {
5095 .master = &omap44xx_l4_cfg_hwmod, 5094 .master = &omap44xx_l4_cfg_hwmod,
5096 .slave = &omap44xx_mailbox_hwmod, 5095 .slave = &omap44xx_mailbox_hwmod,
5097 .clk = "l4_div_ck", 5096 .clk = "l4_div_ck",
5098 .addr = omap44xx_mailbox_addrs, 5097 .addr = omap44xx_mailbox_addrs,
5099 .user = OCP_USER_MPU | OCP_USER_SDMA, 5098 .user = OCP_USER_MPU | OCP_USER_SDMA,
5100 }; 5099 };
5101 5100
5102 static struct omap_hwmod_addr_space omap44xx_mcasp_addrs[] = { 5101 static struct omap_hwmod_addr_space omap44xx_mcasp_addrs[] = {
5103 { 5102 {
5104 .pa_start = 0x40128000, 5103 .pa_start = 0x40128000,
5105 .pa_end = 0x401283ff, 5104 .pa_end = 0x401283ff,
5106 .flags = ADDR_TYPE_RT 5105 .flags = ADDR_TYPE_RT
5107 }, 5106 },
5108 { } 5107 { }
5109 }; 5108 };
5110 5109
5111 /* l4_abe -> mcasp */ 5110 /* l4_abe -> mcasp */
5112 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcasp = { 5111 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcasp = {
5113 .master = &omap44xx_l4_abe_hwmod, 5112 .master = &omap44xx_l4_abe_hwmod,
5114 .slave = &omap44xx_mcasp_hwmod, 5113 .slave = &omap44xx_mcasp_hwmod,
5115 .clk = "ocp_abe_iclk", 5114 .clk = "ocp_abe_iclk",
5116 .addr = omap44xx_mcasp_addrs, 5115 .addr = omap44xx_mcasp_addrs,
5117 .user = OCP_USER_MPU, 5116 .user = OCP_USER_MPU,
5118 }; 5117 };
5119 5118
5120 static struct omap_hwmod_addr_space omap44xx_mcasp_dma_addrs[] = { 5119 static struct omap_hwmod_addr_space omap44xx_mcasp_dma_addrs[] = {
5121 { 5120 {
5122 .pa_start = 0x49028000, 5121 .pa_start = 0x49028000,
5123 .pa_end = 0x490283ff, 5122 .pa_end = 0x490283ff,
5124 .flags = ADDR_TYPE_RT 5123 .flags = ADDR_TYPE_RT
5125 }, 5124 },
5126 { } 5125 { }
5127 }; 5126 };
5128 5127
5129 /* l4_abe -> mcasp (dma) */ 5128 /* l4_abe -> mcasp (dma) */
5130 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcasp_dma = { 5129 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcasp_dma = {
5131 .master = &omap44xx_l4_abe_hwmod, 5130 .master = &omap44xx_l4_abe_hwmod,
5132 .slave = &omap44xx_mcasp_hwmod, 5131 .slave = &omap44xx_mcasp_hwmod,
5133 .clk = "ocp_abe_iclk", 5132 .clk = "ocp_abe_iclk",
5134 .addr = omap44xx_mcasp_dma_addrs, 5133 .addr = omap44xx_mcasp_dma_addrs,
5135 .user = OCP_USER_SDMA, 5134 .user = OCP_USER_SDMA,
5136 }; 5135 };
5137 5136
5138 static struct omap_hwmod_addr_space omap44xx_mcbsp1_addrs[] = { 5137 static struct omap_hwmod_addr_space omap44xx_mcbsp1_addrs[] = {
5139 { 5138 {
5140 .name = "mpu", 5139 .name = "mpu",
5141 .pa_start = 0x40122000, 5140 .pa_start = 0x40122000,
5142 .pa_end = 0x401220ff, 5141 .pa_end = 0x401220ff,
5143 .flags = ADDR_TYPE_RT 5142 .flags = ADDR_TYPE_RT
5144 }, 5143 },
5145 { } 5144 { }
5146 }; 5145 };
5147 5146
5148 /* l4_abe -> mcbsp1 */ 5147 /* l4_abe -> mcbsp1 */
5149 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp1 = { 5148 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp1 = {
5150 .master = &omap44xx_l4_abe_hwmod, 5149 .master = &omap44xx_l4_abe_hwmod,
5151 .slave = &omap44xx_mcbsp1_hwmod, 5150 .slave = &omap44xx_mcbsp1_hwmod,
5152 .clk = "ocp_abe_iclk", 5151 .clk = "ocp_abe_iclk",
5153 .addr = omap44xx_mcbsp1_addrs, 5152 .addr = omap44xx_mcbsp1_addrs,
5154 .user = OCP_USER_MPU, 5153 .user = OCP_USER_MPU,
5155 }; 5154 };
5156 5155
5157 static struct omap_hwmod_addr_space omap44xx_mcbsp1_dma_addrs[] = { 5156 static struct omap_hwmod_addr_space omap44xx_mcbsp1_dma_addrs[] = {
5158 { 5157 {
5159 .name = "dma", 5158 .name = "dma",
5160 .pa_start = 0x49022000, 5159 .pa_start = 0x49022000,
5161 .pa_end = 0x490220ff, 5160 .pa_end = 0x490220ff,
5162 .flags = ADDR_TYPE_RT 5161 .flags = ADDR_TYPE_RT
5163 }, 5162 },
5164 { } 5163 { }
5165 }; 5164 };
5166 5165
5167 /* l4_abe -> mcbsp1 (dma) */ 5166 /* l4_abe -> mcbsp1 (dma) */
5168 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp1_dma = { 5167 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp1_dma = {
5169 .master = &omap44xx_l4_abe_hwmod, 5168 .master = &omap44xx_l4_abe_hwmod,
5170 .slave = &omap44xx_mcbsp1_hwmod, 5169 .slave = &omap44xx_mcbsp1_hwmod,
5171 .clk = "ocp_abe_iclk", 5170 .clk = "ocp_abe_iclk",
5172 .addr = omap44xx_mcbsp1_dma_addrs, 5171 .addr = omap44xx_mcbsp1_dma_addrs,
5173 .user = OCP_USER_SDMA, 5172 .user = OCP_USER_SDMA,
5174 }; 5173 };
5175 5174
5176 static struct omap_hwmod_addr_space omap44xx_mcbsp2_addrs[] = { 5175 static struct omap_hwmod_addr_space omap44xx_mcbsp2_addrs[] = {
5177 { 5176 {
5178 .name = "mpu", 5177 .name = "mpu",
5179 .pa_start = 0x40124000, 5178 .pa_start = 0x40124000,
5180 .pa_end = 0x401240ff, 5179 .pa_end = 0x401240ff,
5181 .flags = ADDR_TYPE_RT 5180 .flags = ADDR_TYPE_RT
5182 }, 5181 },
5183 { } 5182 { }
5184 }; 5183 };
5185 5184
5186 /* l4_abe -> mcbsp2 */ 5185 /* l4_abe -> mcbsp2 */
5187 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp2 = { 5186 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp2 = {
5188 .master = &omap44xx_l4_abe_hwmod, 5187 .master = &omap44xx_l4_abe_hwmod,
5189 .slave = &omap44xx_mcbsp2_hwmod, 5188 .slave = &omap44xx_mcbsp2_hwmod,
5190 .clk = "ocp_abe_iclk", 5189 .clk = "ocp_abe_iclk",
5191 .addr = omap44xx_mcbsp2_addrs, 5190 .addr = omap44xx_mcbsp2_addrs,
5192 .user = OCP_USER_MPU, 5191 .user = OCP_USER_MPU,
5193 }; 5192 };
5194 5193
5195 static struct omap_hwmod_addr_space omap44xx_mcbsp2_dma_addrs[] = { 5194 static struct omap_hwmod_addr_space omap44xx_mcbsp2_dma_addrs[] = {
5196 { 5195 {
5197 .name = "dma", 5196 .name = "dma",
5198 .pa_start = 0x49024000, 5197 .pa_start = 0x49024000,
5199 .pa_end = 0x490240ff, 5198 .pa_end = 0x490240ff,
5200 .flags = ADDR_TYPE_RT 5199 .flags = ADDR_TYPE_RT
5201 }, 5200 },
5202 { } 5201 { }
5203 }; 5202 };
5204 5203
5205 /* l4_abe -> mcbsp2 (dma) */ 5204 /* l4_abe -> mcbsp2 (dma) */
5206 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp2_dma = { 5205 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp2_dma = {
5207 .master = &omap44xx_l4_abe_hwmod, 5206 .master = &omap44xx_l4_abe_hwmod,
5208 .slave = &omap44xx_mcbsp2_hwmod, 5207 .slave = &omap44xx_mcbsp2_hwmod,
5209 .clk = "ocp_abe_iclk", 5208 .clk = "ocp_abe_iclk",
5210 .addr = omap44xx_mcbsp2_dma_addrs, 5209 .addr = omap44xx_mcbsp2_dma_addrs,
5211 .user = OCP_USER_SDMA, 5210 .user = OCP_USER_SDMA,
5212 }; 5211 };
5213 5212
5214 static struct omap_hwmod_addr_space omap44xx_mcbsp3_addrs[] = { 5213 static struct omap_hwmod_addr_space omap44xx_mcbsp3_addrs[] = {
5215 { 5214 {
5216 .name = "mpu", 5215 .name = "mpu",
5217 .pa_start = 0x40126000, 5216 .pa_start = 0x40126000,
5218 .pa_end = 0x401260ff, 5217 .pa_end = 0x401260ff,
5219 .flags = ADDR_TYPE_RT 5218 .flags = ADDR_TYPE_RT
5220 }, 5219 },
5221 { } 5220 { }
5222 }; 5221 };
5223 5222
5224 /* l4_abe -> mcbsp3 */ 5223 /* l4_abe -> mcbsp3 */
5225 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp3 = { 5224 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp3 = {
5226 .master = &omap44xx_l4_abe_hwmod, 5225 .master = &omap44xx_l4_abe_hwmod,
5227 .slave = &omap44xx_mcbsp3_hwmod, 5226 .slave = &omap44xx_mcbsp3_hwmod,
5228 .clk = "ocp_abe_iclk", 5227 .clk = "ocp_abe_iclk",
5229 .addr = omap44xx_mcbsp3_addrs, 5228 .addr = omap44xx_mcbsp3_addrs,
5230 .user = OCP_USER_MPU, 5229 .user = OCP_USER_MPU,
5231 }; 5230 };
5232 5231
5233 static struct omap_hwmod_addr_space omap44xx_mcbsp3_dma_addrs[] = { 5232 static struct omap_hwmod_addr_space omap44xx_mcbsp3_dma_addrs[] = {
5234 { 5233 {
5235 .name = "dma", 5234 .name = "dma",
5236 .pa_start = 0x49026000, 5235 .pa_start = 0x49026000,
5237 .pa_end = 0x490260ff, 5236 .pa_end = 0x490260ff,
5238 .flags = ADDR_TYPE_RT 5237 .flags = ADDR_TYPE_RT
5239 }, 5238 },
5240 { } 5239 { }
5241 }; 5240 };
5242 5241
5243 /* l4_abe -> mcbsp3 (dma) */ 5242 /* l4_abe -> mcbsp3 (dma) */
5244 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp3_dma = { 5243 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcbsp3_dma = {
5245 .master = &omap44xx_l4_abe_hwmod, 5244 .master = &omap44xx_l4_abe_hwmod,
5246 .slave = &omap44xx_mcbsp3_hwmod, 5245 .slave = &omap44xx_mcbsp3_hwmod,
5247 .clk = "ocp_abe_iclk", 5246 .clk = "ocp_abe_iclk",
5248 .addr = omap44xx_mcbsp3_dma_addrs, 5247 .addr = omap44xx_mcbsp3_dma_addrs,
5249 .user = OCP_USER_SDMA, 5248 .user = OCP_USER_SDMA,
5250 }; 5249 };
5251 5250
5252 static struct omap_hwmod_addr_space omap44xx_mcbsp4_addrs[] = { 5251 static struct omap_hwmod_addr_space omap44xx_mcbsp4_addrs[] = {
5253 { 5252 {
5254 .pa_start = 0x48096000, 5253 .pa_start = 0x48096000,
5255 .pa_end = 0x480960ff, 5254 .pa_end = 0x480960ff,
5256 .flags = ADDR_TYPE_RT 5255 .flags = ADDR_TYPE_RT
5257 }, 5256 },
5258 { } 5257 { }
5259 }; 5258 };
5260 5259
5261 /* l4_per -> mcbsp4 */ 5260 /* l4_per -> mcbsp4 */
5262 static struct omap_hwmod_ocp_if omap44xx_l4_per__mcbsp4 = { 5261 static struct omap_hwmod_ocp_if omap44xx_l4_per__mcbsp4 = {
5263 .master = &omap44xx_l4_per_hwmod, 5262 .master = &omap44xx_l4_per_hwmod,
5264 .slave = &omap44xx_mcbsp4_hwmod, 5263 .slave = &omap44xx_mcbsp4_hwmod,
5265 .clk = "l4_div_ck", 5264 .clk = "l4_div_ck",
5266 .addr = omap44xx_mcbsp4_addrs, 5265 .addr = omap44xx_mcbsp4_addrs,
5267 .user = OCP_USER_MPU | OCP_USER_SDMA, 5266 .user = OCP_USER_MPU | OCP_USER_SDMA,
5268 }; 5267 };
5269 5268
5270 static struct omap_hwmod_addr_space omap44xx_mcpdm_addrs[] = { 5269 static struct omap_hwmod_addr_space omap44xx_mcpdm_addrs[] = {
5271 { 5270 {
5272 .name = "mpu", 5271 .name = "mpu",
5273 .pa_start = 0x40132000, 5272 .pa_start = 0x40132000,
5274 .pa_end = 0x4013207f, 5273 .pa_end = 0x4013207f,
5275 .flags = ADDR_TYPE_RT 5274 .flags = ADDR_TYPE_RT
5276 }, 5275 },
5277 { } 5276 { }
5278 }; 5277 };
5279 5278
5280 /* l4_abe -> mcpdm */ 5279 /* l4_abe -> mcpdm */
5281 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcpdm = { 5280 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcpdm = {
5282 .master = &omap44xx_l4_abe_hwmod, 5281 .master = &omap44xx_l4_abe_hwmod,
5283 .slave = &omap44xx_mcpdm_hwmod, 5282 .slave = &omap44xx_mcpdm_hwmod,
5284 .clk = "ocp_abe_iclk", 5283 .clk = "ocp_abe_iclk",
5285 .addr = omap44xx_mcpdm_addrs, 5284 .addr = omap44xx_mcpdm_addrs,
5286 .user = OCP_USER_MPU, 5285 .user = OCP_USER_MPU,
5287 }; 5286 };
5288 5287
5289 static struct omap_hwmod_addr_space omap44xx_mcpdm_dma_addrs[] = { 5288 static struct omap_hwmod_addr_space omap44xx_mcpdm_dma_addrs[] = {
5290 { 5289 {
5291 .name = "dma", 5290 .name = "dma",
5292 .pa_start = 0x49032000, 5291 .pa_start = 0x49032000,
5293 .pa_end = 0x4903207f, 5292 .pa_end = 0x4903207f,
5294 .flags = ADDR_TYPE_RT 5293 .flags = ADDR_TYPE_RT
5295 }, 5294 },
5296 { } 5295 { }
5297 }; 5296 };
5298 5297
5299 /* l4_abe -> mcpdm (dma) */ 5298 /* l4_abe -> mcpdm (dma) */
5300 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcpdm_dma = { 5299 static struct omap_hwmod_ocp_if omap44xx_l4_abe__mcpdm_dma = {
5301 .master = &omap44xx_l4_abe_hwmod, 5300 .master = &omap44xx_l4_abe_hwmod,
5302 .slave = &omap44xx_mcpdm_hwmod, 5301 .slave = &omap44xx_mcpdm_hwmod,
5303 .clk = "ocp_abe_iclk", 5302 .clk = "ocp_abe_iclk",
5304 .addr = omap44xx_mcpdm_dma_addrs, 5303 .addr = omap44xx_mcpdm_dma_addrs,
5305 .user = OCP_USER_SDMA, 5304 .user = OCP_USER_SDMA,
5306 }; 5305 };
5307 5306
5308 static struct omap_hwmod_addr_space omap44xx_mcspi1_addrs[] = { 5307 static struct omap_hwmod_addr_space omap44xx_mcspi1_addrs[] = {
5309 { 5308 {
5310 .pa_start = 0x48098000, 5309 .pa_start = 0x48098000,
5311 .pa_end = 0x480981ff, 5310 .pa_end = 0x480981ff,
5312 .flags = ADDR_TYPE_RT 5311 .flags = ADDR_TYPE_RT
5313 }, 5312 },
5314 { } 5313 { }
5315 }; 5314 };
5316 5315
5317 /* l4_per -> mcspi1 */ 5316 /* l4_per -> mcspi1 */
5318 static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi1 = { 5317 static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi1 = {
5319 .master = &omap44xx_l4_per_hwmod, 5318 .master = &omap44xx_l4_per_hwmod,
5320 .slave = &omap44xx_mcspi1_hwmod, 5319 .slave = &omap44xx_mcspi1_hwmod,
5321 .clk = "l4_div_ck", 5320 .clk = "l4_div_ck",
5322 .addr = omap44xx_mcspi1_addrs, 5321 .addr = omap44xx_mcspi1_addrs,
5323 .user = OCP_USER_MPU | OCP_USER_SDMA, 5322 .user = OCP_USER_MPU | OCP_USER_SDMA,
5324 }; 5323 };
5325 5324
5326 static struct omap_hwmod_addr_space omap44xx_mcspi2_addrs[] = { 5325 static struct omap_hwmod_addr_space omap44xx_mcspi2_addrs[] = {
5327 { 5326 {
5328 .pa_start = 0x4809a000, 5327 .pa_start = 0x4809a000,
5329 .pa_end = 0x4809a1ff, 5328 .pa_end = 0x4809a1ff,
5330 .flags = ADDR_TYPE_RT 5329 .flags = ADDR_TYPE_RT
5331 }, 5330 },
5332 { } 5331 { }
5333 }; 5332 };
5334 5333
5335 /* l4_per -> mcspi2 */ 5334 /* l4_per -> mcspi2 */
5336 static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi2 = { 5335 static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi2 = {
5337 .master = &omap44xx_l4_per_hwmod, 5336 .master = &omap44xx_l4_per_hwmod,
5338 .slave = &omap44xx_mcspi2_hwmod, 5337 .slave = &omap44xx_mcspi2_hwmod,
5339 .clk = "l4_div_ck", 5338 .clk = "l4_div_ck",
5340 .addr = omap44xx_mcspi2_addrs, 5339 .addr = omap44xx_mcspi2_addrs,
5341 .user = OCP_USER_MPU | OCP_USER_SDMA, 5340 .user = OCP_USER_MPU | OCP_USER_SDMA,
5342 }; 5341 };
5343 5342
5344 static struct omap_hwmod_addr_space omap44xx_mcspi3_addrs[] = { 5343 static struct omap_hwmod_addr_space omap44xx_mcspi3_addrs[] = {
5345 { 5344 {
5346 .pa_start = 0x480b8000, 5345 .pa_start = 0x480b8000,
5347 .pa_end = 0x480b81ff, 5346 .pa_end = 0x480b81ff,
5348 .flags = ADDR_TYPE_RT 5347 .flags = ADDR_TYPE_RT
5349 }, 5348 },
5350 { } 5349 { }
5351 }; 5350 };
5352 5351
5353 /* l4_per -> mcspi3 */ 5352 /* l4_per -> mcspi3 */
5354 static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi3 = { 5353 static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi3 = {
5355 .master = &omap44xx_l4_per_hwmod, 5354 .master = &omap44xx_l4_per_hwmod,
5356 .slave = &omap44xx_mcspi3_hwmod, 5355 .slave = &omap44xx_mcspi3_hwmod,
5357 .clk = "l4_div_ck", 5356 .clk = "l4_div_ck",
5358 .addr = omap44xx_mcspi3_addrs, 5357 .addr = omap44xx_mcspi3_addrs,
5359 .user = OCP_USER_MPU | OCP_USER_SDMA, 5358 .user = OCP_USER_MPU | OCP_USER_SDMA,
5360 }; 5359 };
5361 5360
5362 static struct omap_hwmod_addr_space omap44xx_mcspi4_addrs[] = { 5361 static struct omap_hwmod_addr_space omap44xx_mcspi4_addrs[] = {
5363 { 5362 {
5364 .pa_start = 0x480ba000, 5363 .pa_start = 0x480ba000,
5365 .pa_end = 0x480ba1ff, 5364 .pa_end = 0x480ba1ff,
5366 .flags = ADDR_TYPE_RT 5365 .flags = ADDR_TYPE_RT
5367 }, 5366 },
5368 { } 5367 { }
5369 }; 5368 };
5370 5369
5371 /* l4_per -> mcspi4 */ 5370 /* l4_per -> mcspi4 */
5372 static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi4 = { 5371 static struct omap_hwmod_ocp_if omap44xx_l4_per__mcspi4 = {
5373 .master = &omap44xx_l4_per_hwmod, 5372 .master = &omap44xx_l4_per_hwmod,
5374 .slave = &omap44xx_mcspi4_hwmod, 5373 .slave = &omap44xx_mcspi4_hwmod,
5375 .clk = "l4_div_ck", 5374 .clk = "l4_div_ck",
5376 .addr = omap44xx_mcspi4_addrs, 5375 .addr = omap44xx_mcspi4_addrs,
5377 .user = OCP_USER_MPU | OCP_USER_SDMA, 5376 .user = OCP_USER_MPU | OCP_USER_SDMA,
5378 }; 5377 };
5379 5378
5380 static struct omap_hwmod_addr_space omap44xx_mmc1_addrs[] = { 5379 static struct omap_hwmod_addr_space omap44xx_mmc1_addrs[] = {
5381 { 5380 {
5382 .pa_start = 0x4809c000, 5381 .pa_start = 0x4809c000,
5383 .pa_end = 0x4809c3ff, 5382 .pa_end = 0x4809c3ff,
5384 .flags = ADDR_TYPE_RT 5383 .flags = ADDR_TYPE_RT
5385 }, 5384 },
5386 { } 5385 { }
5387 }; 5386 };
5388 5387
5389 /* l4_per -> mmc1 */ 5388 /* l4_per -> mmc1 */
5390 static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc1 = { 5389 static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc1 = {
5391 .master = &omap44xx_l4_per_hwmod, 5390 .master = &omap44xx_l4_per_hwmod,
5392 .slave = &omap44xx_mmc1_hwmod, 5391 .slave = &omap44xx_mmc1_hwmod,
5393 .clk = "l4_div_ck", 5392 .clk = "l4_div_ck",
5394 .addr = omap44xx_mmc1_addrs, 5393 .addr = omap44xx_mmc1_addrs,
5395 .user = OCP_USER_MPU | OCP_USER_SDMA, 5394 .user = OCP_USER_MPU | OCP_USER_SDMA,
5396 }; 5395 };
5397 5396
5398 static struct omap_hwmod_addr_space omap44xx_mmc2_addrs[] = { 5397 static struct omap_hwmod_addr_space omap44xx_mmc2_addrs[] = {
5399 { 5398 {
5400 .pa_start = 0x480b4000, 5399 .pa_start = 0x480b4000,
5401 .pa_end = 0x480b43ff, 5400 .pa_end = 0x480b43ff,
5402 .flags = ADDR_TYPE_RT 5401 .flags = ADDR_TYPE_RT
5403 }, 5402 },
5404 { } 5403 { }
5405 }; 5404 };
5406 5405
5407 /* l4_per -> mmc2 */ 5406 /* l4_per -> mmc2 */
5408 static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc2 = { 5407 static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc2 = {
5409 .master = &omap44xx_l4_per_hwmod, 5408 .master = &omap44xx_l4_per_hwmod,
5410 .slave = &omap44xx_mmc2_hwmod, 5409 .slave = &omap44xx_mmc2_hwmod,
5411 .clk = "l4_div_ck", 5410 .clk = "l4_div_ck",
5412 .addr = omap44xx_mmc2_addrs, 5411 .addr = omap44xx_mmc2_addrs,
5413 .user = OCP_USER_MPU | OCP_USER_SDMA, 5412 .user = OCP_USER_MPU | OCP_USER_SDMA,
5414 }; 5413 };
5415 5414
5416 static struct omap_hwmod_addr_space omap44xx_mmc3_addrs[] = { 5415 static struct omap_hwmod_addr_space omap44xx_mmc3_addrs[] = {
5417 { 5416 {
5418 .pa_start = 0x480ad000, 5417 .pa_start = 0x480ad000,
5419 .pa_end = 0x480ad3ff, 5418 .pa_end = 0x480ad3ff,
5420 .flags = ADDR_TYPE_RT 5419 .flags = ADDR_TYPE_RT
5421 }, 5420 },
5422 { } 5421 { }
5423 }; 5422 };
5424 5423
5425 /* l4_per -> mmc3 */ 5424 /* l4_per -> mmc3 */
5426 static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc3 = { 5425 static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc3 = {
5427 .master = &omap44xx_l4_per_hwmod, 5426 .master = &omap44xx_l4_per_hwmod,
5428 .slave = &omap44xx_mmc3_hwmod, 5427 .slave = &omap44xx_mmc3_hwmod,
5429 .clk = "l4_div_ck", 5428 .clk = "l4_div_ck",
5430 .addr = omap44xx_mmc3_addrs, 5429 .addr = omap44xx_mmc3_addrs,
5431 .user = OCP_USER_MPU | OCP_USER_SDMA, 5430 .user = OCP_USER_MPU | OCP_USER_SDMA,
5432 }; 5431 };
5433 5432
5434 static struct omap_hwmod_addr_space omap44xx_mmc4_addrs[] = { 5433 static struct omap_hwmod_addr_space omap44xx_mmc4_addrs[] = {
5435 { 5434 {
5436 .pa_start = 0x480d1000, 5435 .pa_start = 0x480d1000,
5437 .pa_end = 0x480d13ff, 5436 .pa_end = 0x480d13ff,
5438 .flags = ADDR_TYPE_RT 5437 .flags = ADDR_TYPE_RT
5439 }, 5438 },
5440 { } 5439 { }
5441 }; 5440 };
5442 5441
5443 /* l4_per -> mmc4 */ 5442 /* l4_per -> mmc4 */
5444 static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc4 = { 5443 static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc4 = {
5445 .master = &omap44xx_l4_per_hwmod, 5444 .master = &omap44xx_l4_per_hwmod,
5446 .slave = &omap44xx_mmc4_hwmod, 5445 .slave = &omap44xx_mmc4_hwmod,
5447 .clk = "l4_div_ck", 5446 .clk = "l4_div_ck",
5448 .addr = omap44xx_mmc4_addrs, 5447 .addr = omap44xx_mmc4_addrs,
5449 .user = OCP_USER_MPU | OCP_USER_SDMA, 5448 .user = OCP_USER_MPU | OCP_USER_SDMA,
5450 }; 5449 };
5451 5450
5452 static struct omap_hwmod_addr_space omap44xx_mmc5_addrs[] = { 5451 static struct omap_hwmod_addr_space omap44xx_mmc5_addrs[] = {
5453 { 5452 {
5454 .pa_start = 0x480d5000, 5453 .pa_start = 0x480d5000,
5455 .pa_end = 0x480d53ff, 5454 .pa_end = 0x480d53ff,
5456 .flags = ADDR_TYPE_RT 5455 .flags = ADDR_TYPE_RT
5457 }, 5456 },
5458 { } 5457 { }
5459 }; 5458 };
5460 5459
5461 /* l4_per -> mmc5 */ 5460 /* l4_per -> mmc5 */
5462 static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc5 = { 5461 static struct omap_hwmod_ocp_if omap44xx_l4_per__mmc5 = {
5463 .master = &omap44xx_l4_per_hwmod, 5462 .master = &omap44xx_l4_per_hwmod,
5464 .slave = &omap44xx_mmc5_hwmod, 5463 .slave = &omap44xx_mmc5_hwmod,
5465 .clk = "l4_div_ck", 5464 .clk = "l4_div_ck",
5466 .addr = omap44xx_mmc5_addrs, 5465 .addr = omap44xx_mmc5_addrs,
5467 .user = OCP_USER_MPU | OCP_USER_SDMA, 5466 .user = OCP_USER_MPU | OCP_USER_SDMA,
5468 }; 5467 };
5469 5468
5470 /* l3_main_2 -> ocmc_ram */ 5469 /* l3_main_2 -> ocmc_ram */
5471 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__ocmc_ram = { 5470 static struct omap_hwmod_ocp_if omap44xx_l3_main_2__ocmc_ram = {
5472 .master = &omap44xx_l3_main_2_hwmod, 5471 .master = &omap44xx_l3_main_2_hwmod,
5473 .slave = &omap44xx_ocmc_ram_hwmod, 5472 .slave = &omap44xx_ocmc_ram_hwmod,
5474 .clk = "l3_div_ck", 5473 .clk = "l3_div_ck",
5475 .user = OCP_USER_MPU | OCP_USER_SDMA, 5474 .user = OCP_USER_MPU | OCP_USER_SDMA,
5476 }; 5475 };
5477 5476
5478 static struct omap_hwmod_addr_space omap44xx_ocp2scp_usb_phy_addrs[] = { 5477 static struct omap_hwmod_addr_space omap44xx_ocp2scp_usb_phy_addrs[] = {
5479 { 5478 {
5480 .pa_start = 0x4a0ad000, 5479 .pa_start = 0x4a0ad000,
5481 .pa_end = 0x4a0ad01f, 5480 .pa_end = 0x4a0ad01f,
5482 .flags = ADDR_TYPE_RT 5481 .flags = ADDR_TYPE_RT
5483 }, 5482 },
5484 { } 5483 { }
5485 }; 5484 };
5486 5485
5487 /* l4_cfg -> ocp2scp_usb_phy */ 5486 /* l4_cfg -> ocp2scp_usb_phy */
5488 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__ocp2scp_usb_phy = { 5487 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__ocp2scp_usb_phy = {
5489 .master = &omap44xx_l4_cfg_hwmod, 5488 .master = &omap44xx_l4_cfg_hwmod,
5490 .slave = &omap44xx_ocp2scp_usb_phy_hwmod, 5489 .slave = &omap44xx_ocp2scp_usb_phy_hwmod,
5491 .clk = "l4_div_ck", 5490 .clk = "l4_div_ck",
5492 .addr = omap44xx_ocp2scp_usb_phy_addrs, 5491 .addr = omap44xx_ocp2scp_usb_phy_addrs,
5493 .user = OCP_USER_MPU | OCP_USER_SDMA, 5492 .user = OCP_USER_MPU | OCP_USER_SDMA,
5494 }; 5493 };
5495 5494
5496 static struct omap_hwmod_addr_space omap44xx_prcm_mpu_addrs[] = { 5495 static struct omap_hwmod_addr_space omap44xx_prcm_mpu_addrs[] = {
5497 { 5496 {
5498 .pa_start = 0x48243000, 5497 .pa_start = 0x48243000,
5499 .pa_end = 0x48243fff, 5498 .pa_end = 0x48243fff,
5500 .flags = ADDR_TYPE_RT 5499 .flags = ADDR_TYPE_RT
5501 }, 5500 },
5502 { } 5501 { }
5503 }; 5502 };
5504 5503
5505 /* mpu_private -> prcm_mpu */ 5504 /* mpu_private -> prcm_mpu */
5506 static struct omap_hwmod_ocp_if omap44xx_mpu_private__prcm_mpu = { 5505 static struct omap_hwmod_ocp_if omap44xx_mpu_private__prcm_mpu = {
5507 .master = &omap44xx_mpu_private_hwmod, 5506 .master = &omap44xx_mpu_private_hwmod,
5508 .slave = &omap44xx_prcm_mpu_hwmod, 5507 .slave = &omap44xx_prcm_mpu_hwmod,
5509 .clk = "l3_div_ck", 5508 .clk = "l3_div_ck",
5510 .addr = omap44xx_prcm_mpu_addrs, 5509 .addr = omap44xx_prcm_mpu_addrs,
5511 .user = OCP_USER_MPU | OCP_USER_SDMA, 5510 .user = OCP_USER_MPU | OCP_USER_SDMA,
5512 }; 5511 };
5513 5512
5514 static struct omap_hwmod_addr_space omap44xx_cm_core_aon_addrs[] = { 5513 static struct omap_hwmod_addr_space omap44xx_cm_core_aon_addrs[] = {
5515 { 5514 {
5516 .pa_start = 0x4a004000, 5515 .pa_start = 0x4a004000,
5517 .pa_end = 0x4a004fff, 5516 .pa_end = 0x4a004fff,
5518 .flags = ADDR_TYPE_RT 5517 .flags = ADDR_TYPE_RT
5519 }, 5518 },
5520 { } 5519 { }
5521 }; 5520 };
5522 5521
5523 /* l4_wkup -> cm_core_aon */ 5522 /* l4_wkup -> cm_core_aon */
5524 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__cm_core_aon = { 5523 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__cm_core_aon = {
5525 .master = &omap44xx_l4_wkup_hwmod, 5524 .master = &omap44xx_l4_wkup_hwmod,
5526 .slave = &omap44xx_cm_core_aon_hwmod, 5525 .slave = &omap44xx_cm_core_aon_hwmod,
5527 .clk = "l4_wkup_clk_mux_ck", 5526 .clk = "l4_wkup_clk_mux_ck",
5528 .addr = omap44xx_cm_core_aon_addrs, 5527 .addr = omap44xx_cm_core_aon_addrs,
5529 .user = OCP_USER_MPU | OCP_USER_SDMA, 5528 .user = OCP_USER_MPU | OCP_USER_SDMA,
5530 }; 5529 };
5531 5530
5532 static struct omap_hwmod_addr_space omap44xx_cm_core_addrs[] = { 5531 static struct omap_hwmod_addr_space omap44xx_cm_core_addrs[] = {
5533 { 5532 {
5534 .pa_start = 0x4a008000, 5533 .pa_start = 0x4a008000,
5535 .pa_end = 0x4a009fff, 5534 .pa_end = 0x4a009fff,
5536 .flags = ADDR_TYPE_RT 5535 .flags = ADDR_TYPE_RT
5537 }, 5536 },
5538 { } 5537 { }
5539 }; 5538 };
5540 5539
5541 /* l4_cfg -> cm_core */ 5540 /* l4_cfg -> cm_core */
5542 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__cm_core = { 5541 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__cm_core = {
5543 .master = &omap44xx_l4_cfg_hwmod, 5542 .master = &omap44xx_l4_cfg_hwmod,
5544 .slave = &omap44xx_cm_core_hwmod, 5543 .slave = &omap44xx_cm_core_hwmod,
5545 .clk = "l4_div_ck", 5544 .clk = "l4_div_ck",
5546 .addr = omap44xx_cm_core_addrs, 5545 .addr = omap44xx_cm_core_addrs,
5547 .user = OCP_USER_MPU | OCP_USER_SDMA, 5546 .user = OCP_USER_MPU | OCP_USER_SDMA,
5548 }; 5547 };
5549 5548
5550 static struct omap_hwmod_addr_space omap44xx_prm_addrs[] = { 5549 static struct omap_hwmod_addr_space omap44xx_prm_addrs[] = {
5551 { 5550 {
5552 .pa_start = 0x4a306000, 5551 .pa_start = 0x4a306000,
5553 .pa_end = 0x4a307fff, 5552 .pa_end = 0x4a307fff,
5554 .flags = ADDR_TYPE_RT 5553 .flags = ADDR_TYPE_RT
5555 }, 5554 },
5556 { } 5555 { }
5557 }; 5556 };
5558 5557
5559 /* l4_wkup -> prm */ 5558 /* l4_wkup -> prm */
5560 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__prm = { 5559 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__prm = {
5561 .master = &omap44xx_l4_wkup_hwmod, 5560 .master = &omap44xx_l4_wkup_hwmod,
5562 .slave = &omap44xx_prm_hwmod, 5561 .slave = &omap44xx_prm_hwmod,
5563 .clk = "l4_wkup_clk_mux_ck", 5562 .clk = "l4_wkup_clk_mux_ck",
5564 .addr = omap44xx_prm_addrs, 5563 .addr = omap44xx_prm_addrs,
5565 .user = OCP_USER_MPU | OCP_USER_SDMA, 5564 .user = OCP_USER_MPU | OCP_USER_SDMA,
5566 }; 5565 };
5567 5566
5568 static struct omap_hwmod_addr_space omap44xx_scrm_addrs[] = { 5567 static struct omap_hwmod_addr_space omap44xx_scrm_addrs[] = {
5569 { 5568 {
5570 .pa_start = 0x4a30a000, 5569 .pa_start = 0x4a30a000,
5571 .pa_end = 0x4a30a7ff, 5570 .pa_end = 0x4a30a7ff,
5572 .flags = ADDR_TYPE_RT 5571 .flags = ADDR_TYPE_RT
5573 }, 5572 },
5574 { } 5573 { }
5575 }; 5574 };
5576 5575
5577 /* l4_wkup -> scrm */ 5576 /* l4_wkup -> scrm */
5578 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__scrm = { 5577 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__scrm = {
5579 .master = &omap44xx_l4_wkup_hwmod, 5578 .master = &omap44xx_l4_wkup_hwmod,
5580 .slave = &omap44xx_scrm_hwmod, 5579 .slave = &omap44xx_scrm_hwmod,
5581 .clk = "l4_wkup_clk_mux_ck", 5580 .clk = "l4_wkup_clk_mux_ck",
5582 .addr = omap44xx_scrm_addrs, 5581 .addr = omap44xx_scrm_addrs,
5583 .user = OCP_USER_MPU | OCP_USER_SDMA, 5582 .user = OCP_USER_MPU | OCP_USER_SDMA,
5584 }; 5583 };
5585 5584
5586 /* l3_main_2 -> sl2if */ 5585 /* l3_main_2 -> sl2if */
5587 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_l3_main_2__sl2if = { 5586 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_l3_main_2__sl2if = {
5588 .master = &omap44xx_l3_main_2_hwmod, 5587 .master = &omap44xx_l3_main_2_hwmod,
5589 .slave = &omap44xx_sl2if_hwmod, 5588 .slave = &omap44xx_sl2if_hwmod,
5590 .clk = "l3_div_ck", 5589 .clk = "l3_div_ck",
5591 .user = OCP_USER_MPU | OCP_USER_SDMA, 5590 .user = OCP_USER_MPU | OCP_USER_SDMA,
5592 }; 5591 };
5593 5592
5594 static struct omap_hwmod_addr_space omap44xx_slimbus1_addrs[] = { 5593 static struct omap_hwmod_addr_space omap44xx_slimbus1_addrs[] = {
5595 { 5594 {
5596 .pa_start = 0x4012c000, 5595 .pa_start = 0x4012c000,
5597 .pa_end = 0x4012c3ff, 5596 .pa_end = 0x4012c3ff,
5598 .flags = ADDR_TYPE_RT 5597 .flags = ADDR_TYPE_RT
5599 }, 5598 },
5600 { } 5599 { }
5601 }; 5600 };
5602 5601
5603 /* l4_abe -> slimbus1 */ 5602 /* l4_abe -> slimbus1 */
5604 static struct omap_hwmod_ocp_if omap44xx_l4_abe__slimbus1 = { 5603 static struct omap_hwmod_ocp_if omap44xx_l4_abe__slimbus1 = {
5605 .master = &omap44xx_l4_abe_hwmod, 5604 .master = &omap44xx_l4_abe_hwmod,
5606 .slave = &omap44xx_slimbus1_hwmod, 5605 .slave = &omap44xx_slimbus1_hwmod,
5607 .clk = "ocp_abe_iclk", 5606 .clk = "ocp_abe_iclk",
5608 .addr = omap44xx_slimbus1_addrs, 5607 .addr = omap44xx_slimbus1_addrs,
5609 .user = OCP_USER_MPU, 5608 .user = OCP_USER_MPU,
5610 }; 5609 };
5611 5610
5612 static struct omap_hwmod_addr_space omap44xx_slimbus1_dma_addrs[] = { 5611 static struct omap_hwmod_addr_space omap44xx_slimbus1_dma_addrs[] = {
5613 { 5612 {
5614 .pa_start = 0x4902c000, 5613 .pa_start = 0x4902c000,
5615 .pa_end = 0x4902c3ff, 5614 .pa_end = 0x4902c3ff,
5616 .flags = ADDR_TYPE_RT 5615 .flags = ADDR_TYPE_RT
5617 }, 5616 },
5618 { } 5617 { }
5619 }; 5618 };
5620 5619
5621 /* l4_abe -> slimbus1 (dma) */ 5620 /* l4_abe -> slimbus1 (dma) */
5622 static struct omap_hwmod_ocp_if omap44xx_l4_abe__slimbus1_dma = { 5621 static struct omap_hwmod_ocp_if omap44xx_l4_abe__slimbus1_dma = {
5623 .master = &omap44xx_l4_abe_hwmod, 5622 .master = &omap44xx_l4_abe_hwmod,
5624 .slave = &omap44xx_slimbus1_hwmod, 5623 .slave = &omap44xx_slimbus1_hwmod,
5625 .clk = "ocp_abe_iclk", 5624 .clk = "ocp_abe_iclk",
5626 .addr = omap44xx_slimbus1_dma_addrs, 5625 .addr = omap44xx_slimbus1_dma_addrs,
5627 .user = OCP_USER_SDMA, 5626 .user = OCP_USER_SDMA,
5628 }; 5627 };
5629 5628
5630 static struct omap_hwmod_addr_space omap44xx_slimbus2_addrs[] = { 5629 static struct omap_hwmod_addr_space omap44xx_slimbus2_addrs[] = {
5631 { 5630 {
5632 .pa_start = 0x48076000, 5631 .pa_start = 0x48076000,
5633 .pa_end = 0x480763ff, 5632 .pa_end = 0x480763ff,
5634 .flags = ADDR_TYPE_RT 5633 .flags = ADDR_TYPE_RT
5635 }, 5634 },
5636 { } 5635 { }
5637 }; 5636 };
5638 5637
5639 /* l4_per -> slimbus2 */ 5638 /* l4_per -> slimbus2 */
5640 static struct omap_hwmod_ocp_if omap44xx_l4_per__slimbus2 = { 5639 static struct omap_hwmod_ocp_if omap44xx_l4_per__slimbus2 = {
5641 .master = &omap44xx_l4_per_hwmod, 5640 .master = &omap44xx_l4_per_hwmod,
5642 .slave = &omap44xx_slimbus2_hwmod, 5641 .slave = &omap44xx_slimbus2_hwmod,
5643 .clk = "l4_div_ck", 5642 .clk = "l4_div_ck",
5644 .addr = omap44xx_slimbus2_addrs, 5643 .addr = omap44xx_slimbus2_addrs,
5645 .user = OCP_USER_MPU | OCP_USER_SDMA, 5644 .user = OCP_USER_MPU | OCP_USER_SDMA,
5646 }; 5645 };
5647 5646
5648 static struct omap_hwmod_addr_space omap44xx_smartreflex_core_addrs[] = { 5647 static struct omap_hwmod_addr_space omap44xx_smartreflex_core_addrs[] = {
5649 { 5648 {
5650 .pa_start = 0x4a0dd000, 5649 .pa_start = 0x4a0dd000,
5651 .pa_end = 0x4a0dd03f, 5650 .pa_end = 0x4a0dd03f,
5652 .flags = ADDR_TYPE_RT 5651 .flags = ADDR_TYPE_RT
5653 }, 5652 },
5654 { } 5653 { }
5655 }; 5654 };
5656 5655
5657 /* l4_cfg -> smartreflex_core */ 5656 /* l4_cfg -> smartreflex_core */
5658 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__smartreflex_core = { 5657 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__smartreflex_core = {
5659 .master = &omap44xx_l4_cfg_hwmod, 5658 .master = &omap44xx_l4_cfg_hwmod,
5660 .slave = &omap44xx_smartreflex_core_hwmod, 5659 .slave = &omap44xx_smartreflex_core_hwmod,
5661 .clk = "l4_div_ck", 5660 .clk = "l4_div_ck",
5662 .addr = omap44xx_smartreflex_core_addrs, 5661 .addr = omap44xx_smartreflex_core_addrs,
5663 .user = OCP_USER_MPU | OCP_USER_SDMA, 5662 .user = OCP_USER_MPU | OCP_USER_SDMA,
5664 }; 5663 };
5665 5664
5666 static struct omap_hwmod_addr_space omap44xx_smartreflex_iva_addrs[] = { 5665 static struct omap_hwmod_addr_space omap44xx_smartreflex_iva_addrs[] = {
5667 { 5666 {
5668 .pa_start = 0x4a0db000, 5667 .pa_start = 0x4a0db000,
5669 .pa_end = 0x4a0db03f, 5668 .pa_end = 0x4a0db03f,
5670 .flags = ADDR_TYPE_RT 5669 .flags = ADDR_TYPE_RT
5671 }, 5670 },
5672 { } 5671 { }
5673 }; 5672 };
5674 5673
5675 /* l4_cfg -> smartreflex_iva */ 5674 /* l4_cfg -> smartreflex_iva */
5676 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__smartreflex_iva = { 5675 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__smartreflex_iva = {
5677 .master = &omap44xx_l4_cfg_hwmod, 5676 .master = &omap44xx_l4_cfg_hwmod,
5678 .slave = &omap44xx_smartreflex_iva_hwmod, 5677 .slave = &omap44xx_smartreflex_iva_hwmod,
5679 .clk = "l4_div_ck", 5678 .clk = "l4_div_ck",
5680 .addr = omap44xx_smartreflex_iva_addrs, 5679 .addr = omap44xx_smartreflex_iva_addrs,
5681 .user = OCP_USER_MPU | OCP_USER_SDMA, 5680 .user = OCP_USER_MPU | OCP_USER_SDMA,
5682 }; 5681 };
5683 5682
5684 static struct omap_hwmod_addr_space omap44xx_smartreflex_mpu_addrs[] = { 5683 static struct omap_hwmod_addr_space omap44xx_smartreflex_mpu_addrs[] = {
5685 { 5684 {
5686 .pa_start = 0x4a0d9000, 5685 .pa_start = 0x4a0d9000,
5687 .pa_end = 0x4a0d903f, 5686 .pa_end = 0x4a0d903f,
5688 .flags = ADDR_TYPE_RT 5687 .flags = ADDR_TYPE_RT
5689 }, 5688 },
5690 { } 5689 { }
5691 }; 5690 };
5692 5691
5693 /* l4_cfg -> smartreflex_mpu */ 5692 /* l4_cfg -> smartreflex_mpu */
5694 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__smartreflex_mpu = { 5693 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__smartreflex_mpu = {
5695 .master = &omap44xx_l4_cfg_hwmod, 5694 .master = &omap44xx_l4_cfg_hwmod,
5696 .slave = &omap44xx_smartreflex_mpu_hwmod, 5695 .slave = &omap44xx_smartreflex_mpu_hwmod,
5697 .clk = "l4_div_ck", 5696 .clk = "l4_div_ck",
5698 .addr = omap44xx_smartreflex_mpu_addrs, 5697 .addr = omap44xx_smartreflex_mpu_addrs,
5699 .user = OCP_USER_MPU | OCP_USER_SDMA, 5698 .user = OCP_USER_MPU | OCP_USER_SDMA,
5700 }; 5699 };
5701 5700
5702 static struct omap_hwmod_addr_space omap44xx_spinlock_addrs[] = { 5701 static struct omap_hwmod_addr_space omap44xx_spinlock_addrs[] = {
5703 { 5702 {
5704 .pa_start = 0x4a0f6000, 5703 .pa_start = 0x4a0f6000,
5705 .pa_end = 0x4a0f6fff, 5704 .pa_end = 0x4a0f6fff,
5706 .flags = ADDR_TYPE_RT 5705 .flags = ADDR_TYPE_RT
5707 }, 5706 },
5708 { } 5707 { }
5709 }; 5708 };
5710 5709
5711 /* l4_cfg -> spinlock */ 5710 /* l4_cfg -> spinlock */
5712 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__spinlock = { 5711 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__spinlock = {
5713 .master = &omap44xx_l4_cfg_hwmod, 5712 .master = &omap44xx_l4_cfg_hwmod,
5714 .slave = &omap44xx_spinlock_hwmod, 5713 .slave = &omap44xx_spinlock_hwmod,
5715 .clk = "l4_div_ck", 5714 .clk = "l4_div_ck",
5716 .addr = omap44xx_spinlock_addrs, 5715 .addr = omap44xx_spinlock_addrs,
5717 .user = OCP_USER_MPU | OCP_USER_SDMA, 5716 .user = OCP_USER_MPU | OCP_USER_SDMA,
5718 }; 5717 };
5719 5718
5720 static struct omap_hwmod_addr_space omap44xx_timer1_addrs[] = { 5719 static struct omap_hwmod_addr_space omap44xx_timer1_addrs[] = {
5721 { 5720 {
5722 .pa_start = 0x4a318000, 5721 .pa_start = 0x4a318000,
5723 .pa_end = 0x4a31807f, 5722 .pa_end = 0x4a31807f,
5724 .flags = ADDR_TYPE_RT 5723 .flags = ADDR_TYPE_RT
5725 }, 5724 },
5726 { } 5725 { }
5727 }; 5726 };
5728 5727
5729 /* l4_wkup -> timer1 */ 5728 /* l4_wkup -> timer1 */
5730 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__timer1 = { 5729 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__timer1 = {
5731 .master = &omap44xx_l4_wkup_hwmod, 5730 .master = &omap44xx_l4_wkup_hwmod,
5732 .slave = &omap44xx_timer1_hwmod, 5731 .slave = &omap44xx_timer1_hwmod,
5733 .clk = "l4_wkup_clk_mux_ck", 5732 .clk = "l4_wkup_clk_mux_ck",
5734 .addr = omap44xx_timer1_addrs, 5733 .addr = omap44xx_timer1_addrs,
5735 .user = OCP_USER_MPU | OCP_USER_SDMA, 5734 .user = OCP_USER_MPU | OCP_USER_SDMA,
5736 }; 5735 };
5737 5736
5738 static struct omap_hwmod_addr_space omap44xx_timer2_addrs[] = { 5737 static struct omap_hwmod_addr_space omap44xx_timer2_addrs[] = {
5739 { 5738 {
5740 .pa_start = 0x48032000, 5739 .pa_start = 0x48032000,
5741 .pa_end = 0x4803207f, 5740 .pa_end = 0x4803207f,
5742 .flags = ADDR_TYPE_RT 5741 .flags = ADDR_TYPE_RT
5743 }, 5742 },
5744 { } 5743 { }
5745 }; 5744 };
5746 5745
5747 /* l4_per -> timer2 */ 5746 /* l4_per -> timer2 */
5748 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer2 = { 5747 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer2 = {
5749 .master = &omap44xx_l4_per_hwmod, 5748 .master = &omap44xx_l4_per_hwmod,
5750 .slave = &omap44xx_timer2_hwmod, 5749 .slave = &omap44xx_timer2_hwmod,
5751 .clk = "l4_div_ck", 5750 .clk = "l4_div_ck",
5752 .addr = omap44xx_timer2_addrs, 5751 .addr = omap44xx_timer2_addrs,
5753 .user = OCP_USER_MPU | OCP_USER_SDMA, 5752 .user = OCP_USER_MPU | OCP_USER_SDMA,
5754 }; 5753 };
5755 5754
5756 static struct omap_hwmod_addr_space omap44xx_timer3_addrs[] = { 5755 static struct omap_hwmod_addr_space omap44xx_timer3_addrs[] = {
5757 { 5756 {
5758 .pa_start = 0x48034000, 5757 .pa_start = 0x48034000,
5759 .pa_end = 0x4803407f, 5758 .pa_end = 0x4803407f,
5760 .flags = ADDR_TYPE_RT 5759 .flags = ADDR_TYPE_RT
5761 }, 5760 },
5762 { } 5761 { }
5763 }; 5762 };
5764 5763
5765 /* l4_per -> timer3 */ 5764 /* l4_per -> timer3 */
5766 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer3 = { 5765 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer3 = {
5767 .master = &omap44xx_l4_per_hwmod, 5766 .master = &omap44xx_l4_per_hwmod,
5768 .slave = &omap44xx_timer3_hwmod, 5767 .slave = &omap44xx_timer3_hwmod,
5769 .clk = "l4_div_ck", 5768 .clk = "l4_div_ck",
5770 .addr = omap44xx_timer3_addrs, 5769 .addr = omap44xx_timer3_addrs,
5771 .user = OCP_USER_MPU | OCP_USER_SDMA, 5770 .user = OCP_USER_MPU | OCP_USER_SDMA,
5772 }; 5771 };
5773 5772
5774 static struct omap_hwmod_addr_space omap44xx_timer4_addrs[] = { 5773 static struct omap_hwmod_addr_space omap44xx_timer4_addrs[] = {
5775 { 5774 {
5776 .pa_start = 0x48036000, 5775 .pa_start = 0x48036000,
5777 .pa_end = 0x4803607f, 5776 .pa_end = 0x4803607f,
5778 .flags = ADDR_TYPE_RT 5777 .flags = ADDR_TYPE_RT
5779 }, 5778 },
5780 { } 5779 { }
5781 }; 5780 };
5782 5781
5783 /* l4_per -> timer4 */ 5782 /* l4_per -> timer4 */
5784 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer4 = { 5783 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer4 = {
5785 .master = &omap44xx_l4_per_hwmod, 5784 .master = &omap44xx_l4_per_hwmod,
5786 .slave = &omap44xx_timer4_hwmod, 5785 .slave = &omap44xx_timer4_hwmod,
5787 .clk = "l4_div_ck", 5786 .clk = "l4_div_ck",
5788 .addr = omap44xx_timer4_addrs, 5787 .addr = omap44xx_timer4_addrs,
5789 .user = OCP_USER_MPU | OCP_USER_SDMA, 5788 .user = OCP_USER_MPU | OCP_USER_SDMA,
5790 }; 5789 };
5791 5790
5792 static struct omap_hwmod_addr_space omap44xx_timer5_addrs[] = { 5791 static struct omap_hwmod_addr_space omap44xx_timer5_addrs[] = {
5793 { 5792 {
5794 .pa_start = 0x40138000, 5793 .pa_start = 0x40138000,
5795 .pa_end = 0x4013807f, 5794 .pa_end = 0x4013807f,
5796 .flags = ADDR_TYPE_RT 5795 .flags = ADDR_TYPE_RT
5797 }, 5796 },
5798 { } 5797 { }
5799 }; 5798 };
5800 5799
5801 /* l4_abe -> timer5 */ 5800 /* l4_abe -> timer5 */
5802 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer5 = { 5801 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer5 = {
5803 .master = &omap44xx_l4_abe_hwmod, 5802 .master = &omap44xx_l4_abe_hwmod,
5804 .slave = &omap44xx_timer5_hwmod, 5803 .slave = &omap44xx_timer5_hwmod,
5805 .clk = "ocp_abe_iclk", 5804 .clk = "ocp_abe_iclk",
5806 .addr = omap44xx_timer5_addrs, 5805 .addr = omap44xx_timer5_addrs,
5807 .user = OCP_USER_MPU, 5806 .user = OCP_USER_MPU,
5808 }; 5807 };
5809 5808
5810 static struct omap_hwmod_addr_space omap44xx_timer5_dma_addrs[] = { 5809 static struct omap_hwmod_addr_space omap44xx_timer5_dma_addrs[] = {
5811 { 5810 {
5812 .pa_start = 0x49038000, 5811 .pa_start = 0x49038000,
5813 .pa_end = 0x4903807f, 5812 .pa_end = 0x4903807f,
5814 .flags = ADDR_TYPE_RT 5813 .flags = ADDR_TYPE_RT
5815 }, 5814 },
5816 { } 5815 { }
5817 }; 5816 };
5818 5817
5819 /* l4_abe -> timer5 (dma) */ 5818 /* l4_abe -> timer5 (dma) */
5820 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer5_dma = { 5819 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer5_dma = {
5821 .master = &omap44xx_l4_abe_hwmod, 5820 .master = &omap44xx_l4_abe_hwmod,
5822 .slave = &omap44xx_timer5_hwmod, 5821 .slave = &omap44xx_timer5_hwmod,
5823 .clk = "ocp_abe_iclk", 5822 .clk = "ocp_abe_iclk",
5824 .addr = omap44xx_timer5_dma_addrs, 5823 .addr = omap44xx_timer5_dma_addrs,
5825 .user = OCP_USER_SDMA, 5824 .user = OCP_USER_SDMA,
5826 }; 5825 };
5827 5826
5828 static struct omap_hwmod_addr_space omap44xx_timer6_addrs[] = { 5827 static struct omap_hwmod_addr_space omap44xx_timer6_addrs[] = {
5829 { 5828 {
5830 .pa_start = 0x4013a000, 5829 .pa_start = 0x4013a000,
5831 .pa_end = 0x4013a07f, 5830 .pa_end = 0x4013a07f,
5832 .flags = ADDR_TYPE_RT 5831 .flags = ADDR_TYPE_RT
5833 }, 5832 },
5834 { } 5833 { }
5835 }; 5834 };
5836 5835
5837 /* l4_abe -> timer6 */ 5836 /* l4_abe -> timer6 */
5838 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer6 = { 5837 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer6 = {
5839 .master = &omap44xx_l4_abe_hwmod, 5838 .master = &omap44xx_l4_abe_hwmod,
5840 .slave = &omap44xx_timer6_hwmod, 5839 .slave = &omap44xx_timer6_hwmod,
5841 .clk = "ocp_abe_iclk", 5840 .clk = "ocp_abe_iclk",
5842 .addr = omap44xx_timer6_addrs, 5841 .addr = omap44xx_timer6_addrs,
5843 .user = OCP_USER_MPU, 5842 .user = OCP_USER_MPU,
5844 }; 5843 };
5845 5844
5846 static struct omap_hwmod_addr_space omap44xx_timer6_dma_addrs[] = { 5845 static struct omap_hwmod_addr_space omap44xx_timer6_dma_addrs[] = {
5847 { 5846 {
5848 .pa_start = 0x4903a000, 5847 .pa_start = 0x4903a000,
5849 .pa_end = 0x4903a07f, 5848 .pa_end = 0x4903a07f,
5850 .flags = ADDR_TYPE_RT 5849 .flags = ADDR_TYPE_RT
5851 }, 5850 },
5852 { } 5851 { }
5853 }; 5852 };
5854 5853
5855 /* l4_abe -> timer6 (dma) */ 5854 /* l4_abe -> timer6 (dma) */
5856 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer6_dma = { 5855 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer6_dma = {
5857 .master = &omap44xx_l4_abe_hwmod, 5856 .master = &omap44xx_l4_abe_hwmod,
5858 .slave = &omap44xx_timer6_hwmod, 5857 .slave = &omap44xx_timer6_hwmod,
5859 .clk = "ocp_abe_iclk", 5858 .clk = "ocp_abe_iclk",
5860 .addr = omap44xx_timer6_dma_addrs, 5859 .addr = omap44xx_timer6_dma_addrs,
5861 .user = OCP_USER_SDMA, 5860 .user = OCP_USER_SDMA,
5862 }; 5861 };
5863 5862
5864 static struct omap_hwmod_addr_space omap44xx_timer7_addrs[] = { 5863 static struct omap_hwmod_addr_space omap44xx_timer7_addrs[] = {
5865 { 5864 {
5866 .pa_start = 0x4013c000, 5865 .pa_start = 0x4013c000,
5867 .pa_end = 0x4013c07f, 5866 .pa_end = 0x4013c07f,
5868 .flags = ADDR_TYPE_RT 5867 .flags = ADDR_TYPE_RT
5869 }, 5868 },
5870 { } 5869 { }
5871 }; 5870 };
5872 5871
5873 /* l4_abe -> timer7 */ 5872 /* l4_abe -> timer7 */
5874 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer7 = { 5873 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer7 = {
5875 .master = &omap44xx_l4_abe_hwmod, 5874 .master = &omap44xx_l4_abe_hwmod,
5876 .slave = &omap44xx_timer7_hwmod, 5875 .slave = &omap44xx_timer7_hwmod,
5877 .clk = "ocp_abe_iclk", 5876 .clk = "ocp_abe_iclk",
5878 .addr = omap44xx_timer7_addrs, 5877 .addr = omap44xx_timer7_addrs,
5879 .user = OCP_USER_MPU, 5878 .user = OCP_USER_MPU,
5880 }; 5879 };
5881 5880
5882 static struct omap_hwmod_addr_space omap44xx_timer7_dma_addrs[] = { 5881 static struct omap_hwmod_addr_space omap44xx_timer7_dma_addrs[] = {
5883 { 5882 {
5884 .pa_start = 0x4903c000, 5883 .pa_start = 0x4903c000,
5885 .pa_end = 0x4903c07f, 5884 .pa_end = 0x4903c07f,
5886 .flags = ADDR_TYPE_RT 5885 .flags = ADDR_TYPE_RT
5887 }, 5886 },
5888 { } 5887 { }
5889 }; 5888 };
5890 5889
5891 /* l4_abe -> timer7 (dma) */ 5890 /* l4_abe -> timer7 (dma) */
5892 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer7_dma = { 5891 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer7_dma = {
5893 .master = &omap44xx_l4_abe_hwmod, 5892 .master = &omap44xx_l4_abe_hwmod,
5894 .slave = &omap44xx_timer7_hwmod, 5893 .slave = &omap44xx_timer7_hwmod,
5895 .clk = "ocp_abe_iclk", 5894 .clk = "ocp_abe_iclk",
5896 .addr = omap44xx_timer7_dma_addrs, 5895 .addr = omap44xx_timer7_dma_addrs,
5897 .user = OCP_USER_SDMA, 5896 .user = OCP_USER_SDMA,
5898 }; 5897 };
5899 5898
5900 static struct omap_hwmod_addr_space omap44xx_timer8_addrs[] = { 5899 static struct omap_hwmod_addr_space omap44xx_timer8_addrs[] = {
5901 { 5900 {
5902 .pa_start = 0x4013e000, 5901 .pa_start = 0x4013e000,
5903 .pa_end = 0x4013e07f, 5902 .pa_end = 0x4013e07f,
5904 .flags = ADDR_TYPE_RT 5903 .flags = ADDR_TYPE_RT
5905 }, 5904 },
5906 { } 5905 { }
5907 }; 5906 };
5908 5907
5909 /* l4_abe -> timer8 */ 5908 /* l4_abe -> timer8 */
5910 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer8 = { 5909 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer8 = {
5911 .master = &omap44xx_l4_abe_hwmod, 5910 .master = &omap44xx_l4_abe_hwmod,
5912 .slave = &omap44xx_timer8_hwmod, 5911 .slave = &omap44xx_timer8_hwmod,
5913 .clk = "ocp_abe_iclk", 5912 .clk = "ocp_abe_iclk",
5914 .addr = omap44xx_timer8_addrs, 5913 .addr = omap44xx_timer8_addrs,
5915 .user = OCP_USER_MPU, 5914 .user = OCP_USER_MPU,
5916 }; 5915 };
5917 5916
5918 static struct omap_hwmod_addr_space omap44xx_timer8_dma_addrs[] = { 5917 static struct omap_hwmod_addr_space omap44xx_timer8_dma_addrs[] = {
5919 { 5918 {
5920 .pa_start = 0x4903e000, 5919 .pa_start = 0x4903e000,
5921 .pa_end = 0x4903e07f, 5920 .pa_end = 0x4903e07f,
5922 .flags = ADDR_TYPE_RT 5921 .flags = ADDR_TYPE_RT
5923 }, 5922 },
5924 { } 5923 { }
5925 }; 5924 };
5926 5925
5927 /* l4_abe -> timer8 (dma) */ 5926 /* l4_abe -> timer8 (dma) */
5928 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer8_dma = { 5927 static struct omap_hwmod_ocp_if omap44xx_l4_abe__timer8_dma = {
5929 .master = &omap44xx_l4_abe_hwmod, 5928 .master = &omap44xx_l4_abe_hwmod,
5930 .slave = &omap44xx_timer8_hwmod, 5929 .slave = &omap44xx_timer8_hwmod,
5931 .clk = "ocp_abe_iclk", 5930 .clk = "ocp_abe_iclk",
5932 .addr = omap44xx_timer8_dma_addrs, 5931 .addr = omap44xx_timer8_dma_addrs,
5933 .user = OCP_USER_SDMA, 5932 .user = OCP_USER_SDMA,
5934 }; 5933 };
5935 5934
5936 static struct omap_hwmod_addr_space omap44xx_timer9_addrs[] = { 5935 static struct omap_hwmod_addr_space omap44xx_timer9_addrs[] = {
5937 { 5936 {
5938 .pa_start = 0x4803e000, 5937 .pa_start = 0x4803e000,
5939 .pa_end = 0x4803e07f, 5938 .pa_end = 0x4803e07f,
5940 .flags = ADDR_TYPE_RT 5939 .flags = ADDR_TYPE_RT
5941 }, 5940 },
5942 { } 5941 { }
5943 }; 5942 };
5944 5943
5945 /* l4_per -> timer9 */ 5944 /* l4_per -> timer9 */
5946 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer9 = { 5945 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer9 = {
5947 .master = &omap44xx_l4_per_hwmod, 5946 .master = &omap44xx_l4_per_hwmod,
5948 .slave = &omap44xx_timer9_hwmod, 5947 .slave = &omap44xx_timer9_hwmod,
5949 .clk = "l4_div_ck", 5948 .clk = "l4_div_ck",
5950 .addr = omap44xx_timer9_addrs, 5949 .addr = omap44xx_timer9_addrs,
5951 .user = OCP_USER_MPU | OCP_USER_SDMA, 5950 .user = OCP_USER_MPU | OCP_USER_SDMA,
5952 }; 5951 };
5953 5952
5954 static struct omap_hwmod_addr_space omap44xx_timer10_addrs[] = { 5953 static struct omap_hwmod_addr_space omap44xx_timer10_addrs[] = {
5955 { 5954 {
5956 .pa_start = 0x48086000, 5955 .pa_start = 0x48086000,
5957 .pa_end = 0x4808607f, 5956 .pa_end = 0x4808607f,
5958 .flags = ADDR_TYPE_RT 5957 .flags = ADDR_TYPE_RT
5959 }, 5958 },
5960 { } 5959 { }
5961 }; 5960 };
5962 5961
5963 /* l4_per -> timer10 */ 5962 /* l4_per -> timer10 */
5964 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer10 = { 5963 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer10 = {
5965 .master = &omap44xx_l4_per_hwmod, 5964 .master = &omap44xx_l4_per_hwmod,
5966 .slave = &omap44xx_timer10_hwmod, 5965 .slave = &omap44xx_timer10_hwmod,
5967 .clk = "l4_div_ck", 5966 .clk = "l4_div_ck",
5968 .addr = omap44xx_timer10_addrs, 5967 .addr = omap44xx_timer10_addrs,
5969 .user = OCP_USER_MPU | OCP_USER_SDMA, 5968 .user = OCP_USER_MPU | OCP_USER_SDMA,
5970 }; 5969 };
5971 5970
5972 static struct omap_hwmod_addr_space omap44xx_timer11_addrs[] = { 5971 static struct omap_hwmod_addr_space omap44xx_timer11_addrs[] = {
5973 { 5972 {
5974 .pa_start = 0x48088000, 5973 .pa_start = 0x48088000,
5975 .pa_end = 0x4808807f, 5974 .pa_end = 0x4808807f,
5976 .flags = ADDR_TYPE_RT 5975 .flags = ADDR_TYPE_RT
5977 }, 5976 },
5978 { } 5977 { }
5979 }; 5978 };
5980 5979
5981 /* l4_per -> timer11 */ 5980 /* l4_per -> timer11 */
5982 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer11 = { 5981 static struct omap_hwmod_ocp_if omap44xx_l4_per__timer11 = {
5983 .master = &omap44xx_l4_per_hwmod, 5982 .master = &omap44xx_l4_per_hwmod,
5984 .slave = &omap44xx_timer11_hwmod, 5983 .slave = &omap44xx_timer11_hwmod,
5985 .clk = "l4_div_ck", 5984 .clk = "l4_div_ck",
5986 .addr = omap44xx_timer11_addrs, 5985 .addr = omap44xx_timer11_addrs,
5987 .user = OCP_USER_MPU | OCP_USER_SDMA, 5986 .user = OCP_USER_MPU | OCP_USER_SDMA,
5988 }; 5987 };
5989 5988
5990 static struct omap_hwmod_addr_space omap44xx_uart1_addrs[] = { 5989 static struct omap_hwmod_addr_space omap44xx_uart1_addrs[] = {
5991 { 5990 {
5992 .pa_start = 0x4806a000, 5991 .pa_start = 0x4806a000,
5993 .pa_end = 0x4806a0ff, 5992 .pa_end = 0x4806a0ff,
5994 .flags = ADDR_TYPE_RT 5993 .flags = ADDR_TYPE_RT
5995 }, 5994 },
5996 { } 5995 { }
5997 }; 5996 };
5998 5997
5999 /* l4_per -> uart1 */ 5998 /* l4_per -> uart1 */
6000 static struct omap_hwmod_ocp_if omap44xx_l4_per__uart1 = { 5999 static struct omap_hwmod_ocp_if omap44xx_l4_per__uart1 = {
6001 .master = &omap44xx_l4_per_hwmod, 6000 .master = &omap44xx_l4_per_hwmod,
6002 .slave = &omap44xx_uart1_hwmod, 6001 .slave = &omap44xx_uart1_hwmod,
6003 .clk = "l4_div_ck", 6002 .clk = "l4_div_ck",
6004 .addr = omap44xx_uart1_addrs, 6003 .addr = omap44xx_uart1_addrs,
6005 .user = OCP_USER_MPU | OCP_USER_SDMA, 6004 .user = OCP_USER_MPU | OCP_USER_SDMA,
6006 }; 6005 };
6007 6006
6008 static struct omap_hwmod_addr_space omap44xx_uart2_addrs[] = { 6007 static struct omap_hwmod_addr_space omap44xx_uart2_addrs[] = {
6009 { 6008 {
6010 .pa_start = 0x4806c000, 6009 .pa_start = 0x4806c000,
6011 .pa_end = 0x4806c0ff, 6010 .pa_end = 0x4806c0ff,
6012 .flags = ADDR_TYPE_RT 6011 .flags = ADDR_TYPE_RT
6013 }, 6012 },
6014 { } 6013 { }
6015 }; 6014 };
6016 6015
6017 /* l4_per -> uart2 */ 6016 /* l4_per -> uart2 */
6018 static struct omap_hwmod_ocp_if omap44xx_l4_per__uart2 = { 6017 static struct omap_hwmod_ocp_if omap44xx_l4_per__uart2 = {
6019 .master = &omap44xx_l4_per_hwmod, 6018 .master = &omap44xx_l4_per_hwmod,
6020 .slave = &omap44xx_uart2_hwmod, 6019 .slave = &omap44xx_uart2_hwmod,
6021 .clk = "l4_div_ck", 6020 .clk = "l4_div_ck",
6022 .addr = omap44xx_uart2_addrs, 6021 .addr = omap44xx_uart2_addrs,
6023 .user = OCP_USER_MPU | OCP_USER_SDMA, 6022 .user = OCP_USER_MPU | OCP_USER_SDMA,
6024 }; 6023 };
6025 6024
6026 static struct omap_hwmod_addr_space omap44xx_uart3_addrs[] = { 6025 static struct omap_hwmod_addr_space omap44xx_uart3_addrs[] = {
6027 { 6026 {
6028 .pa_start = 0x48020000, 6027 .pa_start = 0x48020000,
6029 .pa_end = 0x480200ff, 6028 .pa_end = 0x480200ff,
6030 .flags = ADDR_TYPE_RT 6029 .flags = ADDR_TYPE_RT
6031 }, 6030 },
6032 { } 6031 { }
6033 }; 6032 };
6034 6033
6035 /* l4_per -> uart3 */ 6034 /* l4_per -> uart3 */
6036 static struct omap_hwmod_ocp_if omap44xx_l4_per__uart3 = { 6035 static struct omap_hwmod_ocp_if omap44xx_l4_per__uart3 = {
6037 .master = &omap44xx_l4_per_hwmod, 6036 .master = &omap44xx_l4_per_hwmod,
6038 .slave = &omap44xx_uart3_hwmod, 6037 .slave = &omap44xx_uart3_hwmod,
6039 .clk = "l4_div_ck", 6038 .clk = "l4_div_ck",
6040 .addr = omap44xx_uart3_addrs, 6039 .addr = omap44xx_uart3_addrs,
6041 .user = OCP_USER_MPU | OCP_USER_SDMA, 6040 .user = OCP_USER_MPU | OCP_USER_SDMA,
6042 }; 6041 };
6043 6042
6044 static struct omap_hwmod_addr_space omap44xx_uart4_addrs[] = { 6043 static struct omap_hwmod_addr_space omap44xx_uart4_addrs[] = {
6045 { 6044 {
6046 .pa_start = 0x4806e000, 6045 .pa_start = 0x4806e000,
6047 .pa_end = 0x4806e0ff, 6046 .pa_end = 0x4806e0ff,
6048 .flags = ADDR_TYPE_RT 6047 .flags = ADDR_TYPE_RT
6049 }, 6048 },
6050 { } 6049 { }
6051 }; 6050 };
6052 6051
6053 /* l4_per -> uart4 */ 6052 /* l4_per -> uart4 */
6054 static struct omap_hwmod_ocp_if omap44xx_l4_per__uart4 = { 6053 static struct omap_hwmod_ocp_if omap44xx_l4_per__uart4 = {
6055 .master = &omap44xx_l4_per_hwmod, 6054 .master = &omap44xx_l4_per_hwmod,
6056 .slave = &omap44xx_uart4_hwmod, 6055 .slave = &omap44xx_uart4_hwmod,
6057 .clk = "l4_div_ck", 6056 .clk = "l4_div_ck",
6058 .addr = omap44xx_uart4_addrs, 6057 .addr = omap44xx_uart4_addrs,
6059 .user = OCP_USER_MPU | OCP_USER_SDMA, 6058 .user = OCP_USER_MPU | OCP_USER_SDMA,
6060 }; 6059 };
6061 6060
6062 static struct omap_hwmod_addr_space omap44xx_usb_host_fs_addrs[] = { 6061 static struct omap_hwmod_addr_space omap44xx_usb_host_fs_addrs[] = {
6063 { 6062 {
6064 .pa_start = 0x4a0a9000, 6063 .pa_start = 0x4a0a9000,
6065 .pa_end = 0x4a0a93ff, 6064 .pa_end = 0x4a0a93ff,
6066 .flags = ADDR_TYPE_RT 6065 .flags = ADDR_TYPE_RT
6067 }, 6066 },
6068 { } 6067 { }
6069 }; 6068 };
6070 6069
6071 /* l4_cfg -> usb_host_fs */ 6070 /* l4_cfg -> usb_host_fs */
6072 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_l4_cfg__usb_host_fs = { 6071 static struct omap_hwmod_ocp_if __maybe_unused omap44xx_l4_cfg__usb_host_fs = {
6073 .master = &omap44xx_l4_cfg_hwmod, 6072 .master = &omap44xx_l4_cfg_hwmod,
6074 .slave = &omap44xx_usb_host_fs_hwmod, 6073 .slave = &omap44xx_usb_host_fs_hwmod,
6075 .clk = "l4_div_ck", 6074 .clk = "l4_div_ck",
6076 .addr = omap44xx_usb_host_fs_addrs, 6075 .addr = omap44xx_usb_host_fs_addrs,
6077 .user = OCP_USER_MPU | OCP_USER_SDMA, 6076 .user = OCP_USER_MPU | OCP_USER_SDMA,
6078 }; 6077 };
6079 6078
6080 static struct omap_hwmod_addr_space omap44xx_usb_host_hs_addrs[] = { 6079 static struct omap_hwmod_addr_space omap44xx_usb_host_hs_addrs[] = {
6081 { 6080 {
6082 .name = "uhh", 6081 .name = "uhh",
6083 .pa_start = 0x4a064000, 6082 .pa_start = 0x4a064000,
6084 .pa_end = 0x4a0647ff, 6083 .pa_end = 0x4a0647ff,
6085 .flags = ADDR_TYPE_RT 6084 .flags = ADDR_TYPE_RT
6086 }, 6085 },
6087 { 6086 {
6088 .name = "ohci", 6087 .name = "ohci",
6089 .pa_start = 0x4a064800, 6088 .pa_start = 0x4a064800,
6090 .pa_end = 0x4a064bff, 6089 .pa_end = 0x4a064bff,
6091 }, 6090 },
6092 { 6091 {
6093 .name = "ehci", 6092 .name = "ehci",
6094 .pa_start = 0x4a064c00, 6093 .pa_start = 0x4a064c00,
6095 .pa_end = 0x4a064fff, 6094 .pa_end = 0x4a064fff,
6096 }, 6095 },
6097 {} 6096 {}
6098 }; 6097 };
6099 6098
6100 /* l4_cfg -> usb_host_hs */ 6099 /* l4_cfg -> usb_host_hs */
6101 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__usb_host_hs = { 6100 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__usb_host_hs = {
6102 .master = &omap44xx_l4_cfg_hwmod, 6101 .master = &omap44xx_l4_cfg_hwmod,
6103 .slave = &omap44xx_usb_host_hs_hwmod, 6102 .slave = &omap44xx_usb_host_hs_hwmod,
6104 .clk = "l4_div_ck", 6103 .clk = "l4_div_ck",
6105 .addr = omap44xx_usb_host_hs_addrs, 6104 .addr = omap44xx_usb_host_hs_addrs,
6106 .user = OCP_USER_MPU | OCP_USER_SDMA, 6105 .user = OCP_USER_MPU | OCP_USER_SDMA,
6107 }; 6106 };
6108 6107
6109 static struct omap_hwmod_addr_space omap44xx_usb_otg_hs_addrs[] = { 6108 static struct omap_hwmod_addr_space omap44xx_usb_otg_hs_addrs[] = {
6110 { 6109 {
6111 .pa_start = 0x4a0ab000, 6110 .pa_start = 0x4a0ab000,
6112 .pa_end = 0x4a0ab7ff, 6111 .pa_end = 0x4a0ab7ff,
6113 .flags = ADDR_TYPE_RT 6112 .flags = ADDR_TYPE_RT
6114 }, 6113 },
6115 { 6114 {
6116 /* XXX: Remove this once control module driver is in place */ 6115 /* XXX: Remove this once control module driver is in place */
6117 .pa_start = 0x4a00233c, 6116 .pa_start = 0x4a00233c,
6118 .pa_end = 0x4a00233f, 6117 .pa_end = 0x4a00233f,
6119 .flags = ADDR_TYPE_RT 6118 .flags = ADDR_TYPE_RT
6120 }, 6119 },
6121 { } 6120 { }
6122 }; 6121 };
6123 6122
6124 /* l4_cfg -> usb_otg_hs */ 6123 /* l4_cfg -> usb_otg_hs */
6125 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__usb_otg_hs = { 6124 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__usb_otg_hs = {
6126 .master = &omap44xx_l4_cfg_hwmod, 6125 .master = &omap44xx_l4_cfg_hwmod,
6127 .slave = &omap44xx_usb_otg_hs_hwmod, 6126 .slave = &omap44xx_usb_otg_hs_hwmod,
6128 .clk = "l4_div_ck", 6127 .clk = "l4_div_ck",
6129 .addr = omap44xx_usb_otg_hs_addrs, 6128 .addr = omap44xx_usb_otg_hs_addrs,
6130 .user = OCP_USER_MPU | OCP_USER_SDMA, 6129 .user = OCP_USER_MPU | OCP_USER_SDMA,
6131 }; 6130 };
6132 6131
6133 static struct omap_hwmod_addr_space omap44xx_usb_tll_hs_addrs[] = { 6132 static struct omap_hwmod_addr_space omap44xx_usb_tll_hs_addrs[] = {
6134 { 6133 {
6135 .name = "tll", 6134 .name = "tll",
6136 .pa_start = 0x4a062000, 6135 .pa_start = 0x4a062000,
6137 .pa_end = 0x4a063fff, 6136 .pa_end = 0x4a063fff,
6138 .flags = ADDR_TYPE_RT 6137 .flags = ADDR_TYPE_RT
6139 }, 6138 },
6140 {} 6139 {}
6141 }; 6140 };
6142 6141
6143 /* l4_cfg -> usb_tll_hs */ 6142 /* l4_cfg -> usb_tll_hs */
6144 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__usb_tll_hs = { 6143 static struct omap_hwmod_ocp_if omap44xx_l4_cfg__usb_tll_hs = {
6145 .master = &omap44xx_l4_cfg_hwmod, 6144 .master = &omap44xx_l4_cfg_hwmod,
6146 .slave = &omap44xx_usb_tll_hs_hwmod, 6145 .slave = &omap44xx_usb_tll_hs_hwmod,
6147 .clk = "l4_div_ck", 6146 .clk = "l4_div_ck",
6148 .addr = omap44xx_usb_tll_hs_addrs, 6147 .addr = omap44xx_usb_tll_hs_addrs,
6149 .user = OCP_USER_MPU | OCP_USER_SDMA, 6148 .user = OCP_USER_MPU | OCP_USER_SDMA,
6150 }; 6149 };
6151 6150
6152 static struct omap_hwmod_addr_space omap44xx_wd_timer2_addrs[] = { 6151 static struct omap_hwmod_addr_space omap44xx_wd_timer2_addrs[] = {
6153 { 6152 {
6154 .pa_start = 0x4a314000, 6153 .pa_start = 0x4a314000,
6155 .pa_end = 0x4a31407f, 6154 .pa_end = 0x4a31407f,
6156 .flags = ADDR_TYPE_RT 6155 .flags = ADDR_TYPE_RT
6157 }, 6156 },
6158 { } 6157 { }
6159 }; 6158 };
6160 6159
6161 /* l4_wkup -> wd_timer2 */ 6160 /* l4_wkup -> wd_timer2 */
6162 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__wd_timer2 = { 6161 static struct omap_hwmod_ocp_if omap44xx_l4_wkup__wd_timer2 = {
6163 .master = &omap44xx_l4_wkup_hwmod, 6162 .master = &omap44xx_l4_wkup_hwmod,
6164 .slave = &omap44xx_wd_timer2_hwmod, 6163 .slave = &omap44xx_wd_timer2_hwmod,
6165 .clk = "l4_wkup_clk_mux_ck", 6164 .clk = "l4_wkup_clk_mux_ck",
6166 .addr = omap44xx_wd_timer2_addrs, 6165 .addr = omap44xx_wd_timer2_addrs,
6167 .user = OCP_USER_MPU | OCP_USER_SDMA, 6166 .user = OCP_USER_MPU | OCP_USER_SDMA,
6168 }; 6167 };
6169 6168
6170 static struct omap_hwmod_addr_space omap44xx_wd_timer3_addrs[] = { 6169 static struct omap_hwmod_addr_space omap44xx_wd_timer3_addrs[] = {
6171 { 6170 {
6172 .pa_start = 0x40130000, 6171 .pa_start = 0x40130000,
6173 .pa_end = 0x4013007f, 6172 .pa_end = 0x4013007f,
6174 .flags = ADDR_TYPE_RT 6173 .flags = ADDR_TYPE_RT
6175 }, 6174 },
6176 { } 6175 { }
6177 }; 6176 };
6178 6177
6179 /* l4_abe -> wd_timer3 */ 6178 /* l4_abe -> wd_timer3 */
6180 static struct omap_hwmod_ocp_if omap44xx_l4_abe__wd_timer3 = { 6179 static struct omap_hwmod_ocp_if omap44xx_l4_abe__wd_timer3 = {
6181 .master = &omap44xx_l4_abe_hwmod, 6180 .master = &omap44xx_l4_abe_hwmod,
6182 .slave = &omap44xx_wd_timer3_hwmod, 6181 .slave = &omap44xx_wd_timer3_hwmod,
6183 .clk = "ocp_abe_iclk", 6182 .clk = "ocp_abe_iclk",
6184 .addr = omap44xx_wd_timer3_addrs, 6183 .addr = omap44xx_wd_timer3_addrs,
6185 .user = OCP_USER_MPU, 6184 .user = OCP_USER_MPU,
6186 }; 6185 };
6187 6186
6188 static struct omap_hwmod_addr_space omap44xx_wd_timer3_dma_addrs[] = { 6187 static struct omap_hwmod_addr_space omap44xx_wd_timer3_dma_addrs[] = {
6189 { 6188 {
6190 .pa_start = 0x49030000, 6189 .pa_start = 0x49030000,
6191 .pa_end = 0x4903007f, 6190 .pa_end = 0x4903007f,
6192 .flags = ADDR_TYPE_RT 6191 .flags = ADDR_TYPE_RT
6193 }, 6192 },
6194 { } 6193 { }
6195 }; 6194 };
6196 6195
6197 /* l4_abe -> wd_timer3 (dma) */ 6196 /* l4_abe -> wd_timer3 (dma) */
6198 static struct omap_hwmod_ocp_if omap44xx_l4_abe__wd_timer3_dma = { 6197 static struct omap_hwmod_ocp_if omap44xx_l4_abe__wd_timer3_dma = {
6199 .master = &omap44xx_l4_abe_hwmod, 6198 .master = &omap44xx_l4_abe_hwmod,
6200 .slave = &omap44xx_wd_timer3_hwmod, 6199 .slave = &omap44xx_wd_timer3_hwmod,
6201 .clk = "ocp_abe_iclk", 6200 .clk = "ocp_abe_iclk",
6202 .addr = omap44xx_wd_timer3_dma_addrs, 6201 .addr = omap44xx_wd_timer3_dma_addrs,
6203 .user = OCP_USER_SDMA, 6202 .user = OCP_USER_SDMA,
6204 }; 6203 };
6205 6204
6206 static struct omap_hwmod_ocp_if *omap44xx_hwmod_ocp_ifs[] __initdata = { 6205 static struct omap_hwmod_ocp_if *omap44xx_hwmod_ocp_ifs[] __initdata = {
6207 &omap44xx_c2c__c2c_target_fw, 6206 &omap44xx_c2c__c2c_target_fw,
6208 &omap44xx_l4_cfg__c2c_target_fw, 6207 &omap44xx_l4_cfg__c2c_target_fw,
6209 &omap44xx_l3_main_1__dmm, 6208 &omap44xx_l3_main_1__dmm,
6210 &omap44xx_mpu__dmm, 6209 &omap44xx_mpu__dmm,
6211 &omap44xx_c2c__emif_fw, 6210 &omap44xx_c2c__emif_fw,
6212 &omap44xx_dmm__emif_fw, 6211 &omap44xx_dmm__emif_fw,
6213 &omap44xx_l4_cfg__emif_fw, 6212 &omap44xx_l4_cfg__emif_fw,
6214 &omap44xx_iva__l3_instr, 6213 &omap44xx_iva__l3_instr,
6215 &omap44xx_l3_main_3__l3_instr, 6214 &omap44xx_l3_main_3__l3_instr,
6216 &omap44xx_ocp_wp_noc__l3_instr, 6215 &omap44xx_ocp_wp_noc__l3_instr,
6217 &omap44xx_dsp__l3_main_1, 6216 &omap44xx_dsp__l3_main_1,
6218 &omap44xx_dss__l3_main_1, 6217 &omap44xx_dss__l3_main_1,
6219 &omap44xx_l3_main_2__l3_main_1, 6218 &omap44xx_l3_main_2__l3_main_1,
6220 &omap44xx_l4_cfg__l3_main_1, 6219 &omap44xx_l4_cfg__l3_main_1,
6221 &omap44xx_mmc1__l3_main_1, 6220 &omap44xx_mmc1__l3_main_1,
6222 &omap44xx_mmc2__l3_main_1, 6221 &omap44xx_mmc2__l3_main_1,
6223 &omap44xx_mpu__l3_main_1, 6222 &omap44xx_mpu__l3_main_1,
6224 &omap44xx_c2c_target_fw__l3_main_2, 6223 &omap44xx_c2c_target_fw__l3_main_2,
6225 &omap44xx_debugss__l3_main_2, 6224 &omap44xx_debugss__l3_main_2,
6226 &omap44xx_dma_system__l3_main_2, 6225 &omap44xx_dma_system__l3_main_2,
6227 &omap44xx_fdif__l3_main_2, 6226 &omap44xx_fdif__l3_main_2,
6228 &omap44xx_gpu__l3_main_2, 6227 &omap44xx_gpu__l3_main_2,
6229 &omap44xx_hsi__l3_main_2, 6228 &omap44xx_hsi__l3_main_2,
6230 &omap44xx_ipu__l3_main_2, 6229 &omap44xx_ipu__l3_main_2,
6231 &omap44xx_iss__l3_main_2, 6230 &omap44xx_iss__l3_main_2,
6232 &omap44xx_iva__l3_main_2, 6231 &omap44xx_iva__l3_main_2,
6233 &omap44xx_l3_main_1__l3_main_2, 6232 &omap44xx_l3_main_1__l3_main_2,
6234 &omap44xx_l4_cfg__l3_main_2, 6233 &omap44xx_l4_cfg__l3_main_2,
6235 /* &omap44xx_usb_host_fs__l3_main_2, */ 6234 /* &omap44xx_usb_host_fs__l3_main_2, */
6236 &omap44xx_usb_host_hs__l3_main_2, 6235 &omap44xx_usb_host_hs__l3_main_2,
6237 &omap44xx_usb_otg_hs__l3_main_2, 6236 &omap44xx_usb_otg_hs__l3_main_2,
6238 &omap44xx_l3_main_1__l3_main_3, 6237 &omap44xx_l3_main_1__l3_main_3,
6239 &omap44xx_l3_main_2__l3_main_3, 6238 &omap44xx_l3_main_2__l3_main_3,
6240 &omap44xx_l4_cfg__l3_main_3, 6239 &omap44xx_l4_cfg__l3_main_3,
6241 /* &omap44xx_aess__l4_abe, */ 6240 /* &omap44xx_aess__l4_abe, */
6242 &omap44xx_dsp__l4_abe, 6241 &omap44xx_dsp__l4_abe,
6243 &omap44xx_l3_main_1__l4_abe, 6242 &omap44xx_l3_main_1__l4_abe,
6244 &omap44xx_mpu__l4_abe, 6243 &omap44xx_mpu__l4_abe,
6245 &omap44xx_l3_main_1__l4_cfg, 6244 &omap44xx_l3_main_1__l4_cfg,
6246 &omap44xx_l3_main_2__l4_per, 6245 &omap44xx_l3_main_2__l4_per,
6247 &omap44xx_l4_cfg__l4_wkup, 6246 &omap44xx_l4_cfg__l4_wkup,
6248 &omap44xx_mpu__mpu_private, 6247 &omap44xx_mpu__mpu_private,
6249 &omap44xx_l4_cfg__ocp_wp_noc, 6248 &omap44xx_l4_cfg__ocp_wp_noc,
6250 /* &omap44xx_l4_abe__aess, */ 6249 /* &omap44xx_l4_abe__aess, */
6251 /* &omap44xx_l4_abe__aess_dma, */ 6250 /* &omap44xx_l4_abe__aess_dma, */
6252 &omap44xx_l3_main_2__c2c, 6251 &omap44xx_l3_main_2__c2c,
6253 &omap44xx_l4_wkup__counter_32k, 6252 &omap44xx_l4_wkup__counter_32k,
6254 &omap44xx_l4_cfg__ctrl_module_core, 6253 &omap44xx_l4_cfg__ctrl_module_core,
6255 &omap44xx_l4_cfg__ctrl_module_pad_core, 6254 &omap44xx_l4_cfg__ctrl_module_pad_core,
6256 &omap44xx_l4_wkup__ctrl_module_wkup, 6255 &omap44xx_l4_wkup__ctrl_module_wkup,
6257 &omap44xx_l4_wkup__ctrl_module_pad_wkup, 6256 &omap44xx_l4_wkup__ctrl_module_pad_wkup,
6258 &omap44xx_l3_instr__debugss, 6257 &omap44xx_l3_instr__debugss,
6259 &omap44xx_l4_cfg__dma_system, 6258 &omap44xx_l4_cfg__dma_system,
6260 &omap44xx_l4_abe__dmic, 6259 &omap44xx_l4_abe__dmic,
6261 &omap44xx_l4_abe__dmic_dma, 6260 &omap44xx_l4_abe__dmic_dma,
6262 &omap44xx_dsp__iva, 6261 &omap44xx_dsp__iva,
6263 /* &omap44xx_dsp__sl2if, */ 6262 /* &omap44xx_dsp__sl2if, */
6264 &omap44xx_l4_cfg__dsp, 6263 &omap44xx_l4_cfg__dsp,
6265 &omap44xx_l3_main_2__dss, 6264 &omap44xx_l3_main_2__dss,
6266 &omap44xx_l4_per__dss, 6265 &omap44xx_l4_per__dss,
6267 &omap44xx_l3_main_2__dss_dispc, 6266 &omap44xx_l3_main_2__dss_dispc,
6268 &omap44xx_l4_per__dss_dispc, 6267 &omap44xx_l4_per__dss_dispc,
6269 &omap44xx_l3_main_2__dss_dsi1, 6268 &omap44xx_l3_main_2__dss_dsi1,
6270 &omap44xx_l4_per__dss_dsi1, 6269 &omap44xx_l4_per__dss_dsi1,
6271 &omap44xx_l3_main_2__dss_dsi2, 6270 &omap44xx_l3_main_2__dss_dsi2,
6272 &omap44xx_l4_per__dss_dsi2, 6271 &omap44xx_l4_per__dss_dsi2,
6273 &omap44xx_l3_main_2__dss_hdmi, 6272 &omap44xx_l3_main_2__dss_hdmi,
6274 &omap44xx_l4_per__dss_hdmi, 6273 &omap44xx_l4_per__dss_hdmi,
6275 &omap44xx_l3_main_2__dss_rfbi, 6274 &omap44xx_l3_main_2__dss_rfbi,
6276 &omap44xx_l4_per__dss_rfbi, 6275 &omap44xx_l4_per__dss_rfbi,
6277 &omap44xx_l3_main_2__dss_venc, 6276 &omap44xx_l3_main_2__dss_venc,
6278 &omap44xx_l4_per__dss_venc, 6277 &omap44xx_l4_per__dss_venc,
6279 &omap44xx_l4_per__elm, 6278 &omap44xx_l4_per__elm,
6280 &omap44xx_emif_fw__emif1, 6279 &omap44xx_emif_fw__emif1,
6281 &omap44xx_emif_fw__emif2, 6280 &omap44xx_emif_fw__emif2,
6282 &omap44xx_l4_cfg__fdif, 6281 &omap44xx_l4_cfg__fdif,
6283 &omap44xx_l4_wkup__gpio1, 6282 &omap44xx_l4_wkup__gpio1,
6284 &omap44xx_l4_per__gpio2, 6283 &omap44xx_l4_per__gpio2,
6285 &omap44xx_l4_per__gpio3, 6284 &omap44xx_l4_per__gpio3,
6286 &omap44xx_l4_per__gpio4, 6285 &omap44xx_l4_per__gpio4,
6287 &omap44xx_l4_per__gpio5, 6286 &omap44xx_l4_per__gpio5,
6288 &omap44xx_l4_per__gpio6, 6287 &omap44xx_l4_per__gpio6,
6289 &omap44xx_l3_main_2__gpmc, 6288 &omap44xx_l3_main_2__gpmc,
6290 &omap44xx_l3_main_2__gpu, 6289 &omap44xx_l3_main_2__gpu,
6291 &omap44xx_l4_per__hdq1w, 6290 &omap44xx_l4_per__hdq1w,
6292 &omap44xx_l4_cfg__hsi, 6291 &omap44xx_l4_cfg__hsi,
6293 &omap44xx_l4_per__i2c1, 6292 &omap44xx_l4_per__i2c1,
6294 &omap44xx_l4_per__i2c2, 6293 &omap44xx_l4_per__i2c2,
6295 &omap44xx_l4_per__i2c3, 6294 &omap44xx_l4_per__i2c3,
6296 &omap44xx_l4_per__i2c4, 6295 &omap44xx_l4_per__i2c4,
6297 &omap44xx_l3_main_2__ipu, 6296 &omap44xx_l3_main_2__ipu,
6298 &omap44xx_l3_main_2__iss, 6297 &omap44xx_l3_main_2__iss,
6299 /* &omap44xx_iva__sl2if, */ 6298 /* &omap44xx_iva__sl2if, */
6300 &omap44xx_l3_main_2__iva, 6299 &omap44xx_l3_main_2__iva,
6301 &omap44xx_l4_wkup__kbd, 6300 &omap44xx_l4_wkup__kbd,
6302 &omap44xx_l4_cfg__mailbox, 6301 &omap44xx_l4_cfg__mailbox,
6303 &omap44xx_l4_abe__mcasp, 6302 &omap44xx_l4_abe__mcasp,
6304 &omap44xx_l4_abe__mcasp_dma, 6303 &omap44xx_l4_abe__mcasp_dma,
6305 &omap44xx_l4_abe__mcbsp1, 6304 &omap44xx_l4_abe__mcbsp1,
6306 &omap44xx_l4_abe__mcbsp1_dma, 6305 &omap44xx_l4_abe__mcbsp1_dma,
6307 &omap44xx_l4_abe__mcbsp2, 6306 &omap44xx_l4_abe__mcbsp2,
6308 &omap44xx_l4_abe__mcbsp2_dma, 6307 &omap44xx_l4_abe__mcbsp2_dma,
6309 &omap44xx_l4_abe__mcbsp3, 6308 &omap44xx_l4_abe__mcbsp3,
6310 &omap44xx_l4_abe__mcbsp3_dma, 6309 &omap44xx_l4_abe__mcbsp3_dma,
6311 &omap44xx_l4_per__mcbsp4, 6310 &omap44xx_l4_per__mcbsp4,
6312 &omap44xx_l4_abe__mcpdm, 6311 &omap44xx_l4_abe__mcpdm,
6313 &omap44xx_l4_abe__mcpdm_dma, 6312 &omap44xx_l4_abe__mcpdm_dma,
6314 &omap44xx_l4_per__mcspi1, 6313 &omap44xx_l4_per__mcspi1,
6315 &omap44xx_l4_per__mcspi2, 6314 &omap44xx_l4_per__mcspi2,
6316 &omap44xx_l4_per__mcspi3, 6315 &omap44xx_l4_per__mcspi3,
6317 &omap44xx_l4_per__mcspi4, 6316 &omap44xx_l4_per__mcspi4,
6318 &omap44xx_l4_per__mmc1, 6317 &omap44xx_l4_per__mmc1,
6319 &omap44xx_l4_per__mmc2, 6318 &omap44xx_l4_per__mmc2,
6320 &omap44xx_l4_per__mmc3, 6319 &omap44xx_l4_per__mmc3,
6321 &omap44xx_l4_per__mmc4, 6320 &omap44xx_l4_per__mmc4,
6322 &omap44xx_l4_per__mmc5, 6321 &omap44xx_l4_per__mmc5,
6323 &omap44xx_l3_main_2__mmu_ipu, 6322 &omap44xx_l3_main_2__mmu_ipu,
6324 &omap44xx_l4_cfg__mmu_dsp, 6323 &omap44xx_l4_cfg__mmu_dsp,
6325 &omap44xx_l3_main_2__ocmc_ram, 6324 &omap44xx_l3_main_2__ocmc_ram,
6326 &omap44xx_l4_cfg__ocp2scp_usb_phy, 6325 &omap44xx_l4_cfg__ocp2scp_usb_phy,
6327 &omap44xx_mpu_private__prcm_mpu, 6326 &omap44xx_mpu_private__prcm_mpu,
6328 &omap44xx_l4_wkup__cm_core_aon, 6327 &omap44xx_l4_wkup__cm_core_aon,
6329 &omap44xx_l4_cfg__cm_core, 6328 &omap44xx_l4_cfg__cm_core,
6330 &omap44xx_l4_wkup__prm, 6329 &omap44xx_l4_wkup__prm,
6331 &omap44xx_l4_wkup__scrm, 6330 &omap44xx_l4_wkup__scrm,
6332 /* &omap44xx_l3_main_2__sl2if, */ 6331 /* &omap44xx_l3_main_2__sl2if, */
6333 &omap44xx_l4_abe__slimbus1, 6332 &omap44xx_l4_abe__slimbus1,
6334 &omap44xx_l4_abe__slimbus1_dma, 6333 &omap44xx_l4_abe__slimbus1_dma,
6335 &omap44xx_l4_per__slimbus2, 6334 &omap44xx_l4_per__slimbus2,
6336 &omap44xx_l4_cfg__smartreflex_core, 6335 &omap44xx_l4_cfg__smartreflex_core,
6337 &omap44xx_l4_cfg__smartreflex_iva, 6336 &omap44xx_l4_cfg__smartreflex_iva,
6338 &omap44xx_l4_cfg__smartreflex_mpu, 6337 &omap44xx_l4_cfg__smartreflex_mpu,
6339 &omap44xx_l4_cfg__spinlock, 6338 &omap44xx_l4_cfg__spinlock,
6340 &omap44xx_l4_wkup__timer1, 6339 &omap44xx_l4_wkup__timer1,
6341 &omap44xx_l4_per__timer2, 6340 &omap44xx_l4_per__timer2,
6342 &omap44xx_l4_per__timer3, 6341 &omap44xx_l4_per__timer3,
6343 &omap44xx_l4_per__timer4, 6342 &omap44xx_l4_per__timer4,
6344 &omap44xx_l4_abe__timer5, 6343 &omap44xx_l4_abe__timer5,
6345 &omap44xx_l4_abe__timer5_dma, 6344 &omap44xx_l4_abe__timer5_dma,
6346 &omap44xx_l4_abe__timer6, 6345 &omap44xx_l4_abe__timer6,
6347 &omap44xx_l4_abe__timer6_dma, 6346 &omap44xx_l4_abe__timer6_dma,
6348 &omap44xx_l4_abe__timer7, 6347 &omap44xx_l4_abe__timer7,
6349 &omap44xx_l4_abe__timer7_dma, 6348 &omap44xx_l4_abe__timer7_dma,
6350 &omap44xx_l4_abe__timer8, 6349 &omap44xx_l4_abe__timer8,
6351 &omap44xx_l4_abe__timer8_dma, 6350 &omap44xx_l4_abe__timer8_dma,
6352 &omap44xx_l4_per__timer9, 6351 &omap44xx_l4_per__timer9,
6353 &omap44xx_l4_per__timer10, 6352 &omap44xx_l4_per__timer10,
6354 &omap44xx_l4_per__timer11, 6353 &omap44xx_l4_per__timer11,
6355 &omap44xx_l4_per__uart1, 6354 &omap44xx_l4_per__uart1,
6356 &omap44xx_l4_per__uart2, 6355 &omap44xx_l4_per__uart2,
6357 &omap44xx_l4_per__uart3, 6356 &omap44xx_l4_per__uart3,
6358 &omap44xx_l4_per__uart4, 6357 &omap44xx_l4_per__uart4,
6359 /* &omap44xx_l4_cfg__usb_host_fs, */ 6358 /* &omap44xx_l4_cfg__usb_host_fs, */
6360 &omap44xx_l4_cfg__usb_host_hs, 6359 &omap44xx_l4_cfg__usb_host_hs,
6361 &omap44xx_l4_cfg__usb_otg_hs, 6360 &omap44xx_l4_cfg__usb_otg_hs,
6362 &omap44xx_l4_cfg__usb_tll_hs, 6361 &omap44xx_l4_cfg__usb_tll_hs,
6363 &omap44xx_l4_wkup__wd_timer2, 6362 &omap44xx_l4_wkup__wd_timer2,
6364 &omap44xx_l4_abe__wd_timer3, 6363 &omap44xx_l4_abe__wd_timer3,
6365 &omap44xx_l4_abe__wd_timer3_dma, 6364 &omap44xx_l4_abe__wd_timer3_dma,
6366 NULL, 6365 NULL,
6367 }; 6366 };
6368 6367
6369 int __init omap44xx_hwmod_init(void) 6368 int __init omap44xx_hwmod_init(void)
6370 { 6369 {
6371 omap_hwmod_init(); 6370 omap_hwmod_init();
6372 return omap_hwmod_register_links(omap44xx_hwmod_ocp_ifs); 6371 return omap_hwmod_register_links(omap44xx_hwmod_ocp_ifs);
6373 } 6372 }
6374 6373
6375 6374
drivers/i2c/busses/i2c-omap.c
1 /* 1 /*
2 * TI OMAP I2C master mode driver 2 * TI OMAP I2C master mode driver
3 * 3 *
4 * Copyright (C) 2003 MontaVista Software, Inc. 4 * Copyright (C) 2003 MontaVista Software, Inc.
5 * Copyright (C) 2005 Nokia Corporation 5 * Copyright (C) 2005 Nokia Corporation
6 * Copyright (C) 2004 - 2007 Texas Instruments. 6 * Copyright (C) 2004 - 2007 Texas Instruments.
7 * 7 *
8 * Originally written by MontaVista Software, Inc. 8 * Originally written by MontaVista Software, Inc.
9 * Additional contributions by: 9 * Additional contributions by:
10 * Tony Lindgren <tony@atomide.com> 10 * Tony Lindgren <tony@atomide.com>
11 * Imre Deak <imre.deak@nokia.com> 11 * Imre Deak <imre.deak@nokia.com>
12 * Juha Yrjรถlรค <juha.yrjola@solidboot.com> 12 * Juha Yrjรถlรค <juha.yrjola@solidboot.com>
13 * Syed Khasim <x0khasim@ti.com> 13 * Syed Khasim <x0khasim@ti.com>
14 * Nishant Menon <nm@ti.com> 14 * Nishant Menon <nm@ti.com>
15 * 15 *
16 * This program is free software; you can redistribute it and/or modify 16 * This program is free software; you can redistribute it and/or modify
17 * it under the terms of the GNU General Public License as published by 17 * it under the terms of the GNU General Public License as published by
18 * the Free Software Foundation; either version 2 of the License, or 18 * the Free Software Foundation; either version 2 of the License, or
19 * (at your option) any later version. 19 * (at your option) any later version.
20 * 20 *
21 * This program is distributed in the hope that it will be useful, 21 * This program is distributed in the hope that it will be useful,
22 * but WITHOUT ANY WARRANTY; without even the implied warranty of 22 * but WITHOUT ANY WARRANTY; without even the implied warranty of
23 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 23 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24 * GNU General Public License for more details. 24 * GNU General Public License for more details.
25 * 25 *
26 * You should have received a copy of the GNU General Public License 26 * You should have received a copy of the GNU General Public License
27 * along with this program; if not, write to the Free Software 27 * along with this program; if not, write to the Free Software
28 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 28 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
29 */ 29 */
30 30
31 #include <linux/module.h> 31 #include <linux/module.h>
32 #include <linux/delay.h> 32 #include <linux/delay.h>
33 #include <linux/i2c.h> 33 #include <linux/i2c.h>
34 #include <linux/err.h> 34 #include <linux/err.h>
35 #include <linux/interrupt.h> 35 #include <linux/interrupt.h>
36 #include <linux/completion.h> 36 #include <linux/completion.h>
37 #include <linux/platform_device.h> 37 #include <linux/platform_device.h>
38 #include <linux/clk.h> 38 #include <linux/clk.h>
39 #include <linux/io.h> 39 #include <linux/io.h>
40 #include <linux/of.h> 40 #include <linux/of.h>
41 #include <linux/of_i2c.h> 41 #include <linux/of_i2c.h>
42 #include <linux/of_device.h> 42 #include <linux/of_device.h>
43 #include <linux/slab.h> 43 #include <linux/slab.h>
44 #include <linux/i2c-omap.h> 44 #include <linux/i2c-omap.h>
45 #include <linux/pm_runtime.h> 45 #include <linux/pm_runtime.h>
46 #include <linux/pinctrl/consumer.h> 46 #include <linux/pinctrl/consumer.h>
47 47
48 /* I2C controller revisions */ 48 /* I2C controller revisions */
49 #define OMAP_I2C_OMAP1_REV_2 0x20 49 #define OMAP_I2C_OMAP1_REV_2 0x20
50 50
51 /* I2C controller revisions present on specific hardware */ 51 /* I2C controller revisions present on specific hardware */
52 #define OMAP_I2C_REV_ON_2430 0x00000036 52 #define OMAP_I2C_REV_ON_2430 0x00000036
53 #define OMAP_I2C_REV_ON_3430_3530 0x0000003C 53 #define OMAP_I2C_REV_ON_3430_3530 0x0000003C
54 #define OMAP_I2C_REV_ON_3630 0x00000040 54 #define OMAP_I2C_REV_ON_3630 0x00000040
55 #define OMAP_I2C_REV_ON_4430_PLUS 0x50400002 55 #define OMAP_I2C_REV_ON_4430_PLUS 0x50400002
56 56
57 /* timeout waiting for the controller to respond */ 57 /* timeout waiting for the controller to respond */
58 #define OMAP_I2C_TIMEOUT (msecs_to_jiffies(1000)) 58 #define OMAP_I2C_TIMEOUT (msecs_to_jiffies(1000))
59 59
60 /* timeout for pm runtime autosuspend */ 60 /* timeout for pm runtime autosuspend */
61 #define OMAP_I2C_PM_TIMEOUT 1000 /* ms */ 61 #define OMAP_I2C_PM_TIMEOUT 1000 /* ms */
62 62
63 /* For OMAP3 I2C_IV has changed to I2C_WE (wakeup enable) */ 63 /* For OMAP3 I2C_IV has changed to I2C_WE (wakeup enable) */
64 enum { 64 enum {
65 OMAP_I2C_REV_REG = 0, 65 OMAP_I2C_REV_REG = 0,
66 OMAP_I2C_IE_REG, 66 OMAP_I2C_IE_REG,
67 OMAP_I2C_STAT_REG, 67 OMAP_I2C_STAT_REG,
68 OMAP_I2C_IV_REG, 68 OMAP_I2C_IV_REG,
69 OMAP_I2C_WE_REG, 69 OMAP_I2C_WE_REG,
70 OMAP_I2C_SYSS_REG, 70 OMAP_I2C_SYSS_REG,
71 OMAP_I2C_BUF_REG, 71 OMAP_I2C_BUF_REG,
72 OMAP_I2C_CNT_REG, 72 OMAP_I2C_CNT_REG,
73 OMAP_I2C_DATA_REG, 73 OMAP_I2C_DATA_REG,
74 OMAP_I2C_SYSC_REG, 74 OMAP_I2C_SYSC_REG,
75 OMAP_I2C_CON_REG, 75 OMAP_I2C_CON_REG,
76 OMAP_I2C_OA_REG, 76 OMAP_I2C_OA_REG,
77 OMAP_I2C_SA_REG, 77 OMAP_I2C_SA_REG,
78 OMAP_I2C_PSC_REG, 78 OMAP_I2C_PSC_REG,
79 OMAP_I2C_SCLL_REG, 79 OMAP_I2C_SCLL_REG,
80 OMAP_I2C_SCLH_REG, 80 OMAP_I2C_SCLH_REG,
81 OMAP_I2C_SYSTEST_REG, 81 OMAP_I2C_SYSTEST_REG,
82 OMAP_I2C_BUFSTAT_REG, 82 OMAP_I2C_BUFSTAT_REG,
83 /* only on OMAP4430 */ 83 /* only on OMAP4430 */
84 OMAP_I2C_IP_V2_REVNB_LO, 84 OMAP_I2C_IP_V2_REVNB_LO,
85 OMAP_I2C_IP_V2_REVNB_HI, 85 OMAP_I2C_IP_V2_REVNB_HI,
86 OMAP_I2C_IP_V2_IRQSTATUS_RAW, 86 OMAP_I2C_IP_V2_IRQSTATUS_RAW,
87 OMAP_I2C_IP_V2_IRQENABLE_SET, 87 OMAP_I2C_IP_V2_IRQENABLE_SET,
88 OMAP_I2C_IP_V2_IRQENABLE_CLR, 88 OMAP_I2C_IP_V2_IRQENABLE_CLR,
89 }; 89 };
90 90
91 /* I2C Interrupt Enable Register (OMAP_I2C_IE): */ 91 /* I2C Interrupt Enable Register (OMAP_I2C_IE): */
92 #define OMAP_I2C_IE_XDR (1 << 14) /* TX Buffer drain int enable */ 92 #define OMAP_I2C_IE_XDR (1 << 14) /* TX Buffer drain int enable */
93 #define OMAP_I2C_IE_RDR (1 << 13) /* RX Buffer drain int enable */ 93 #define OMAP_I2C_IE_RDR (1 << 13) /* RX Buffer drain int enable */
94 #define OMAP_I2C_IE_XRDY (1 << 4) /* TX data ready int enable */ 94 #define OMAP_I2C_IE_XRDY (1 << 4) /* TX data ready int enable */
95 #define OMAP_I2C_IE_RRDY (1 << 3) /* RX data ready int enable */ 95 #define OMAP_I2C_IE_RRDY (1 << 3) /* RX data ready int enable */
96 #define OMAP_I2C_IE_ARDY (1 << 2) /* Access ready int enable */ 96 #define OMAP_I2C_IE_ARDY (1 << 2) /* Access ready int enable */
97 #define OMAP_I2C_IE_NACK (1 << 1) /* No ack interrupt enable */ 97 #define OMAP_I2C_IE_NACK (1 << 1) /* No ack interrupt enable */
98 #define OMAP_I2C_IE_AL (1 << 0) /* Arbitration lost int ena */ 98 #define OMAP_I2C_IE_AL (1 << 0) /* Arbitration lost int ena */
99 99
100 /* I2C Status Register (OMAP_I2C_STAT): */ 100 /* I2C Status Register (OMAP_I2C_STAT): */
101 #define OMAP_I2C_STAT_XDR (1 << 14) /* TX Buffer draining */ 101 #define OMAP_I2C_STAT_XDR (1 << 14) /* TX Buffer draining */
102 #define OMAP_I2C_STAT_RDR (1 << 13) /* RX Buffer draining */ 102 #define OMAP_I2C_STAT_RDR (1 << 13) /* RX Buffer draining */
103 #define OMAP_I2C_STAT_BB (1 << 12) /* Bus busy */ 103 #define OMAP_I2C_STAT_BB (1 << 12) /* Bus busy */
104 #define OMAP_I2C_STAT_ROVR (1 << 11) /* Receive overrun */ 104 #define OMAP_I2C_STAT_ROVR (1 << 11) /* Receive overrun */
105 #define OMAP_I2C_STAT_XUDF (1 << 10) /* Transmit underflow */ 105 #define OMAP_I2C_STAT_XUDF (1 << 10) /* Transmit underflow */
106 #define OMAP_I2C_STAT_AAS (1 << 9) /* Address as slave */ 106 #define OMAP_I2C_STAT_AAS (1 << 9) /* Address as slave */
107 #define OMAP_I2C_STAT_AD0 (1 << 8) /* Address zero */ 107 #define OMAP_I2C_STAT_AD0 (1 << 8) /* Address zero */
108 #define OMAP_I2C_STAT_XRDY (1 << 4) /* Transmit data ready */ 108 #define OMAP_I2C_STAT_XRDY (1 << 4) /* Transmit data ready */
109 #define OMAP_I2C_STAT_RRDY (1 << 3) /* Receive data ready */ 109 #define OMAP_I2C_STAT_RRDY (1 << 3) /* Receive data ready */
110 #define OMAP_I2C_STAT_ARDY (1 << 2) /* Register access ready */ 110 #define OMAP_I2C_STAT_ARDY (1 << 2) /* Register access ready */
111 #define OMAP_I2C_STAT_NACK (1 << 1) /* No ack interrupt enable */ 111 #define OMAP_I2C_STAT_NACK (1 << 1) /* No ack interrupt enable */
112 #define OMAP_I2C_STAT_AL (1 << 0) /* Arbitration lost int ena */ 112 #define OMAP_I2C_STAT_AL (1 << 0) /* Arbitration lost int ena */
113 113
114 /* I2C WE wakeup enable register */ 114 /* I2C WE wakeup enable register */
115 #define OMAP_I2C_WE_XDR_WE (1 << 14) /* TX drain wakup */ 115 #define OMAP_I2C_WE_XDR_WE (1 << 14) /* TX drain wakup */
116 #define OMAP_I2C_WE_RDR_WE (1 << 13) /* RX drain wakeup */ 116 #define OMAP_I2C_WE_RDR_WE (1 << 13) /* RX drain wakeup */
117 #define OMAP_I2C_WE_AAS_WE (1 << 9) /* Address as slave wakeup*/ 117 #define OMAP_I2C_WE_AAS_WE (1 << 9) /* Address as slave wakeup*/
118 #define OMAP_I2C_WE_BF_WE (1 << 8) /* Bus free wakeup */ 118 #define OMAP_I2C_WE_BF_WE (1 << 8) /* Bus free wakeup */
119 #define OMAP_I2C_WE_STC_WE (1 << 6) /* Start condition wakeup */ 119 #define OMAP_I2C_WE_STC_WE (1 << 6) /* Start condition wakeup */
120 #define OMAP_I2C_WE_GC_WE (1 << 5) /* General call wakeup */ 120 #define OMAP_I2C_WE_GC_WE (1 << 5) /* General call wakeup */
121 #define OMAP_I2C_WE_DRDY_WE (1 << 3) /* TX/RX data ready wakeup */ 121 #define OMAP_I2C_WE_DRDY_WE (1 << 3) /* TX/RX data ready wakeup */
122 #define OMAP_I2C_WE_ARDY_WE (1 << 2) /* Reg access ready wakeup */ 122 #define OMAP_I2C_WE_ARDY_WE (1 << 2) /* Reg access ready wakeup */
123 #define OMAP_I2C_WE_NACK_WE (1 << 1) /* No acknowledgment wakeup */ 123 #define OMAP_I2C_WE_NACK_WE (1 << 1) /* No acknowledgment wakeup */
124 #define OMAP_I2C_WE_AL_WE (1 << 0) /* Arbitration lost wakeup */ 124 #define OMAP_I2C_WE_AL_WE (1 << 0) /* Arbitration lost wakeup */
125 125
126 #define OMAP_I2C_WE_ALL (OMAP_I2C_WE_XDR_WE | OMAP_I2C_WE_RDR_WE | \ 126 #define OMAP_I2C_WE_ALL (OMAP_I2C_WE_XDR_WE | OMAP_I2C_WE_RDR_WE | \
127 OMAP_I2C_WE_AAS_WE | OMAP_I2C_WE_BF_WE | \ 127 OMAP_I2C_WE_AAS_WE | OMAP_I2C_WE_BF_WE | \
128 OMAP_I2C_WE_STC_WE | OMAP_I2C_WE_GC_WE | \ 128 OMAP_I2C_WE_STC_WE | OMAP_I2C_WE_GC_WE | \
129 OMAP_I2C_WE_DRDY_WE | OMAP_I2C_WE_ARDY_WE | \ 129 OMAP_I2C_WE_DRDY_WE | OMAP_I2C_WE_ARDY_WE | \
130 OMAP_I2C_WE_NACK_WE | OMAP_I2C_WE_AL_WE) 130 OMAP_I2C_WE_NACK_WE | OMAP_I2C_WE_AL_WE)
131 131
132 /* I2C Buffer Configuration Register (OMAP_I2C_BUF): */ 132 /* I2C Buffer Configuration Register (OMAP_I2C_BUF): */
133 #define OMAP_I2C_BUF_RDMA_EN (1 << 15) /* RX DMA channel enable */ 133 #define OMAP_I2C_BUF_RDMA_EN (1 << 15) /* RX DMA channel enable */
134 #define OMAP_I2C_BUF_RXFIF_CLR (1 << 14) /* RX FIFO Clear */ 134 #define OMAP_I2C_BUF_RXFIF_CLR (1 << 14) /* RX FIFO Clear */
135 #define OMAP_I2C_BUF_XDMA_EN (1 << 7) /* TX DMA channel enable */ 135 #define OMAP_I2C_BUF_XDMA_EN (1 << 7) /* TX DMA channel enable */
136 #define OMAP_I2C_BUF_TXFIF_CLR (1 << 6) /* TX FIFO Clear */ 136 #define OMAP_I2C_BUF_TXFIF_CLR (1 << 6) /* TX FIFO Clear */
137 137
138 /* I2C Configuration Register (OMAP_I2C_CON): */ 138 /* I2C Configuration Register (OMAP_I2C_CON): */
139 #define OMAP_I2C_CON_EN (1 << 15) /* I2C module enable */ 139 #define OMAP_I2C_CON_EN (1 << 15) /* I2C module enable */
140 #define OMAP_I2C_CON_BE (1 << 14) /* Big endian mode */ 140 #define OMAP_I2C_CON_BE (1 << 14) /* Big endian mode */
141 #define OMAP_I2C_CON_OPMODE_HS (1 << 12) /* High Speed support */ 141 #define OMAP_I2C_CON_OPMODE_HS (1 << 12) /* High Speed support */
142 #define OMAP_I2C_CON_STB (1 << 11) /* Start byte mode (master) */ 142 #define OMAP_I2C_CON_STB (1 << 11) /* Start byte mode (master) */
143 #define OMAP_I2C_CON_MST (1 << 10) /* Master/slave mode */ 143 #define OMAP_I2C_CON_MST (1 << 10) /* Master/slave mode */
144 #define OMAP_I2C_CON_TRX (1 << 9) /* TX/RX mode (master only) */ 144 #define OMAP_I2C_CON_TRX (1 << 9) /* TX/RX mode (master only) */
145 #define OMAP_I2C_CON_XA (1 << 8) /* Expand address */ 145 #define OMAP_I2C_CON_XA (1 << 8) /* Expand address */
146 #define OMAP_I2C_CON_RM (1 << 2) /* Repeat mode (master only) */ 146 #define OMAP_I2C_CON_RM (1 << 2) /* Repeat mode (master only) */
147 #define OMAP_I2C_CON_STP (1 << 1) /* Stop cond (master only) */ 147 #define OMAP_I2C_CON_STP (1 << 1) /* Stop cond (master only) */
148 #define OMAP_I2C_CON_STT (1 << 0) /* Start condition (master) */ 148 #define OMAP_I2C_CON_STT (1 << 0) /* Start condition (master) */
149 149
150 /* I2C SCL time value when Master */ 150 /* I2C SCL time value when Master */
151 #define OMAP_I2C_SCLL_HSSCLL 8 151 #define OMAP_I2C_SCLL_HSSCLL 8
152 #define OMAP_I2C_SCLH_HSSCLH 8 152 #define OMAP_I2C_SCLH_HSSCLH 8
153 153
154 /* I2C System Test Register (OMAP_I2C_SYSTEST): */ 154 /* I2C System Test Register (OMAP_I2C_SYSTEST): */
155 #ifdef DEBUG 155 #ifdef DEBUG
156 #define OMAP_I2C_SYSTEST_ST_EN (1 << 15) /* System test enable */ 156 #define OMAP_I2C_SYSTEST_ST_EN (1 << 15) /* System test enable */
157 #define OMAP_I2C_SYSTEST_FREE (1 << 14) /* Free running mode */ 157 #define OMAP_I2C_SYSTEST_FREE (1 << 14) /* Free running mode */
158 #define OMAP_I2C_SYSTEST_TMODE_MASK (3 << 12) /* Test mode select */ 158 #define OMAP_I2C_SYSTEST_TMODE_MASK (3 << 12) /* Test mode select */
159 #define OMAP_I2C_SYSTEST_TMODE_SHIFT (12) /* Test mode select */ 159 #define OMAP_I2C_SYSTEST_TMODE_SHIFT (12) /* Test mode select */
160 #define OMAP_I2C_SYSTEST_SCL_I (1 << 3) /* SCL line sense in */ 160 #define OMAP_I2C_SYSTEST_SCL_I (1 << 3) /* SCL line sense in */
161 #define OMAP_I2C_SYSTEST_SCL_O (1 << 2) /* SCL line drive out */ 161 #define OMAP_I2C_SYSTEST_SCL_O (1 << 2) /* SCL line drive out */
162 #define OMAP_I2C_SYSTEST_SDA_I (1 << 1) /* SDA line sense in */ 162 #define OMAP_I2C_SYSTEST_SDA_I (1 << 1) /* SDA line sense in */
163 #define OMAP_I2C_SYSTEST_SDA_O (1 << 0) /* SDA line drive out */ 163 #define OMAP_I2C_SYSTEST_SDA_O (1 << 0) /* SDA line drive out */
164 #endif 164 #endif
165 165
166 /* OCP_SYSSTATUS bit definitions */ 166 /* OCP_SYSSTATUS bit definitions */
167 #define SYSS_RESETDONE_MASK (1 << 0) 167 #define SYSS_RESETDONE_MASK (1 << 0)
168 168
169 /* OCP_SYSCONFIG bit definitions */ 169 /* OCP_SYSCONFIG bit definitions */
170 #define SYSC_CLOCKACTIVITY_MASK (0x3 << 8) 170 #define SYSC_CLOCKACTIVITY_MASK (0x3 << 8)
171 #define SYSC_SIDLEMODE_MASK (0x3 << 3) 171 #define SYSC_SIDLEMODE_MASK (0x3 << 3)
172 #define SYSC_ENAWAKEUP_MASK (1 << 2) 172 #define SYSC_ENAWAKEUP_MASK (1 << 2)
173 #define SYSC_SOFTRESET_MASK (1 << 1) 173 #define SYSC_SOFTRESET_MASK (1 << 1)
174 #define SYSC_AUTOIDLE_MASK (1 << 0) 174 #define SYSC_AUTOIDLE_MASK (1 << 0)
175 175
176 #define SYSC_IDLEMODE_SMART 0x2 176 #define SYSC_IDLEMODE_SMART 0x2
177 #define SYSC_CLOCKACTIVITY_FCLK 0x2 177 #define SYSC_CLOCKACTIVITY_FCLK 0x2
178 178
179 /* Errata definitions */ 179 /* Errata definitions */
180 #define I2C_OMAP_ERRATA_I207 (1 << 0) 180 #define I2C_OMAP_ERRATA_I207 (1 << 0)
181 #define I2C_OMAP_ERRATA_I462 (1 << 1) 181 #define I2C_OMAP_ERRATA_I462 (1 << 1)
182 182
183 struct omap_i2c_dev { 183 struct omap_i2c_dev {
184 spinlock_t lock; /* IRQ synchronization */ 184 spinlock_t lock; /* IRQ synchronization */
185 struct device *dev; 185 struct device *dev;
186 void __iomem *base; /* virtual */ 186 void __iomem *base; /* virtual */
187 int irq; 187 int irq;
188 int reg_shift; /* bit shift for I2C register addresses */ 188 int reg_shift; /* bit shift for I2C register addresses */
189 struct completion cmd_complete; 189 struct completion cmd_complete;
190 struct resource *ioarea; 190 struct resource *ioarea;
191 u32 latency; /* maximum mpu wkup latency */ 191 u32 latency; /* maximum mpu wkup latency */
192 void (*set_mpu_wkup_lat)(struct device *dev, 192 void (*set_mpu_wkup_lat)(struct device *dev,
193 long latency); 193 long latency);
194 u32 speed; /* Speed of bus in kHz */ 194 u32 speed; /* Speed of bus in kHz */
195 u32 flags; 195 u32 flags;
196 u16 cmd_err; 196 u16 cmd_err;
197 u8 *buf; 197 u8 *buf;
198 u8 *regs; 198 u8 *regs;
199 size_t buf_len; 199 size_t buf_len;
200 struct i2c_adapter adapter; 200 struct i2c_adapter adapter;
201 u8 threshold; 201 u8 threshold;
202 u8 fifo_size; /* use as flag and value 202 u8 fifo_size; /* use as flag and value
203 * fifo_size==0 implies no fifo 203 * fifo_size==0 implies no fifo
204 * if set, should be trsh+1 204 * if set, should be trsh+1
205 */ 205 */
206 u32 rev; 206 u32 rev;
207 unsigned b_hw:1; /* bad h/w fixes */ 207 unsigned b_hw:1; /* bad h/w fixes */
208 unsigned receiver:1; /* true when we're in receiver mode */ 208 unsigned receiver:1; /* true when we're in receiver mode */
209 u16 iestate; /* Saved interrupt register */ 209 u16 iestate; /* Saved interrupt register */
210 u16 pscstate; 210 u16 pscstate;
211 u16 scllstate; 211 u16 scllstate;
212 u16 sclhstate; 212 u16 sclhstate;
213 u16 syscstate; 213 u16 syscstate;
214 u16 westate; 214 u16 westate;
215 u16 errata; 215 u16 errata;
216 216
217 struct pinctrl *pins; 217 struct pinctrl *pins;
218 }; 218 };
219 219
220 static const u8 reg_map_ip_v1[] = { 220 static const u8 reg_map_ip_v1[] = {
221 [OMAP_I2C_REV_REG] = 0x00, 221 [OMAP_I2C_REV_REG] = 0x00,
222 [OMAP_I2C_IE_REG] = 0x01, 222 [OMAP_I2C_IE_REG] = 0x01,
223 [OMAP_I2C_STAT_REG] = 0x02, 223 [OMAP_I2C_STAT_REG] = 0x02,
224 [OMAP_I2C_IV_REG] = 0x03, 224 [OMAP_I2C_IV_REG] = 0x03,
225 [OMAP_I2C_WE_REG] = 0x03, 225 [OMAP_I2C_WE_REG] = 0x03,
226 [OMAP_I2C_SYSS_REG] = 0x04, 226 [OMAP_I2C_SYSS_REG] = 0x04,
227 [OMAP_I2C_BUF_REG] = 0x05, 227 [OMAP_I2C_BUF_REG] = 0x05,
228 [OMAP_I2C_CNT_REG] = 0x06, 228 [OMAP_I2C_CNT_REG] = 0x06,
229 [OMAP_I2C_DATA_REG] = 0x07, 229 [OMAP_I2C_DATA_REG] = 0x07,
230 [OMAP_I2C_SYSC_REG] = 0x08, 230 [OMAP_I2C_SYSC_REG] = 0x08,
231 [OMAP_I2C_CON_REG] = 0x09, 231 [OMAP_I2C_CON_REG] = 0x09,
232 [OMAP_I2C_OA_REG] = 0x0a, 232 [OMAP_I2C_OA_REG] = 0x0a,
233 [OMAP_I2C_SA_REG] = 0x0b, 233 [OMAP_I2C_SA_REG] = 0x0b,
234 [OMAP_I2C_PSC_REG] = 0x0c, 234 [OMAP_I2C_PSC_REG] = 0x0c,
235 [OMAP_I2C_SCLL_REG] = 0x0d, 235 [OMAP_I2C_SCLL_REG] = 0x0d,
236 [OMAP_I2C_SCLH_REG] = 0x0e, 236 [OMAP_I2C_SCLH_REG] = 0x0e,
237 [OMAP_I2C_SYSTEST_REG] = 0x0f, 237 [OMAP_I2C_SYSTEST_REG] = 0x0f,
238 [OMAP_I2C_BUFSTAT_REG] = 0x10, 238 [OMAP_I2C_BUFSTAT_REG] = 0x10,
239 }; 239 };
240 240
241 static const u8 reg_map_ip_v2[] = { 241 static const u8 reg_map_ip_v2[] = {
242 [OMAP_I2C_REV_REG] = 0x04, 242 [OMAP_I2C_REV_REG] = 0x04,
243 [OMAP_I2C_IE_REG] = 0x2c, 243 [OMAP_I2C_IE_REG] = 0x2c,
244 [OMAP_I2C_STAT_REG] = 0x28, 244 [OMAP_I2C_STAT_REG] = 0x28,
245 [OMAP_I2C_IV_REG] = 0x34, 245 [OMAP_I2C_IV_REG] = 0x34,
246 [OMAP_I2C_WE_REG] = 0x34, 246 [OMAP_I2C_WE_REG] = 0x34,
247 [OMAP_I2C_SYSS_REG] = 0x90, 247 [OMAP_I2C_SYSS_REG] = 0x90,
248 [OMAP_I2C_BUF_REG] = 0x94, 248 [OMAP_I2C_BUF_REG] = 0x94,
249 [OMAP_I2C_CNT_REG] = 0x98, 249 [OMAP_I2C_CNT_REG] = 0x98,
250 [OMAP_I2C_DATA_REG] = 0x9c, 250 [OMAP_I2C_DATA_REG] = 0x9c,
251 [OMAP_I2C_SYSC_REG] = 0x10, 251 [OMAP_I2C_SYSC_REG] = 0x10,
252 [OMAP_I2C_CON_REG] = 0xa4, 252 [OMAP_I2C_CON_REG] = 0xa4,
253 [OMAP_I2C_OA_REG] = 0xa8, 253 [OMAP_I2C_OA_REG] = 0xa8,
254 [OMAP_I2C_SA_REG] = 0xac, 254 [OMAP_I2C_SA_REG] = 0xac,
255 [OMAP_I2C_PSC_REG] = 0xb0, 255 [OMAP_I2C_PSC_REG] = 0xb0,
256 [OMAP_I2C_SCLL_REG] = 0xb4, 256 [OMAP_I2C_SCLL_REG] = 0xb4,
257 [OMAP_I2C_SCLH_REG] = 0xb8, 257 [OMAP_I2C_SCLH_REG] = 0xb8,
258 [OMAP_I2C_SYSTEST_REG] = 0xbC, 258 [OMAP_I2C_SYSTEST_REG] = 0xbC,
259 [OMAP_I2C_BUFSTAT_REG] = 0xc0, 259 [OMAP_I2C_BUFSTAT_REG] = 0xc0,
260 [OMAP_I2C_IP_V2_REVNB_LO] = 0x00, 260 [OMAP_I2C_IP_V2_REVNB_LO] = 0x00,
261 [OMAP_I2C_IP_V2_REVNB_HI] = 0x04, 261 [OMAP_I2C_IP_V2_REVNB_HI] = 0x04,
262 [OMAP_I2C_IP_V2_IRQSTATUS_RAW] = 0x24, 262 [OMAP_I2C_IP_V2_IRQSTATUS_RAW] = 0x24,
263 [OMAP_I2C_IP_V2_IRQENABLE_SET] = 0x2c, 263 [OMAP_I2C_IP_V2_IRQENABLE_SET] = 0x2c,
264 [OMAP_I2C_IP_V2_IRQENABLE_CLR] = 0x30, 264 [OMAP_I2C_IP_V2_IRQENABLE_CLR] = 0x30,
265 }; 265 };
266 266
267 static inline void omap_i2c_write_reg(struct omap_i2c_dev *i2c_dev, 267 static inline void omap_i2c_write_reg(struct omap_i2c_dev *i2c_dev,
268 int reg, u16 val) 268 int reg, u16 val)
269 { 269 {
270 __raw_writew(val, i2c_dev->base + 270 __raw_writew(val, i2c_dev->base +
271 (i2c_dev->regs[reg] << i2c_dev->reg_shift)); 271 (i2c_dev->regs[reg] << i2c_dev->reg_shift));
272 } 272 }
273 273
274 static inline u16 omap_i2c_read_reg(struct omap_i2c_dev *i2c_dev, int reg) 274 static inline u16 omap_i2c_read_reg(struct omap_i2c_dev *i2c_dev, int reg)
275 { 275 {
276 return __raw_readw(i2c_dev->base + 276 return __raw_readw(i2c_dev->base +
277 (i2c_dev->regs[reg] << i2c_dev->reg_shift)); 277 (i2c_dev->regs[reg] << i2c_dev->reg_shift));
278 } 278 }
279 279
280 static void __omap_i2c_init(struct omap_i2c_dev *dev) 280 static void __omap_i2c_init(struct omap_i2c_dev *dev)
281 { 281 {
282 282
283 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, 0); 283 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, 0);
284 284
285 /* Setup clock prescaler to obtain approx 12MHz I2C module clock: */ 285 /* Setup clock prescaler to obtain approx 12MHz I2C module clock: */
286 omap_i2c_write_reg(dev, OMAP_I2C_PSC_REG, dev->pscstate); 286 omap_i2c_write_reg(dev, OMAP_I2C_PSC_REG, dev->pscstate);
287 287
288 /* SCL low and high time values */ 288 /* SCL low and high time values */
289 omap_i2c_write_reg(dev, OMAP_I2C_SCLL_REG, dev->scllstate); 289 omap_i2c_write_reg(dev, OMAP_I2C_SCLL_REG, dev->scllstate);
290 omap_i2c_write_reg(dev, OMAP_I2C_SCLH_REG, dev->sclhstate); 290 omap_i2c_write_reg(dev, OMAP_I2C_SCLH_REG, dev->sclhstate);
291 if (dev->rev >= OMAP_I2C_REV_ON_3430_3530) 291 if (dev->rev >= OMAP_I2C_REV_ON_3430_3530)
292 omap_i2c_write_reg(dev, OMAP_I2C_WE_REG, dev->westate); 292 omap_i2c_write_reg(dev, OMAP_I2C_WE_REG, dev->westate);
293 293
294 /* Take the I2C module out of reset: */ 294 /* Take the I2C module out of reset: */
295 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, OMAP_I2C_CON_EN); 295 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, OMAP_I2C_CON_EN);
296 296
297 /* 297 /*
298 * Don't write to this register if the IE state is 0 as it can 298 * Don't write to this register if the IE state is 0 as it can
299 * cause deadlock. 299 * cause deadlock.
300 */ 300 */
301 if (dev->iestate) 301 if (dev->iestate)
302 omap_i2c_write_reg(dev, OMAP_I2C_IE_REG, dev->iestate); 302 omap_i2c_write_reg(dev, OMAP_I2C_IE_REG, dev->iestate);
303 } 303 }
304 304
305 static int omap_i2c_reset(struct omap_i2c_dev *dev) 305 static int omap_i2c_reset(struct omap_i2c_dev *dev)
306 { 306 {
307 unsigned long timeout; 307 unsigned long timeout;
308 u16 sysc; 308 u16 sysc;
309 309
310 if (dev->rev >= OMAP_I2C_OMAP1_REV_2) { 310 if (dev->rev >= OMAP_I2C_OMAP1_REV_2) {
311 sysc = omap_i2c_read_reg(dev, OMAP_I2C_SYSC_REG); 311 sysc = omap_i2c_read_reg(dev, OMAP_I2C_SYSC_REG);
312 312
313 /* Disable I2C controller before soft reset */ 313 /* Disable I2C controller before soft reset */
314 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, 314 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG,
315 omap_i2c_read_reg(dev, OMAP_I2C_CON_REG) & 315 omap_i2c_read_reg(dev, OMAP_I2C_CON_REG) &
316 ~(OMAP_I2C_CON_EN)); 316 ~(OMAP_I2C_CON_EN));
317 317
318 omap_i2c_write_reg(dev, OMAP_I2C_SYSC_REG, SYSC_SOFTRESET_MASK); 318 omap_i2c_write_reg(dev, OMAP_I2C_SYSC_REG, SYSC_SOFTRESET_MASK);
319 /* For some reason we need to set the EN bit before the 319 /* For some reason we need to set the EN bit before the
320 * reset done bit gets set. */ 320 * reset done bit gets set. */
321 timeout = jiffies + OMAP_I2C_TIMEOUT; 321 timeout = jiffies + OMAP_I2C_TIMEOUT;
322 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, OMAP_I2C_CON_EN); 322 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, OMAP_I2C_CON_EN);
323 while (!(omap_i2c_read_reg(dev, OMAP_I2C_SYSS_REG) & 323 while (!(omap_i2c_read_reg(dev, OMAP_I2C_SYSS_REG) &
324 SYSS_RESETDONE_MASK)) { 324 SYSS_RESETDONE_MASK)) {
325 if (time_after(jiffies, timeout)) { 325 if (time_after(jiffies, timeout)) {
326 dev_warn(dev->dev, "timeout waiting " 326 dev_warn(dev->dev, "timeout waiting "
327 "for controller reset\n"); 327 "for controller reset\n");
328 return -ETIMEDOUT; 328 return -ETIMEDOUT;
329 } 329 }
330 msleep(1); 330 msleep(1);
331 } 331 }
332 332
333 /* SYSC register is cleared by the reset; rewrite it */ 333 /* SYSC register is cleared by the reset; rewrite it */
334 omap_i2c_write_reg(dev, OMAP_I2C_SYSC_REG, sysc); 334 omap_i2c_write_reg(dev, OMAP_I2C_SYSC_REG, sysc);
335 335
336 } 336 }
337 return 0; 337 return 0;
338 } 338 }
339 339
340 static int omap_i2c_init(struct omap_i2c_dev *dev) 340 static int omap_i2c_init(struct omap_i2c_dev *dev)
341 { 341 {
342 u16 psc = 0, scll = 0, sclh = 0; 342 u16 psc = 0, scll = 0, sclh = 0;
343 u16 fsscll = 0, fssclh = 0, hsscll = 0, hssclh = 0; 343 u16 fsscll = 0, fssclh = 0, hsscll = 0, hssclh = 0;
344 unsigned long fclk_rate = 12000000; 344 unsigned long fclk_rate = 12000000;
345 unsigned long internal_clk = 0; 345 unsigned long internal_clk = 0;
346 struct clk *fclk; 346 struct clk *fclk;
347 347
348 if (dev->rev >= OMAP_I2C_REV_ON_3430_3530) { 348 if (dev->rev >= OMAP_I2C_REV_ON_3430_3530) {
349 /* 349 /*
350 * Enabling all wakup sources to stop I2C freezing on 350 * Enabling all wakup sources to stop I2C freezing on
351 * WFI instruction. 351 * WFI instruction.
352 * REVISIT: Some wkup sources might not be needed. 352 * REVISIT: Some wkup sources might not be needed.
353 */ 353 */
354 dev->westate = OMAP_I2C_WE_ALL; 354 dev->westate = OMAP_I2C_WE_ALL;
355 } 355 }
356 356
357 if (dev->flags & OMAP_I2C_FLAG_ALWAYS_ARMXOR_CLK) { 357 if (dev->flags & OMAP_I2C_FLAG_ALWAYS_ARMXOR_CLK) {
358 /* 358 /*
359 * The I2C functional clock is the armxor_ck, so there's 359 * The I2C functional clock is the armxor_ck, so there's
360 * no need to get "armxor_ck" separately. Now, if OMAP2420 360 * no need to get "armxor_ck" separately. Now, if OMAP2420
361 * always returns 12MHz for the functional clock, we can 361 * always returns 12MHz for the functional clock, we can
362 * do this bit unconditionally. 362 * do this bit unconditionally.
363 */ 363 */
364 fclk = clk_get(dev->dev, "fck"); 364 fclk = clk_get(dev->dev, "fck");
365 fclk_rate = clk_get_rate(fclk); 365 fclk_rate = clk_get_rate(fclk);
366 clk_put(fclk); 366 clk_put(fclk);
367 367
368 /* TRM for 5912 says the I2C clock must be prescaled to be 368 /* TRM for 5912 says the I2C clock must be prescaled to be
369 * between 7 - 12 MHz. The XOR input clock is typically 369 * between 7 - 12 MHz. The XOR input clock is typically
370 * 12, 13 or 19.2 MHz. So we should have code that produces: 370 * 12, 13 or 19.2 MHz. So we should have code that produces:
371 * 371 *
372 * XOR MHz Divider Prescaler 372 * XOR MHz Divider Prescaler
373 * 12 1 0 373 * 12 1 0
374 * 13 2 1 374 * 13 2 1
375 * 19.2 2 1 375 * 19.2 2 1
376 */ 376 */
377 if (fclk_rate > 12000000) 377 if (fclk_rate > 12000000)
378 psc = fclk_rate / 12000000; 378 psc = fclk_rate / 12000000;
379 } 379 }
380 380
381 if (!(dev->flags & OMAP_I2C_FLAG_SIMPLE_CLOCK)) { 381 if (!(dev->flags & OMAP_I2C_FLAG_SIMPLE_CLOCK)) {
382 382
383 /* 383 /*
384 * HSI2C controller internal clk rate should be 19.2 Mhz for 384 * HSI2C controller internal clk rate should be 19.2 Mhz for
385 * HS and for all modes on 2430. On 34xx we can use lower rate 385 * HS and for all modes on 2430. On 34xx we can use lower rate
386 * to get longer filter period for better noise suppression. 386 * to get longer filter period for better noise suppression.
387 * The filter is iclk (fclk for HS) period. 387 * The filter is iclk (fclk for HS) period.
388 */ 388 */
389 if (dev->speed > 400 || 389 if (dev->speed > 400 ||
390 dev->flags & OMAP_I2C_FLAG_FORCE_19200_INT_CLK) 390 dev->flags & OMAP_I2C_FLAG_FORCE_19200_INT_CLK)
391 internal_clk = 19200; 391 internal_clk = 19200;
392 else if (dev->speed > 100) 392 else if (dev->speed > 100)
393 internal_clk = 9600; 393 internal_clk = 9600;
394 else 394 else
395 internal_clk = 4000; 395 internal_clk = 4000;
396 fclk = clk_get(dev->dev, "fck"); 396 fclk = clk_get(dev->dev, "fck");
397 fclk_rate = clk_get_rate(fclk) / 1000; 397 fclk_rate = clk_get_rate(fclk) / 1000;
398 clk_put(fclk); 398 clk_put(fclk);
399 399
400 /* Compute prescaler divisor */ 400 /* Compute prescaler divisor */
401 psc = fclk_rate / internal_clk; 401 psc = fclk_rate / internal_clk;
402 psc = psc - 1; 402 psc = psc - 1;
403 403
404 /* If configured for High Speed */ 404 /* If configured for High Speed */
405 if (dev->speed > 400) { 405 if (dev->speed > 400) {
406 unsigned long scl; 406 unsigned long scl;
407 407
408 /* For first phase of HS mode */ 408 /* For first phase of HS mode */
409 scl = internal_clk / 400; 409 scl = internal_clk / 400;
410 fsscll = scl - (scl / 3) - 7; 410 fsscll = scl - (scl / 3) - 7;
411 fssclh = (scl / 3) - 5; 411 fssclh = (scl / 3) - 5;
412 412
413 /* For second phase of HS mode */ 413 /* For second phase of HS mode */
414 scl = fclk_rate / dev->speed; 414 scl = fclk_rate / dev->speed;
415 hsscll = scl - (scl / 3) - 7; 415 hsscll = scl - (scl / 3) - 7;
416 hssclh = (scl / 3) - 5; 416 hssclh = (scl / 3) - 5;
417 } else if (dev->speed > 100) { 417 } else if (dev->speed > 100) {
418 unsigned long scl; 418 unsigned long scl;
419 419
420 /* Fast mode */ 420 /* Fast mode */
421 scl = internal_clk / dev->speed; 421 scl = internal_clk / dev->speed;
422 fsscll = scl - (scl / 3) - 7; 422 fsscll = scl - (scl / 3) - 7;
423 fssclh = (scl / 3) - 5; 423 fssclh = (scl / 3) - 5;
424 } else { 424 } else {
425 /* Standard mode */ 425 /* Standard mode */
426 fsscll = internal_clk / (dev->speed * 2) - 7; 426 fsscll = internal_clk / (dev->speed * 2) - 7;
427 fssclh = internal_clk / (dev->speed * 2) - 5; 427 fssclh = internal_clk / (dev->speed * 2) - 5;
428 } 428 }
429 scll = (hsscll << OMAP_I2C_SCLL_HSSCLL) | fsscll; 429 scll = (hsscll << OMAP_I2C_SCLL_HSSCLL) | fsscll;
430 sclh = (hssclh << OMAP_I2C_SCLH_HSSCLH) | fssclh; 430 sclh = (hssclh << OMAP_I2C_SCLH_HSSCLH) | fssclh;
431 } else { 431 } else {
432 /* Program desired operating rate */ 432 /* Program desired operating rate */
433 fclk_rate /= (psc + 1) * 1000; 433 fclk_rate /= (psc + 1) * 1000;
434 if (psc > 2) 434 if (psc > 2)
435 psc = 2; 435 psc = 2;
436 scll = fclk_rate / (dev->speed * 2) - 7 + psc; 436 scll = fclk_rate / (dev->speed * 2) - 7 + psc;
437 sclh = fclk_rate / (dev->speed * 2) - 7 + psc; 437 sclh = fclk_rate / (dev->speed * 2) - 7 + psc;
438 } 438 }
439 439
440 dev->iestate = (OMAP_I2C_IE_XRDY | OMAP_I2C_IE_RRDY | 440 dev->iestate = (OMAP_I2C_IE_XRDY | OMAP_I2C_IE_RRDY |
441 OMAP_I2C_IE_ARDY | OMAP_I2C_IE_NACK | 441 OMAP_I2C_IE_ARDY | OMAP_I2C_IE_NACK |
442 OMAP_I2C_IE_AL) | ((dev->fifo_size) ? 442 OMAP_I2C_IE_AL) | ((dev->fifo_size) ?
443 (OMAP_I2C_IE_RDR | OMAP_I2C_IE_XDR) : 0); 443 (OMAP_I2C_IE_RDR | OMAP_I2C_IE_XDR) : 0);
444 444
445 dev->pscstate = psc; 445 dev->pscstate = psc;
446 dev->scllstate = scll; 446 dev->scllstate = scll;
447 dev->sclhstate = sclh; 447 dev->sclhstate = sclh;
448 448
449 __omap_i2c_init(dev); 449 __omap_i2c_init(dev);
450 450
451 return 0; 451 return 0;
452 } 452 }
453 453
454 /* 454 /*
455 * Waiting on Bus Busy 455 * Waiting on Bus Busy
456 */ 456 */
457 static int omap_i2c_wait_for_bb(struct omap_i2c_dev *dev) 457 static int omap_i2c_wait_for_bb(struct omap_i2c_dev *dev)
458 { 458 {
459 unsigned long timeout; 459 unsigned long timeout;
460 460
461 timeout = jiffies + OMAP_I2C_TIMEOUT; 461 timeout = jiffies + OMAP_I2C_TIMEOUT;
462 while (omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG) & OMAP_I2C_STAT_BB) { 462 while (omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG) & OMAP_I2C_STAT_BB) {
463 if (time_after(jiffies, timeout)) { 463 if (time_after(jiffies, timeout)) {
464 dev_warn(dev->dev, "timeout waiting for bus ready\n"); 464 dev_warn(dev->dev, "timeout waiting for bus ready\n");
465 return -ETIMEDOUT; 465 return -ETIMEDOUT;
466 } 466 }
467 msleep(1); 467 msleep(1);
468 } 468 }
469 469
470 return 0; 470 return 0;
471 } 471 }
472 472
473 static void omap_i2c_resize_fifo(struct omap_i2c_dev *dev, u8 size, bool is_rx) 473 static void omap_i2c_resize_fifo(struct omap_i2c_dev *dev, u8 size, bool is_rx)
474 { 474 {
475 u16 buf; 475 u16 buf;
476 476
477 if (dev->flags & OMAP_I2C_FLAG_NO_FIFO) 477 if (dev->flags & OMAP_I2C_FLAG_NO_FIFO)
478 return; 478 return;
479 479
480 /* 480 /*
481 * Set up notification threshold based on message size. We're doing 481 * Set up notification threshold based on message size. We're doing
482 * this to try and avoid draining feature as much as possible. Whenever 482 * this to try and avoid draining feature as much as possible. Whenever
483 * we have big messages to transfer (bigger than our total fifo size) 483 * we have big messages to transfer (bigger than our total fifo size)
484 * then we might use draining feature to transfer the remaining bytes. 484 * then we might use draining feature to transfer the remaining bytes.
485 */ 485 */
486 486
487 dev->threshold = clamp(size, (u8) 1, dev->fifo_size); 487 dev->threshold = clamp(size, (u8) 1, dev->fifo_size);
488 488
489 buf = omap_i2c_read_reg(dev, OMAP_I2C_BUF_REG); 489 buf = omap_i2c_read_reg(dev, OMAP_I2C_BUF_REG);
490 490
491 if (is_rx) { 491 if (is_rx) {
492 /* Clear RX Threshold */ 492 /* Clear RX Threshold */
493 buf &= ~(0x3f << 8); 493 buf &= ~(0x3f << 8);
494 buf |= ((dev->threshold - 1) << 8) | OMAP_I2C_BUF_RXFIF_CLR; 494 buf |= ((dev->threshold - 1) << 8) | OMAP_I2C_BUF_RXFIF_CLR;
495 } else { 495 } else {
496 /* Clear TX Threshold */ 496 /* Clear TX Threshold */
497 buf &= ~0x3f; 497 buf &= ~0x3f;
498 buf |= (dev->threshold - 1) | OMAP_I2C_BUF_TXFIF_CLR; 498 buf |= (dev->threshold - 1) | OMAP_I2C_BUF_TXFIF_CLR;
499 } 499 }
500 500
501 omap_i2c_write_reg(dev, OMAP_I2C_BUF_REG, buf); 501 omap_i2c_write_reg(dev, OMAP_I2C_BUF_REG, buf);
502 502
503 if (dev->rev < OMAP_I2C_REV_ON_3630) 503 if (dev->rev < OMAP_I2C_REV_ON_3630)
504 dev->b_hw = 1; /* Enable hardware fixes */ 504 dev->b_hw = 1; /* Enable hardware fixes */
505 505
506 /* calculate wakeup latency constraint for MPU */ 506 /* calculate wakeup latency constraint for MPU */
507 if (dev->set_mpu_wkup_lat != NULL) 507 if (dev->set_mpu_wkup_lat != NULL)
508 dev->latency = (1000000 * dev->threshold) / 508 dev->latency = (1000000 * dev->threshold) /
509 (1000 * dev->speed / 8); 509 (1000 * dev->speed / 8);
510 } 510 }
511 511
512 /* 512 /*
513 * Low level master read/write transaction. 513 * Low level master read/write transaction.
514 */ 514 */
515 static int omap_i2c_xfer_msg(struct i2c_adapter *adap, 515 static int omap_i2c_xfer_msg(struct i2c_adapter *adap,
516 struct i2c_msg *msg, int stop) 516 struct i2c_msg *msg, int stop)
517 { 517 {
518 struct omap_i2c_dev *dev = i2c_get_adapdata(adap); 518 struct omap_i2c_dev *dev = i2c_get_adapdata(adap);
519 unsigned long timeout; 519 unsigned long timeout;
520 u16 w; 520 u16 w;
521 521
522 dev_dbg(dev->dev, "addr: 0x%04x, len: %d, flags: 0x%x, stop: %d\n", 522 dev_dbg(dev->dev, "addr: 0x%04x, len: %d, flags: 0x%x, stop: %d\n",
523 msg->addr, msg->len, msg->flags, stop); 523 msg->addr, msg->len, msg->flags, stop);
524 524
525 if (msg->len == 0) 525 if (msg->len == 0)
526 return -EINVAL; 526 return -EINVAL;
527 527
528 dev->receiver = !!(msg->flags & I2C_M_RD); 528 dev->receiver = !!(msg->flags & I2C_M_RD);
529 omap_i2c_resize_fifo(dev, msg->len, dev->receiver); 529 omap_i2c_resize_fifo(dev, msg->len, dev->receiver);
530 530
531 omap_i2c_write_reg(dev, OMAP_I2C_SA_REG, msg->addr); 531 omap_i2c_write_reg(dev, OMAP_I2C_SA_REG, msg->addr);
532 532
533 /* REVISIT: Could the STB bit of I2C_CON be used with probing? */ 533 /* REVISIT: Could the STB bit of I2C_CON be used with probing? */
534 dev->buf = msg->buf; 534 dev->buf = msg->buf;
535 dev->buf_len = msg->len; 535 dev->buf_len = msg->len;
536 536
537 /* make sure writes to dev->buf_len are ordered */ 537 /* make sure writes to dev->buf_len are ordered */
538 barrier(); 538 barrier();
539 539
540 omap_i2c_write_reg(dev, OMAP_I2C_CNT_REG, dev->buf_len); 540 omap_i2c_write_reg(dev, OMAP_I2C_CNT_REG, dev->buf_len);
541 541
542 /* Clear the FIFO Buffers */ 542 /* Clear the FIFO Buffers */
543 w = omap_i2c_read_reg(dev, OMAP_I2C_BUF_REG); 543 w = omap_i2c_read_reg(dev, OMAP_I2C_BUF_REG);
544 w |= OMAP_I2C_BUF_RXFIF_CLR | OMAP_I2C_BUF_TXFIF_CLR; 544 w |= OMAP_I2C_BUF_RXFIF_CLR | OMAP_I2C_BUF_TXFIF_CLR;
545 omap_i2c_write_reg(dev, OMAP_I2C_BUF_REG, w); 545 omap_i2c_write_reg(dev, OMAP_I2C_BUF_REG, w);
546 546
547 INIT_COMPLETION(dev->cmd_complete); 547 INIT_COMPLETION(dev->cmd_complete);
548 dev->cmd_err = 0; 548 dev->cmd_err = 0;
549 549
550 w = OMAP_I2C_CON_EN | OMAP_I2C_CON_MST | OMAP_I2C_CON_STT; 550 w = OMAP_I2C_CON_EN | OMAP_I2C_CON_MST | OMAP_I2C_CON_STT;
551 551
552 /* High speed configuration */ 552 /* High speed configuration */
553 if (dev->speed > 400) 553 if (dev->speed > 400)
554 w |= OMAP_I2C_CON_OPMODE_HS; 554 w |= OMAP_I2C_CON_OPMODE_HS;
555 555
556 if (msg->flags & I2C_M_STOP) 556 if (msg->flags & I2C_M_STOP)
557 stop = 1; 557 stop = 1;
558 if (msg->flags & I2C_M_TEN) 558 if (msg->flags & I2C_M_TEN)
559 w |= OMAP_I2C_CON_XA; 559 w |= OMAP_I2C_CON_XA;
560 if (!(msg->flags & I2C_M_RD)) 560 if (!(msg->flags & I2C_M_RD))
561 w |= OMAP_I2C_CON_TRX; 561 w |= OMAP_I2C_CON_TRX;
562 562
563 if (!dev->b_hw && stop) 563 if (!dev->b_hw && stop)
564 w |= OMAP_I2C_CON_STP; 564 w |= OMAP_I2C_CON_STP;
565 565
566 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, w); 566 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, w);
567 567
568 /* 568 /*
569 * Don't write stt and stp together on some hardware. 569 * Don't write stt and stp together on some hardware.
570 */ 570 */
571 if (dev->b_hw && stop) { 571 if (dev->b_hw && stop) {
572 unsigned long delay = jiffies + OMAP_I2C_TIMEOUT; 572 unsigned long delay = jiffies + OMAP_I2C_TIMEOUT;
573 u16 con = omap_i2c_read_reg(dev, OMAP_I2C_CON_REG); 573 u16 con = omap_i2c_read_reg(dev, OMAP_I2C_CON_REG);
574 while (con & OMAP_I2C_CON_STT) { 574 while (con & OMAP_I2C_CON_STT) {
575 con = omap_i2c_read_reg(dev, OMAP_I2C_CON_REG); 575 con = omap_i2c_read_reg(dev, OMAP_I2C_CON_REG);
576 576
577 /* Let the user know if i2c is in a bad state */ 577 /* Let the user know if i2c is in a bad state */
578 if (time_after(jiffies, delay)) { 578 if (time_after(jiffies, delay)) {
579 dev_err(dev->dev, "controller timed out " 579 dev_err(dev->dev, "controller timed out "
580 "waiting for start condition to finish\n"); 580 "waiting for start condition to finish\n");
581 return -ETIMEDOUT; 581 return -ETIMEDOUT;
582 } 582 }
583 cpu_relax(); 583 cpu_relax();
584 } 584 }
585 585
586 w |= OMAP_I2C_CON_STP; 586 w |= OMAP_I2C_CON_STP;
587 w &= ~OMAP_I2C_CON_STT; 587 w &= ~OMAP_I2C_CON_STT;
588 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, w); 588 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, w);
589 } 589 }
590 590
591 /* 591 /*
592 * REVISIT: We should abort the transfer on signals, but the bus goes 592 * REVISIT: We should abort the transfer on signals, but the bus goes
593 * into arbitration and we're currently unable to recover from it. 593 * into arbitration and we're currently unable to recover from it.
594 */ 594 */
595 timeout = wait_for_completion_timeout(&dev->cmd_complete, 595 timeout = wait_for_completion_timeout(&dev->cmd_complete,
596 OMAP_I2C_TIMEOUT); 596 OMAP_I2C_TIMEOUT);
597 if (timeout == 0) { 597 if (timeout == 0) {
598 dev_err(dev->dev, "controller timed out\n"); 598 dev_err(dev->dev, "controller timed out\n");
599 omap_i2c_reset(dev); 599 omap_i2c_reset(dev);
600 __omap_i2c_init(dev); 600 __omap_i2c_init(dev);
601 return -ETIMEDOUT; 601 return -ETIMEDOUT;
602 } 602 }
603 603
604 if (likely(!dev->cmd_err)) 604 if (likely(!dev->cmd_err))
605 return 0; 605 return 0;
606 606
607 /* We have an error */ 607 /* We have an error */
608 if (dev->cmd_err & (OMAP_I2C_STAT_AL | OMAP_I2C_STAT_ROVR | 608 if (dev->cmd_err & (OMAP_I2C_STAT_AL | OMAP_I2C_STAT_ROVR |
609 OMAP_I2C_STAT_XUDF)) { 609 OMAP_I2C_STAT_XUDF)) {
610 omap_i2c_reset(dev); 610 omap_i2c_reset(dev);
611 __omap_i2c_init(dev); 611 __omap_i2c_init(dev);
612 return -EIO; 612 return -EIO;
613 } 613 }
614 614
615 if (dev->cmd_err & OMAP_I2C_STAT_NACK) { 615 if (dev->cmd_err & OMAP_I2C_STAT_NACK) {
616 if (msg->flags & I2C_M_IGNORE_NAK) 616 if (msg->flags & I2C_M_IGNORE_NAK)
617 return 0; 617 return 0;
618 if (stop) { 618 if (stop) {
619 w = omap_i2c_read_reg(dev, OMAP_I2C_CON_REG); 619 w = omap_i2c_read_reg(dev, OMAP_I2C_CON_REG);
620 w |= OMAP_I2C_CON_STP; 620 w |= OMAP_I2C_CON_STP;
621 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, w); 621 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, w);
622 } 622 }
623 return -EREMOTEIO; 623 return -EREMOTEIO;
624 } 624 }
625 return -EIO; 625 return -EIO;
626 } 626 }
627 627
628 628
629 /* 629 /*
630 * Prepare controller for a transaction and call omap_i2c_xfer_msg 630 * Prepare controller for a transaction and call omap_i2c_xfer_msg
631 * to do the work during IRQ processing. 631 * to do the work during IRQ processing.
632 */ 632 */
633 static int 633 static int
634 omap_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msgs[], int num) 634 omap_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msgs[], int num)
635 { 635 {
636 struct omap_i2c_dev *dev = i2c_get_adapdata(adap); 636 struct omap_i2c_dev *dev = i2c_get_adapdata(adap);
637 int i; 637 int i;
638 int r; 638 int r;
639 639
640 r = pm_runtime_get_sync(dev->dev); 640 r = pm_runtime_get_sync(dev->dev);
641 if (IS_ERR_VALUE(r)) 641 if (IS_ERR_VALUE(r))
642 goto out; 642 goto out;
643 643
644 r = omap_i2c_wait_for_bb(dev); 644 r = omap_i2c_wait_for_bb(dev);
645 if (r < 0) 645 if (r < 0)
646 goto out; 646 goto out;
647 647
648 if (dev->set_mpu_wkup_lat != NULL) 648 if (dev->set_mpu_wkup_lat != NULL)
649 dev->set_mpu_wkup_lat(dev->dev, dev->latency); 649 dev->set_mpu_wkup_lat(dev->dev, dev->latency);
650 650
651 for (i = 0; i < num; i++) { 651 for (i = 0; i < num; i++) {
652 r = omap_i2c_xfer_msg(adap, &msgs[i], (i == (num - 1))); 652 r = omap_i2c_xfer_msg(adap, &msgs[i], (i == (num - 1)));
653 if (r != 0) 653 if (r != 0)
654 break; 654 break;
655 } 655 }
656 656
657 if (r == 0) 657 if (r == 0)
658 r = num; 658 r = num;
659 659
660 omap_i2c_wait_for_bb(dev); 660 omap_i2c_wait_for_bb(dev);
661 661
662 if (dev->set_mpu_wkup_lat != NULL) 662 if (dev->set_mpu_wkup_lat != NULL)
663 dev->set_mpu_wkup_lat(dev->dev, -1); 663 dev->set_mpu_wkup_lat(dev->dev, -1);
664 664
665 out: 665 out:
666 pm_runtime_mark_last_busy(dev->dev); 666 pm_runtime_mark_last_busy(dev->dev);
667 pm_runtime_put_autosuspend(dev->dev); 667 pm_runtime_put_autosuspend(dev->dev);
668 return r; 668 return r;
669 } 669 }
670 670
671 static u32 671 static u32
672 omap_i2c_func(struct i2c_adapter *adap) 672 omap_i2c_func(struct i2c_adapter *adap)
673 { 673 {
674 return I2C_FUNC_I2C | (I2C_FUNC_SMBUS_EMUL & ~I2C_FUNC_SMBUS_QUICK) | 674 return I2C_FUNC_I2C | (I2C_FUNC_SMBUS_EMUL & ~I2C_FUNC_SMBUS_QUICK) |
675 I2C_FUNC_PROTOCOL_MANGLING; 675 I2C_FUNC_PROTOCOL_MANGLING;
676 } 676 }
677 677
678 static inline void 678 static inline void
679 omap_i2c_complete_cmd(struct omap_i2c_dev *dev, u16 err) 679 omap_i2c_complete_cmd(struct omap_i2c_dev *dev, u16 err)
680 { 680 {
681 dev->cmd_err |= err; 681 dev->cmd_err |= err;
682 complete(&dev->cmd_complete); 682 complete(&dev->cmd_complete);
683 } 683 }
684 684
685 static inline void 685 static inline void
686 omap_i2c_ack_stat(struct omap_i2c_dev *dev, u16 stat) 686 omap_i2c_ack_stat(struct omap_i2c_dev *dev, u16 stat)
687 { 687 {
688 omap_i2c_write_reg(dev, OMAP_I2C_STAT_REG, stat); 688 omap_i2c_write_reg(dev, OMAP_I2C_STAT_REG, stat);
689 } 689 }
690 690
691 static inline void i2c_omap_errata_i207(struct omap_i2c_dev *dev, u16 stat) 691 static inline void i2c_omap_errata_i207(struct omap_i2c_dev *dev, u16 stat)
692 { 692 {
693 /* 693 /*
694 * I2C Errata(Errata Nos. OMAP2: 1.67, OMAP3: 1.8) 694 * I2C Errata(Errata Nos. OMAP2: 1.67, OMAP3: 1.8)
695 * Not applicable for OMAP4. 695 * Not applicable for OMAP4.
696 * Under certain rare conditions, RDR could be set again 696 * Under certain rare conditions, RDR could be set again
697 * when the bus is busy, then ignore the interrupt and 697 * when the bus is busy, then ignore the interrupt and
698 * clear the interrupt. 698 * clear the interrupt.
699 */ 699 */
700 if (stat & OMAP_I2C_STAT_RDR) { 700 if (stat & OMAP_I2C_STAT_RDR) {
701 /* Step 1: If RDR is set, clear it */ 701 /* Step 1: If RDR is set, clear it */
702 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_RDR); 702 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_RDR);
703 703
704 /* Step 2: */ 704 /* Step 2: */
705 if (!(omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG) 705 if (!(omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG)
706 & OMAP_I2C_STAT_BB)) { 706 & OMAP_I2C_STAT_BB)) {
707 707
708 /* Step 3: */ 708 /* Step 3: */
709 if (omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG) 709 if (omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG)
710 & OMAP_I2C_STAT_RDR) { 710 & OMAP_I2C_STAT_RDR) {
711 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_RDR); 711 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_RDR);
712 dev_dbg(dev->dev, "RDR when bus is busy.\n"); 712 dev_dbg(dev->dev, "RDR when bus is busy.\n");
713 } 713 }
714 714
715 } 715 }
716 } 716 }
717 } 717 }
718 718
719 /* rev1 devices are apparently only on some 15xx */ 719 /* rev1 devices are apparently only on some 15xx */
720 #ifdef CONFIG_ARCH_OMAP15XX 720 #ifdef CONFIG_ARCH_OMAP15XX
721 721
722 static irqreturn_t 722 static irqreturn_t
723 omap_i2c_omap1_isr(int this_irq, void *dev_id) 723 omap_i2c_omap1_isr(int this_irq, void *dev_id)
724 { 724 {
725 struct omap_i2c_dev *dev = dev_id; 725 struct omap_i2c_dev *dev = dev_id;
726 u16 iv, w; 726 u16 iv, w;
727 727
728 if (pm_runtime_suspended(dev->dev)) 728 if (pm_runtime_suspended(dev->dev))
729 return IRQ_NONE; 729 return IRQ_NONE;
730 730
731 iv = omap_i2c_read_reg(dev, OMAP_I2C_IV_REG); 731 iv = omap_i2c_read_reg(dev, OMAP_I2C_IV_REG);
732 switch (iv) { 732 switch (iv) {
733 case 0x00: /* None */ 733 case 0x00: /* None */
734 break; 734 break;
735 case 0x01: /* Arbitration lost */ 735 case 0x01: /* Arbitration lost */
736 dev_err(dev->dev, "Arbitration lost\n"); 736 dev_err(dev->dev, "Arbitration lost\n");
737 omap_i2c_complete_cmd(dev, OMAP_I2C_STAT_AL); 737 omap_i2c_complete_cmd(dev, OMAP_I2C_STAT_AL);
738 break; 738 break;
739 case 0x02: /* No acknowledgement */ 739 case 0x02: /* No acknowledgement */
740 omap_i2c_complete_cmd(dev, OMAP_I2C_STAT_NACK); 740 omap_i2c_complete_cmd(dev, OMAP_I2C_STAT_NACK);
741 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, OMAP_I2C_CON_STP); 741 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, OMAP_I2C_CON_STP);
742 break; 742 break;
743 case 0x03: /* Register access ready */ 743 case 0x03: /* Register access ready */
744 omap_i2c_complete_cmd(dev, 0); 744 omap_i2c_complete_cmd(dev, 0);
745 break; 745 break;
746 case 0x04: /* Receive data ready */ 746 case 0x04: /* Receive data ready */
747 if (dev->buf_len) { 747 if (dev->buf_len) {
748 w = omap_i2c_read_reg(dev, OMAP_I2C_DATA_REG); 748 w = omap_i2c_read_reg(dev, OMAP_I2C_DATA_REG);
749 *dev->buf++ = w; 749 *dev->buf++ = w;
750 dev->buf_len--; 750 dev->buf_len--;
751 if (dev->buf_len) { 751 if (dev->buf_len) {
752 *dev->buf++ = w >> 8; 752 *dev->buf++ = w >> 8;
753 dev->buf_len--; 753 dev->buf_len--;
754 } 754 }
755 } else 755 } else
756 dev_err(dev->dev, "RRDY IRQ while no data requested\n"); 756 dev_err(dev->dev, "RRDY IRQ while no data requested\n");
757 break; 757 break;
758 case 0x05: /* Transmit data ready */ 758 case 0x05: /* Transmit data ready */
759 if (dev->buf_len) { 759 if (dev->buf_len) {
760 w = *dev->buf++; 760 w = *dev->buf++;
761 dev->buf_len--; 761 dev->buf_len--;
762 if (dev->buf_len) { 762 if (dev->buf_len) {
763 w |= *dev->buf++ << 8; 763 w |= *dev->buf++ << 8;
764 dev->buf_len--; 764 dev->buf_len--;
765 } 765 }
766 omap_i2c_write_reg(dev, OMAP_I2C_DATA_REG, w); 766 omap_i2c_write_reg(dev, OMAP_I2C_DATA_REG, w);
767 } else 767 } else
768 dev_err(dev->dev, "XRDY IRQ while no data to send\n"); 768 dev_err(dev->dev, "XRDY IRQ while no data to send\n");
769 break; 769 break;
770 default: 770 default:
771 return IRQ_NONE; 771 return IRQ_NONE;
772 } 772 }
773 773
774 return IRQ_HANDLED; 774 return IRQ_HANDLED;
775 } 775 }
776 #else 776 #else
777 #define omap_i2c_omap1_isr NULL 777 #define omap_i2c_omap1_isr NULL
778 #endif 778 #endif
779 779
780 /* 780 /*
781 * OMAP3430 Errata i462: When an XRDY/XDR is hit, wait for XUDF before writing 781 * OMAP3430 Errata i462: When an XRDY/XDR is hit, wait for XUDF before writing
782 * data to DATA_REG. Otherwise some data bytes can be lost while transferring 782 * data to DATA_REG. Otherwise some data bytes can be lost while transferring
783 * them from the memory to the I2C interface. 783 * them from the memory to the I2C interface.
784 */ 784 */
785 static int errata_omap3_i462(struct omap_i2c_dev *dev) 785 static int errata_omap3_i462(struct omap_i2c_dev *dev)
786 { 786 {
787 unsigned long timeout = 10000; 787 unsigned long timeout = 10000;
788 u16 stat; 788 u16 stat;
789 789
790 do { 790 do {
791 stat = omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG); 791 stat = omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG);
792 if (stat & OMAP_I2C_STAT_XUDF) 792 if (stat & OMAP_I2C_STAT_XUDF)
793 break; 793 break;
794 794
795 if (stat & (OMAP_I2C_STAT_NACK | OMAP_I2C_STAT_AL)) { 795 if (stat & (OMAP_I2C_STAT_NACK | OMAP_I2C_STAT_AL)) {
796 omap_i2c_ack_stat(dev, (OMAP_I2C_STAT_XRDY | 796 omap_i2c_ack_stat(dev, (OMAP_I2C_STAT_XRDY |
797 OMAP_I2C_STAT_XDR)); 797 OMAP_I2C_STAT_XDR));
798 if (stat & OMAP_I2C_STAT_NACK) { 798 if (stat & OMAP_I2C_STAT_NACK) {
799 dev->cmd_err |= OMAP_I2C_STAT_NACK; 799 dev->cmd_err |= OMAP_I2C_STAT_NACK;
800 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_NACK); 800 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_NACK);
801 } 801 }
802 802
803 if (stat & OMAP_I2C_STAT_AL) { 803 if (stat & OMAP_I2C_STAT_AL) {
804 dev_err(dev->dev, "Arbitration lost\n"); 804 dev_err(dev->dev, "Arbitration lost\n");
805 dev->cmd_err |= OMAP_I2C_STAT_AL; 805 dev->cmd_err |= OMAP_I2C_STAT_AL;
806 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_NACK); 806 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_NACK);
807 } 807 }
808 808
809 return -EIO; 809 return -EIO;
810 } 810 }
811 811
812 cpu_relax(); 812 cpu_relax();
813 } while (--timeout); 813 } while (--timeout);
814 814
815 if (!timeout) { 815 if (!timeout) {
816 dev_err(dev->dev, "timeout waiting on XUDF bit\n"); 816 dev_err(dev->dev, "timeout waiting on XUDF bit\n");
817 return 0; 817 return 0;
818 } 818 }
819 819
820 return 0; 820 return 0;
821 } 821 }
822 822
823 static void omap_i2c_receive_data(struct omap_i2c_dev *dev, u8 num_bytes, 823 static void omap_i2c_receive_data(struct omap_i2c_dev *dev, u8 num_bytes,
824 bool is_rdr) 824 bool is_rdr)
825 { 825 {
826 u16 w; 826 u16 w;
827 827
828 while (num_bytes--) { 828 while (num_bytes--) {
829 w = omap_i2c_read_reg(dev, OMAP_I2C_DATA_REG); 829 w = omap_i2c_read_reg(dev, OMAP_I2C_DATA_REG);
830 *dev->buf++ = w; 830 *dev->buf++ = w;
831 dev->buf_len--; 831 dev->buf_len--;
832 832
833 /* 833 /*
834 * Data reg in 2430, omap3 and 834 * Data reg in 2430, omap3 and
835 * omap4 is 8 bit wide 835 * omap4 is 8 bit wide
836 */ 836 */
837 if (dev->flags & OMAP_I2C_FLAG_16BIT_DATA_REG) { 837 if (dev->flags & OMAP_I2C_FLAG_16BIT_DATA_REG) {
838 *dev->buf++ = w >> 8; 838 *dev->buf++ = w >> 8;
839 dev->buf_len--; 839 dev->buf_len--;
840 } 840 }
841 } 841 }
842 } 842 }
843 843
844 static int omap_i2c_transmit_data(struct omap_i2c_dev *dev, u8 num_bytes, 844 static int omap_i2c_transmit_data(struct omap_i2c_dev *dev, u8 num_bytes,
845 bool is_xdr) 845 bool is_xdr)
846 { 846 {
847 u16 w; 847 u16 w;
848 848
849 while (num_bytes--) { 849 while (num_bytes--) {
850 w = *dev->buf++; 850 w = *dev->buf++;
851 dev->buf_len--; 851 dev->buf_len--;
852 852
853 /* 853 /*
854 * Data reg in 2430, omap3 and 854 * Data reg in 2430, omap3 and
855 * omap4 is 8 bit wide 855 * omap4 is 8 bit wide
856 */ 856 */
857 if (dev->flags & OMAP_I2C_FLAG_16BIT_DATA_REG) { 857 if (dev->flags & OMAP_I2C_FLAG_16BIT_DATA_REG) {
858 w |= *dev->buf++ << 8; 858 w |= *dev->buf++ << 8;
859 dev->buf_len--; 859 dev->buf_len--;
860 } 860 }
861 861
862 if (dev->errata & I2C_OMAP_ERRATA_I462) { 862 if (dev->errata & I2C_OMAP_ERRATA_I462) {
863 int ret; 863 int ret;
864 864
865 ret = errata_omap3_i462(dev); 865 ret = errata_omap3_i462(dev);
866 if (ret < 0) 866 if (ret < 0)
867 return ret; 867 return ret;
868 } 868 }
869 869
870 omap_i2c_write_reg(dev, OMAP_I2C_DATA_REG, w); 870 omap_i2c_write_reg(dev, OMAP_I2C_DATA_REG, w);
871 } 871 }
872 872
873 return 0; 873 return 0;
874 } 874 }
875 875
876 static irqreturn_t 876 static irqreturn_t
877 omap_i2c_isr(int irq, void *dev_id) 877 omap_i2c_isr(int irq, void *dev_id)
878 { 878 {
879 struct omap_i2c_dev *dev = dev_id; 879 struct omap_i2c_dev *dev = dev_id;
880 irqreturn_t ret = IRQ_HANDLED; 880 irqreturn_t ret = IRQ_HANDLED;
881 u16 mask; 881 u16 mask;
882 u16 stat; 882 u16 stat;
883 883
884 spin_lock(&dev->lock); 884 spin_lock(&dev->lock);
885 mask = omap_i2c_read_reg(dev, OMAP_I2C_IE_REG); 885 mask = omap_i2c_read_reg(dev, OMAP_I2C_IE_REG);
886 stat = omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG); 886 stat = omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG);
887 887
888 if (stat & mask) 888 if (stat & mask)
889 ret = IRQ_WAKE_THREAD; 889 ret = IRQ_WAKE_THREAD;
890 890
891 spin_unlock(&dev->lock); 891 spin_unlock(&dev->lock);
892 892
893 return ret; 893 return ret;
894 } 894 }
895 895
896 static irqreturn_t 896 static irqreturn_t
897 omap_i2c_isr_thread(int this_irq, void *dev_id) 897 omap_i2c_isr_thread(int this_irq, void *dev_id)
898 { 898 {
899 struct omap_i2c_dev *dev = dev_id; 899 struct omap_i2c_dev *dev = dev_id;
900 unsigned long flags; 900 unsigned long flags;
901 u16 bits; 901 u16 bits;
902 u16 stat; 902 u16 stat;
903 int err = 0, count = 0; 903 int err = 0, count = 0;
904 904
905 spin_lock_irqsave(&dev->lock, flags); 905 spin_lock_irqsave(&dev->lock, flags);
906 do { 906 do {
907 bits = omap_i2c_read_reg(dev, OMAP_I2C_IE_REG); 907 bits = omap_i2c_read_reg(dev, OMAP_I2C_IE_REG);
908 stat = omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG); 908 stat = omap_i2c_read_reg(dev, OMAP_I2C_STAT_REG);
909 stat &= bits; 909 stat &= bits;
910 910
911 /* If we're in receiver mode, ignore XDR/XRDY */ 911 /* If we're in receiver mode, ignore XDR/XRDY */
912 if (dev->receiver) 912 if (dev->receiver)
913 stat &= ~(OMAP_I2C_STAT_XDR | OMAP_I2C_STAT_XRDY); 913 stat &= ~(OMAP_I2C_STAT_XDR | OMAP_I2C_STAT_XRDY);
914 else 914 else
915 stat &= ~(OMAP_I2C_STAT_RDR | OMAP_I2C_STAT_RRDY); 915 stat &= ~(OMAP_I2C_STAT_RDR | OMAP_I2C_STAT_RRDY);
916 916
917 if (!stat) { 917 if (!stat) {
918 /* my work here is done */ 918 /* my work here is done */
919 goto out; 919 goto out;
920 } 920 }
921 921
922 dev_dbg(dev->dev, "IRQ (ISR = 0x%04x)\n", stat); 922 dev_dbg(dev->dev, "IRQ (ISR = 0x%04x)\n", stat);
923 if (count++ == 100) { 923 if (count++ == 100) {
924 dev_warn(dev->dev, "Too much work in one IRQ\n"); 924 dev_warn(dev->dev, "Too much work in one IRQ\n");
925 break; 925 break;
926 } 926 }
927 927
928 if (stat & OMAP_I2C_STAT_NACK) { 928 if (stat & OMAP_I2C_STAT_NACK) {
929 err |= OMAP_I2C_STAT_NACK; 929 err |= OMAP_I2C_STAT_NACK;
930 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_NACK); 930 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_NACK);
931 break; 931 break;
932 } 932 }
933 933
934 if (stat & OMAP_I2C_STAT_AL) { 934 if (stat & OMAP_I2C_STAT_AL) {
935 dev_err(dev->dev, "Arbitration lost\n"); 935 dev_err(dev->dev, "Arbitration lost\n");
936 err |= OMAP_I2C_STAT_AL; 936 err |= OMAP_I2C_STAT_AL;
937 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_AL); 937 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_AL);
938 break; 938 break;
939 } 939 }
940 940
941 /* 941 /*
942 * ProDB0017052: Clear ARDY bit twice 942 * ProDB0017052: Clear ARDY bit twice
943 */ 943 */
944 if (stat & (OMAP_I2C_STAT_ARDY | OMAP_I2C_STAT_NACK | 944 if (stat & (OMAP_I2C_STAT_ARDY | OMAP_I2C_STAT_NACK |
945 OMAP_I2C_STAT_AL)) { 945 OMAP_I2C_STAT_AL)) {
946 omap_i2c_ack_stat(dev, (OMAP_I2C_STAT_RRDY | 946 omap_i2c_ack_stat(dev, (OMAP_I2C_STAT_RRDY |
947 OMAP_I2C_STAT_RDR | 947 OMAP_I2C_STAT_RDR |
948 OMAP_I2C_STAT_XRDY | 948 OMAP_I2C_STAT_XRDY |
949 OMAP_I2C_STAT_XDR | 949 OMAP_I2C_STAT_XDR |
950 OMAP_I2C_STAT_ARDY)); 950 OMAP_I2C_STAT_ARDY));
951 break; 951 break;
952 } 952 }
953 953
954 if (stat & OMAP_I2C_STAT_RDR) { 954 if (stat & OMAP_I2C_STAT_RDR) {
955 u8 num_bytes = 1; 955 u8 num_bytes = 1;
956 956
957 if (dev->fifo_size) 957 if (dev->fifo_size)
958 num_bytes = dev->buf_len; 958 num_bytes = dev->buf_len;
959 959
960 omap_i2c_receive_data(dev, num_bytes, true); 960 omap_i2c_receive_data(dev, num_bytes, true);
961 961
962 if (dev->errata & I2C_OMAP_ERRATA_I207) 962 if (dev->errata & I2C_OMAP_ERRATA_I207)
963 i2c_omap_errata_i207(dev, stat); 963 i2c_omap_errata_i207(dev, stat);
964 964
965 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_RDR); 965 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_RDR);
966 break; 966 break;
967 } 967 }
968 968
969 if (stat & OMAP_I2C_STAT_RRDY) { 969 if (stat & OMAP_I2C_STAT_RRDY) {
970 u8 num_bytes = 1; 970 u8 num_bytes = 1;
971 971
972 if (dev->threshold) 972 if (dev->threshold)
973 num_bytes = dev->threshold; 973 num_bytes = dev->threshold;
974 974
975 omap_i2c_receive_data(dev, num_bytes, false); 975 omap_i2c_receive_data(dev, num_bytes, false);
976 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_RRDY); 976 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_RRDY);
977 continue; 977 continue;
978 } 978 }
979 979
980 if (stat & OMAP_I2C_STAT_XDR) { 980 if (stat & OMAP_I2C_STAT_XDR) {
981 u8 num_bytes = 1; 981 u8 num_bytes = 1;
982 int ret; 982 int ret;
983 983
984 if (dev->fifo_size) 984 if (dev->fifo_size)
985 num_bytes = dev->buf_len; 985 num_bytes = dev->buf_len;
986 986
987 ret = omap_i2c_transmit_data(dev, num_bytes, true); 987 ret = omap_i2c_transmit_data(dev, num_bytes, true);
988 if (ret < 0) 988 if (ret < 0)
989 break; 989 break;
990 990
991 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_XDR); 991 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_XDR);
992 break; 992 break;
993 } 993 }
994 994
995 if (stat & OMAP_I2C_STAT_XRDY) { 995 if (stat & OMAP_I2C_STAT_XRDY) {
996 u8 num_bytes = 1; 996 u8 num_bytes = 1;
997 int ret; 997 int ret;
998 998
999 if (dev->threshold) 999 if (dev->threshold)
1000 num_bytes = dev->threshold; 1000 num_bytes = dev->threshold;
1001 1001
1002 ret = omap_i2c_transmit_data(dev, num_bytes, false); 1002 ret = omap_i2c_transmit_data(dev, num_bytes, false);
1003 if (ret < 0) 1003 if (ret < 0)
1004 break; 1004 break;
1005 1005
1006 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_XRDY); 1006 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_XRDY);
1007 continue; 1007 continue;
1008 } 1008 }
1009 1009
1010 if (stat & OMAP_I2C_STAT_ROVR) { 1010 if (stat & OMAP_I2C_STAT_ROVR) {
1011 dev_err(dev->dev, "Receive overrun\n"); 1011 dev_err(dev->dev, "Receive overrun\n");
1012 err |= OMAP_I2C_STAT_ROVR; 1012 err |= OMAP_I2C_STAT_ROVR;
1013 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_ROVR); 1013 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_ROVR);
1014 break; 1014 break;
1015 } 1015 }
1016 1016
1017 if (stat & OMAP_I2C_STAT_XUDF) { 1017 if (stat & OMAP_I2C_STAT_XUDF) {
1018 dev_err(dev->dev, "Transmit underflow\n"); 1018 dev_err(dev->dev, "Transmit underflow\n");
1019 err |= OMAP_I2C_STAT_XUDF; 1019 err |= OMAP_I2C_STAT_XUDF;
1020 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_XUDF); 1020 omap_i2c_ack_stat(dev, OMAP_I2C_STAT_XUDF);
1021 break; 1021 break;
1022 } 1022 }
1023 } while (stat); 1023 } while (stat);
1024 1024
1025 omap_i2c_complete_cmd(dev, err); 1025 omap_i2c_complete_cmd(dev, err);
1026 1026
1027 out: 1027 out:
1028 spin_unlock_irqrestore(&dev->lock, flags); 1028 spin_unlock_irqrestore(&dev->lock, flags);
1029 1029
1030 return IRQ_HANDLED; 1030 return IRQ_HANDLED;
1031 } 1031 }
1032 1032
1033 static const struct i2c_algorithm omap_i2c_algo = { 1033 static const struct i2c_algorithm omap_i2c_algo = {
1034 .master_xfer = omap_i2c_xfer, 1034 .master_xfer = omap_i2c_xfer,
1035 .functionality = omap_i2c_func, 1035 .functionality = omap_i2c_func,
1036 }; 1036 };
1037 1037
1038 #ifdef CONFIG_OF 1038 #ifdef CONFIG_OF
1039 static struct omap_i2c_bus_platform_data omap3_pdata = { 1039 static struct omap_i2c_bus_platform_data omap3_pdata = {
1040 .rev = OMAP_I2C_IP_VERSION_1, 1040 .rev = OMAP_I2C_IP_VERSION_1,
1041 .flags = OMAP_I2C_FLAG_RESET_REGS_POSTIDLE | 1041 .flags = OMAP_I2C_FLAG_BUS_SHIFT_2,
1042 OMAP_I2C_FLAG_BUS_SHIFT_2,
1043 }; 1042 };
1044 1043
1045 static struct omap_i2c_bus_platform_data omap4_pdata = { 1044 static struct omap_i2c_bus_platform_data omap4_pdata = {
1046 .rev = OMAP_I2C_IP_VERSION_2, 1045 .rev = OMAP_I2C_IP_VERSION_2,
1047 }; 1046 };
1048 1047
1049 static const struct of_device_id omap_i2c_of_match[] = { 1048 static const struct of_device_id omap_i2c_of_match[] = {
1050 { 1049 {
1051 .compatible = "ti,omap4-i2c", 1050 .compatible = "ti,omap4-i2c",
1052 .data = &omap4_pdata, 1051 .data = &omap4_pdata,
1053 }, 1052 },
1054 { 1053 {
1055 .compatible = "ti,omap3-i2c", 1054 .compatible = "ti,omap3-i2c",
1056 .data = &omap3_pdata, 1055 .data = &omap3_pdata,
1057 }, 1056 },
1058 { }, 1057 { },
1059 }; 1058 };
1060 MODULE_DEVICE_TABLE(of, omap_i2c_of_match); 1059 MODULE_DEVICE_TABLE(of, omap_i2c_of_match);
1061 #endif 1060 #endif
1062 1061
1063 #define OMAP_I2C_SCHEME(rev) ((rev & 0xc000) >> 14) 1062 #define OMAP_I2C_SCHEME(rev) ((rev & 0xc000) >> 14)
1064 1063
1065 #define OMAP_I2C_REV_SCHEME_0_MAJOR(rev) (rev >> 4) 1064 #define OMAP_I2C_REV_SCHEME_0_MAJOR(rev) (rev >> 4)
1066 #define OMAP_I2C_REV_SCHEME_0_MINOR(rev) (rev & 0xf) 1065 #define OMAP_I2C_REV_SCHEME_0_MINOR(rev) (rev & 0xf)
1067 1066
1068 #define OMAP_I2C_REV_SCHEME_1_MAJOR(rev) ((rev & 0x0700) >> 7) 1067 #define OMAP_I2C_REV_SCHEME_1_MAJOR(rev) ((rev & 0x0700) >> 7)
1069 #define OMAP_I2C_REV_SCHEME_1_MINOR(rev) (rev & 0x1f) 1068 #define OMAP_I2C_REV_SCHEME_1_MINOR(rev) (rev & 0x1f)
1070 #define OMAP_I2C_SCHEME_0 0 1069 #define OMAP_I2C_SCHEME_0 0
1071 #define OMAP_I2C_SCHEME_1 1 1070 #define OMAP_I2C_SCHEME_1 1
1072 1071
1073 static int __devinit 1072 static int __devinit
1074 omap_i2c_probe(struct platform_device *pdev) 1073 omap_i2c_probe(struct platform_device *pdev)
1075 { 1074 {
1076 struct omap_i2c_dev *dev; 1075 struct omap_i2c_dev *dev;
1077 struct i2c_adapter *adap; 1076 struct i2c_adapter *adap;
1078 struct resource *mem; 1077 struct resource *mem;
1079 const struct omap_i2c_bus_platform_data *pdata = 1078 const struct omap_i2c_bus_platform_data *pdata =
1080 pdev->dev.platform_data; 1079 pdev->dev.platform_data;
1081 struct device_node *node = pdev->dev.of_node; 1080 struct device_node *node = pdev->dev.of_node;
1082 const struct of_device_id *match; 1081 const struct of_device_id *match;
1083 int irq; 1082 int irq;
1084 int r; 1083 int r;
1085 u32 rev; 1084 u32 rev;
1086 u16 minor, major, scheme; 1085 u16 minor, major, scheme;
1087 1086
1088 /* NOTE: driver uses the static register mapping */ 1087 /* NOTE: driver uses the static register mapping */
1089 mem = platform_get_resource(pdev, IORESOURCE_MEM, 0); 1088 mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
1090 if (!mem) { 1089 if (!mem) {
1091 dev_err(&pdev->dev, "no mem resource?\n"); 1090 dev_err(&pdev->dev, "no mem resource?\n");
1092 return -ENODEV; 1091 return -ENODEV;
1093 } 1092 }
1094 1093
1095 irq = platform_get_irq(pdev, 0); 1094 irq = platform_get_irq(pdev, 0);
1096 if (irq < 0) { 1095 if (irq < 0) {
1097 dev_err(&pdev->dev, "no irq resource?\n"); 1096 dev_err(&pdev->dev, "no irq resource?\n");
1098 return irq; 1097 return irq;
1099 } 1098 }
1100 1099
1101 dev = devm_kzalloc(&pdev->dev, sizeof(struct omap_i2c_dev), GFP_KERNEL); 1100 dev = devm_kzalloc(&pdev->dev, sizeof(struct omap_i2c_dev), GFP_KERNEL);
1102 if (!dev) { 1101 if (!dev) {
1103 dev_err(&pdev->dev, "Menory allocation failed\n"); 1102 dev_err(&pdev->dev, "Menory allocation failed\n");
1104 return -ENOMEM; 1103 return -ENOMEM;
1105 } 1104 }
1106 1105
1107 dev->base = devm_request_and_ioremap(&pdev->dev, mem); 1106 dev->base = devm_request_and_ioremap(&pdev->dev, mem);
1108 if (!dev->base) { 1107 if (!dev->base) {
1109 dev_err(&pdev->dev, "I2C region already claimed\n"); 1108 dev_err(&pdev->dev, "I2C region already claimed\n");
1110 return -ENOMEM; 1109 return -ENOMEM;
1111 } 1110 }
1112 1111
1113 match = of_match_device(of_match_ptr(omap_i2c_of_match), &pdev->dev); 1112 match = of_match_device(of_match_ptr(omap_i2c_of_match), &pdev->dev);
1114 if (match) { 1113 if (match) {
1115 u32 freq = 100000; /* default to 100000 Hz */ 1114 u32 freq = 100000; /* default to 100000 Hz */
1116 1115
1117 pdata = match->data; 1116 pdata = match->data;
1118 dev->flags = pdata->flags; 1117 dev->flags = pdata->flags;
1119 1118
1120 of_property_read_u32(node, "clock-frequency", &freq); 1119 of_property_read_u32(node, "clock-frequency", &freq);
1121 /* convert DT freq value in Hz into kHz for speed */ 1120 /* convert DT freq value in Hz into kHz for speed */
1122 dev->speed = freq / 1000; 1121 dev->speed = freq / 1000;
1123 } else if (pdata != NULL) { 1122 } else if (pdata != NULL) {
1124 dev->speed = pdata->clkrate; 1123 dev->speed = pdata->clkrate;
1125 dev->flags = pdata->flags; 1124 dev->flags = pdata->flags;
1126 dev->set_mpu_wkup_lat = pdata->set_mpu_wkup_lat; 1125 dev->set_mpu_wkup_lat = pdata->set_mpu_wkup_lat;
1127 } 1126 }
1128 1127
1129 dev->pins = devm_pinctrl_get_select_default(&pdev->dev); 1128 dev->pins = devm_pinctrl_get_select_default(&pdev->dev);
1130 if (IS_ERR(dev->pins)) { 1129 if (IS_ERR(dev->pins)) {
1131 if (PTR_ERR(dev->pins) == -EPROBE_DEFER) 1130 if (PTR_ERR(dev->pins) == -EPROBE_DEFER)
1132 return -EPROBE_DEFER; 1131 return -EPROBE_DEFER;
1133 1132
1134 dev_warn(&pdev->dev, "did not get pins for i2c error: %li\n", 1133 dev_warn(&pdev->dev, "did not get pins for i2c error: %li\n",
1135 PTR_ERR(dev->pins)); 1134 PTR_ERR(dev->pins));
1136 dev->pins = NULL; 1135 dev->pins = NULL;
1137 } 1136 }
1138 1137
1139 dev->dev = &pdev->dev; 1138 dev->dev = &pdev->dev;
1140 dev->irq = irq; 1139 dev->irq = irq;
1141 1140
1142 spin_lock_init(&dev->lock); 1141 spin_lock_init(&dev->lock);
1143 1142
1144 platform_set_drvdata(pdev, dev); 1143 platform_set_drvdata(pdev, dev);
1145 init_completion(&dev->cmd_complete); 1144 init_completion(&dev->cmd_complete);
1146 1145
1147 dev->reg_shift = (dev->flags >> OMAP_I2C_FLAG_BUS_SHIFT__SHIFT) & 3; 1146 dev->reg_shift = (dev->flags >> OMAP_I2C_FLAG_BUS_SHIFT__SHIFT) & 3;
1148 1147
1149 pm_runtime_enable(dev->dev); 1148 pm_runtime_enable(dev->dev);
1150 pm_runtime_set_autosuspend_delay(dev->dev, OMAP_I2C_PM_TIMEOUT); 1149 pm_runtime_set_autosuspend_delay(dev->dev, OMAP_I2C_PM_TIMEOUT);
1151 pm_runtime_use_autosuspend(dev->dev); 1150 pm_runtime_use_autosuspend(dev->dev);
1152 1151
1153 r = pm_runtime_get_sync(dev->dev); 1152 r = pm_runtime_get_sync(dev->dev);
1154 if (IS_ERR_VALUE(r)) 1153 if (IS_ERR_VALUE(r))
1155 goto err_free_mem; 1154 goto err_free_mem;
1156 1155
1157 /* 1156 /*
1158 * Read the Rev hi bit-[15:14] ie scheme this is 1 indicates ver2. 1157 * Read the Rev hi bit-[15:14] ie scheme this is 1 indicates ver2.
1159 * On omap1/3/2 Offset 4 is IE Reg the bit [15:14] is 0 at reset. 1158 * On omap1/3/2 Offset 4 is IE Reg the bit [15:14] is 0 at reset.
1160 * Also since the omap_i2c_read_reg uses reg_map_ip_* a 1159 * Also since the omap_i2c_read_reg uses reg_map_ip_* a
1161 * raw_readw is done. 1160 * raw_readw is done.
1162 */ 1161 */
1163 rev = __raw_readw(dev->base + 0x04); 1162 rev = __raw_readw(dev->base + 0x04);
1164 1163
1165 scheme = OMAP_I2C_SCHEME(rev); 1164 scheme = OMAP_I2C_SCHEME(rev);
1166 switch (scheme) { 1165 switch (scheme) {
1167 case OMAP_I2C_SCHEME_0: 1166 case OMAP_I2C_SCHEME_0:
1168 dev->regs = (u8 *)reg_map_ip_v1; 1167 dev->regs = (u8 *)reg_map_ip_v1;
1169 dev->rev = omap_i2c_read_reg(dev, OMAP_I2C_REV_REG); 1168 dev->rev = omap_i2c_read_reg(dev, OMAP_I2C_REV_REG);
1170 minor = OMAP_I2C_REV_SCHEME_0_MAJOR(dev->rev); 1169 minor = OMAP_I2C_REV_SCHEME_0_MAJOR(dev->rev);
1171 major = OMAP_I2C_REV_SCHEME_0_MAJOR(dev->rev); 1170 major = OMAP_I2C_REV_SCHEME_0_MAJOR(dev->rev);
1172 break; 1171 break;
1173 case OMAP_I2C_SCHEME_1: 1172 case OMAP_I2C_SCHEME_1:
1174 /* FALLTHROUGH */ 1173 /* FALLTHROUGH */
1175 default: 1174 default:
1176 dev->regs = (u8 *)reg_map_ip_v2; 1175 dev->regs = (u8 *)reg_map_ip_v2;
1177 rev = (rev << 16) | 1176 rev = (rev << 16) |
1178 omap_i2c_read_reg(dev, OMAP_I2C_IP_V2_REVNB_LO); 1177 omap_i2c_read_reg(dev, OMAP_I2C_IP_V2_REVNB_LO);
1179 minor = OMAP_I2C_REV_SCHEME_1_MINOR(rev); 1178 minor = OMAP_I2C_REV_SCHEME_1_MINOR(rev);
1180 major = OMAP_I2C_REV_SCHEME_1_MAJOR(rev); 1179 major = OMAP_I2C_REV_SCHEME_1_MAJOR(rev);
1181 dev->rev = rev; 1180 dev->rev = rev;
1182 } 1181 }
1183 1182
1184 dev->errata = 0; 1183 dev->errata = 0;
1185 1184
1186 if (dev->rev >= OMAP_I2C_REV_ON_2430 && 1185 if (dev->rev >= OMAP_I2C_REV_ON_2430 &&
1187 dev->rev < OMAP_I2C_REV_ON_4430_PLUS) 1186 dev->rev < OMAP_I2C_REV_ON_4430_PLUS)
1188 dev->errata |= I2C_OMAP_ERRATA_I207; 1187 dev->errata |= I2C_OMAP_ERRATA_I207;
1189 1188
1190 if (dev->rev <= OMAP_I2C_REV_ON_3430_3530) 1189 if (dev->rev <= OMAP_I2C_REV_ON_3430_3530)
1191 dev->errata |= I2C_OMAP_ERRATA_I462; 1190 dev->errata |= I2C_OMAP_ERRATA_I462;
1192 1191
1193 if (!(dev->flags & OMAP_I2C_FLAG_NO_FIFO)) { 1192 if (!(dev->flags & OMAP_I2C_FLAG_NO_FIFO)) {
1194 u16 s; 1193 u16 s;
1195 1194
1196 /* Set up the fifo size - Get total size */ 1195 /* Set up the fifo size - Get total size */
1197 s = (omap_i2c_read_reg(dev, OMAP_I2C_BUFSTAT_REG) >> 14) & 0x3; 1196 s = (omap_i2c_read_reg(dev, OMAP_I2C_BUFSTAT_REG) >> 14) & 0x3;
1198 dev->fifo_size = 0x8 << s; 1197 dev->fifo_size = 0x8 << s;
1199 1198
1200 /* 1199 /*
1201 * Set up notification threshold as half the total available 1200 * Set up notification threshold as half the total available
1202 * size. This is to ensure that we can handle the status on int 1201 * size. This is to ensure that we can handle the status on int
1203 * call back latencies. 1202 * call back latencies.
1204 */ 1203 */
1205 1204
1206 dev->fifo_size = (dev->fifo_size / 2); 1205 dev->fifo_size = (dev->fifo_size / 2);
1207 1206
1208 if (dev->rev < OMAP_I2C_REV_ON_3630) 1207 if (dev->rev < OMAP_I2C_REV_ON_3630)
1209 dev->b_hw = 1; /* Enable hardware fixes */ 1208 dev->b_hw = 1; /* Enable hardware fixes */
1210 1209
1211 /* calculate wakeup latency constraint for MPU */ 1210 /* calculate wakeup latency constraint for MPU */
1212 if (dev->set_mpu_wkup_lat != NULL) 1211 if (dev->set_mpu_wkup_lat != NULL)
1213 dev->latency = (1000000 * dev->fifo_size) / 1212 dev->latency = (1000000 * dev->fifo_size) /
1214 (1000 * dev->speed / 8); 1213 (1000 * dev->speed / 8);
1215 } 1214 }
1216 1215
1217 /* reset ASAP, clearing any IRQs */ 1216 /* reset ASAP, clearing any IRQs */
1218 omap_i2c_init(dev); 1217 omap_i2c_init(dev);
1219 1218
1220 if (dev->rev < OMAP_I2C_OMAP1_REV_2) 1219 if (dev->rev < OMAP_I2C_OMAP1_REV_2)
1221 r = devm_request_irq(&pdev->dev, dev->irq, omap_i2c_omap1_isr, 1220 r = devm_request_irq(&pdev->dev, dev->irq, omap_i2c_omap1_isr,
1222 IRQF_NO_SUSPEND, pdev->name, dev); 1221 IRQF_NO_SUSPEND, pdev->name, dev);
1223 else 1222 else
1224 r = devm_request_threaded_irq(&pdev->dev, dev->irq, 1223 r = devm_request_threaded_irq(&pdev->dev, dev->irq,
1225 omap_i2c_isr, omap_i2c_isr_thread, 1224 omap_i2c_isr, omap_i2c_isr_thread,
1226 IRQF_NO_SUSPEND | IRQF_ONESHOT, 1225 IRQF_NO_SUSPEND | IRQF_ONESHOT,
1227 pdev->name, dev); 1226 pdev->name, dev);
1228 1227
1229 if (r) { 1228 if (r) {
1230 dev_err(dev->dev, "failure requesting irq %i\n", dev->irq); 1229 dev_err(dev->dev, "failure requesting irq %i\n", dev->irq);
1231 goto err_unuse_clocks; 1230 goto err_unuse_clocks;
1232 } 1231 }
1233 1232
1234 adap = &dev->adapter; 1233 adap = &dev->adapter;
1235 i2c_set_adapdata(adap, dev); 1234 i2c_set_adapdata(adap, dev);
1236 adap->owner = THIS_MODULE; 1235 adap->owner = THIS_MODULE;
1237 adap->class = I2C_CLASS_HWMON; 1236 adap->class = I2C_CLASS_HWMON;
1238 strlcpy(adap->name, "OMAP I2C adapter", sizeof(adap->name)); 1237 strlcpy(adap->name, "OMAP I2C adapter", sizeof(adap->name));
1239 adap->algo = &omap_i2c_algo; 1238 adap->algo = &omap_i2c_algo;
1240 adap->dev.parent = &pdev->dev; 1239 adap->dev.parent = &pdev->dev;
1241 adap->dev.of_node = pdev->dev.of_node; 1240 adap->dev.of_node = pdev->dev.of_node;
1242 1241
1243 /* i2c device drivers may be active on return from add_adapter() */ 1242 /* i2c device drivers may be active on return from add_adapter() */
1244 adap->nr = pdev->id; 1243 adap->nr = pdev->id;
1245 r = i2c_add_numbered_adapter(adap); 1244 r = i2c_add_numbered_adapter(adap);
1246 if (r) { 1245 if (r) {
1247 dev_err(dev->dev, "failure adding adapter\n"); 1246 dev_err(dev->dev, "failure adding adapter\n");
1248 goto err_unuse_clocks; 1247 goto err_unuse_clocks;
1249 } 1248 }
1250 1249
1251 dev_info(dev->dev, "bus %d rev%d.%d at %d kHz\n", adap->nr, 1250 dev_info(dev->dev, "bus %d rev%d.%d at %d kHz\n", adap->nr,
1252 major, minor, dev->speed); 1251 major, minor, dev->speed);
1253 1252
1254 of_i2c_register_devices(adap); 1253 of_i2c_register_devices(adap);
1255 1254
1256 pm_runtime_mark_last_busy(dev->dev); 1255 pm_runtime_mark_last_busy(dev->dev);
1257 pm_runtime_put_autosuspend(dev->dev); 1256 pm_runtime_put_autosuspend(dev->dev);
1258 1257
1259 return 0; 1258 return 0;
1260 1259
1261 err_unuse_clocks: 1260 err_unuse_clocks:
1262 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, 0); 1261 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, 0);
1263 pm_runtime_put(dev->dev); 1262 pm_runtime_put(dev->dev);
1264 pm_runtime_disable(&pdev->dev); 1263 pm_runtime_disable(&pdev->dev);
1265 err_free_mem: 1264 err_free_mem:
1266 platform_set_drvdata(pdev, NULL); 1265 platform_set_drvdata(pdev, NULL);
1267 1266
1268 return r; 1267 return r;
1269 } 1268 }
1270 1269
1271 static int __devexit omap_i2c_remove(struct platform_device *pdev) 1270 static int __devexit omap_i2c_remove(struct platform_device *pdev)
1272 { 1271 {
1273 struct omap_i2c_dev *dev = platform_get_drvdata(pdev); 1272 struct omap_i2c_dev *dev = platform_get_drvdata(pdev);
1274 int ret; 1273 int ret;
1275 1274
1276 platform_set_drvdata(pdev, NULL); 1275 platform_set_drvdata(pdev, NULL);
1277 1276
1278 i2c_del_adapter(&dev->adapter); 1277 i2c_del_adapter(&dev->adapter);
1279 ret = pm_runtime_get_sync(&pdev->dev); 1278 ret = pm_runtime_get_sync(&pdev->dev);
1280 if (IS_ERR_VALUE(ret)) 1279 if (IS_ERR_VALUE(ret))
1281 return ret; 1280 return ret;
1282 1281
1283 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, 0); 1282 omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, 0);
1284 pm_runtime_put(&pdev->dev); 1283 pm_runtime_put(&pdev->dev);
1285 pm_runtime_disable(&pdev->dev); 1284 pm_runtime_disable(&pdev->dev);
1286 return 0; 1285 return 0;
1287 } 1286 }
1288 1287
1289 #ifdef CONFIG_PM 1288 #ifdef CONFIG_PM
1290 #ifdef CONFIG_PM_RUNTIME 1289 #ifdef CONFIG_PM_RUNTIME
1291 static int omap_i2c_runtime_suspend(struct device *dev) 1290 static int omap_i2c_runtime_suspend(struct device *dev)
1292 { 1291 {
1293 struct platform_device *pdev = to_platform_device(dev); 1292 struct platform_device *pdev = to_platform_device(dev);
1294 struct omap_i2c_dev *_dev = platform_get_drvdata(pdev); 1293 struct omap_i2c_dev *_dev = platform_get_drvdata(pdev);
1295 1294
1296 _dev->iestate = omap_i2c_read_reg(_dev, OMAP_I2C_IE_REG); 1295 _dev->iestate = omap_i2c_read_reg(_dev, OMAP_I2C_IE_REG);
1297 1296
1298 omap_i2c_write_reg(_dev, OMAP_I2C_IE_REG, 0); 1297 omap_i2c_write_reg(_dev, OMAP_I2C_IE_REG, 0);
1299 1298
1300 if (_dev->rev < OMAP_I2C_OMAP1_REV_2) { 1299 if (_dev->rev < OMAP_I2C_OMAP1_REV_2) {
1301 omap_i2c_read_reg(_dev, OMAP_I2C_IV_REG); /* Read clears */ 1300 omap_i2c_read_reg(_dev, OMAP_I2C_IV_REG); /* Read clears */
1302 } else { 1301 } else {
1303 omap_i2c_write_reg(_dev, OMAP_I2C_STAT_REG, _dev->iestate); 1302 omap_i2c_write_reg(_dev, OMAP_I2C_STAT_REG, _dev->iestate);
1304 1303
1305 /* Flush posted write */ 1304 /* Flush posted write */
1306 omap_i2c_read_reg(_dev, OMAP_I2C_STAT_REG); 1305 omap_i2c_read_reg(_dev, OMAP_I2C_STAT_REG);
1307 } 1306 }
1308 1307
1309 return 0; 1308 return 0;
1310 } 1309 }
1311 1310
1312 static int omap_i2c_runtime_resume(struct device *dev) 1311 static int omap_i2c_runtime_resume(struct device *dev)
1313 { 1312 {
1314 struct platform_device *pdev = to_platform_device(dev); 1313 struct platform_device *pdev = to_platform_device(dev);
1315 struct omap_i2c_dev *_dev = platform_get_drvdata(pdev); 1314 struct omap_i2c_dev *_dev = platform_get_drvdata(pdev);
1316 1315
1317 if (!_dev->regs) 1316 if (!_dev->regs)
1318 return 0; 1317 return 0;
1319 1318
1320 __omap_i2c_init(_dev); 1319 __omap_i2c_init(_dev);
1321 1320
1322 return 0; 1321 return 0;
1323 } 1322 }
1324 #endif /* CONFIG_PM_RUNTIME */ 1323 #endif /* CONFIG_PM_RUNTIME */
1325 1324
1326 static struct dev_pm_ops omap_i2c_pm_ops = { 1325 static struct dev_pm_ops omap_i2c_pm_ops = {
1327 SET_RUNTIME_PM_OPS(omap_i2c_runtime_suspend, 1326 SET_RUNTIME_PM_OPS(omap_i2c_runtime_suspend,
1328 omap_i2c_runtime_resume, NULL) 1327 omap_i2c_runtime_resume, NULL)
1329 }; 1328 };
1330 #define OMAP_I2C_PM_OPS (&omap_i2c_pm_ops) 1329 #define OMAP_I2C_PM_OPS (&omap_i2c_pm_ops)
1331 #else 1330 #else
1332 #define OMAP_I2C_PM_OPS NULL 1331 #define OMAP_I2C_PM_OPS NULL
1333 #endif /* CONFIG_PM */ 1332 #endif /* CONFIG_PM */
1334 1333
1335 static struct platform_driver omap_i2c_driver = { 1334 static struct platform_driver omap_i2c_driver = {
1336 .probe = omap_i2c_probe, 1335 .probe = omap_i2c_probe,
1337 .remove = __devexit_p(omap_i2c_remove), 1336 .remove = __devexit_p(omap_i2c_remove),
1338 .driver = { 1337 .driver = {
1339 .name = "omap_i2c", 1338 .name = "omap_i2c",
1340 .owner = THIS_MODULE, 1339 .owner = THIS_MODULE,
1341 .pm = OMAP_I2C_PM_OPS, 1340 .pm = OMAP_I2C_PM_OPS,
1342 .of_match_table = of_match_ptr(omap_i2c_of_match), 1341 .of_match_table = of_match_ptr(omap_i2c_of_match),
1343 }, 1342 },
1344 }; 1343 };
1345 1344
1346 /* I2C may be needed to bring up other drivers */ 1345 /* I2C may be needed to bring up other drivers */
1347 static int __init 1346 static int __init
1348 omap_i2c_init_driver(void) 1347 omap_i2c_init_driver(void)
1349 { 1348 {
1350 return platform_driver_register(&omap_i2c_driver); 1349 return platform_driver_register(&omap_i2c_driver);
1351 } 1350 }
1352 subsys_initcall(omap_i2c_init_driver); 1351 subsys_initcall(omap_i2c_init_driver);
1353 1352
1354 static void __exit omap_i2c_exit_driver(void) 1353 static void __exit omap_i2c_exit_driver(void)
1355 { 1354 {
1356 platform_driver_unregister(&omap_i2c_driver); 1355 platform_driver_unregister(&omap_i2c_driver);
1357 } 1356 }
1358 module_exit(omap_i2c_exit_driver); 1357 module_exit(omap_i2c_exit_driver);
1359 1358
1360 MODULE_AUTHOR("MontaVista Software, Inc. (and others)"); 1359 MODULE_AUTHOR("MontaVista Software, Inc. (and others)");
1361 MODULE_DESCRIPTION("TI OMAP I2C bus adapter"); 1360 MODULE_DESCRIPTION("TI OMAP I2C bus adapter");
1362 MODULE_LICENSE("GPL"); 1361 MODULE_LICENSE("GPL");
1363 MODULE_ALIAS("platform:omap_i2c"); 1362 MODULE_ALIAS("platform:omap_i2c");
1364 1363
include/linux/i2c-omap.h
1 #ifndef __I2C_OMAP_H__ 1 #ifndef __I2C_OMAP_H__
2 #define __I2C_OMAP_H__ 2 #define __I2C_OMAP_H__
3 3
4 #include <linux/platform_device.h> 4 #include <linux/platform_device.h>
5 5
6 /* 6 /*
7 * Version 2 of the I2C peripheral unit has a different register 7 * Version 2 of the I2C peripheral unit has a different register
8 * layout and extra registers. The ID register in the V2 peripheral 8 * layout and extra registers. The ID register in the V2 peripheral
9 * unit on the OMAP4430 reports the same ID as the V1 peripheral 9 * unit on the OMAP4430 reports the same ID as the V1 peripheral
10 * unit on the OMAP3530, so we must inform the driver which IP 10 * unit on the OMAP3530, so we must inform the driver which IP
11 * version we know it is running on from platform / cpu-specific 11 * version we know it is running on from platform / cpu-specific
12 * code using these constants in the hwmod class definition. 12 * code using these constants in the hwmod class definition.
13 */ 13 */
14 14
15 #define OMAP_I2C_IP_VERSION_1 1 15 #define OMAP_I2C_IP_VERSION_1 1
16 #define OMAP_I2C_IP_VERSION_2 2 16 #define OMAP_I2C_IP_VERSION_2 2
17 17
18 /* struct omap_i2c_bus_platform_data .flags meanings */ 18 /* struct omap_i2c_bus_platform_data .flags meanings */
19 19
20 #define OMAP_I2C_FLAG_NO_FIFO BIT(0) 20 #define OMAP_I2C_FLAG_NO_FIFO BIT(0)
21 #define OMAP_I2C_FLAG_SIMPLE_CLOCK BIT(1) 21 #define OMAP_I2C_FLAG_SIMPLE_CLOCK BIT(1)
22 #define OMAP_I2C_FLAG_16BIT_DATA_REG BIT(2) 22 #define OMAP_I2C_FLAG_16BIT_DATA_REG BIT(2)
23 #define OMAP_I2C_FLAG_RESET_REGS_POSTIDLE BIT(3)
24 #define OMAP_I2C_FLAG_ALWAYS_ARMXOR_CLK BIT(5) 23 #define OMAP_I2C_FLAG_ALWAYS_ARMXOR_CLK BIT(5)
25 #define OMAP_I2C_FLAG_FORCE_19200_INT_CLK BIT(6) 24 #define OMAP_I2C_FLAG_FORCE_19200_INT_CLK BIT(6)
26 /* how the CPU address bus must be translated for I2C unit access */ 25 /* how the CPU address bus must be translated for I2C unit access */
27 #define OMAP_I2C_FLAG_BUS_SHIFT_NONE 0 26 #define OMAP_I2C_FLAG_BUS_SHIFT_NONE 0
28 #define OMAP_I2C_FLAG_BUS_SHIFT_1 BIT(7) 27 #define OMAP_I2C_FLAG_BUS_SHIFT_1 BIT(7)
29 #define OMAP_I2C_FLAG_BUS_SHIFT_2 BIT(8) 28 #define OMAP_I2C_FLAG_BUS_SHIFT_2 BIT(8)
30 #define OMAP_I2C_FLAG_BUS_SHIFT__SHIFT 7 29 #define OMAP_I2C_FLAG_BUS_SHIFT__SHIFT 7
31 30
32 struct omap_i2c_bus_platform_data { 31 struct omap_i2c_bus_platform_data {
33 u32 clkrate; 32 u32 clkrate;
34 u32 rev; 33 u32 rev;
35 u32 flags; 34 u32 flags;
36 void (*set_mpu_wkup_lat)(struct device *dev, long set); 35 void (*set_mpu_wkup_lat)(struct device *dev, long set);
37 }; 36 };
38 37
39 #endif 38 #endif
40 39