OSDN Git Service

regulator: max8925: fix enabled/disabled judgement mistake
authorKevin Liu <kliu5@marvell.com>
Wed, 4 Jan 2012 07:12:04 +0000 (15:12 +0800)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Fri, 6 Jan 2012 18:56:14 +0000 (10:56 -0800)
commit65364e9ab958f4ad21c5c7b6cc8e2e458128dbcb
tree481535ab2a705f68270015d64fedc67aca10d7e0
parente1de2f423462a5c6ba2c902dff1f5ddd8d3dbde3
regulator: max8925: fix enabled/disabled judgement mistake

Max8925 ldo status should be determined by two factors:
1. power up/down sequence selection(LDOCTL[4:2]).
2. i2c enable bit(LDOCTL[0]).

Max8925 ldo support two types of power up/down sequence:
1. flexible sequence(LDOCTL[4:2] = 0~6).
2. i2c sequence(LDOCTL[4:2] = 7).

With flexible sequence selected, the ldo is enabled during power up by default.
With i2c sequence selected, the ldo is controlled by the i2c enable bit(LDOCTL[0]).

Signed-off-by: Kevin Liu <kliu5@marvell.com>
Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
drivers/regulator/max8925-regulator.c