diff options
Diffstat (limited to 'arch/x86/kernel/smpboot.c')
-rw-r--r-- | arch/x86/kernel/smpboot.c | 59 |
1 files changed, 30 insertions, 29 deletions
diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c index a4f2d8f06e48..52eb1484a48a 100644 --- a/arch/x86/kernel/smpboot.c +++ b/arch/x86/kernel/smpboot.c | |||
@@ -217,7 +217,7 @@ static void __cpuinit smp_callin(void) | |||
217 | panic("%s: phys CPU#%d, CPU#%d already present??\n", __func__, | 217 | panic("%s: phys CPU#%d, CPU#%d already present??\n", __func__, |
218 | phys_id, cpuid); | 218 | phys_id, cpuid); |
219 | } | 219 | } |
220 | Dprintk("CPU#%d (phys ID: %d) waiting for CALLOUT\n", cpuid, phys_id); | 220 | pr_debug("CPU#%d (phys ID: %d) waiting for CALLOUT\n", cpuid, phys_id); |
221 | 221 | ||
222 | /* | 222 | /* |
223 | * STARTUP IPIs are fragile beasts as they might sometimes | 223 | * STARTUP IPIs are fragile beasts as they might sometimes |
@@ -252,7 +252,7 @@ static void __cpuinit smp_callin(void) | |||
252 | * boards) | 252 | * boards) |
253 | */ | 253 | */ |
254 | 254 | ||
255 | Dprintk("CALLIN, before setup_local_APIC().\n"); | 255 | pr_debug("CALLIN, before setup_local_APIC().\n"); |
256 | smp_callin_clear_local_apic(); | 256 | smp_callin_clear_local_apic(); |
257 | setup_local_APIC(); | 257 | setup_local_APIC(); |
258 | end_local_APIC_setup(); | 258 | end_local_APIC_setup(); |
@@ -267,7 +267,7 @@ static void __cpuinit smp_callin(void) | |||
267 | local_irq_enable(); | 267 | local_irq_enable(); |
268 | calibrate_delay(); | 268 | calibrate_delay(); |
269 | local_irq_disable(); | 269 | local_irq_disable(); |
270 | Dprintk("Stack at about %p\n", &cpuid); | 270 | pr_debug("Stack at about %p\n", &cpuid); |
271 | 271 | ||
272 | /* | 272 | /* |
273 | * Save our processor parameters | 273 | * Save our processor parameters |
@@ -514,7 +514,7 @@ static void impress_friends(void) | |||
514 | /* | 514 | /* |
515 | * Allow the user to impress friends. | 515 | * Allow the user to impress friends. |
516 | */ | 516 | */ |
517 | Dprintk("Before bogomips.\n"); | 517 | pr_debug("Before bogomips.\n"); |
518 | for_each_possible_cpu(cpu) | 518 | for_each_possible_cpu(cpu) |
519 | if (cpu_isset(cpu, cpu_callout_map)) | 519 | if (cpu_isset(cpu, cpu_callout_map)) |
520 | bogosum += cpu_data(cpu).loops_per_jiffy; | 520 | bogosum += cpu_data(cpu).loops_per_jiffy; |
@@ -524,7 +524,7 @@ static void impress_friends(void) | |||
524 | bogosum/(500000/HZ), | 524 | bogosum/(500000/HZ), |
525 | (bogosum/(5000/HZ))%100); | 525 | (bogosum/(5000/HZ))%100); |
526 | 526 | ||
527 | Dprintk("Before bogocount - setting activated=1.\n"); | 527 | pr_debug("Before bogocount - setting activated=1.\n"); |
528 | } | 528 | } |
529 | 529 | ||
530 | static inline void __inquire_remote_apic(int apicid) | 530 | static inline void __inquire_remote_apic(int apicid) |
@@ -583,7 +583,7 @@ wakeup_secondary_cpu(int logical_apicid, unsigned long start_eip) | |||
583 | /* Kick the second */ | 583 | /* Kick the second */ |
584 | apic_icr_write(APIC_DM_NMI | APIC_DEST_LOGICAL, logical_apicid); | 584 | apic_icr_write(APIC_DM_NMI | APIC_DEST_LOGICAL, logical_apicid); |
585 | 585 | ||
586 | Dprintk("Waiting for send to finish...\n"); | 586 | pr_debug("Waiting for send to finish...\n"); |
587 | send_status = safe_apic_wait_icr_idle(); | 587 | send_status = safe_apic_wait_icr_idle(); |
588 | 588 | ||
589 | /* | 589 | /* |
@@ -594,7 +594,7 @@ wakeup_secondary_cpu(int logical_apicid, unsigned long start_eip) | |||
594 | if (maxlvt > 3) /* Due to the Pentium erratum 3AP. */ | 594 | if (maxlvt > 3) /* Due to the Pentium erratum 3AP. */ |
595 | apic_write(APIC_ESR, 0); | 595 | apic_write(APIC_ESR, 0); |
596 | accept_status = (apic_read(APIC_ESR) & 0xEF); | 596 | accept_status = (apic_read(APIC_ESR) & 0xEF); |
597 | Dprintk("NMI sent.\n"); | 597 | pr_debug("NMI sent.\n"); |
598 | 598 | ||
599 | if (send_status) | 599 | if (send_status) |
600 | printk(KERN_ERR "APIC never delivered???\n"); | 600 | printk(KERN_ERR "APIC never delivered???\n"); |
@@ -629,7 +629,7 @@ wakeup_secondary_cpu(int phys_apicid, unsigned long start_eip) | |||
629 | apic_read(APIC_ESR); | 629 | apic_read(APIC_ESR); |
630 | } | 630 | } |
631 | 631 | ||
632 | Dprintk("Asserting INIT.\n"); | 632 | pr_debug("Asserting INIT.\n"); |
633 | 633 | ||
634 | /* | 634 | /* |
635 | * Turn INIT on target chip | 635 | * Turn INIT on target chip |
@@ -640,18 +640,18 @@ wakeup_secondary_cpu(int phys_apicid, unsigned long start_eip) | |||
640 | apic_icr_write(APIC_INT_LEVELTRIG | APIC_INT_ASSERT | APIC_DM_INIT, | 640 | apic_icr_write(APIC_INT_LEVELTRIG | APIC_INT_ASSERT | APIC_DM_INIT, |
641 | phys_apicid); | 641 | phys_apicid); |
642 | 642 | ||
643 | Dprintk("Waiting for send to finish...\n"); | 643 | pr_debug("Waiting for send to finish...\n"); |
644 | send_status = safe_apic_wait_icr_idle(); | 644 | send_status = safe_apic_wait_icr_idle(); |
645 | 645 | ||
646 | mdelay(10); | 646 | mdelay(10); |
647 | 647 | ||
648 | Dprintk("Deasserting INIT.\n"); | 648 | pr_debug("Deasserting INIT.\n"); |
649 | 649 | ||
650 | /* Target chip */ | 650 | /* Target chip */ |
651 | /* Send IPI */ | 651 | /* Send IPI */ |
652 | apic_icr_write(APIC_INT_LEVELTRIG | APIC_DM_INIT, phys_apicid); | 652 | apic_icr_write(APIC_INT_LEVELTRIG | APIC_DM_INIT, phys_apicid); |
653 | 653 | ||
654 | Dprintk("Waiting for send to finish...\n"); | 654 | pr_debug("Waiting for send to finish...\n"); |
655 | send_status = safe_apic_wait_icr_idle(); | 655 | send_status = safe_apic_wait_icr_idle(); |
656 | 656 | ||
657 | mb(); | 657 | mb(); |
@@ -678,14 +678,14 @@ wakeup_secondary_cpu(int phys_apicid, unsigned long start_eip) | |||
678 | /* | 678 | /* |
679 | * Run STARTUP IPI loop. | 679 | * Run STARTUP IPI loop. |
680 | */ | 680 | */ |
681 | Dprintk("#startup loops: %d.\n", num_starts); | 681 | pr_debug("#startup loops: %d.\n", num_starts); |
682 | 682 | ||
683 | for (j = 1; j <= num_starts; j++) { | 683 | for (j = 1; j <= num_starts; j++) { |
684 | Dprintk("Sending STARTUP #%d.\n", j); | 684 | pr_debug("Sending STARTUP #%d.\n", j); |
685 | if (maxlvt > 3) /* Due to the Pentium erratum 3AP. */ | 685 | if (maxlvt > 3) /* Due to the Pentium erratum 3AP. */ |
686 | apic_write(APIC_ESR, 0); | 686 | apic_write(APIC_ESR, 0); |
687 | apic_read(APIC_ESR); | 687 | apic_read(APIC_ESR); |
688 | Dprintk("After apic_write.\n"); | 688 | pr_debug("After apic_write.\n"); |
689 | 689 | ||
690 | /* | 690 | /* |
691 | * STARTUP IPI | 691 | * STARTUP IPI |
@@ -702,9 +702,9 @@ wakeup_secondary_cpu(int phys_apicid, unsigned long start_eip) | |||
702 | */ | 702 | */ |
703 | udelay(300); | 703 | udelay(300); |
704 | 704 | ||
705 | Dprintk("Startup point 1.\n"); | 705 | pr_debug("Startup point 1.\n"); |
706 | 706 | ||
707 | Dprintk("Waiting for send to finish...\n"); | 707 | pr_debug("Waiting for send to finish...\n"); |
708 | send_status = safe_apic_wait_icr_idle(); | 708 | send_status = safe_apic_wait_icr_idle(); |
709 | 709 | ||
710 | /* | 710 | /* |
@@ -717,7 +717,7 @@ wakeup_secondary_cpu(int phys_apicid, unsigned long start_eip) | |||
717 | if (send_status || accept_status) | 717 | if (send_status || accept_status) |
718 | break; | 718 | break; |
719 | } | 719 | } |
720 | Dprintk("After Startup.\n"); | 720 | pr_debug("After Startup.\n"); |
721 | 721 | ||
722 | if (send_status) | 722 | if (send_status) |
723 | printk(KERN_ERR "APIC never delivered???\n"); | 723 | printk(KERN_ERR "APIC never delivered???\n"); |
@@ -750,7 +750,7 @@ static void __cpuinit do_fork_idle(struct work_struct *work) | |||
750 | * | 750 | * |
751 | * Must be called after the _cpu_pda pointer table is initialized. | 751 | * Must be called after the _cpu_pda pointer table is initialized. |
752 | */ | 752 | */ |
753 | static int __cpuinit get_local_pda(int cpu) | 753 | int __cpuinit get_local_pda(int cpu) |
754 | { | 754 | { |
755 | struct x8664_pda *oldpda, *newpda; | 755 | struct x8664_pda *oldpda, *newpda; |
756 | unsigned long size = sizeof(struct x8664_pda); | 756 | unsigned long size = sizeof(struct x8664_pda); |
@@ -868,7 +868,7 @@ do_rest: | |||
868 | 868 | ||
869 | if (get_uv_system_type() != UV_NON_UNIQUE_APIC) { | 869 | if (get_uv_system_type() != UV_NON_UNIQUE_APIC) { |
870 | 870 | ||
871 | Dprintk("Setting warm reset code and vector.\n"); | 871 | pr_debug("Setting warm reset code and vector.\n"); |
872 | 872 | ||
873 | store_NMI_vector(&nmi_high, &nmi_low); | 873 | store_NMI_vector(&nmi_high, &nmi_low); |
874 | 874 | ||
@@ -889,9 +889,9 @@ do_rest: | |||
889 | /* | 889 | /* |
890 | * allow APs to start initializing. | 890 | * allow APs to start initializing. |
891 | */ | 891 | */ |
892 | Dprintk("Before Callout %d.\n", cpu); | 892 | pr_debug("Before Callout %d.\n", cpu); |
893 | cpu_set(cpu, cpu_callout_map); | 893 | cpu_set(cpu, cpu_callout_map); |
894 | Dprintk("After Callout %d.\n", cpu); | 894 | pr_debug("After Callout %d.\n", cpu); |
895 | 895 | ||
896 | /* | 896 | /* |
897 | * Wait 5s total for a response | 897 | * Wait 5s total for a response |
@@ -904,10 +904,10 @@ do_rest: | |||
904 | 904 | ||
905 | if (cpu_isset(cpu, cpu_callin_map)) { | 905 | if (cpu_isset(cpu, cpu_callin_map)) { |
906 | /* number CPUs logically, starting from 1 (BSP is 0) */ | 906 | /* number CPUs logically, starting from 1 (BSP is 0) */ |
907 | Dprintk("OK.\n"); | 907 | pr_debug("OK.\n"); |
908 | printk(KERN_INFO "CPU%d: ", cpu); | 908 | printk(KERN_INFO "CPU%d: ", cpu); |
909 | print_cpu_info(&cpu_data(cpu)); | 909 | print_cpu_info(&cpu_data(cpu)); |
910 | Dprintk("CPU has booted.\n"); | 910 | pr_debug("CPU has booted.\n"); |
911 | } else { | 911 | } else { |
912 | boot_error = 1; | 912 | boot_error = 1; |
913 | if (*((volatile unsigned char *)trampoline_base) | 913 | if (*((volatile unsigned char *)trampoline_base) |
@@ -952,7 +952,7 @@ int __cpuinit native_cpu_up(unsigned int cpu) | |||
952 | 952 | ||
953 | WARN_ON(irqs_disabled()); | 953 | WARN_ON(irqs_disabled()); |
954 | 954 | ||
955 | Dprintk("++++++++++++++++++++=_---CPU UP %u\n", cpu); | 955 | pr_debug("++++++++++++++++++++=_---CPU UP %u\n", cpu); |
956 | 956 | ||
957 | if (apicid == BAD_APICID || apicid == boot_cpu_physical_apicid || | 957 | if (apicid == BAD_APICID || apicid == boot_cpu_physical_apicid || |
958 | !physid_isset(apicid, phys_cpu_present_map)) { | 958 | !physid_isset(apicid, phys_cpu_present_map)) { |
@@ -964,7 +964,7 @@ int __cpuinit native_cpu_up(unsigned int cpu) | |||
964 | * Already booted CPU? | 964 | * Already booted CPU? |
965 | */ | 965 | */ |
966 | if (cpu_isset(cpu, cpu_callin_map)) { | 966 | if (cpu_isset(cpu, cpu_callin_map)) { |
967 | Dprintk("do_boot_cpu %d Already started\n", cpu); | 967 | pr_debug("do_boot_cpu %d Already started\n", cpu); |
968 | return -ENOSYS; | 968 | return -ENOSYS; |
969 | } | 969 | } |
970 | 970 | ||
@@ -991,7 +991,7 @@ int __cpuinit native_cpu_up(unsigned int cpu) | |||
991 | err = do_boot_cpu(apicid, cpu); | 991 | err = do_boot_cpu(apicid, cpu); |
992 | #endif | 992 | #endif |
993 | if (err) { | 993 | if (err) { |
994 | Dprintk("do_boot_cpu failed %d\n", err); | 994 | pr_debug("do_boot_cpu failed %d\n", err); |
995 | return -EIO; | 995 | return -EIO; |
996 | } | 996 | } |
997 | 997 | ||
@@ -1202,7 +1202,7 @@ void __init native_smp_prepare_boot_cpu(void) | |||
1202 | 1202 | ||
1203 | void __init native_smp_cpus_done(unsigned int max_cpus) | 1203 | void __init native_smp_cpus_done(unsigned int max_cpus) |
1204 | { | 1204 | { |
1205 | Dprintk("Boot done.\n"); | 1205 | pr_debug("Boot done.\n"); |
1206 | 1206 | ||
1207 | impress_friends(); | 1207 | impress_friends(); |
1208 | smp_checks(); | 1208 | smp_checks(); |
@@ -1300,7 +1300,7 @@ static void __ref remove_cpu_from_maps(int cpu) | |||
1300 | cpu_clear(cpu, cpu_callout_map); | 1300 | cpu_clear(cpu, cpu_callout_map); |
1301 | cpu_clear(cpu, cpu_callin_map); | 1301 | cpu_clear(cpu, cpu_callin_map); |
1302 | /* was set by cpu_init() */ | 1302 | /* was set by cpu_init() */ |
1303 | clear_bit(cpu, (unsigned long *)&cpu_initialized); | 1303 | cpu_clear(cpu, cpu_initialized); |
1304 | numa_remove_cpu(cpu); | 1304 | numa_remove_cpu(cpu); |
1305 | } | 1305 | } |
1306 | 1306 | ||
@@ -1379,7 +1379,8 @@ static int __init parse_maxcpus(char *arg) | |||
1379 | { | 1379 | { |
1380 | extern unsigned int maxcpus; | 1380 | extern unsigned int maxcpus; |
1381 | 1381 | ||
1382 | maxcpus = simple_strtoul(arg, NULL, 0); | 1382 | if (arg) |
1383 | maxcpus = simple_strtoul(arg, NULL, 0); | ||
1383 | return 0; | 1384 | return 0; |
1384 | } | 1385 | } |
1385 | early_param("maxcpus", parse_maxcpus); | 1386 | early_param("maxcpus", parse_maxcpus); |