MLK-13894 ARM: imx: Add low power run voltage change support on i.mx6ull
authorBai Ping <ping.bai@nxp.com>
Wed, 8 Feb 2017 09:22:58 +0000 (17:22 +0800)
committerNitin Garg <nitin.garg@nxp.com>
Mon, 19 Mar 2018 19:58:26 +0000 (14:58 -0500)
Drop the VDD_SOC and VDD_ARM voltage to 0.9V when system runs at low
power run mode.

Signed-off-by: Bai Ping <ping.bai@nxp.com>
arch/arm/mach-imx/busfreq-imx.c

index 1c297a0..5f96e77 100644 (file)
@@ -1,5 +1,6 @@
 /*
  * Copyright (C) 2011-2016 Freescale Semiconductor, Inc. All Rights Reserved.
+ * Copyright 2017 NXP.
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -172,10 +173,8 @@ static void imx6ull_lower_cpu_rate(bool enter)
 
        if (enter) {
                org_arm_rate = clk_get_rate(arm_clk);
-               if (cpu_is_imx6sll()) {
-                       origin_arm_volt = regulator_get_voltage(arm_reg);
-                       origin_soc_volt = regulator_get_voltage(soc_reg);
-               }
+               origin_arm_volt = regulator_get_voltage(arm_reg);
+               origin_soc_volt = regulator_get_voltage(soc_reg);
        }
 
        clk_set_parent(pll1_bypass_clk, pll1_bypass_src_clk);
@@ -195,7 +194,7 @@ static void imx6ull_lower_cpu_rate(bool enter)
                                pr_err("set soc reg voltage failed\n");
                }
        } else {
-               if (cpu_is_imx6sll() && uart_from_osc) {
+               if (uart_from_osc) {
                        ret = regulator_set_voltage_tol(soc_reg, origin_soc_volt, 0);
                        if (ret)
                                pr_err("set soc reg voltage failed\n");