diff options
author | Matt Ranostay <mranostay@gmail.com> | 2016-02-14 02:20:42 +0100 |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2016-02-19 19:57:13 +0100 |
commit | 0d43b3468871f5d5194edfe7052b6a49691eb6fd (patch) | |
tree | 4276b06fa10a6b7dddf40a2506fdd5bb7445d5d4 /drivers/iio/chemical | |
parent | iio: Fix typos in the struct iio_event_spec documentation comments (diff) | |
download | linux-0d43b3468871f5d5194edfe7052b6a49691eb6fd.tar.xz linux-0d43b3468871f5d5194edfe7052b6a49691eb6fd.zip |
iio: chemical: atlas-ph-sensor: switch regmap cache
switch from using REGCACHE_FLAT to REGCACHE_RBTREE so initial hw values
are read from device. This also allows some volatile ranges to be
dropped.
Note that REGCACHE_FLAT is intended only for very low lag cases so doesn't
do nice things like read initial values from the device. Hence this change.
Signed-off-by: Matt Ranostay <mranostay@gmail.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'drivers/iio/chemical')
-rw-r--r-- | drivers/iio/chemical/atlas-ph-sensor.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/iio/chemical/atlas-ph-sensor.c b/drivers/iio/chemical/atlas-ph-sensor.c index 06cd49cbfae1..71c8e02ea48a 100644 --- a/drivers/iio/chemical/atlas-ph-sensor.c +++ b/drivers/iio/chemical/atlas-ph-sensor.c @@ -65,8 +65,6 @@ struct atlas_data { static const struct regmap_range atlas_volatile_ranges[] = { regmap_reg_range(ATLAS_REG_INT_CONTROL, ATLAS_REG_INT_CONTROL), - regmap_reg_range(ATLAS_REG_CALIB_STATUS, ATLAS_REG_CALIB_STATUS), - regmap_reg_range(ATLAS_REG_TEMP_DATA, ATLAS_REG_TEMP_DATA + 4), regmap_reg_range(ATLAS_REG_PH_DATA, ATLAS_REG_PH_DATA + 4), }; @@ -83,7 +81,7 @@ static const struct regmap_config atlas_regmap_config = { .volatile_table = &atlas_volatile_table, .max_register = ATLAS_REG_PH_DATA + 4, - .cache_type = REGCACHE_FLAT, + .cache_type = REGCACHE_RBTREE, }; static const struct iio_chan_spec atlas_channels[] = { |