[PATCH][Xenial SRU] iio: st_pressure: initialize lps22hb bootime

Shrirang Bagul shrirang.bagul at canonical.com
Wed Apr 12 12:23:48 UTC 2017


BugLink: https://bugs.launchpad.net/bugs/1682103

This patch initializes the bootime in struct st_sensor_settings for
lps22hb sensor. Without this, sensor channels read from sysfs always
report stale values.

Signed-off-by: Shrirang Bagul <shrirang.bagul at canonical.com>
Cc: <Stable at vger.kernel.org>
Signed-off-by: Jonathan Cameron <jic23 at kernel.org>
(backported from commit 51f528a1636f352ad776a912ac86026ac7a89a2a)
Signed-off-by: Shrirang Bagul <shrirang.bagul at canonical.com>
---
 drivers/iio/pressure/st_pressure_core.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/iio/pressure/st_pressure_core.c b/drivers/iio/pressure/st_pressure_core.c
index da8f147..542b644 100644
--- a/drivers/iio/pressure/st_pressure_core.c
+++ b/drivers/iio/pressure/st_pressure_core.c
@@ -533,6 +533,7 @@ static const struct st_sensor_settings st_press_sensors_settings[] = {
 			.mask_int2 = ST_PRESS_LPS22HB_DRDY_IRQ_INT2_MASK,
 		},
 		.multi_read_bit = ST_PRESS_LPS22HB_MULTIREAD_BIT,
+		.bootime = 2,
 	},
 };
 
-- 
2.9.3





More information about the kernel-team mailing list