]> git.karo-electronics.de Git - mv-sheeva.git/commit
regulator: tps6586x-regulator - fix value range checking for val
authorAxel Lin <axel.lin@gmail.com>
Sun, 22 Aug 2010 14:38:15 +0000 (22:38 +0800)
committerLiam Girdwood <lrg@slimlogic.co.uk>
Wed, 1 Sep 2010 11:59:34 +0000 (12:59 +0100)
commit327531bada36e5786b13bb6918ad8afc545adfa2
tree1ea5cb6f7d430a793eed7e2e5cf803f8cf16bb79
parentc356cbc2d4d99cf5a1429603fa1841e50987c4d3
regulator: tps6586x-regulator - fix value range checking for val

val is used as array index of ri->voltages.
Thus the valid value range should be 0 .. ri->desc.n_voltages - 1.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
drivers/regulator/tps6586x-regulator.c