OpenCloudOS-Kernel/drivers/iio/temperature
sayli karnik 231147ee77 iio: maxim_thermocouple: Align 16 bit big endian value of raw reads
Driver was reporting invalid raw read values for MAX6675 on big
endian architectures. MAX6675 buffered mode is not affected, nor
is the MAX31855.

The driver was losing a 2 byte read value when it used a 32 bit
integer buffer to store a 16 bit big endian value. Use big endian
types to properly align buffers on big endian architectures.

Fixes following sparse endianness warnings:
warning: cast to restricted __be16
warning: cast to restricted __be32
Fixes checkpatch issue:
CHECK: No space is necessary after a cast

Signed-off-by: sayli karnik <karniksayli1995@gmail.com>
Fixes: 1f25ca11d8 ("iio: temperature: add support for Maxim
thermocouple chips")
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2016-10-01 14:40:23 +01:00
..
Kconfig iio: temperature: add Kconfig selects for triggered buffer 2016-08-21 19:50:44 +01:00
Makefile iio: temperature: add support for Maxim thermocouple chips 2016-07-10 14:44:03 +01:00
maxim_thermocouple.c iio: maxim_thermocouple: Align 16 bit big endian value of raw reads 2016-10-01 14:40:23 +01:00
mlx90614.c iio: convert to common i2c_check_functionality() return value 2016-02-27 17:17:43 +00:00
tmp006.c iio: convert to common i2c_check_functionality() return value 2016-02-27 17:17:43 +00:00
tsys01.c iio: convert to common i2c_check_functionality() return value 2016-02-27 17:17:43 +00:00
tsys02d.c iio: Export I2C module alias information 2016-05-21 20:08:14 +01:00