diff options
author | Peng Fan <Peng.Fan@freescale.com> | 2015-04-29 10:52:52 +0800 |
---|---|---|
committer | Peng Fan <Peng.Fan@freescale.com> | 2015-04-29 15:10:57 +0800 |
commit | dd842f32b6d8d770e844790643ece352f92b8c5e (patch) | |
tree | 976176297a3cf2b160bf73632e0a88e86c227852 /board/freescale/mx6slevk | |
parent | b7f3f9a6100519c784085ea9f6e575162555fb42 (diff) | |
download | u-boot-imx-dd842f32b6d8d770e844790643ece352f92b8c5e.zip u-boot-imx-dd842f32b6d8d770e844790643ece352f92b8c5e.tar.gz u-boot-imx-dd842f32b6d8d770e844790643ece352f92b8c5e.tar.bz2 |
MLK-10774-53 imx: update setting pmic volatage
We should not rely on pfuze_common_init to set the voltage,
may be we should remove the voltage settings in pfuze_common_init.
This patch is to setting the voltages in power_init_board.
Signed-off-by: Peng Fan <Peng.Fan@freescale.com>
Diffstat (limited to 'board/freescale/mx6slevk')
-rw-r--r-- | board/freescale/mx6slevk/mx6slevk.c | 32 |
1 files changed, 31 insertions, 1 deletions
diff --git a/board/freescale/mx6slevk/mx6slevk.c b/board/freescale/mx6slevk/mx6slevk.c index c721055..76a991f 100644 --- a/board/freescale/mx6slevk/mx6slevk.c +++ b/board/freescale/mx6slevk/mx6slevk.c @@ -380,11 +380,41 @@ struct i2c_pads_info i2c_pad_info1 = { static struct pmic *pfuze; int power_init_board(void) { + unsigned int reg, ret; + pfuze = pfuze_common_init(I2C_PMIC); if (!pfuze) return -ENODEV; - return pfuze_mode_init(pfuze, APS_PFM); + ret = pfuze_mode_init(pfuze, APS_PFM); + if (ret < 0) + return ret; + + /* set SW1AB staby volatage 0.975V */ + pmic_reg_read(pfuze, PFUZE100_SW1ABSTBY, ®); + reg &= ~0x3f; + reg |= 0x1b; + pmic_reg_write(pfuze, PFUZE100_SW1ABSTBY, reg); + + /* set SW1AB/VDDARM step ramp up time from 16us to 4us/25mV */ + pmic_reg_read(pfuze, PFUZE100_SW1ABCONF, ®); + reg &= ~0xc0; + reg |= 0x40; + pmic_reg_write(pfuze, PFUZE100_SW1ABCONF, reg); + + /* set SW1C staby volatage 0.975V */ + pmic_reg_read(pfuze, PFUZE100_SW1CSTBY, ®); + reg &= ~0x3f; + reg |= 0x1b; + pmic_reg_write(pfuze, PFUZE100_SW1CSTBY, reg); + + /* set SW1C/VDDSOC step ramp up time to from 16us to 4us/25mV */ + pmic_reg_read(pfuze, PFUZE100_SW1CCONF, ®); + reg &= ~0xc0; + reg |= 0x40; + pmic_reg_write(pfuze, PFUZE100_SW1CCONF, reg); + + return 0; } #ifdef CONFIG_LDO_BYPASS_CHECK |