diff options
author | Axel Lin <axel.lin@gmail.com> | 2012-03-28 07:46:39 -0400 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-04-01 06:59:37 -0400 |
commit | 4af7c1d313a085268d071da6729c4ed055be934f (patch) | |
tree | a67daf6adb071e55705ee33789ec1f3e6056ab58 /drivers/regulator/tps6524x-regulator.c | |
parent | f8ee33936f07d49b8e902920e7a5950ac2118d6a (diff) |
regulator: Convert tps6524x to get_voltage_sel
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'drivers/regulator/tps6524x-regulator.c')
-rw-r--r-- | drivers/regulator/tps6524x-regulator.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/regulator/tps6524x-regulator.c b/drivers/regulator/tps6524x-regulator.c index 3a4a1d550db0..2a828a07386a 100644 --- a/drivers/regulator/tps6524x-regulator.c +++ b/drivers/regulator/tps6524x-regulator.c | |||
@@ -472,7 +472,7 @@ static int set_voltage_sel(struct regulator_dev *rdev, unsigned selector) | |||
472 | return write_field(hw, &info->voltage, selector); | 472 | return write_field(hw, &info->voltage, selector); |
473 | } | 473 | } |
474 | 474 | ||
475 | static int get_voltage(struct regulator_dev *rdev) | 475 | static int get_voltage_sel(struct regulator_dev *rdev) |
476 | { | 476 | { |
477 | const struct supply_info *info; | 477 | const struct supply_info *info; |
478 | struct tps6524x *hw; | 478 | struct tps6524x *hw; |
@@ -490,7 +490,7 @@ static int get_voltage(struct regulator_dev *rdev) | |||
490 | if (WARN_ON(ret >= info->n_voltages)) | 490 | if (WARN_ON(ret >= info->n_voltages)) |
491 | return -EIO; | 491 | return -EIO; |
492 | 492 | ||
493 | return info->voltages[ret]; | 493 | return ret; |
494 | } | 494 | } |
495 | 495 | ||
496 | static int set_current_limit(struct regulator_dev *rdev, int min_uA, | 496 | static int set_current_limit(struct regulator_dev *rdev, int min_uA, |
@@ -575,7 +575,7 @@ static struct regulator_ops regulator_ops = { | |||
575 | .is_enabled = is_supply_enabled, | 575 | .is_enabled = is_supply_enabled, |
576 | .enable = enable_supply, | 576 | .enable = enable_supply, |
577 | .disable = disable_supply, | 577 | .disable = disable_supply, |
578 | .get_voltage = get_voltage, | 578 | .get_voltage_sel = get_voltage_sel, |
579 | .set_voltage_sel = set_voltage_sel, | 579 | .set_voltage_sel = set_voltage_sel, |
580 | .list_voltage = list_voltage, | 580 | .list_voltage = list_voltage, |
581 | .set_current_limit = set_current_limit, | 581 | .set_current_limit = set_current_limit, |