aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFabio Estevam <fabio.estevam@freescale.com>2015-05-24 16:39:04 -0400
committerJonathan Cameron <jic23@kernel.org>2015-06-07 12:28:58 -0400
commit6c0d48cb29c29b306ba3548afb45154d22eb4d78 (patch)
tree51b38126ab705635ec5686a79d9ca4c168977524
parentdc7b8d98ac003c9f1e83a5f927c372dac6f114a1 (diff)
iio: twl4030-madc: Pass the IRQF_ONESHOT flag
Since commit 1c6c69525b40 ("genirq: Reject bogus threaded irq requests") threaded IRQs without a primary handler need to be requested with IRQF_ONESHOT, otherwise the request will fail. So pass the IRQF_ONESHOT flag in this case. The semantic patch that makes this change is available in scripts/coccinelle/misc/irqf_oneshot.cocci. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Cc: <stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
-rw-r--r--drivers/iio/adc/twl4030-madc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/iio/adc/twl4030-madc.c b/drivers/iio/adc/twl4030-madc.c
index 94c5f05b4bc1..4caecbea4c97 100644
--- a/drivers/iio/adc/twl4030-madc.c
+++ b/drivers/iio/adc/twl4030-madc.c
@@ -835,7 +835,8 @@ static int twl4030_madc_probe(struct platform_device *pdev)
835 irq = platform_get_irq(pdev, 0); 835 irq = platform_get_irq(pdev, 0);
836 ret = devm_request_threaded_irq(&pdev->dev, irq, NULL, 836 ret = devm_request_threaded_irq(&pdev->dev, irq, NULL,
837 twl4030_madc_threaded_irq_handler, 837 twl4030_madc_threaded_irq_handler,
838 IRQF_TRIGGER_RISING, "twl4030_madc", madc); 838 IRQF_TRIGGER_RISING | IRQF_ONESHOT,
839 "twl4030_madc", madc);
839 if (ret) { 840 if (ret) {
840 dev_err(&pdev->dev, "could not request irq\n"); 841 dev_err(&pdev->dev, "could not request irq\n");
841 goto err_i2c; 842 goto err_i2c;