aboutsummaryrefslogtreecommitdiffstats
path: root/arch/parisc
diff options
context:
space:
mode:
Diffstat (limited to 'arch/parisc')
-rw-r--r--arch/parisc/kernel/smp.c25
1 files changed, 10 insertions, 15 deletions
diff --git a/arch/parisc/kernel/smp.c b/arch/parisc/kernel/smp.c
index 25564b7ca6bb..d6ac1c60a471 100644
--- a/arch/parisc/kernel/smp.c
+++ b/arch/parisc/kernel/smp.c
@@ -298,8 +298,8 @@ send_IPI_allbutself(enum ipi_message_type op)
298{ 298{
299 int i; 299 int i;
300 300
301 for (i = 0; i < NR_CPUS; i++) { 301 for_each_online_cpu(i) {
302 if (cpu_online(i) && i != smp_processor_id()) 302 if (i != smp_processor_id())
303 send_IPI_single(i, op); 303 send_IPI_single(i, op);
304 } 304 }
305} 305}
@@ -643,14 +643,13 @@ int sys_cpus(int argc, char **argv)
643 if ( argc == 1 ){ 643 if ( argc == 1 ){
644 644
645#ifdef DUMP_MORE_STATE 645#ifdef DUMP_MORE_STATE
646 for(i=0; i<NR_CPUS; i++) { 646 for_each_online_cpu(i) {
647 int cpus_per_line = 4; 647 int cpus_per_line = 4;
648 if(cpu_online(i)) { 648
649 if (j++ % cpus_per_line) 649 if (j++ % cpus_per_line)
650 printk(" %3d",i); 650 printk(" %3d",i);
651 else 651 else
652 printk("\n %3d",i); 652 printk("\n %3d",i);
653 }
654 } 653 }
655 printk("\n"); 654 printk("\n");
656#else 655#else
@@ -659,9 +658,7 @@ int sys_cpus(int argc, char **argv)
659 } else if((argc==2) && !(strcmp(argv[1],"-l"))) { 658 } else if((argc==2) && !(strcmp(argv[1],"-l"))) {
660 printk("\nCPUSTATE TASK CPUNUM CPUID HARDCPU(HPA)\n"); 659 printk("\nCPUSTATE TASK CPUNUM CPUID HARDCPU(HPA)\n");
661#ifdef DUMP_MORE_STATE 660#ifdef DUMP_MORE_STATE
662 for(i=0;i<NR_CPUS;i++) { 661 for_each_online_cpu(i) {
663 if (!cpu_online(i))
664 continue;
665 if (cpu_data[i].cpuid != NO_PROC_ID) { 662 if (cpu_data[i].cpuid != NO_PROC_ID) {
666 switch(cpu_data[i].state) { 663 switch(cpu_data[i].state) {
667 case STATE_RENDEZVOUS: 664 case STATE_RENDEZVOUS:
@@ -695,9 +692,7 @@ int sys_cpus(int argc, char **argv)
695 } else if ((argc==2) && !(strcmp(argv[1],"-s"))) { 692 } else if ((argc==2) && !(strcmp(argv[1],"-s"))) {
696#ifdef DUMP_MORE_STATE 693#ifdef DUMP_MORE_STATE
697 printk("\nCPUSTATE CPUID\n"); 694 printk("\nCPUSTATE CPUID\n");
698 for (i=0;i<NR_CPUS;i++) { 695 for_each_online_cpu(i) {
699 if (!cpu_online(i))
700 continue;
701 if (cpu_data[i].cpuid != NO_PROC_ID) { 696 if (cpu_data[i].cpuid != NO_PROC_ID) {
702 switch(cpu_data[i].state) { 697 switch(cpu_data[i].state) {
703 case STATE_RENDEZVOUS: 698 case STATE_RENDEZVOUS: