diff options
Diffstat (limited to 'arch/arm/plat-omap/common.c')
-rw-r--r-- | arch/arm/plat-omap/common.c | 69 |
1 files changed, 46 insertions, 23 deletions
diff --git a/arch/arm/plat-omap/common.c b/arch/arm/plat-omap/common.c index dddc0273bc8b..088c1a03b946 100644 --- a/arch/arm/plat-omap/common.c +++ b/arch/arm/plat-omap/common.c | |||
@@ -34,6 +34,7 @@ | |||
34 | #include <plat/control.h> | 34 | #include <plat/control.h> |
35 | #include <plat/mux.h> | 35 | #include <plat/mux.h> |
36 | #include <plat/fpga.h> | 36 | #include <plat/fpga.h> |
37 | #include <plat/serial.h> | ||
37 | 38 | ||
38 | #include <plat/clock.h> | 39 | #include <plat/clock.h> |
39 | 40 | ||
@@ -126,7 +127,7 @@ static cycle_t omap2430_32k_read(struct clocksource *cs) | |||
126 | #define omap2430_32k_read NULL | 127 | #define omap2430_32k_read NULL |
127 | #endif | 128 | #endif |
128 | 129 | ||
129 | #ifdef CONFIG_ARCH_OMAP34XX | 130 | #ifdef CONFIG_ARCH_OMAP3 |
130 | static cycle_t omap34xx_32k_read(struct clocksource *cs) | 131 | static cycle_t omap34xx_32k_read(struct clocksource *cs) |
131 | { | 132 | { |
132 | return omap_readl(OMAP3430_32KSYNCT_BASE + 0x10); | 133 | return omap_readl(OMAP3430_32KSYNCT_BASE + 0x10); |
@@ -245,6 +246,7 @@ static void __init __omap2_set_globals(struct omap_globals *omap2_globals) | |||
245 | omap2_set_globals_sdrc(omap2_globals); | 246 | omap2_set_globals_sdrc(omap2_globals); |
246 | omap2_set_globals_control(omap2_globals); | 247 | omap2_set_globals_control(omap2_globals); |
247 | omap2_set_globals_prcm(omap2_globals); | 248 | omap2_set_globals_prcm(omap2_globals); |
249 | omap2_set_globals_uart(omap2_globals); | ||
248 | } | 250 | } |
249 | 251 | ||
250 | #endif | 252 | #endif |
@@ -254,11 +256,14 @@ static void __init __omap2_set_globals(struct omap_globals *omap2_globals) | |||
254 | static struct omap_globals omap242x_globals = { | 256 | static struct omap_globals omap242x_globals = { |
255 | .class = OMAP242X_CLASS, | 257 | .class = OMAP242X_CLASS, |
256 | .tap = OMAP2_L4_IO_ADDRESS(0x48014000), | 258 | .tap = OMAP2_L4_IO_ADDRESS(0x48014000), |
257 | .sdrc = OMAP2_L3_IO_ADDRESS(OMAP2420_SDRC_BASE), | 259 | .sdrc = OMAP2420_SDRC_BASE, |
258 | .sms = OMAP2_L3_IO_ADDRESS(OMAP2420_SMS_BASE), | 260 | .sms = OMAP2420_SMS_BASE, |
259 | .ctrl = OMAP2_L4_IO_ADDRESS(OMAP2420_CTRL_BASE), | 261 | .ctrl = OMAP2420_CTRL_BASE, |
260 | .prm = OMAP2_L4_IO_ADDRESS(OMAP2420_PRM_BASE), | 262 | .prm = OMAP2420_PRM_BASE, |
261 | .cm = OMAP2_L4_IO_ADDRESS(OMAP2420_CM_BASE), | 263 | .cm = OMAP2420_CM_BASE, |
264 | .uart1_phys = OMAP2_UART1_BASE, | ||
265 | .uart2_phys = OMAP2_UART2_BASE, | ||
266 | .uart3_phys = OMAP2_UART3_BASE, | ||
262 | }; | 267 | }; |
263 | 268 | ||
264 | void __init omap2_set_globals_242x(void) | 269 | void __init omap2_set_globals_242x(void) |
@@ -272,11 +277,14 @@ void __init omap2_set_globals_242x(void) | |||
272 | static struct omap_globals omap243x_globals = { | 277 | static struct omap_globals omap243x_globals = { |
273 | .class = OMAP243X_CLASS, | 278 | .class = OMAP243X_CLASS, |
274 | .tap = OMAP2_L4_IO_ADDRESS(0x4900a000), | 279 | .tap = OMAP2_L4_IO_ADDRESS(0x4900a000), |
275 | .sdrc = OMAP2_L3_IO_ADDRESS(OMAP243X_SDRC_BASE), | 280 | .sdrc = OMAP243X_SDRC_BASE, |
276 | .sms = OMAP2_L3_IO_ADDRESS(OMAP243X_SMS_BASE), | 281 | .sms = OMAP243X_SMS_BASE, |
277 | .ctrl = OMAP2_L4_IO_ADDRESS(OMAP243X_CTRL_BASE), | 282 | .ctrl = OMAP243X_CTRL_BASE, |
278 | .prm = OMAP2_L4_IO_ADDRESS(OMAP2430_PRM_BASE), | 283 | .prm = OMAP2430_PRM_BASE, |
279 | .cm = OMAP2_L4_IO_ADDRESS(OMAP2430_CM_BASE), | 284 | .cm = OMAP2430_CM_BASE, |
285 | .uart1_phys = OMAP2_UART1_BASE, | ||
286 | .uart2_phys = OMAP2_UART2_BASE, | ||
287 | .uart3_phys = OMAP2_UART3_BASE, | ||
280 | }; | 288 | }; |
281 | 289 | ||
282 | void __init omap2_set_globals_243x(void) | 290 | void __init omap2_set_globals_243x(void) |
@@ -285,21 +293,31 @@ void __init omap2_set_globals_243x(void) | |||
285 | } | 293 | } |
286 | #endif | 294 | #endif |
287 | 295 | ||
288 | #if defined(CONFIG_ARCH_OMAP3430) | 296 | #if defined(CONFIG_ARCH_OMAP3) |
289 | 297 | ||
290 | static struct omap_globals omap343x_globals = { | 298 | static struct omap_globals omap3_globals = { |
291 | .class = OMAP343X_CLASS, | 299 | .class = OMAP343X_CLASS, |
292 | .tap = OMAP2_L4_IO_ADDRESS(0x4830A000), | 300 | .tap = OMAP2_L4_IO_ADDRESS(0x4830A000), |
293 | .sdrc = OMAP2_L3_IO_ADDRESS(OMAP343X_SDRC_BASE), | 301 | .sdrc = OMAP343X_SDRC_BASE, |
294 | .sms = OMAP2_L3_IO_ADDRESS(OMAP343X_SMS_BASE), | 302 | .sms = OMAP343X_SMS_BASE, |
295 | .ctrl = OMAP2_L4_IO_ADDRESS(OMAP343X_CTRL_BASE), | 303 | .ctrl = OMAP343X_CTRL_BASE, |
296 | .prm = OMAP2_L4_IO_ADDRESS(OMAP3430_PRM_BASE), | 304 | .prm = OMAP3430_PRM_BASE, |
297 | .cm = OMAP2_L4_IO_ADDRESS(OMAP3430_CM_BASE), | 305 | .cm = OMAP3430_CM_BASE, |
306 | .uart1_phys = OMAP3_UART1_BASE, | ||
307 | .uart2_phys = OMAP3_UART2_BASE, | ||
308 | .uart3_phys = OMAP3_UART3_BASE, | ||
298 | }; | 309 | }; |
299 | 310 | ||
300 | void __init omap2_set_globals_343x(void) | 311 | void __init omap2_set_globals_343x(void) |
301 | { | 312 | { |
302 | __omap2_set_globals(&omap343x_globals); | 313 | __omap2_set_globals(&omap3_globals); |
314 | } | ||
315 | |||
316 | void __init omap2_set_globals_36xx(void) | ||
317 | { | ||
318 | omap3_globals.uart4_phys = OMAP3_UART4_BASE; | ||
319 | |||
320 | __omap2_set_globals(&omap3_globals); | ||
303 | } | 321 | } |
304 | #endif | 322 | #endif |
305 | 323 | ||
@@ -307,10 +325,14 @@ void __init omap2_set_globals_343x(void) | |||
307 | static struct omap_globals omap4_globals = { | 325 | static struct omap_globals omap4_globals = { |
308 | .class = OMAP443X_CLASS, | 326 | .class = OMAP443X_CLASS, |
309 | .tap = OMAP2_L4_IO_ADDRESS(OMAP443X_SCM_BASE), | 327 | .tap = OMAP2_L4_IO_ADDRESS(OMAP443X_SCM_BASE), |
310 | .ctrl = OMAP2_L4_IO_ADDRESS(OMAP443X_CTRL_BASE), | 328 | .ctrl = OMAP443X_CTRL_BASE, |
311 | .prm = OMAP2_L4_IO_ADDRESS(OMAP4430_PRM_BASE), | 329 | .prm = OMAP4430_PRM_BASE, |
312 | .cm = OMAP2_L4_IO_ADDRESS(OMAP4430_CM_BASE), | 330 | .cm = OMAP4430_CM_BASE, |
313 | .cm2 = OMAP2_L4_IO_ADDRESS(OMAP4430_CM2_BASE), | 331 | .cm2 = OMAP4430_CM2_BASE, |
332 | .uart1_phys = OMAP4_UART1_BASE, | ||
333 | .uart2_phys = OMAP4_UART2_BASE, | ||
334 | .uart3_phys = OMAP4_UART3_BASE, | ||
335 | .uart4_phys = OMAP4_UART4_BASE, | ||
314 | }; | 336 | }; |
315 | 337 | ||
316 | void __init omap2_set_globals_443x(void) | 338 | void __init omap2_set_globals_443x(void) |
@@ -318,6 +340,7 @@ void __init omap2_set_globals_443x(void) | |||
318 | omap2_set_globals_tap(&omap4_globals); | 340 | omap2_set_globals_tap(&omap4_globals); |
319 | omap2_set_globals_control(&omap4_globals); | 341 | omap2_set_globals_control(&omap4_globals); |
320 | omap2_set_globals_prcm(&omap4_globals); | 342 | omap2_set_globals_prcm(&omap4_globals); |
343 | omap2_set_globals_uart(&omap4_globals); | ||
321 | } | 344 | } |
322 | #endif | 345 | #endif |
323 | 346 | ||