Skip to content

Commit

Permalink
genirq: Make early_irq_init() print out more informative
Browse files Browse the repository at this point in the history
The printk in early_irq_init() is cryptic and badly formatted:

  NR_IRQS:33024 nr_irqs:968 16

The last number is the number of preallocated interrupts, so add a prefix
to it:

  NR_IRQS: 33024, nr_irqs: 968, preallocated irqs: 16

Cleanup the formatting for better readability as well.

Signed-off-by: Vincent Legoll <vincent.legoll@gmail.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: http://lkml.kernel.org/r/1494318849-6733-1-git-send-email-vincent.legoll@gmail.com
  • Loading branch information
Vincent Legoll authored and Thomas Gleixner committed May 26, 2017
1 parent 5328666 commit 5a29ef2
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions kernel/irq/irqdesc.c
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,8 @@ int __init early_irq_init(void)

/* Let arch update nr_irqs and return the nr of preallocated irqs */
initcnt = arch_probe_nr_irqs();
printk(KERN_INFO "NR_IRQS:%d nr_irqs:%d %d\n", NR_IRQS, nr_irqs, initcnt);
printk(KERN_INFO "NR_IRQS: %d, nr_irqs: %d, preallocated irqs: %d\n",
NR_IRQS, nr_irqs, initcnt);

if (WARN_ON(nr_irqs > IRQ_BITMAP_BITS))
nr_irqs = IRQ_BITMAP_BITS;
Expand Down Expand Up @@ -516,7 +517,7 @@ int __init early_irq_init(void)

init_irq_default_affinity();

printk(KERN_INFO "NR_IRQS:%d\n", NR_IRQS);
printk(KERN_INFO "NR_IRQS: %d\n", NR_IRQS);

desc = irq_desc;
count = ARRAY_SIZE(irq_desc);
Expand Down

0 comments on commit 5a29ef2

Please sign in to comment.