diff options
author | Ye.Li <B37916@freescale.com> | 2014-06-04 11:38:13 +0800 |
---|---|---|
committer | Peng Fan <Peng.Fan@freescale.com> | 2015-04-29 14:40:29 +0800 |
commit | 420626272a5fb4975ebbd7ec357e574cb2b073c6 (patch) | |
tree | 5c81f7e07a3bcc108b442e3cb5341ae4d17c9ec6 /arch | |
parent | 5028519b434d5dfbe53c48ac4b115ff8b69bbac7 (diff) | |
download | u-boot-imx-420626272a5fb4975ebbd7ec357e574cb2b073c6.zip u-boot-imx-420626272a5fb4975ebbd7ec357e574cb2b073c6.tar.gz u-boot-imx-420626272a5fb4975ebbd7ec357e574cb2b073c6.tar.bz2 |
ENGR00315894-11 i.mx6:shutdown vddpu and pcie phy to save power
shutdown vddpu and pcie phy to save power
Signed-off-by: Anson Huang <b20788@freescale.com>
Signed-off-by: Jason Liu <r64343@freescale.com>
Signed-off-by: Ye.Li <B37916@freescale.com>
(cherry picked from commit 580011f86caf137d59a487694f6f7da042164e05)
Signed-off-by: Peng Fan <Peng.Fan@freescale.com>
Conflicts:
arch/arm/cpu/armv7/mx6/soc.c
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/cpu/armv7/mx6/soc.c | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/arch/arm/cpu/armv7/mx6/soc.c b/arch/arm/cpu/armv7/mx6/soc.c index 06a9e6d..ea1143b 100644 --- a/arch/arm/cpu/armv7/mx6/soc.c +++ b/arch/arm/cpu/armv7/mx6/soc.c @@ -305,6 +305,34 @@ static void init_src(void) writel(val, &src_regs->scr); } +static void imx_set_vddpu_power_down(void) +{ + struct anatop_regs *anatop = (struct anatop_regs *)ANATOP_BASE_ADDR; + u32 val; + + /* need to power down xPU in GPC before turn off PU LDO */ + val = readl(GPC_BASE_ADDR + 0x260); + writel(val | 0x1, GPC_BASE_ADDR + 0x260); + + val = readl(GPC_BASE_ADDR + 0x0); + writel(val | 0x1, GPC_BASE_ADDR + 0x0); + while (readl(GPC_BASE_ADDR + 0x0) & 0x1) + ; + + /* disable VDDPU */ + val = 0x3e00; + writel(val, &anatop->reg_core_clr); +} + +static void imx_set_pcie_phy_power_down(void) +{ + u32 val; + + val = readl(IOMUXC_BASE_ADDR + 0x4); + val |= 0x1 << 18; + writel(val, IOMUXC_BASE_ADDR + 0x4); +} + int arch_cpu_init(void) { init_aips(); @@ -334,6 +362,9 @@ int arch_cpu_init(void) imx_set_wdog_powerdown(false); /* Disable PDE bit of WMCR register */ + imx_set_pcie_phy_power_down(); + imx_set_vddpu_power_down(); + #ifdef CONFIG_APBH_DMA /* Start APBH DMA */ mxs_dma_init(); |