regulator: use voltage number array in 88pm860x
authorHaojian Zhuang <haojian.zhuang@marvell.com>
Tue, 4 May 2010 13:54:51 +0000 (09:54 -0400)
committerLiam Girdwood <lrg@slimlogic.co.uk>
Tue, 25 May 2010 09:16:02 +0000 (10:16 +0100)
commit9f79e9db2e282857912bcfe7f741bcdd5c46e860
tree690e0647b56032ef703112e6e03c0b65ddaea10c
parent192bbb95ca16f2b4d4383e76b3262672e6116daa
regulator: use voltage number array in 88pm860x

A lot of condition comparision statements are used in original driver. These
statements are used to check the boundary of voltage numbers since voltage
number isn't linear.

Now use array of voltage numbers instead. Clean code with simpler way.

Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
drivers/mfd/88pm860x-core.c
drivers/regulator/88pm8607.c
include/linux/mfd/88pm860x.h