diff options
author | Sean Nyekjaer <sean@geanix.com> | 2021-08-17 15:43:36 +0300 |
---|---|---|
committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2021-09-14 14:02:09 +0300 |
commit | 9033c7a357481fb5bcc1737bafa4aec572dca5c6 (patch) | |
tree | a95fcc3c12463c126777588617129cb5f8847a70 /drivers/iio | |
parent | f7a28df7db84eb3410e9eca37832efa5aed93338 (diff) | |
download | linux-9033c7a357481fb5bcc1737bafa4aec572dca5c6.tar.xz |
iio: accel: fxls8962af: return IRQ_HANDLED when fifo is flushed
fxls8962af_fifo_flush() will return the samples flushed.
So return IRQ_NONE only if an error is returned.
Fixes: 79e3a5bdd9ef ("iio: accel: fxls8962af: add hw buffered sampling")
Signed-off-by: Sean Nyekjaer <sean@geanix.com>
Link: https://lore.kernel.org/r/20210817124336.1672169-1-sean@geanix.com
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/iio')
-rw-r--r-- | drivers/iio/accel/fxls8962af-core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/iio/accel/fxls8962af-core.c b/drivers/iio/accel/fxls8962af-core.c index 0019f1ea7df2..f41db9e0249a 100644 --- a/drivers/iio/accel/fxls8962af-core.c +++ b/drivers/iio/accel/fxls8962af-core.c @@ -738,7 +738,7 @@ static irqreturn_t fxls8962af_interrupt(int irq, void *p) if (reg & FXLS8962AF_INT_STATUS_SRC_BUF) { ret = fxls8962af_fifo_flush(indio_dev); - if (ret) + if (ret < 0) return IRQ_NONE; return IRQ_HANDLED; |