diff options
author | Axel Lin <axel.lin@gmail.com> | 2012-06-18 10:11:28 +0800 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-06-18 10:56:51 +0100 |
commit | 398715ab9414b3b7741c8239c254111f5016821c (patch) | |
tree | b617985059b139e4b799eb973ea75f0e829e0253 /lib/idr.c | |
parent | 086ccd4379ad6c9c7c7713ef5f61b9d12e995147 (diff) |
regulator: core: Support table based mapping in regulator_set_voltage_time_sel
For table based mapping, we can calculate voltage difference by below equation:
abs(rdev->desc->volt_table[new_selector] - rdev->desc->volt_table[old_selector])
Thus we can make regulator_set_voltage_time_sel work for table based mapping.
regulator_set_voltage_time_sel() only supports linear or table based mapping.
In case it is misused, also warn if neither linear nor table based mapping
is used with regulator_set_voltage_time_sel().
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'lib/idr.c')
0 files changed, 0 insertions, 0 deletions