-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
genirq: Move debug code to separate header
It'll break when I'm going to undefine the constants. Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
- Loading branch information
Thomas Gleixner
committed
Feb 19, 2011
1 parent
fae581e
commit 1ce6068
Showing
2 changed files
with
44 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
/* | ||
* Debugging printout: | ||
*/ | ||
|
||
#include <linux/kallsyms.h> | ||
|
||
#define P(f) if (desc->status & f) printk("%14s set\n", #f) | ||
#define PS(f) if (desc->istate & f) printk("%14s set\n", #f) | ||
|
||
static inline void print_irq_desc(unsigned int irq, struct irq_desc *desc) | ||
{ | ||
printk("irq %d, desc: %p, depth: %d, count: %d, unhandled: %d\n", | ||
irq, desc, desc->depth, desc->irq_count, desc->irqs_unhandled); | ||
printk("->handle_irq(): %p, ", desc->handle_irq); | ||
print_symbol("%s\n", (unsigned long)desc->handle_irq); | ||
printk("->irq_data.chip(): %p, ", desc->irq_data.chip); | ||
print_symbol("%s\n", (unsigned long)desc->irq_data.chip); | ||
printk("->action(): %p\n", desc->action); | ||
if (desc->action) { | ||
printk("->action->handler(): %p, ", desc->action->handler); | ||
print_symbol("%s\n", (unsigned long)desc->action->handler); | ||
} | ||
|
||
P(IRQ_LEVEL); | ||
P(IRQ_PER_CPU); | ||
P(IRQ_NOPROBE); | ||
P(IRQ_NOREQUEST); | ||
P(IRQ_NOAUTOEN); | ||
|
||
PS(IRQS_AUTODETECT); | ||
PS(IRQS_INPROGRESS); | ||
PS(IRQS_REPLAY); | ||
PS(IRQS_WAITING); | ||
PS(IRQS_DISABLED); | ||
PS(IRQS_PENDING); | ||
PS(IRQS_MASKED); | ||
} | ||
|
||
#undef P | ||
#undef PS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters