]> www.infradead.org Git - linux.git/commitdiff
iio: adc: ads1119: Fix IRQ flags
authorFrancesco Dolcini <francesco.dolcini@toradex.com>
Wed, 31 Jul 2024 14:06:57 +0000 (16:06 +0200)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sat, 3 Aug 2024 15:47:13 +0000 (16:47 +0100)
Remove IRQF_TRIGGER_FALLING flag from irq request, this should come from
the platform firmware and should not be hard-coded into the driver.

Add IRQF_ONESHOT flag to the irq request, the interrupt should not be
re-activated in interrupt context, it should be done only after the
device irq handler run.

Fixes: a9306887eba4 ("iio: adc: ti-ads1119: Add driver")
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
Reviwed-by: João Paulo Gonçalves <jpaulo.silvagoncalves@gmail.com>
Link: https://patch.msgid.link/20240731140657.88265-1-francesco@dolcini.it
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/adc/ti-ads1119.c

index 630f5d5f9a6043ead77695947c62d1cd02dace7b..d649980479e450f4eae5e28492cca89a0250fb90 100644 (file)
@@ -735,7 +735,7 @@ static int ads1119_probe(struct i2c_client *client)
        if (client->irq > 0) {
                ret = devm_request_threaded_irq(dev, client->irq,
                                                ads1119_irq_handler,
-                                               NULL, IRQF_TRIGGER_FALLING,
+                                               NULL, IRQF_ONESHOT,
                                                "ads1119", indio_dev);
                if (ret)
                        return dev_err_probe(dev, ret,