regulator: anatop: Use linear_min_sel with linear mapping
authorAxel Lin <axel.lin@ingics.com>
Sun, 9 Dec 2012 00:05:45 +0000 (08:05 +0800)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 10 Dec 2012 03:38:09 +0000 (12:38 +0900)
commit985884db501d7026257d122c3cc32a7005a9a864
tree96379e7eb17813863a6fefe27a08064f2da841de
parent5d6e6ffc400dbc3ea0cc58b8b6f9d9ac748d6572
regulator: anatop: Use linear_min_sel with linear mapping

By setting linear_min_sel to anatop_reg->min_bit_val, we can avoid
adjust the anatop_reg->min_bit_val offset in [set|get]_voltage_sel.

With this chance we can refactor this driver to use
regulator_[get|set]_voltage_sel_regmap.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Reviewed-by: Ying-Chun Liu <paulliu@debian.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
drivers/regulator/anatop-regulator.c