diff options
author | Grant Likely <grant.likely@secretlab.ca> | 2008-01-02 14:14:28 -0500 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2008-01-16 22:57:14 -0500 |
commit | d518b71784c6fa4c8eafb334236883f763f8e296 (patch) | |
tree | a2d941c07b285d0d947fdc1739680d7772e6a722 /arch/powerpc/platforms/powermac/setup.c | |
parent | 97759e494e2bfccc23ffc7b236196cb5c1703e2e (diff) |
[POWERPC] powermac: Use machine_*_initcall() hooks in platform code
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/platforms/powermac/setup.c')
-rw-r--r-- | arch/powerpc/platforms/powermac/setup.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/arch/powerpc/platforms/powermac/setup.c b/arch/powerpc/platforms/powermac/setup.c index adad4e976381..36ff1b6b7fac 100644 --- a/arch/powerpc/platforms/powermac/setup.c +++ b/arch/powerpc/platforms/powermac/setup.c | |||
@@ -397,17 +397,13 @@ static int initializing = 1; | |||
397 | 397 | ||
398 | static int pmac_late_init(void) | 398 | static int pmac_late_init(void) |
399 | { | 399 | { |
400 | if (!machine_is(powermac)) | ||
401 | return -ENODEV; | ||
402 | |||
403 | initializing = 0; | 400 | initializing = 0; |
404 | /* this is udbg (which is __init) and we can later use it during | 401 | /* this is udbg (which is __init) and we can later use it during |
405 | * cpu hotplug (in smp_core99_kick_cpu) */ | 402 | * cpu hotplug (in smp_core99_kick_cpu) */ |
406 | ppc_md.progress = NULL; | 403 | ppc_md.progress = NULL; |
407 | return 0; | 404 | return 0; |
408 | } | 405 | } |
409 | 406 | machine_late_initcall(powermac, pmac_late_init); | |
410 | late_initcall(pmac_late_init); | ||
411 | 407 | ||
412 | /* | 408 | /* |
413 | * This is __init_refok because we check for "initializing" before | 409 | * This is __init_refok because we check for "initializing" before |
@@ -534,9 +530,6 @@ static int __init pmac_declare_of_platform_devices(void) | |||
534 | if (machine_is(chrp)) | 530 | if (machine_is(chrp)) |
535 | return -1; | 531 | return -1; |
536 | 532 | ||
537 | if (!machine_is(powermac)) | ||
538 | return 0; | ||
539 | |||
540 | np = of_find_node_by_name(NULL, "valkyrie"); | 533 | np = of_find_node_by_name(NULL, "valkyrie"); |
541 | if (np) | 534 | if (np) |
542 | of_platform_device_create(np, "valkyrie", NULL); | 535 | of_platform_device_create(np, "valkyrie", NULL); |
@@ -551,8 +544,7 @@ static int __init pmac_declare_of_platform_devices(void) | |||
551 | 544 | ||
552 | return 0; | 545 | return 0; |
553 | } | 546 | } |
554 | 547 | machine_device_initcall(powermac, pmac_declare_of_platform_devices); | |
555 | device_initcall(pmac_declare_of_platform_devices); | ||
556 | 548 | ||
557 | /* | 549 | /* |
558 | * Called very early, MMU is off, device-tree isn't unflattened | 550 | * Called very early, MMU is off, device-tree isn't unflattened |