From add9bde216fefe1b65b41f7c0948cef48aa98c14 Mon Sep 17 00:00:00 2001 From: Heiko Carstens Date: Wed, 2 Jan 2013 14:01:23 +0100 Subject: s390/irq: enable irq sum accounting for /proc/stat again For more than two years, since f2c66cd8eeddedb440f33bc0f5cec1ed7ae376cb "/proc/stat: scalability of irq num per cpu" the output of /proc/stat is broken. The first field in the "intr" line should contain the sum of all interrupts, however since the above mentioned change it is always zero. The reason for that is that a per cpu irq sum variable had been introduced which got incremented when calling kstat_incr_irqs_this_cpu(). However on s390 we directly incremented only the per cpu per irq counter by accessing the array element via kstat_cpu(smp_processor_id()).irqs[...]. So fix this and use the kstat_incr_irqs_this_cpu() wrapper which increments both: the per cpu per irq counter and the per cpu irq sum counter. Signed-off-by: Heiko Carstens Signed-off-by: Martin Schwidefsky --- arch/s390/kernel/irq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'arch/s390') diff --git a/arch/s390/kernel/irq.c b/arch/s390/kernel/irq.c index bf24293970ce..a8f8ab027ba8 100644 --- a/arch/s390/kernel/irq.c +++ b/arch/s390/kernel/irq.c @@ -222,7 +222,7 @@ void __irq_entry do_extint(struct pt_regs *regs, struct ext_code ext_code, /* Serve timer interrupts first. */ clock_comparator_work(); } - kstat_cpu(smp_processor_id()).irqs[EXTERNAL_INTERRUPT]++; + kstat_incr_irqs_this_cpu(EXTERNAL_INTERRUPT, NULL); if (ext_code.code != 0x1004) __get_cpu_var(s390_idle).nohz_delay = 1; -- cgit v1.2.1