aboutsummaryrefslogtreecommitdiffstats
path: root/arch/ia64
diff options
context:
space:
mode:
Diffstat (limited to 'arch/ia64')
-rw-r--r--arch/ia64/kernel/irq.c12
-rw-r--r--arch/ia64/kernel/mca.c4
-rw-r--r--arch/ia64/kernel/module.c6
-rw-r--r--arch/ia64/kernel/smp.c10
-rw-r--r--arch/ia64/kernel/smpboot.c6
-rw-r--r--arch/ia64/mm/tlb.c5
6 files changed, 21 insertions, 22 deletions
diff --git a/arch/ia64/kernel/irq.c b/arch/ia64/kernel/irq.c
index 205d98028261..d33244c32759 100644
--- a/arch/ia64/kernel/irq.c
+++ b/arch/ia64/kernel/irq.c
@@ -57,9 +57,9 @@ int show_interrupts(struct seq_file *p, void *v)
57 57
58 if (i == 0) { 58 if (i == 0) {
59 seq_printf(p, " "); 59 seq_printf(p, " ");
60 for (j=0; j<NR_CPUS; j++) 60 for_each_online_cpu(j) {
61 if (cpu_online(j)) 61 seq_printf(p, "CPU%d ",j);
62 seq_printf(p, "CPU%d ",j); 62 }
63 seq_putc(p, '\n'); 63 seq_putc(p, '\n');
64 } 64 }
65 65
@@ -72,9 +72,9 @@ int show_interrupts(struct seq_file *p, void *v)
72#ifndef CONFIG_SMP 72#ifndef CONFIG_SMP
73 seq_printf(p, "%10u ", kstat_irqs(i)); 73 seq_printf(p, "%10u ", kstat_irqs(i));
74#else 74#else
75 for (j = 0; j < NR_CPUS; j++) 75 for_each_online_cpu(j) {
76 if (cpu_online(j)) 76 seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]);
77 seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]); 77 }
78#endif 78#endif
79 seq_printf(p, " %14s", irq_desc[i].handler->typename); 79 seq_printf(p, " %14s", irq_desc[i].handler->typename);
80 seq_printf(p, " %s", action->name); 80 seq_printf(p, " %s", action->name);
diff --git a/arch/ia64/kernel/mca.c b/arch/ia64/kernel/mca.c
index d0a5106fba24..52c47da17246 100644
--- a/arch/ia64/kernel/mca.c
+++ b/arch/ia64/kernel/mca.c
@@ -508,9 +508,7 @@ ia64_mca_wakeup_all(void)
508 int cpu; 508 int cpu;
509 509
510 /* Clear the Rendez checkin flag for all cpus */ 510 /* Clear the Rendez checkin flag for all cpus */
511 for(cpu = 0; cpu < NR_CPUS; cpu++) { 511 for_each_online_cpu(cpu) {
512 if (!cpu_online(cpu))
513 continue;
514 if (ia64_mc_info.imi_rendez_checkin[cpu] == IA64_MCA_RENDEZ_CHECKIN_DONE) 512 if (ia64_mc_info.imi_rendez_checkin[cpu] == IA64_MCA_RENDEZ_CHECKIN_DONE)
515 ia64_mca_wakeup(cpu); 513 ia64_mca_wakeup(cpu);
516 } 514 }
diff --git a/arch/ia64/kernel/module.c b/arch/ia64/kernel/module.c
index f1aca7cffd12..7a2f0a798d12 100644
--- a/arch/ia64/kernel/module.c
+++ b/arch/ia64/kernel/module.c
@@ -947,8 +947,8 @@ void
947percpu_modcopy (void *pcpudst, const void *src, unsigned long size) 947percpu_modcopy (void *pcpudst, const void *src, unsigned long size)
948{ 948{
949 unsigned int i; 949 unsigned int i;
950 for (i = 0; i < NR_CPUS; i++) 950 for_each_cpu(i) {
951 if (cpu_possible(i)) 951 memcpy(pcpudst + __per_cpu_offset[i], src, size);
952 memcpy(pcpudst + __per_cpu_offset[i], src, size); 952 }
953} 953}
954#endif /* CONFIG_SMP */ 954#endif /* CONFIG_SMP */
diff --git a/arch/ia64/kernel/smp.c b/arch/ia64/kernel/smp.c
index 0166a9847095..657ac99a451c 100644
--- a/arch/ia64/kernel/smp.c
+++ b/arch/ia64/kernel/smp.c
@@ -185,8 +185,8 @@ send_IPI_allbutself (int op)
185{ 185{
186 unsigned int i; 186 unsigned int i;
187 187
188 for (i = 0; i < NR_CPUS; i++) { 188 for_each_online_cpu(i) {
189 if (cpu_online(i) && i != smp_processor_id()) 189 if (i != smp_processor_id())
190 send_IPI_single(i, op); 190 send_IPI_single(i, op);
191 } 191 }
192} 192}
@@ -199,9 +199,9 @@ send_IPI_all (int op)
199{ 199{
200 int i; 200 int i;
201 201
202 for (i = 0; i < NR_CPUS; i++) 202 for_each_online_cpu(i) {
203 if (cpu_online(i)) 203 send_IPI_single(i, op);
204 send_IPI_single(i, op); 204 }
205} 205}
206 206
207/* 207/*
diff --git a/arch/ia64/kernel/smpboot.c b/arch/ia64/kernel/smpboot.c
index 7d72c0d872b3..400a48987124 100644
--- a/arch/ia64/kernel/smpboot.c
+++ b/arch/ia64/kernel/smpboot.c
@@ -694,9 +694,9 @@ smp_cpus_done (unsigned int dummy)
694 * Allow the user to impress friends. 694 * Allow the user to impress friends.
695 */ 695 */
696 696
697 for (cpu = 0; cpu < NR_CPUS; cpu++) 697 for_each_online_cpu(cpu) {
698 if (cpu_online(cpu)) 698 bogosum += cpu_data(cpu)->loops_per_jiffy;
699 bogosum += cpu_data(cpu)->loops_per_jiffy; 699 }
700 700
701 printk(KERN_INFO "Total of %d processors activated (%lu.%02lu BogoMIPS).\n", 701 printk(KERN_INFO "Total of %d processors activated (%lu.%02lu BogoMIPS).\n",
702 (int)num_online_cpus(), bogosum/(500000/HZ), (bogosum/(5000/HZ))%100); 702 (int)num_online_cpus(), bogosum/(500000/HZ), (bogosum/(5000/HZ))%100);
diff --git a/arch/ia64/mm/tlb.c b/arch/ia64/mm/tlb.c
index 464557e4ed82..987fb754d6ad 100644
--- a/arch/ia64/mm/tlb.c
+++ b/arch/ia64/mm/tlb.c
@@ -77,9 +77,10 @@ wrap_mmu_context (struct mm_struct *mm)
77 /* can't call flush_tlb_all() here because of race condition with O(1) scheduler [EF] */ 77 /* can't call flush_tlb_all() here because of race condition with O(1) scheduler [EF] */
78 { 78 {
79 int cpu = get_cpu(); /* prevent preemption/migration */ 79 int cpu = get_cpu(); /* prevent preemption/migration */
80 for (i = 0; i < NR_CPUS; ++i) 80 for_each_online_cpu(i) {
81 if (cpu_online(i) && (i != cpu)) 81 if (i != cpu)
82 per_cpu(ia64_need_tlb_flush, i) = 1; 82 per_cpu(ia64_need_tlb_flush, i) = 1;
83 }
83 put_cpu(); 84 put_cpu();
84 } 85 }
85 local_flush_tlb_all(); 86 local_flush_tlb_all();