aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/irq/irqdomain.c
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2012-04-11 02:26:25 -0400
committerGrant Likely <grant.likely@secretlab.ca>2012-04-11 03:01:45 -0400
commit15e06bf64f686befd2030da867a3dad965b96cc0 (patch)
tree769d3c6192d1eeff58fd84d5e6c4667f2952d26c /kernel/irq/irqdomain.c
parentac5830a33f5b25eae1dc0708b3e7a3d270a6c07f (diff)
irqdomain: Fix debugfs formatting
This patch fixes the irq_domain_mapping debugfs output to pad pointer values with leading zeros so that pointer values are displayed correctly. Otherwise you get output similar to "0x 5e0000000000000". Also, when the irq_domain is set to 'null' Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Cc: David Daney <david.daney@cavium.com> Cc: Mika Westerberg <mika.westerberg@linux.intel.com>
Diffstat (limited to 'kernel/irq/irqdomain.c')
-rw-r--r--kernel/irq/irqdomain.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/kernel/irq/irqdomain.c b/kernel/irq/irqdomain.c
index 9310a8d365b0..eb05e40f4553 100644
--- a/kernel/irq/irqdomain.c
+++ b/kernel/irq/irqdomain.c
@@ -643,8 +643,8 @@ static int virq_debug_show(struct seq_file *m, void *private)
643 void *data; 643 void *data;
644 int i; 644 int i;
645 645
646 seq_printf(m, "%-5s %-7s %-15s %-18s %s\n", "virq", "hwirq", 646 seq_printf(m, "%-5s %-7s %-15s %-*s %s\n", "irq", "hwirq",
647 "chip name", "chip data", "domain name"); 647 "chip name", 2 * sizeof(void *) + 2, "chip data", "domain name");
648 648
649 for (i = 1; i < nr_irqs; i++) { 649 for (i = 1; i < nr_irqs; i++) {
650 desc = irq_to_desc(i); 650 desc = irq_to_desc(i);
@@ -667,7 +667,7 @@ static int virq_debug_show(struct seq_file *m, void *private)
667 seq_printf(m, "%-15s ", p); 667 seq_printf(m, "%-15s ", p);
668 668
669 data = irq_desc_get_chip_data(desc); 669 data = irq_desc_get_chip_data(desc);
670 seq_printf(m, "0x%16p ", data); 670 seq_printf(m, data ? "0x%p " : " %p ", data);
671 671
672 if (desc->irq_data.domain && desc->irq_data.domain->of_node) 672 if (desc->irq_data.domain && desc->irq_data.domain->of_node)
673 p = desc->irq_data.domain->of_node->full_name; 673 p = desc->irq_data.domain->of_node->full_name;