diff mbox series

iio: accel: adxl372: Set iio_chan BE

Message ID 20200219143112.25976-1-alexandru.tachici@analog.com (mailing list archive)
State New, archived
Headers show
Series iio: accel: adxl372: Set iio_chan BE | expand

Commit Message

Alexandru Tachici Feb. 19, 2020, 2:31 p.m. UTC
Data stored in the iio-buffer is BE and this
should be specified in the iio_chan_spec struct.

Fixes: f4f55ce38e5f8 ("iio:adxl372: Add FIFO and interrupts support")
Signed-off-by: Alexandru Tachici <alexandru.tachici@analog.com>
---
 drivers/iio/accel/adxl372.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Jonathan Cameron Feb. 21, 2020, 1:09 p.m. UTC | #1
On Wed, 19 Feb 2020 16:31:12 +0200
Alexandru Tachici <alexandru.tachici@analog.com> wrote:

> Data stored in the iio-buffer is BE and this
> should be specified in the iio_chan_spec struct.
> 
> Fixes: f4f55ce38e5f8 ("iio:adxl372: Add FIFO and interrupts support")
> Signed-off-by: Alexandru Tachici <alexandru.tachici@analog.com>
Applied to the fixes-togreg branch of iio.git and marked for stable.

Thanks,

Jonathan

> ---
>  drivers/iio/accel/adxl372.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/iio/accel/adxl372.c b/drivers/iio/accel/adxl372.c
> index 9c6eebf379ca..3eb413df3c8d 100644
> --- a/drivers/iio/accel/adxl372.c
> +++ b/drivers/iio/accel/adxl372.c
> @@ -237,6 +237,7 @@ static const struct adxl372_axis_lookup adxl372_axis_lookup_table[] = {
>  		.realbits = 12,						\
>  		.storagebits = 16,					\
>  		.shift = 4,						\
> +		.endianness = IIO_BE,					\
>  	},								\
>  }
>
diff mbox series

Patch

diff --git a/drivers/iio/accel/adxl372.c b/drivers/iio/accel/adxl372.c
index 9c6eebf379ca..3eb413df3c8d 100644
--- a/drivers/iio/accel/adxl372.c
+++ b/drivers/iio/accel/adxl372.c
@@ -237,6 +237,7 @@  static const struct adxl372_axis_lookup adxl372_axis_lookup_table[] = {
 		.realbits = 12,						\
 		.storagebits = 16,					\
 		.shift = 4,						\
+		.endianness = IIO_BE,					\
 	},								\
 }