diff options
author | Ingo Molnar <mingo@elte.hu> | 2009-02-26 07:51:40 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-02-26 07:58:26 -0500 |
commit | 1f5bcabf1b997d6b76a09114b5a79423495a1263 (patch) | |
tree | e933ed3b2f534d6014fdbaa9d8210d7d1919f7cb /arch/x86/kernel/smpboot.c | |
parent | 0917c01f8e793f57a53cf886533d4c75c67f6e89 (diff) |
x86: apic: simplify secondary CPU wakeup methods
Impact: cleanup
- rename apic->wakeup_cpu to apic->wakeup_secondary_cpu, to
make it apparent that this is an SMP-only method
- handle NULL ->wakeup_secondary_cpus to mean the default INIT
wakeup sequence - this allows simplification of the APIC
driver templates.
Cc: Yinghai Lu <yinghai@kernel.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/smpboot.c')
-rw-r--r-- | arch/x86/kernel/smpboot.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c index 9b338aa03b40..249334f5080a 100644 --- a/arch/x86/kernel/smpboot.c +++ b/arch/x86/kernel/smpboot.c | |||
@@ -742,7 +742,8 @@ static void __cpuinit do_fork_idle(struct work_struct *work) | |||
742 | /* | 742 | /* |
743 | * NOTE - on most systems this is a PHYSICAL apic ID, but on multiquad | 743 | * NOTE - on most systems this is a PHYSICAL apic ID, but on multiquad |
744 | * (ie clustered apic addressing mode), this is a LOGICAL apic ID. | 744 | * (ie clustered apic addressing mode), this is a LOGICAL apic ID. |
745 | * Returns zero if CPU booted OK, else error code from ->wakeup_cpu. | 745 | * Returns zero if CPU booted OK, else error code from |
746 | * ->wakeup_secondary_cpu. | ||
746 | */ | 747 | */ |
747 | static int __cpuinit do_boot_cpu(int apicid, int cpu) | 748 | static int __cpuinit do_boot_cpu(int apicid, int cpu) |
748 | { | 749 | { |
@@ -829,9 +830,13 @@ do_rest: | |||
829 | } | 830 | } |
830 | 831 | ||
831 | /* | 832 | /* |
832 | * Starting actual IPI sequence... | 833 | * Kick the secondary CPU. Use the method in the APIC driver |
834 | * if it's defined - or use an INIT boot APIC message otherwise: | ||
833 | */ | 835 | */ |
834 | boot_error = apic->wakeup_cpu(apicid, start_ip); | 836 | if (apic->wakeup_secondary_cpu) |
837 | boot_error = apic->wakeup_secondary_cpu(apicid, start_ip); | ||
838 | else | ||
839 | boot_error = wakeup_secondary_cpu_via_init(apicid, start_ip); | ||
835 | 840 | ||
836 | if (!boot_error) { | 841 | if (!boot_error) { |
837 | /* | 842 | /* |