aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/kernel/smp.c
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@arm.linux.org.uk>2010-11-15 09:20:41 -0500
committerRussell King <rmk+kernel@arm.linux.org.uk>2010-12-20 10:06:58 -0500
commitcab8c6f3053c1b147bba825844c8e208f8b3b9f4 (patch)
treeee11484788efc820b48f2348ec72df6e8356b7b5 /arch/arm/kernel/smp.c
parent46c48f222f568decb881a552caa1c8f9c96c521e (diff)
ARM: SMP: move ipi_count into irq_stat structure
Move the ipi_count into irq_stat, which allows the ipi_data structure to be entirely removed. Reviewed-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/kernel/smp.c')
-rw-r--r--arch/arm/kernel/smp.c14
1 files changed, 2 insertions, 12 deletions
diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c
index 24131264ec2c..65b5ba867805 100644
--- a/arch/arm/kernel/smp.c
+++ b/arch/arm/kernel/smp.c
@@ -46,15 +46,6 @@
46 */ 46 */
47struct secondary_data secondary_data; 47struct secondary_data secondary_data;
48 48
49/*
50 * structures for inter-processor calls
51 */
52struct ipi_data {
53 unsigned long ipi_count;
54};
55
56static DEFINE_PER_CPU(struct ipi_data, ipi_data);
57
58enum ipi_msg_type { 49enum ipi_msg_type {
59 IPI_TIMER = 2, 50 IPI_TIMER = 2,
60 IPI_RESCHEDULE, 51 IPI_RESCHEDULE,
@@ -398,7 +389,7 @@ void show_ipi_list(struct seq_file *p)
398 seq_puts(p, "IPI:"); 389 seq_puts(p, "IPI:");
399 390
400 for_each_present_cpu(cpu) 391 for_each_present_cpu(cpu)
401 seq_printf(p, " %10lu", per_cpu(ipi_data, cpu).ipi_count); 392 seq_printf(p, " %10u", __get_irq_stat(cpu, ipi_irqs));
402 393
403 seq_putc(p, '\n'); 394 seq_putc(p, '\n');
404} 395}
@@ -513,10 +504,9 @@ static void ipi_cpu_stop(unsigned int cpu)
513asmlinkage void __exception do_IPI(int ipinr, struct pt_regs *regs) 504asmlinkage void __exception do_IPI(int ipinr, struct pt_regs *regs)
514{ 505{
515 unsigned int cpu = smp_processor_id(); 506 unsigned int cpu = smp_processor_id();
516 struct ipi_data *ipi = &per_cpu(ipi_data, cpu);
517 struct pt_regs *old_regs = set_irq_regs(regs); 507 struct pt_regs *old_regs = set_irq_regs(regs);
518 508
519 ipi->ipi_count++; 509 __inc_irq_stat(cpu, ipi_irqs);
520 510
521 switch (ipinr) { 511 switch (ipinr) {
522 case IPI_TIMER: 512 case IPI_TIMER: