ARM: 7590/1: /proc/interrupts: limit the display of IPIs to online CPUs only
authorNicolas Pitre <nicolas.pitre@linaro.org>
Mon, 3 Dec 2012 20:13:03 +0000 (21:13 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Fri, 7 Dec 2012 11:45:28 +0000 (11:45 +0000)
This is what is done for the regular interrupts in kernel/irqs/proc.c
already, before calling arch_show_interrupts().  Not doing so for the
IPIs causes the column headers not to match with the content whenever
some CPUs are offline.

Signed-off-by: Nicolas Pitre <nico@linaro.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
arch/arm/kernel/smp.c

index fbc8b26..fc4d526 100644 (file)
@@ -443,7 +443,7 @@ void show_ipi_list(struct seq_file *p, int prec)
        for (i = 0; i < NR_IPI; i++) {
                seq_printf(p, "%*s%u: ", prec - 1, "IPI", i);
 
-               for_each_present_cpu(cpu)
+               for_each_online_cpu(cpu)
                        seq_printf(p, "%10u ",
                                   __get_irq_stat(cpu, ipi_irqs[i]));