diff options
Diffstat (limited to 'arch/arm/mach-omap2/io.c')
| -rw-r--r-- | arch/arm/mach-omap2/io.c | 85 |
1 files changed, 71 insertions, 14 deletions
diff --git a/arch/arm/mach-omap2/io.c b/arch/arm/mach-omap2/io.c index 807b8d919f81..9df757644cce 100644 --- a/arch/arm/mach-omap2/io.c +++ b/arch/arm/mach-omap2/io.c | |||
| @@ -40,8 +40,16 @@ | |||
| 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" | ||
| 45 | 53 | ||
| 46 | /* | 54 | /* |
| 47 | * The machine specific code may provide the extra mapping besides the | 55 | * The machine specific code may provide the extra mapping besides the |
| @@ -264,7 +272,7 @@ static struct map_desc omap54xx_io_desc[] __initdata = { | |||
| 264 | #endif | 272 | #endif |
| 265 | 273 | ||
| 266 | #ifdef CONFIG_SOC_OMAP2420 | 274 | #ifdef CONFIG_SOC_OMAP2420 |
| 267 | void __init omap242x_map_common_io(void) | 275 | void __init omap242x_map_io(void) |
| 268 | { | 276 | { |
| 269 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); | 277 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); |
| 270 | iotable_init(omap242x_io_desc, ARRAY_SIZE(omap242x_io_desc)); | 278 | iotable_init(omap242x_io_desc, ARRAY_SIZE(omap242x_io_desc)); |
| @@ -272,7 +280,7 @@ void __init omap242x_map_common_io(void) | |||
| 272 | #endif | 280 | #endif |
| 273 | 281 | ||
| 274 | #ifdef CONFIG_SOC_OMAP2430 | 282 | #ifdef CONFIG_SOC_OMAP2430 |
| 275 | void __init omap243x_map_common_io(void) | 283 | void __init omap243x_map_io(void) |
| 276 | { | 284 | { |
| 277 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); | 285 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); |
| 278 | iotable_init(omap243x_io_desc, ARRAY_SIZE(omap243x_io_desc)); | 286 | iotable_init(omap243x_io_desc, ARRAY_SIZE(omap243x_io_desc)); |
| @@ -280,28 +288,28 @@ void __init omap243x_map_common_io(void) | |||
| 280 | #endif | 288 | #endif |
| 281 | 289 | ||
| 282 | #ifdef CONFIG_ARCH_OMAP3 | 290 | #ifdef CONFIG_ARCH_OMAP3 |
| 283 | void __init omap34xx_map_common_io(void) | 291 | void __init omap3_map_io(void) |
| 284 | { | 292 | { |
| 285 | iotable_init(omap34xx_io_desc, ARRAY_SIZE(omap34xx_io_desc)); | 293 | iotable_init(omap34xx_io_desc, ARRAY_SIZE(omap34xx_io_desc)); |
| 286 | } | 294 | } |
| 287 | #endif | 295 | #endif |
| 288 | 296 | ||
| 289 | #ifdef CONFIG_SOC_TI81XX | 297 | #ifdef CONFIG_SOC_TI81XX |
| 290 | void __init omapti81xx_map_common_io(void) | 298 | void __init ti81xx_map_io(void) |
| 291 | { | 299 | { |
| 292 | iotable_init(omapti81xx_io_desc, ARRAY_SIZE(omapti81xx_io_desc)); | 300 | iotable_init(omapti81xx_io_desc, ARRAY_SIZE(omapti81xx_io_desc)); |
| 293 | } | 301 | } |
| 294 | #endif | 302 | #endif |
| 295 | 303 | ||
| 296 | #ifdef CONFIG_SOC_AM33XX | 304 | #ifdef CONFIG_SOC_AM33XX |
| 297 | void __init omapam33xx_map_common_io(void) | 305 | void __init am33xx_map_io(void) |
| 298 | { | 306 | { |
| 299 | iotable_init(omapam33xx_io_desc, ARRAY_SIZE(omapam33xx_io_desc)); | 307 | iotable_init(omapam33xx_io_desc, ARRAY_SIZE(omapam33xx_io_desc)); |
| 300 | } | 308 | } |
| 301 | #endif | 309 | #endif |
| 302 | 310 | ||
| 303 | #ifdef CONFIG_ARCH_OMAP4 | 311 | #ifdef CONFIG_ARCH_OMAP4 |
| 304 | void __init omap44xx_map_common_io(void) | 312 | void __init omap4_map_io(void) |
| 305 | { | 313 | { |
| 306 | iotable_init(omap44xx_io_desc, ARRAY_SIZE(omap44xx_io_desc)); | 314 | iotable_init(omap44xx_io_desc, ARRAY_SIZE(omap44xx_io_desc)); |
| 307 | omap_barriers_init(); | 315 | omap_barriers_init(); |
| @@ -309,7 +317,7 @@ void __init omap44xx_map_common_io(void) | |||
| 309 | #endif | 317 | #endif |
| 310 | 318 | ||
| 311 | #ifdef CONFIG_SOC_OMAP5 | 319 | #ifdef CONFIG_SOC_OMAP5 |
| 312 | void __init omap5_map_common_io(void) | 320 | void __init omap5_map_io(void) |
| 313 | { | 321 | { |
| 314 | iotable_init(omap54xx_io_desc, ARRAY_SIZE(omap54xx_io_desc)); | 322 | iotable_init(omap54xx_io_desc, ARRAY_SIZE(omap54xx_io_desc)); |
| 315 | } | 323 | } |
| @@ -371,8 +379,15 @@ static void __init omap_hwmod_init_postsetup(void) | |||
| 371 | #ifdef CONFIG_SOC_OMAP2420 | 379 | #ifdef CONFIG_SOC_OMAP2420 |
| 372 | void __init omap2420_init_early(void) | 380 | void __init omap2420_init_early(void) |
| 373 | { | 381 | { |
| 374 | omap2_set_globals_242x(); | 382 | omap2_set_globals_tap(OMAP242X_CLASS, OMAP2_L4_IO_ADDRESS(0x48014000)); |
| 383 | omap2_set_globals_sdrc(OMAP2_L3_IO_ADDRESS(OMAP2420_SDRC_BASE), | ||
| 384 | OMAP2_L3_IO_ADDRESS(OMAP2420_SMS_BASE)); | ||
| 385 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP242X_CTRL_BASE), | ||
| 386 | NULL); | ||
| 387 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP2420_PRM_BASE)); | ||
| 388 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP2420_CM_BASE), NULL); | ||
| 375 | omap2xxx_check_revision(); | 389 | omap2xxx_check_revision(); |
| 390 | omap2xxx_cm_init(); | ||
| 376 | omap2xxx_voltagedomains_init(); | 391 | omap2xxx_voltagedomains_init(); |
| 377 | omap242x_powerdomains_init(); | 392 | omap242x_powerdomains_init(); |
| 378 | omap242x_clockdomains_init(); | 393 | omap242x_clockdomains_init(); |
| @@ -392,8 +407,15 @@ void __init omap2420_init_late(void) | |||
| 392 | #ifdef CONFIG_SOC_OMAP2430 | 407 | #ifdef CONFIG_SOC_OMAP2430 |
| 393 | void __init omap2430_init_early(void) | 408 | void __init omap2430_init_early(void) |
| 394 | { | 409 | { |
| 395 | omap2_set_globals_243x(); | 410 | omap2_set_globals_tap(OMAP243X_CLASS, OMAP2_L4_IO_ADDRESS(0x4900a000)); |
| 411 | omap2_set_globals_sdrc(OMAP2_L3_IO_ADDRESS(OMAP243X_SDRC_BASE), | ||
| 412 | OMAP2_L3_IO_ADDRESS(OMAP243X_SMS_BASE)); | ||
| 413 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP243X_CTRL_BASE), | ||
| 414 | NULL); | ||
| 415 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP2430_PRM_BASE)); | ||
| 416 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP2430_CM_BASE), NULL); | ||
| 396 | omap2xxx_check_revision(); | 417 | omap2xxx_check_revision(); |
| 418 | omap2xxx_cm_init(); | ||
| 397 | omap2xxx_voltagedomains_init(); | 419 | omap2xxx_voltagedomains_init(); |
| 398 | omap243x_powerdomains_init(); | 420 | omap243x_powerdomains_init(); |
| 399 | omap243x_clockdomains_init(); | 421 | omap243x_clockdomains_init(); |
| @@ -417,9 +439,16 @@ void __init omap2430_init_late(void) | |||
| 417 | #ifdef CONFIG_ARCH_OMAP3 | 439 | #ifdef CONFIG_ARCH_OMAP3 |
| 418 | void __init omap3_init_early(void) | 440 | void __init omap3_init_early(void) |
| 419 | { | 441 | { |
| 420 | omap2_set_globals_3xxx(); | 442 | omap2_set_globals_tap(OMAP343X_CLASS, OMAP2_L4_IO_ADDRESS(0x4830A000)); |
| 443 | omap2_set_globals_sdrc(OMAP2_L3_IO_ADDRESS(OMAP343X_SDRC_BASE), | ||
| 444 | OMAP2_L3_IO_ADDRESS(OMAP343X_SMS_BASE)); | ||
| 445 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP343X_CTRL_BASE), | ||
| 446 | NULL); | ||
| 447 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP3430_PRM_BASE)); | ||
| 448 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP3430_CM_BASE), NULL); | ||
| 421 | omap3xxx_check_revision(); | 449 | omap3xxx_check_revision(); |
| 422 | omap3xxx_check_features(); | 450 | omap3xxx_check_features(); |
| 451 | omap3xxx_cm_init(); | ||
| 423 | omap3xxx_voltagedomains_init(); | 452 | omap3xxx_voltagedomains_init(); |
| 424 | omap3xxx_powerdomains_init(); | 453 | omap3xxx_powerdomains_init(); |
| 425 | omap3xxx_clockdomains_init(); | 454 | omap3xxx_clockdomains_init(); |
| @@ -450,7 +479,12 @@ void __init am35xx_init_early(void) | |||
| 450 | 479 | ||
| 451 | void __init ti81xx_init_early(void) | 480 | void __init ti81xx_init_early(void) |
| 452 | { | 481 | { |
| 453 | omap2_set_globals_ti81xx(); | 482 | omap2_set_globals_tap(OMAP343X_CLASS, |
| 483 | OMAP2_L4_IO_ADDRESS(TI81XX_TAP_BASE)); | ||
| 484 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(TI81XX_CTRL_BASE), | ||
| 485 | NULL); | ||
| 486 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(TI81XX_PRCM_BASE)); | ||
| 487 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(TI81XX_PRCM_BASE), NULL); | ||
| 454 | omap3xxx_check_revision(); | 488 | omap3xxx_check_revision(); |
| 455 | ti81xx_check_features(); | 489 | ti81xx_check_features(); |
| 456 | omap3xxx_voltagedomains_init(); | 490 | omap3xxx_voltagedomains_init(); |
| @@ -507,7 +541,12 @@ void __init ti81xx_init_late(void) | |||
| 507 | #ifdef CONFIG_SOC_AM33XX | 541 | #ifdef CONFIG_SOC_AM33XX |
| 508 | void __init am33xx_init_early(void) | 542 | void __init am33xx_init_early(void) |
| 509 | { | 543 | { |
| 510 | omap2_set_globals_am33xx(); | 544 | omap2_set_globals_tap(AM335X_CLASS, |
| 545 | AM33XX_L4_WK_IO_ADDRESS(AM33XX_TAP_BASE)); | ||
| 546 | omap2_set_globals_control(AM33XX_L4_WK_IO_ADDRESS(AM33XX_CTRL_BASE), | ||
| 547 | NULL); | ||
| 548 | omap2_set_globals_prm(AM33XX_L4_WK_IO_ADDRESS(AM33XX_PRCM_BASE)); | ||
| 549 | omap2_set_globals_cm(AM33XX_L4_WK_IO_ADDRESS(AM33XX_PRCM_BASE), NULL); | ||
| 511 | omap3xxx_check_revision(); | 550 | omap3xxx_check_revision(); |
| 512 | ti81xx_check_features(); | 551 | ti81xx_check_features(); |
| 513 | am33xx_voltagedomains_init(); | 552 | am33xx_voltagedomains_init(); |
| @@ -522,7 +561,16 @@ void __init am33xx_init_early(void) | |||
| 522 | #ifdef CONFIG_ARCH_OMAP4 | 561 | #ifdef CONFIG_ARCH_OMAP4 |
| 523 | void __init omap4430_init_early(void) | 562 | void __init omap4430_init_early(void) |
| 524 | { | 563 | { |
| 525 | omap2_set_globals_443x(); | 564 | omap2_set_globals_tap(OMAP443X_CLASS, |
| 565 | OMAP2_L4_IO_ADDRESS(OMAP443X_SCM_BASE)); | ||
| 566 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP443X_SCM_BASE), | ||
| 567 | OMAP2_L4_IO_ADDRESS(OMAP443X_CTRL_BASE)); | ||
| 568 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP4430_PRM_BASE)); | ||
| 569 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP4430_CM_BASE), | ||
| 570 | OMAP2_L4_IO_ADDRESS(OMAP4430_CM2_BASE)); | ||
| 571 | omap2_set_globals_prcm_mpu(OMAP2_L4_IO_ADDRESS(OMAP4430_PRCM_MPU_BASE)); | ||
| 572 | omap_prm_base_init(); | ||
| 573 | omap_cm_base_init(); | ||
| 526 | omap4xxx_check_revision(); | 574 | omap4xxx_check_revision(); |
| 527 | omap4xxx_check_features(); | 575 | omap4xxx_check_features(); |
| 528 | omap44xx_voltagedomains_init(); | 576 | omap44xx_voltagedomains_init(); |
| @@ -544,7 +592,16 @@ void __init omap4430_init_late(void) | |||
| 544 | #ifdef CONFIG_SOC_OMAP5 | 592 | #ifdef CONFIG_SOC_OMAP5 |
| 545 | void __init omap5_init_early(void) | 593 | void __init omap5_init_early(void) |
| 546 | { | 594 | { |
| 547 | omap2_set_globals_5xxx(); | 595 | omap2_set_globals_tap(OMAP54XX_CLASS, |
| 596 | OMAP2_L4_IO_ADDRESS(OMAP54XX_SCM_BASE)); | ||
| 597 | omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP54XX_SCM_BASE), | ||
| 598 | OMAP2_L4_IO_ADDRESS(OMAP54XX_CTRL_BASE)); | ||
| 599 | omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP54XX_PRM_BASE)); | ||
| 600 | omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP54XX_CM_CORE_AON_BASE), | ||
| 601 | OMAP2_L4_IO_ADDRESS(OMAP54XX_CM_CORE_BASE)); | ||
| 602 | omap2_set_globals_prcm_mpu(OMAP2_L4_IO_ADDRESS(OMAP54XX_PRCM_MPU_BASE)); | ||
| 603 | omap_prm_base_init(); | ||
| 604 | omap_cm_base_init(); | ||
| 548 | omap5xxx_check_revision(); | 605 | omap5xxx_check_revision(); |
| 549 | } | 606 | } |
| 550 | #endif | 607 | #endif |
