diff options
Diffstat (limited to 'arch/ppc64/kernel/setup.c')
| -rw-r--r-- | arch/ppc64/kernel/setup.c | 30 |
1 files changed, 11 insertions, 19 deletions
diff --git a/arch/ppc64/kernel/setup.c b/arch/ppc64/kernel/setup.c index 5ac48bd64891..776b55b45e1b 100644 --- a/arch/ppc64/kernel/setup.c +++ b/arch/ppc64/kernel/setup.c | |||
| @@ -58,6 +58,7 @@ | |||
| 58 | #include <asm/mmu.h> | 58 | #include <asm/mmu.h> |
| 59 | #include <asm/lmb.h> | 59 | #include <asm/lmb.h> |
| 60 | #include <asm/iSeries/ItLpNaca.h> | 60 | #include <asm/iSeries/ItLpNaca.h> |
| 61 | #include <asm/firmware.h> | ||
| 61 | 62 | ||
| 62 | #ifdef DEBUG | 63 | #ifdef DEBUG |
| 63 | #define DBG(fmt...) udbg_printf(fmt) | 64 | #define DBG(fmt...) udbg_printf(fmt) |
| @@ -153,7 +154,7 @@ struct screen_info screen_info = { | |||
| 153 | .orig_video_points = 16 | 154 | .orig_video_points = 16 |
| 154 | }; | 155 | }; |
| 155 | 156 | ||
| 156 | #if defined(CONFIG_PPC_MULTIPLATFORM) && defined(CONFIG_SMP) | 157 | #ifdef CONFIG_SMP |
| 157 | 158 | ||
| 158 | static int smt_enabled_cmdline; | 159 | static int smt_enabled_cmdline; |
| 159 | 160 | ||
| @@ -306,15 +307,13 @@ static void __init setup_cpu_maps(void) | |||
| 306 | 307 | ||
| 307 | systemcfg->processorCount = num_present_cpus(); | 308 | systemcfg->processorCount = num_present_cpus(); |
| 308 | } | 309 | } |
| 309 | #endif /* defined(CONFIG_PPC_MULTIPLATFORM) && defined(CONFIG_SMP) */ | 310 | #endif /* CONFIG_SMP */ |
| 310 | |||
| 311 | |||
| 312 | #ifdef CONFIG_PPC_MULTIPLATFORM | ||
| 313 | 311 | ||
| 314 | extern struct machdep_calls pSeries_md; | 312 | extern struct machdep_calls pSeries_md; |
| 315 | extern struct machdep_calls pmac_md; | 313 | extern struct machdep_calls pmac_md; |
| 316 | extern struct machdep_calls maple_md; | 314 | extern struct machdep_calls maple_md; |
| 317 | extern struct machdep_calls bpa_md; | 315 | extern struct machdep_calls bpa_md; |
| 316 | extern struct machdep_calls iseries_md; | ||
| 318 | 317 | ||
| 319 | /* Ultimately, stuff them in an elf section like initcalls... */ | 318 | /* Ultimately, stuff them in an elf section like initcalls... */ |
| 320 | static struct machdep_calls __initdata *machines[] = { | 319 | static struct machdep_calls __initdata *machines[] = { |
| @@ -330,6 +329,9 @@ static struct machdep_calls __initdata *machines[] = { | |||
| 330 | #ifdef CONFIG_PPC_BPA | 329 | #ifdef CONFIG_PPC_BPA |
| 331 | &bpa_md, | 330 | &bpa_md, |
| 332 | #endif | 331 | #endif |
| 332 | #ifdef CONFIG_PPC_ISERIES | ||
| 333 | &iseries_md, | ||
| 334 | #endif | ||
| 333 | NULL | 335 | NULL |
| 334 | }; | 336 | }; |
| 335 | 337 | ||
| @@ -401,7 +403,8 @@ void __init early_setup(unsigned long dt_ptr) | |||
| 401 | /* | 403 | /* |
| 402 | * Initialize stab / SLB management | 404 | * Initialize stab / SLB management |
| 403 | */ | 405 | */ |
| 404 | stab_initialize(lpaca->stab_real); | 406 | if (!firmware_has_feature(FW_FEATURE_ISERIES)) |
| 407 | stab_initialize(lpaca->stab_real); | ||
| 405 | 408 | ||
| 406 | /* | 409 | /* |
| 407 | * Initialize the MMU Hash table and create the linear mapping | 410 | * Initialize the MMU Hash table and create the linear mapping |
| @@ -532,8 +535,6 @@ static void __init check_for_initrd(void) | |||
| 532 | #endif /* CONFIG_BLK_DEV_INITRD */ | 535 | #endif /* CONFIG_BLK_DEV_INITRD */ |
| 533 | } | 536 | } |
| 534 | 537 | ||
| 535 | #endif /* CONFIG_PPC_MULTIPLATFORM */ | ||
| 536 | |||
| 537 | /* | 538 | /* |
| 538 | * Do some initial setup of the system. The parameters are those which | 539 | * Do some initial setup of the system. The parameters are those which |
| 539 | * were passed in from the bootloader. | 540 | * were passed in from the bootloader. |
| @@ -542,14 +543,6 @@ void __init setup_system(void) | |||
| 542 | { | 543 | { |
| 543 | DBG(" -> setup_system()\n"); | 544 | DBG(" -> setup_system()\n"); |
| 544 | 545 | ||
| 545 | #ifdef CONFIG_PPC_ISERIES | ||
| 546 | /* pSeries systems are identified in prom.c via OF. */ | ||
| 547 | if (itLpNaca.xLparInstalled == 1) | ||
| 548 | systemcfg->platform = PLATFORM_ISERIES_LPAR; | ||
| 549 | |||
| 550 | ppc_md.init_early(); | ||
| 551 | #else /* CONFIG_PPC_ISERIES */ | ||
| 552 | |||
| 553 | /* | 546 | /* |
| 554 | * Unflatten the device-tree passed by prom_init or kexec | 547 | * Unflatten the device-tree passed by prom_init or kexec |
| 555 | */ | 548 | */ |
| @@ -607,9 +600,8 @@ void __init setup_system(void) | |||
| 607 | strlcpy(saved_command_line, cmd_line, COMMAND_LINE_SIZE); | 600 | strlcpy(saved_command_line, cmd_line, COMMAND_LINE_SIZE); |
| 608 | 601 | ||
| 609 | parse_early_param(); | 602 | parse_early_param(); |
| 610 | #endif /* !CONFIG_PPC_ISERIES */ | ||
| 611 | 603 | ||
| 612 | #if defined(CONFIG_SMP) && !defined(CONFIG_PPC_ISERIES) | 604 | #ifdef CONFIG_SMP |
| 613 | /* | 605 | /* |
| 614 | * iSeries has already initialized the cpu maps at this point. | 606 | * iSeries has already initialized the cpu maps at this point. |
| 615 | */ | 607 | */ |
| @@ -619,7 +611,7 @@ void __init setup_system(void) | |||
| 619 | * we can map physical -> logical CPU ids | 611 | * we can map physical -> logical CPU ids |
| 620 | */ | 612 | */ |
| 621 | smp_release_cpus(); | 613 | smp_release_cpus(); |
| 622 | #endif /* defined(CONFIG_SMP) && !defined(CONFIG_PPC_ISERIES) */ | 614 | #endif |
| 623 | 615 | ||
| 624 | printk("Starting Linux PPC64 %s\n", system_utsname.version); | 616 | printk("Starting Linux PPC64 %s\n", system_utsname.version); |
| 625 | 617 | ||
