]> git.baikalelectronics.ru Git - kernel.git/commit
iio: cros_ec: Reapply range at resume
authorGwendal Grignou <gwendal@chromium.org>
Wed, 27 May 2020 04:35:17 +0000 (21:35 -0700)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sun, 14 Jun 2020 10:49:41 +0000 (11:49 +0100)
commit0008cd2ca845a3140ae8f615c5a62c567ba2dd30
tree4c3279b9dcd7fa1c8009f2f8df4ad748db14d625
parentd1003d132919948f522b6868ea3c1231d3bb5e67
iio: cros_ec: Reapply range at resume

EC does not currently preserve range across sensor reinit.
If sensor is powered down at suspend, it will default to the EC default
range at resume, not the range set by the host.

Save range if modified, and apply at resume.

Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/common/cros_ec_sensors/cros_ec_sensors.c
drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.c
drivers/iio/light/cros_ec_light_prox.c
drivers/iio/pressure/cros_ec_baro.c
include/linux/iio/common/cros_ec_sensors_core.h