mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-21 19:53:59 +08:00
iio: humidity: hdc100x: fix IIO_HUMIDITYRELATIVE channel reporting
The IIO_HUMIDITYRELATIVE channel was being incorrectly reported back as percent when it should have been milli percent. This is via an incorrect scale value being returned to userspace. Signed-off-by: Chris Lesiak <chris.lesiak@licor.com> Acked-by: Matt Ranostay <matt.ranostay@konsulko.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
This commit is contained in:
parent
c41d79b74b
commit
342a6928bd
@ -229,7 +229,7 @@ static int hdc100x_read_raw(struct iio_dev *indio_dev,
|
||||
*val2 = 65536;
|
||||
return IIO_VAL_FRACTIONAL;
|
||||
} else {
|
||||
*val = 100;
|
||||
*val = 100000;
|
||||
*val2 = 65536;
|
||||
return IIO_VAL_FRACTIONAL;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user