[PATCH] warn if free_irq() is called from IRQ context
authorIngo Molnar <mingo@elte.hu>
Sun, 26 Mar 2006 09:36:54 +0000 (01:36 -0800)
committerLinus Torvalds <torvalds@g5.osdl.org>
Sun, 26 Mar 2006 16:56:53 +0000 (08:56 -0800)
Warn if free_irq() is called in IRQ context - free_irq() can execute /proc
VFS work, which must not be done in IRQ context.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
kernel/irq/manage.c

index 6edfcef..ac766ad 100644 (file)
@@ -271,6 +271,7 @@ void free_irq(unsigned int irq, void *dev_id)
        struct irqaction **p;
        unsigned long flags;
 
+       WARN_ON(in_interrupt());
        if (irq >= NR_IRQS)
                return;