Thread (6 messages) flat view 6 messages, 2 authors, 2007-03-15

Re: [PATCH] Add irq host and hwirq pair fields to output when showing interrupts.

From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Date: 2007-03-13 07:15:02

On Tue, 2007-03-13 at 11:19 +0800, Zhang Wei wrote:
quoted hunk ↗ jump to hunk
Signed-off-by: Zhang Wei <redacted>
---
 arch/powerpc/kernel/irq.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/powerpc/kernel/irq.c b/arch/powerpc/kernel/irq.c
index 919fbf5..2a30ffd 100644
--- a/arch/powerpc/kernel/irq.c
+++ b/arch/powerpc/kernel/irq.c
@@ -194,7 +194,7 @@ #else
 		seq_printf(p, "%10u ", kstat_irqs(i));
 #endif /* CONFIG_SMP */
 		if (desc->chip)
-			seq_printf(p, " %s ", desc->chip->typename);
+			seq_printf(p, " (%3d) @%s ", (irq_map[i].host->revmap_type == IRQ_HOST_MAP_LEGACY) ? i : virq_to_hw(i), desc->chip->typename);
 		else
 			seq_puts(p, "  None      ");
 		seq_printf(p, "%s", (desc->status & IRQ_LEVEL) ? "Level " : "Edge  ");
Well, first, we shouldn't modify the output of /proc/interrupts as this
will likely break all sort of userland tools displaying it (well, I
think).

Now, regarding the patch itself, printing the hw irq is not that useful
without some indication of which host it belongs to. Best is to add a
name() or something like that to the host ops.

Ben.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help