aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@novell.com>2007-10-17 12:04:40 -0400
committerThomas Gleixner <tglx@inhelltoy.tec.linutronix.de>2007-10-17 14:16:54 -0400
commit072f5d82b58cba760191393a6a99fd1123c76e67 (patch)
tree8b0bd815aed4a466d7747ddacc4105e13316f4f4 /arch/x86/kernel
parent38e760a1335ffaca5a08624a9aed6fe2055c2c98 (diff)
x86: also show non-zero IRQ counts for vectors that currently don't have a handler
It doesn't seem to make sense to hide these, even if their counts can't change at the point in time they're being displayed. [ tglx: arch/x86 adaptation ] Signed-off-by: Jan Beulich <jbeulich@novell.com> Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/kernel')
-rw-r--r--arch/x86/kernel/irq_32.c18
-rw-r--r--arch/x86/kernel/irq_64.c18
2 files changed, 28 insertions, 8 deletions
diff --git a/arch/x86/kernel/irq_32.c b/arch/x86/kernel/irq_32.c
index 10f359021aae..d3fde94f7345 100644
--- a/arch/x86/kernel/irq_32.c
+++ b/arch/x86/kernel/irq_32.c
@@ -255,9 +255,17 @@ int show_interrupts(struct seq_file *p, void *v)
255 } 255 }
256 256
257 if (i < NR_IRQS) { 257 if (i < NR_IRQS) {
258 unsigned any_count = 0;
259
258 spin_lock_irqsave(&irq_desc[i].lock, flags); 260 spin_lock_irqsave(&irq_desc[i].lock, flags);
261#ifndef CONFIG_SMP
262 any_count = kstat_irqs(i);
263#else
264 for_each_online_cpu(j)
265 any_count |= kstat_cpu(j).irqs[i];
266#endif
259 action = irq_desc[i].action; 267 action = irq_desc[i].action;
260 if (!action) 268 if (!action && !any_count)
261 goto skip; 269 goto skip;
262 seq_printf(p, "%3d: ",i); 270 seq_printf(p, "%3d: ",i);
263#ifndef CONFIG_SMP 271#ifndef CONFIG_SMP
@@ -268,10 +276,12 @@ int show_interrupts(struct seq_file *p, void *v)
268#endif 276#endif
269 seq_printf(p, " %8s", irq_desc[i].chip->name); 277 seq_printf(p, " %8s", irq_desc[i].chip->name);
270 seq_printf(p, "-%-8s", irq_desc[i].name); 278 seq_printf(p, "-%-8s", irq_desc[i].name);
271 seq_printf(p, " %s", action->name);
272 279
273 for (action=action->next; action; action = action->next) 280 if (action) {
274 seq_printf(p, ", %s", action->name); 281 seq_printf(p, " %s", action->name);
282 while ((action = action->next) != NULL)
283 seq_printf(p, ", %s", action->name);
284 }
275 285
276 seq_putc(p, '\n'); 286 seq_putc(p, '\n');
277skip: 287skip:
diff --git a/arch/x86/kernel/irq_64.c b/arch/x86/kernel/irq_64.c
index 3881189df8ee..6b5c730d67b9 100644
--- a/arch/x86/kernel/irq_64.c
+++ b/arch/x86/kernel/irq_64.c
@@ -62,9 +62,17 @@ int show_interrupts(struct seq_file *p, void *v)
62 } 62 }
63 63
64 if (i < NR_IRQS) { 64 if (i < NR_IRQS) {
65 unsigned any_count = 0;
66
65 spin_lock_irqsave(&irq_desc[i].lock, flags); 67 spin_lock_irqsave(&irq_desc[i].lock, flags);
68#ifndef CONFIG_SMP
69 any_count = kstat_irqs(i);
70#else
71 for_each_online_cpu(j)
72 any_count |= kstat_cpu(j).irqs[i];
73#endif
66 action = irq_desc[i].action; 74 action = irq_desc[i].action;
67 if (!action) 75 if (!action && !any_count)
68 goto skip; 76 goto skip;
69 seq_printf(p, "%3d: ",i); 77 seq_printf(p, "%3d: ",i);
70#ifndef CONFIG_SMP 78#ifndef CONFIG_SMP
@@ -76,9 +84,11 @@ int show_interrupts(struct seq_file *p, void *v)
76 seq_printf(p, " %8s", irq_desc[i].chip->name); 84 seq_printf(p, " %8s", irq_desc[i].chip->name);
77 seq_printf(p, "-%-8s", irq_desc[i].name); 85 seq_printf(p, "-%-8s", irq_desc[i].name);
78 86
79 seq_printf(p, " %s", action->name); 87 if (action) {
80 for (action=action->next; action; action = action->next) 88 seq_printf(p, " %s", action->name);
81 seq_printf(p, ", %s", action->name); 89 while ((action = action->next) != NULL)
90 seq_printf(p, ", %s", action->name);
91 }
82 seq_putc(p, '\n'); 92 seq_putc(p, '\n');
83skip: 93skip:
84 spin_unlock_irqrestore(&irq_desc[i].lock, flags); 94 spin_unlock_irqrestore(&irq_desc[i].lock, flags);