diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1999-01-03 17:49:53 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 1999-01-03 17:49:53 +0000 |
commit | eb7a5bf93aaa4be1d7c6181100ab7639e74d67f7 (patch) | |
tree | 5746fea1605ff013be9b78a1556aaad7615d664a /arch/alpha/kernel/irq.c | |
parent | 80ea5b1e15398277650e1197957053b5a71c08bc (diff) |
Merge with Linux 2.1.131 plus some more MIPS goodies.
Diffstat (limited to 'arch/alpha/kernel/irq.c')
-rw-r--r-- | arch/alpha/kernel/irq.c | 39 |
1 files changed, 28 insertions, 11 deletions
diff --git a/arch/alpha/kernel/irq.c b/arch/alpha/kernel/irq.c index e8fee6a0d..8f6afc14b 100644 --- a/arch/alpha/kernel/irq.c +++ b/arch/alpha/kernel/irq.c @@ -311,26 +311,41 @@ free_irq(unsigned int irq, void *dev_id) int get_irq_list(char *buf) { - int i, len = 0; + int i, j; struct irqaction * action; - int cpu = smp_processor_id(); + char *p = buf; + +#ifdef __SMP__ + p += sprintf(p, " "); + for (j = 0; j < smp_num_cpus; j++) + p += sprintf(p, "CPU%d ", j); + *p++ = '\n'; +#endif for (i = 0; i < NR_IRQS; i++) { action = irq_action[i]; if (!action) continue; - len += sprintf(buf+len, "%2d: %10u %c %s", - i, kstat.irqs[cpu][i], - (action->flags & SA_INTERRUPT) ? '+' : ' ', - action->name); + p += sprintf(p, "%3d: ",i); +#ifndef __SMP__ + p += sprintf(p, "%10u ", kstat_irqs(i)); +#else + for (j = 0; j < smp_num_cpus; j++) + p += sprintf(p, "%10u ", + kstat.irqs[cpu_logical_map(j)][i]); +#endif + p += sprintf(p, " %c%s", + (action->flags & SA_INTERRUPT)?'+':' ', + action->name); + for (action=action->next; action; action = action->next) { - len += sprintf(buf+len, ", %s%s", - (action->flags & SA_INTERRUPT) ? "+":"", - action->name); + p += sprintf(p, ", %c%s", + (action->flags & SA_INTERRUPT)?'+':' ', + action->name); } - len += sprintf(buf+len, "\n"); + *p++ = '\n'; } - return len; + return p - buf; } #ifdef __SMP__ @@ -427,8 +442,10 @@ get_irqlock(int cpu, void* where) /* * Finally. */ +#if DEBUG_SPINLOCK global_irq_lock.task = current; global_irq_lock.previous = where; +#endif global_irq_holder = cpu; previous_irqholder = where; } |