On 04/05/2011 02:53 AM, Timur Tabi wrote: > Is it okay to call disable_irq() before calling request_irq()? My > device creates lots of spurious interrupts, and so I want the > interrupt enable only when I expect a real interrupt to occur. It > seems to work, but I just want to make sure it's a proper technique. > It might work in your case, but in general that would certainly be really bad practice. If the irq was not requested before request_irq should enable the IRQ regardless of whether irq_disable was called or not. I have a patch which adds the IRQF_NOAUTOEN flag, which allows you to request a IRQ without automatically enabling it. Unfortunately the current version of the patch will fail if your irq_chip implements the irq_startup callback. I've attached the patch. - Lars