diff options
author | Tony Lindgren <tony@atomide.com> | 2012-11-30 11:40:31 -0500 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2012-11-30 11:40:31 -0500 |
commit | 2589d056122f6dcb405d411eae872aac8cf9da1b (patch) | |
tree | 8b2fb3a9f8205c110842c59ed42987a6f2b17e1a /arch/arm/mach-omap2/io.c | |
parent | 42a1cc9c0ec2a00b53b4f02849dc4377b09b3b05 (diff) | |
parent | 8b9c1ac2e11a9fb3a5a8860fb7570ff7633aa7f7 (diff) |
Merge tag 'tags/omap-for-v3.8/devel-prcm-signed' into omap-for-v3.8/cleanup-headers-prepare-multiplatform-v3
omap prcm changes via Paul Walmsley <paul@pwsan.com>:
Some miscellaneous OMAP hwmod changes for 3.8, along with a PRM
change needed for one of the hwmod patches to function.
Basic test logs for this branch on top of Tony's
omap-for-v3.8/clock branch at commit
558a0780b0a04862a678f7823215424b4e5501f9 are here:
http://www.pwsan.com/omap/testlogs/hwmod_devel_a_3.8/20121121161522/
However, omap-for-v3.8/clock at 558a0780 does not include some fixes
that are needed for a successful test. With several reverts,
fixes, and workarounds applied, the following test logs were
obtained:
http://www.pwsan.com/omap/testlogs/TEST_hwmod_devel_a_3.8/20121121162719/
which indicate that the series tests cleanly.
Conflicts:
arch/arm/mach-omap2/cm33xx.c
arch/arm/mach-omap2/io.c
arch/arm/mach-omap2/prm_common.c
Diffstat (limited to 'arch/arm/mach-omap2/io.c')
-rw-r--r-- | arch/arm/mach-omap2/io.c | 101 |
1 files changed, 87 insertions, 14 deletions
diff --git a/arch/arm/mach-omap2/io.c b/arch/arm/mach-omap2/io.c index 807b8d919f81..7c39238322e0 100644 --- a/arch/arm/mach-omap2/io.c +++ b/arch/arm/mach-omap2/io.c | |||
@@ -40,8 +40,19 @@ | |||
40 | #include "clock44xx.h" | 40 | #include "clock44xx.h" |
41 | #include "omap-pm.h" | 41 | #include "omap-pm.h" |
42 | #include "sdrc.h" | 42 | #include "sdrc.h" |
43 | #include "control.h" | ||
43 | #include "serial.h" | 44 | #include "serial.h" |
44 | #include "sram.h" | 45 | #include "sram.h" |
46 | #include "cm2xxx.h" | ||
47 | #include "cm3xxx.h" | ||
48 | #include "prm.h" | ||
49 | #include "cm.h" | ||
50 | #include "prcm_mpu44xx.h" | ||
51 | #include "prminst44xx.h" | ||
52 | #include "cminst44xx.h" | ||
53 | #include "prm2xxx.h" | ||
54 | #include "prm3xxx.h" | ||
55 | #include "prm44xx.h" | ||
45 | 56 | ||
46 | /* | 57 | /* |
47 | * The machine specific code may provide the extra mapping besides the | 58 | * The machine specific code may provide the extra mapping besides the |
@@ -264,7 +275,7 @@ static struct map_desc omap54xx_io_desc[] __initdata = { | |||
264 | #endif | 275 | #endif |
265 | 276 | ||
266 | #ifdef CONFIG_SOC_OMAP2420 | 277 | #ifdef CONFIG_SOC_OMAP2420 |
267 | void __init omap242x_map_common_io(void) | 278 | void __init omap242x_map_io(void) |
268 | { | 279 | { |
269 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); | 280 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); |
270 | iotable_init(omap242x_io_desc, ARRAY_SIZE(omap242x_io_desc)); | 281 | iotable_init(omap242x_io_desc, ARRAY_SIZE(omap242x_io_desc)); |
@@ -272,7 +283,7 @@ void __init omap242x_map_common_io(void) | |||
272 | #endif | 283 | #endif |
273 | 284 | ||
274 | #ifdef CONFIG_SOC_OMAP2430 | 285 | #ifdef CONFIG_SOC_OMAP2430 |
275 | void __init omap243x_map_common_io(void) | 286 | void __init omap243x_map_io(void) |
276 | { | 287 | { |
277 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); | 288 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); |
278 | iotable_init(omap243x_io_desc, ARRAY_SIZE(omap243x_io_desc)); | 289 | iotable_init(omap243x_io_desc, ARRAY_SIZE(omap243x_io_desc)); |
@@ -280,28 +291,28 @@ void __init omap243x_map_common_io(void) | |||
280 | #endif | 291 | #endif |
281 | 292 | ||
282 | #ifdef CONFIG_ARCH_OMAP3 | 293 | #ifdef CONFIG_ARCH_OMAP3 |
283 | void __init omap34xx_map_common_io(void) | 294 | void __init omap3_map_io(void) |
284 | { | 295 | { |
285 | iotable_init(omap34xx_io_desc, ARRAY_SIZE(omap34xx_io_desc)); | 296 | iotable_init(omap34xx_io_desc, ARRAY_SIZE(omap34xx_io_desc)); |
286 | } | 297 | } |
287 | #endif | 298 | #endif |
288 | 299 | ||
289 | #ifdef CONFIG_SOC_TI81XX | 300 | #ifdef CONFIG_SOC_TI81XX |
290 | void __init omapti81xx_map_common_io(void) | 301 | void __init ti81xx_map_io(void) |
291 | { | 302 | { |
292 | iotable_init(omapti81xx_io_desc, ARRAY_SIZE(omapti81xx_io_desc)); | 303 | iotable_init(omapti81xx_io_desc, ARRAY_SIZE(omapti81xx_io_desc)); |
293 | } | 304 | } |
294 | #endif | 305 | #endif |
295 | 306 | ||
296 | #ifdef CONFIG_SOC_AM33XX | 307 | #ifdef CONFIG_SOC_AM33XX |
297 | void __init omapam33xx_map_common_io(void) | 308 | void __init am33xx_map_io(void) |
298 | { | 309 | { |
299 | iotable_init(omapam33xx_io_desc, ARRAY_SIZE(omapam33xx_io_desc)); | 310 | iotable_init(omapam33xx_io_desc, ARRAY_SIZE(omapam33xx_io_desc)); |
300 | } | 311 | } |
301 | #endif | 312 | #endif |
302 | 313 | ||
303 | #ifdef CONFIG_ARCH_OMAP4 | 314 | #ifdef CONFIG_ARCH_OMAP4 |
304 | void __init omap44xx_map_common_io(void) | 315 | void __init omap4_map_io(void) |
305 | { | 316 | { |
306 | iotable_init(omap44xx_io_desc, ARRAY_SIZE(omap44xx_io_desc)); | 317 | iotable_init(omap44xx_io_desc, ARRAY_SIZE(omap44xx_io_desc)); |
307 | omap_barriers_init(); | 318 | omap_barriers_init(); |
@@ -309,7 +320,7 @@ void __init omap44xx_map_common_io(void) | |||
309 | #endif | 320 | #endif |
310 | 321 | ||
311 | #ifdef CONFIG_SOC_OMAP5 | 322 | #ifdef CONFIG_SOC_OMAP5 |
312 | void __init omap5_map_common_io(void) | 323 | void __init omap5_map_io(void) |
313 | { | 324 | { |
314 | iotable_init(omap54xx_io_desc, ARRAY_SIZE(omap54xx_io_desc)); | 325 | iotable_init(omap54xx_io_desc, ARRAY_SIZE(omap54xx_io_desc)); |
315 | } | 326 | } |
@@ -371,8 +382,16 @@ static void __init omap_hwmod_init_postsetup(void) | |||
371 | #ifdef CONFIG_SOC_OMAP2420 | 382 | #ifdef CONFIG_SOC_OMAP2420 |
372 | void __init omap2420_init_early(void) | 383 | void __init omap2420_init_early(void) |
373 | { | 384 | { |
374 | omap2_set_globals_242x(); | 385 | omap2_set_globals_tap(OMAP242X_CLASS, OMAP2_L4_IO_ADDRESS(0x48014000)); |
386 | omap2_set_globals_sdrc(OMAP2_L3_IO_ADDRESS(OMAP2420_SDRC_BASE), | ||
387 | OMAP2_L3_IO_ADDRESS(OMAP2420_SMS_BASE)); | ||
388 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP242X_CTRL_BASE), | ||
389 | NULL); | ||
390 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP2420_PRM_BASE)); | ||
391 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP2420_CM_BASE), NULL); | ||
375 | omap2xxx_check_revision(); | 392 | omap2xxx_check_revision(); |
393 | omap2xxx_prm_init(); | ||
394 | omap2xxx_cm_init(); | ||
376 | omap2xxx_voltagedomains_init(); | 395 | omap2xxx_voltagedomains_init(); |
377 | omap242x_powerdomains_init(); | 396 | omap242x_powerdomains_init(); |
378 | omap242x_clockdomains_init(); | 397 | omap242x_clockdomains_init(); |
@@ -386,14 +405,23 @@ void __init omap2420_init_late(void) | |||
386 | omap_mux_late_init(); | 405 | omap_mux_late_init(); |
387 | omap2_common_pm_late_init(); | 406 | omap2_common_pm_late_init(); |
388 | omap2_pm_init(); | 407 | omap2_pm_init(); |
408 | omap2_clk_enable_autoidle_all(); | ||
389 | } | 409 | } |
390 | #endif | 410 | #endif |
391 | 411 | ||
392 | #ifdef CONFIG_SOC_OMAP2430 | 412 | #ifdef CONFIG_SOC_OMAP2430 |
393 | void __init omap2430_init_early(void) | 413 | void __init omap2430_init_early(void) |
394 | { | 414 | { |
395 | omap2_set_globals_243x(); | 415 | omap2_set_globals_tap(OMAP243X_CLASS, OMAP2_L4_IO_ADDRESS(0x4900a000)); |
416 | omap2_set_globals_sdrc(OMAP2_L3_IO_ADDRESS(OMAP243X_SDRC_BASE), | ||
417 | OMAP2_L3_IO_ADDRESS(OMAP243X_SMS_BASE)); | ||
418 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP243X_CTRL_BASE), | ||
419 | NULL); | ||
420 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP2430_PRM_BASE)); | ||
421 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP2430_CM_BASE), NULL); | ||
396 | omap2xxx_check_revision(); | 422 | omap2xxx_check_revision(); |
423 | omap2xxx_prm_init(); | ||
424 | omap2xxx_cm_init(); | ||
397 | omap2xxx_voltagedomains_init(); | 425 | omap2xxx_voltagedomains_init(); |
398 | omap243x_powerdomains_init(); | 426 | omap243x_powerdomains_init(); |
399 | omap243x_clockdomains_init(); | 427 | omap243x_clockdomains_init(); |
@@ -407,6 +435,7 @@ void __init omap2430_init_late(void) | |||
407 | omap_mux_late_init(); | 435 | omap_mux_late_init(); |
408 | omap2_common_pm_late_init(); | 436 | omap2_common_pm_late_init(); |
409 | omap2_pm_init(); | 437 | omap2_pm_init(); |
438 | omap2_clk_enable_autoidle_all(); | ||
410 | } | 439 | } |
411 | #endif | 440 | #endif |
412 | 441 | ||
@@ -417,9 +446,17 @@ void __init omap2430_init_late(void) | |||
417 | #ifdef CONFIG_ARCH_OMAP3 | 446 | #ifdef CONFIG_ARCH_OMAP3 |
418 | void __init omap3_init_early(void) | 447 | void __init omap3_init_early(void) |
419 | { | 448 | { |
420 | omap2_set_globals_3xxx(); | 449 | omap2_set_globals_tap(OMAP343X_CLASS, OMAP2_L4_IO_ADDRESS(0x4830A000)); |
450 | omap2_set_globals_sdrc(OMAP2_L3_IO_ADDRESS(OMAP343X_SDRC_BASE), | ||
451 | OMAP2_L3_IO_ADDRESS(OMAP343X_SMS_BASE)); | ||
452 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP343X_CTRL_BASE), | ||
453 | NULL); | ||
454 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP3430_PRM_BASE)); | ||
455 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP3430_CM_BASE), NULL); | ||
421 | omap3xxx_check_revision(); | 456 | omap3xxx_check_revision(); |
422 | omap3xxx_check_features(); | 457 | omap3xxx_check_features(); |
458 | omap3xxx_prm_init(); | ||
459 | omap3xxx_cm_init(); | ||
423 | omap3xxx_voltagedomains_init(); | 460 | omap3xxx_voltagedomains_init(); |
424 | omap3xxx_powerdomains_init(); | 461 | omap3xxx_powerdomains_init(); |
425 | omap3xxx_clockdomains_init(); | 462 | omap3xxx_clockdomains_init(); |
@@ -450,7 +487,12 @@ void __init am35xx_init_early(void) | |||
450 | 487 | ||
451 | void __init ti81xx_init_early(void) | 488 | void __init ti81xx_init_early(void) |
452 | { | 489 | { |
453 | omap2_set_globals_ti81xx(); | 490 | omap2_set_globals_tap(OMAP343X_CLASS, |
491 | OMAP2_L4_IO_ADDRESS(TI81XX_TAP_BASE)); | ||
492 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(TI81XX_CTRL_BASE), | ||
493 | NULL); | ||
494 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(TI81XX_PRCM_BASE)); | ||
495 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(TI81XX_PRCM_BASE), NULL); | ||
454 | omap3xxx_check_revision(); | 496 | omap3xxx_check_revision(); |
455 | ti81xx_check_features(); | 497 | ti81xx_check_features(); |
456 | omap3xxx_voltagedomains_init(); | 498 | omap3xxx_voltagedomains_init(); |
@@ -466,6 +508,7 @@ void __init omap3_init_late(void) | |||
466 | omap_mux_late_init(); | 508 | omap_mux_late_init(); |
467 | omap2_common_pm_late_init(); | 509 | omap2_common_pm_late_init(); |
468 | omap3_pm_init(); | 510 | omap3_pm_init(); |
511 | omap2_clk_enable_autoidle_all(); | ||
469 | } | 512 | } |
470 | 513 | ||
471 | void __init omap3430_init_late(void) | 514 | void __init omap3430_init_late(void) |
@@ -473,6 +516,7 @@ void __init omap3430_init_late(void) | |||
473 | omap_mux_late_init(); | 516 | omap_mux_late_init(); |
474 | omap2_common_pm_late_init(); | 517 | omap2_common_pm_late_init(); |
475 | omap3_pm_init(); | 518 | omap3_pm_init(); |
519 | omap2_clk_enable_autoidle_all(); | ||
476 | } | 520 | } |
477 | 521 | ||
478 | void __init omap35xx_init_late(void) | 522 | void __init omap35xx_init_late(void) |
@@ -480,6 +524,7 @@ void __init omap35xx_init_late(void) | |||
480 | omap_mux_late_init(); | 524 | omap_mux_late_init(); |
481 | omap2_common_pm_late_init(); | 525 | omap2_common_pm_late_init(); |
482 | omap3_pm_init(); | 526 | omap3_pm_init(); |
527 | omap2_clk_enable_autoidle_all(); | ||
483 | } | 528 | } |
484 | 529 | ||
485 | void __init omap3630_init_late(void) | 530 | void __init omap3630_init_late(void) |
@@ -487,6 +532,7 @@ void __init omap3630_init_late(void) | |||
487 | omap_mux_late_init(); | 532 | omap_mux_late_init(); |
488 | omap2_common_pm_late_init(); | 533 | omap2_common_pm_late_init(); |
489 | omap3_pm_init(); | 534 | omap3_pm_init(); |
535 | omap2_clk_enable_autoidle_all(); | ||
490 | } | 536 | } |
491 | 537 | ||
492 | void __init am35xx_init_late(void) | 538 | void __init am35xx_init_late(void) |
@@ -494,6 +540,7 @@ void __init am35xx_init_late(void) | |||
494 | omap_mux_late_init(); | 540 | omap_mux_late_init(); |
495 | omap2_common_pm_late_init(); | 541 | omap2_common_pm_late_init(); |
496 | omap3_pm_init(); | 542 | omap3_pm_init(); |
543 | omap2_clk_enable_autoidle_all(); | ||
497 | } | 544 | } |
498 | 545 | ||
499 | void __init ti81xx_init_late(void) | 546 | void __init ti81xx_init_late(void) |
@@ -501,13 +548,19 @@ void __init ti81xx_init_late(void) | |||
501 | omap_mux_late_init(); | 548 | omap_mux_late_init(); |
502 | omap2_common_pm_late_init(); | 549 | omap2_common_pm_late_init(); |
503 | omap3_pm_init(); | 550 | omap3_pm_init(); |
551 | omap2_clk_enable_autoidle_all(); | ||
504 | } | 552 | } |
505 | #endif | 553 | #endif |
506 | 554 | ||
507 | #ifdef CONFIG_SOC_AM33XX | 555 | #ifdef CONFIG_SOC_AM33XX |
508 | void __init am33xx_init_early(void) | 556 | void __init am33xx_init_early(void) |
509 | { | 557 | { |
510 | omap2_set_globals_am33xx(); | 558 | omap2_set_globals_tap(AM335X_CLASS, |
559 | AM33XX_L4_WK_IO_ADDRESS(AM33XX_TAP_BASE)); | ||
560 | omap2_set_globals_control(AM33XX_L4_WK_IO_ADDRESS(AM33XX_CTRL_BASE), | ||
561 | NULL); | ||
562 | omap2_set_globals_prm(AM33XX_L4_WK_IO_ADDRESS(AM33XX_PRCM_BASE)); | ||
563 | omap2_set_globals_cm(AM33XX_L4_WK_IO_ADDRESS(AM33XX_PRCM_BASE), NULL); | ||
511 | omap3xxx_check_revision(); | 564 | omap3xxx_check_revision(); |
512 | ti81xx_check_features(); | 565 | ti81xx_check_features(); |
513 | am33xx_voltagedomains_init(); | 566 | am33xx_voltagedomains_init(); |
@@ -522,9 +575,19 @@ void __init am33xx_init_early(void) | |||
522 | #ifdef CONFIG_ARCH_OMAP4 | 575 | #ifdef CONFIG_ARCH_OMAP4 |
523 | void __init omap4430_init_early(void) | 576 | void __init omap4430_init_early(void) |
524 | { | 577 | { |
525 | omap2_set_globals_443x(); | 578 | omap2_set_globals_tap(OMAP443X_CLASS, |
579 | OMAP2_L4_IO_ADDRESS(OMAP443X_SCM_BASE)); | ||
580 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP443X_SCM_BASE), | ||
581 | OMAP2_L4_IO_ADDRESS(OMAP443X_CTRL_BASE)); | ||
582 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP4430_PRM_BASE)); | ||
583 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP4430_CM_BASE), | ||
584 | OMAP2_L4_IO_ADDRESS(OMAP4430_CM2_BASE)); | ||
585 | omap2_set_globals_prcm_mpu(OMAP2_L4_IO_ADDRESS(OMAP4430_PRCM_MPU_BASE)); | ||
586 | omap_prm_base_init(); | ||
587 | omap_cm_base_init(); | ||
526 | omap4xxx_check_revision(); | 588 | omap4xxx_check_revision(); |
527 | omap4xxx_check_features(); | 589 | omap4xxx_check_features(); |
590 | omap44xx_prm_init(); | ||
528 | omap44xx_voltagedomains_init(); | 591 | omap44xx_voltagedomains_init(); |
529 | omap44xx_powerdomains_init(); | 592 | omap44xx_powerdomains_init(); |
530 | omap44xx_clockdomains_init(); | 593 | omap44xx_clockdomains_init(); |
@@ -538,13 +601,23 @@ void __init omap4430_init_late(void) | |||
538 | omap_mux_late_init(); | 601 | omap_mux_late_init(); |
539 | omap2_common_pm_late_init(); | 602 | omap2_common_pm_late_init(); |
540 | omap4_pm_init(); | 603 | omap4_pm_init(); |
604 | omap2_clk_enable_autoidle_all(); | ||
541 | } | 605 | } |
542 | #endif | 606 | #endif |
543 | 607 | ||
544 | #ifdef CONFIG_SOC_OMAP5 | 608 | #ifdef CONFIG_SOC_OMAP5 |
545 | void __init omap5_init_early(void) | 609 | void __init omap5_init_early(void) |
546 | { | 610 | { |
547 | omap2_set_globals_5xxx(); | 611 | omap2_set_globals_tap(OMAP54XX_CLASS, |
612 | OMAP2_L4_IO_ADDRESS(OMAP54XX_SCM_BASE)); | ||
613 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP54XX_SCM_BASE), | ||
614 | OMAP2_L4_IO_ADDRESS(OMAP54XX_CTRL_BASE)); | ||
615 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP54XX_PRM_BASE)); | ||
616 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP54XX_CM_CORE_AON_BASE), | ||
617 | OMAP2_L4_IO_ADDRESS(OMAP54XX_CM_CORE_BASE)); | ||
618 | omap2_set_globals_prcm_mpu(OMAP2_L4_IO_ADDRESS(OMAP54XX_PRCM_MPU_BASE)); | ||
619 | omap_prm_base_init(); | ||
620 | omap_cm_base_init(); | ||
548 | omap5xxx_check_revision(); | 621 | omap5xxx_check_revision(); |
549 | } | 622 | } |
550 | #endif | 623 | #endif |