1 /// Since commit 1c6c69525b40 ("genirq: Reject bogus threaded irq requests")
2 /// threaded IRQs without a primary handler need to be requested with
3 /// IRQF_ONESHOT, otherwise the request will fail.
5 /// So pass the IRQF_ONESHOT flag in this case.
8 // Confidence: Moderate
10 // Options: --no-includes
18 expression dev, irq, thread_fn;
22 request_threaded_irq@p(irq, NULL, thread_fn,
30 devm_request_threaded_irq@p(dev, irq, NULL, thread_fn,
40 expression dev, irq, thread_fn, flags, e;
44 flags = IRQF_ONESHOT | ...
46 flags |= IRQF_ONESHOT | ...
50 request_threaded_irq@p(irq, NULL, thread_fn, flags, ...);
52 devm_request_threaded_irq@p(dev, irq, NULL, thread_fn, flags, ...);
56 expression dev, irq, thread_fn, flags;
57 position p != {r1.p,r2.p};
60 request_threaded_irq@p(irq, NULL, thread_fn,
70 devm_request_threaded_irq@p(dev, irq, NULL, thread_fn,
83 position p != {r1.p,r2.p};
86 *request_threaded_irq@p(irq, NULL, ...)
88 *devm_request_threaded_irq@p(dev, irq, NULL, ...)
92 @match depends on report || org@
94 position p != {r1.p,r2.p};
97 request_threaded_irq@p(irq, NULL, ...)
99 devm_request_threaded_irq@p(dev, irq, NULL, ...)
102 @script:python depends on org@
105 msg = "ERROR: Threaded IRQ with no primary handler requested without IRQF_ONESHOT"
106 coccilib.org.print_todo(p[0],msg)
108 @script:python depends on report@
111 msg = "ERROR: Threaded IRQ with no primary handler requested without IRQF_ONESHOT"
112 coccilib.report.print_report(p[0],msg)