From: Russell King Date: Sat, 14 Jan 2012 00:01:01 +0000 (+0000) Subject: sched/accounting, proc: Fix /proc/stat interrupts sum X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=f7e6746ebae984ea67b0a1a1e23c7e6698240631;p=GitHub%2Fmt8127%2Fandroid_kernel_alcatel_ttab.git sched/accounting, proc: Fix /proc/stat interrupts sum Commit 3292beb340c7688 ("sched/accounting: Change cpustat fields to an array") deleted the code which provides us with the sum of all interrupts in the system, causing vmstat to report zero interrupts occuring in the system. Fix this by restoring the code. Signed-off-by: Russell King Tested-by: Russell King # [on ARM] Tested-by: Tony Luck Tested-by: Steven Rostedt Cc: Glauber Costa Cc: KAMEZAWA Hiroyuki Cc: Linus Torvalds Cc: Andrew Morton Cc: Paul Tuner Cc: Peter Zijlstra Signed-off-by: Ingo Molnar --- diff --git a/fs/proc/stat.c b/fs/proc/stat.c index d76ca6ae2b1b..121f77cfef76 100644 --- a/fs/proc/stat.c +++ b/fs/proc/stat.c @@ -77,6 +77,8 @@ static int show_stat(struct seq_file *p, void *v) steal += kcpustat_cpu(i).cpustat[CPUTIME_STEAL]; guest += kcpustat_cpu(i).cpustat[CPUTIME_GUEST]; guest_nice += kcpustat_cpu(i).cpustat[CPUTIME_GUEST_NICE]; + sum += kstat_cpu_irqs_sum(i); + sum += arch_irq_stat_cpu(i); for (j = 0; j < NR_SOFTIRQS; j++) { unsigned int softirq_stat = kstat_softirqs_cpu(j, i);