linux/drivers/iio/humidity
Chris Lesiak 0d2f6fd3ff iio: si7020: Swap data byte order
The Silicon Labs Si7013, Si7020, and Si7021 family of I2C humidity and
temperature sensors deliver 16 bit data high byte first.

See the datasheet available at:
https://www.silabs.com/Support%20Documents%2fTechnicalDocs%2fSi7020-A20.pdf

But as documented in Documentation/i2c/smbus-protocol,
i2c_smbus_read_word_data() expects the low byte first.

Change the driver to use i2c_smbus_read_word_swapped to get correct byte
order.

Signed-off-by: Chris Lesiak <chris.lesiak@licor.com>
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2015-11-15 12:36:19 +00:00
..
dht11.c iio: dht11: Use new function ktime_get_resolution_ns() 2015-07-20 18:41:20 +01:00
Kconfig iio: Allow compile test of GPIO consumers if !GPIOLIB 2015-05-10 20:31:43 +01:00
Makefile IIO: add si7020 driver 2014-10-04 12:43:30 +01:00
si7005.c iio: Drop owner assignment from i2c_driver 2015-07-11 18:50:07 +01:00
si7020.c iio: si7020: Swap data byte order 2015-11-15 12:36:19 +00:00