Commit b50003b6 authored by Axel Lin's avatar Axel Lin Committed by Mark Brown

regulator: lp3972: Convert to use regulator_map_voltage_ascend

All regulators have ascendant voltage list in this driver.
Thus use regulator_map_voltage_ascend is more efficient than the default
regulator_map_voltage_iterate.
Signed-off-by: default avatarAxel Lin <axel.lin@ingics.com>
Acked-by: default avatarMarek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent 3e655618
...@@ -309,6 +309,7 @@ static int lp3972_ldo_set_voltage_sel(struct regulator_dev *dev, ...@@ -309,6 +309,7 @@ static int lp3972_ldo_set_voltage_sel(struct regulator_dev *dev,
static struct regulator_ops lp3972_ldo_ops = { static struct regulator_ops lp3972_ldo_ops = {
.list_voltage = regulator_list_voltage_table, .list_voltage = regulator_list_voltage_table,
.map_voltage = regulator_map_voltage_ascend,
.is_enabled = lp3972_ldo_is_enabled, .is_enabled = lp3972_ldo_is_enabled,
.enable = lp3972_ldo_enable, .enable = lp3972_ldo_enable,
.disable = lp3972_ldo_disable, .disable = lp3972_ldo_disable,
...@@ -389,6 +390,7 @@ static int lp3972_dcdc_set_voltage_sel(struct regulator_dev *dev, ...@@ -389,6 +390,7 @@ static int lp3972_dcdc_set_voltage_sel(struct regulator_dev *dev,
static struct regulator_ops lp3972_dcdc_ops = { static struct regulator_ops lp3972_dcdc_ops = {
.list_voltage = regulator_list_voltage_table, .list_voltage = regulator_list_voltage_table,
.map_voltage = regulator_map_voltage_ascend,
.is_enabled = lp3972_dcdc_is_enabled, .is_enabled = lp3972_dcdc_is_enabled,
.enable = lp3972_dcdc_enable, .enable = lp3972_dcdc_enable,
.disable = lp3972_dcdc_disable, .disable = lp3972_dcdc_disable,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment