]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
iio: st_sensors: print error when failing to get IRQ
authorLinus Walleij <linus.walleij@linaro.org>
Thu, 30 Apr 2015 13:15:46 +0000 (15:15 +0200)
committerJonathan Cameron <jic23@kernel.org>
Thu, 7 May 2015 09:42:32 +0000 (10:42 +0100)
Print a proper error message if we're missing the trigger
IRQ.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/iio/common/st_sensors/st_sensors_trigger.c

index 8d8ca6f1e16a5d602b182355fc1f051738dc48c2..3e907040c2c7a7712035376b019c462bd441ddb8 100644 (file)
@@ -37,8 +37,10 @@ int st_sensors_allocate_trigger(struct iio_dev *indio_dev,
                        IRQF_TRIGGER_RISING,
                        sdata->trig->name,
                        sdata->trig);
-       if (err)
+       if (err) {
+               dev_err(&indio_dev->dev, "failed to request trigger IRQ.\n");
                goto request_irq_error;
+       }
 
        iio_trigger_set_drvdata(sdata->trig, indio_dev);
        sdata->trig->ops = trigger_ops;