iio: accel: adxl372: Perform a reset at start up
authorStefan Popa <stefan.popa@analog.com>
Tue, 10 Sep 2019 14:44:46 +0000 (17:44 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 17 Oct 2019 20:47:04 +0000 (13:47 -0700)
commitbbf631e0c554e0e7ef08f89ec7f9b39625aece9a
tree024826cfe2a94a1402b43149628a743b1ae00d27
parent6fbee1b1a26a6b9eb539db4b304de5215fd8c0b2
iio: accel: adxl372: Perform a reset at start up

commit d9a997bd4d762d5bd8cc548d762902f58b5e0a74 upstream.

We need to perform a reset a start up to make sure that the chip is in a
consistent state. This reset also disables all the interrupts which
should only be enabled together with the iio buffer. Not doing this, was
sometimes causing unwanted interrupts to trigger.

Signed-off-by: Stefan Popa <stefan.popa@analog.com>
Fixes: f4f55ce38e5f ("iio:adxl372: Add FIFO and interrupts support")
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/iio/accel/adxl372.c