linux-stable/drivers/iio
Narcisa Ana Maria Vasile 8f114acd4e iio: chemical: ccs811: Fix output of IIO_CONCENTRATION channels
in_concentration_raw should report, according to sysfs-bus-iio documentation,
a "Raw (unscaled no offset etc.) percentage reading of a substance."

Modify scale to convert from ppm/ppb to percentage:
1 ppm = 0.0001%
1 ppb = 0.0000001%

There is no offset needed to convert the ppm/ppb to percentage,
so remove offset from IIO_CONCENTRATION (IIO_MOD_CO2) channel.

Cc'd stable to reduce chance of userspace breakage in the long
run as we fix this wrong bit of ABI usage.

Signed-off-by: Narcisa Ana Maria Vasile <narcisaanamaria12@gmail.com>
Cc: <Stable@vger.kernel.org>
Reviewed-by: Matt Ranostay <matt.ranostay@konsulko.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-01-08 16:03:44 +01:00
..
accel iio: mma8452: replace license description with SPDX specifier 2018-01-08 16:03:41 +01:00
adc iio: adc: stm32: fix scan of multiple channels with DMA 2018-01-08 16:03:43 +01:00
amplifiers iio:amplifiers:ad8366 drop assign iio_info.driver_module and iio_trigger_ops.owner 2017-08-22 21:24:50 +01:00
buffer License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
chemical iio: chemical: ccs811: Fix output of IIO_CONCENTRATION channels 2018-01-08 16:03:44 +01:00
common iio: common: ssp_sensors: account for const type of of_device_id.data 2018-01-08 16:03:43 +01:00
counter iio: stm32: Adopt SPDX identifier 2018-01-08 16:03:41 +01:00
dac iio: dac: mcp4725: Remove unneeded conversions to bool 2018-01-08 16:03:41 +01:00
dummy iio: dummy_evgen: modify the return value check for irq_sim_init() 2018-01-08 16:03:41 +01:00
frequency iio:frequency: drop assign iio_info.driver_module 2017-08-22 21:28:20 +01:00
gyro gyro:adis16136: fix debugfs_simple_attr.cocci warnings 2018-01-08 16:03:44 +01:00
health Merge Linus's staging merge point into staging-next 2017-12-06 15:27:17 +01:00
humidity iio: humidity: hts221: move common code in hts221_core 2018-01-08 16:03:43 +01:00
imu imu:adis16480: fix debugfs_simple_attr.cocci warnings 2018-01-08 16:03:44 +01:00
light iio: light: make a couple of config structures static 2018-01-08 16:03:41 +01:00
magnetometer iio: magnetometer: ak8975: Add another ACPI ID 2017-12-02 10:40:02 +00:00
multiplexer iio: multiplexer: add NULL check on devm_kzalloc() and devm_kmemdup() return values 2017-09-03 18:10:29 +01:00
orientation iio:orientation: drop assign iio_info.driver_module 2017-08-22 21:33:36 +01:00
potentiometer Staging/IIO patches for 4.15-rc1 2017-11-13 20:53:28 -08:00
potentiostat iio:potentiostat:lmp91000 drop assign iio_info.driver_module and iio_trigger_ops.owner 2017-08-22 21:34:48 +01:00
pressure iio:pressure:bmp280: Read calibration data in probe 2018-01-08 16:03:43 +01:00
proximity Merge Linus's staging merge point into staging-next 2017-12-06 15:27:17 +01:00
temperature Staging/IIO patches for 4.15-rc1 2017-11-13 20:53:28 -08:00
trigger iio: stm32: Adopt SPDX identifier 2018-01-08 16:03:41 +01:00
iio_core.h
iio_core_trigger.h
industrialio-buffer.c iio: buffer: Expose data available 2018-01-08 16:03:41 +01:00
industrialio-configfs.c iio: make function argument and some structures const 2017-10-19 16:15:24 +02:00
industrialio-core.c Merge Linus's staging merge point into staging-next 2017-12-06 15:27:17 +01:00
industrialio-event.c
industrialio-sw-device.c iio: make function argument and some structures const 2017-10-19 16:15:24 +02:00
industrialio-sw-trigger.c iio: make function argument and some structures const 2017-10-19 16:15:24 +02:00
industrialio-trigger.c iio:trigger: Remove necessity to have a trig->ops structure. 2017-08-22 21:20:28 +01:00
industrialio-triggered-event.c
inkern.c First round of IIO new device support, features and cleanups for the 4.14 cycle. 2017-07-27 21:29:49 -07:00
Kconfig iio: multiplexer: new iio category and iio-mux driver 2017-06-03 19:29:26 +09:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00