summaryrefslogtreecommitdiff
path: root/drivers/regulator/tps6524x-regulator.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2012-03-14 17:16:02 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2012-03-14 17:16:02 -0700
commitff398c45b03d9d64135d928c0146d8c38a70fd3b (patch)
treecb7feb8551e0424963305a4d36562145e0298535 /drivers/regulator/tps6524x-regulator.c
parentcc198126c5b6fb675140b245b5757692a77bb9a0 (diff)
parent9365121869a15da99d6091802f11a82d59024d62 (diff)
Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator
Pull regulator fixes from Mark Brown: "Another small batch of driver specific bug fixes, a couple more errors in the da9052 driver and a bad return value in the tps6524x driver." * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: regulator: da9052: Ensure the selected voltage falls within the specified range regulator: Set n_voltages for da9052 regulators regulator: Fix setting selector in tps6524x set_voltage function
Diffstat (limited to 'drivers/regulator/tps6524x-regulator.c')
-rw-r--r--drivers/regulator/tps6524x-regulator.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/regulator/tps6524x-regulator.c b/drivers/regulator/tps6524x-regulator.c
index 70b7b1f4f00..2e94686b6fe 100644
--- a/drivers/regulator/tps6524x-regulator.c
+++ b/drivers/regulator/tps6524x-regulator.c
@@ -481,7 +481,7 @@ static int set_voltage(struct regulator_dev *rdev, int min_uV, int max_uV,
if (i >= info->n_voltages)
i = info->n_voltages - 1;
- *selector = info->voltages[i];
+ *selector = i;
return write_field(hw, &info->voltage, i);
}