Skip to content

Commit

Permalink
MLK-12861-1 ARM: imx: support runtime clock management on i.mx7d when…
Browse files Browse the repository at this point in the history
… M4 is enabled

For i.MX7D, current runtime clock management code will skip all
PLL/PFD/GATE enable/disable when M4 is enabled, this is NOT good
for power number in low power idle and audio playback, as M4 only
uses one high speed PFD which is from system PLL, it is never
disabled runtimely, so we can just enable the hardware operation of
PLL/PFD/GATE for A7.

Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
  • Loading branch information
Anson-Huang committed May 30, 2016
1 parent 059449a commit 02a2e8d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion arch/arm/mach-imx/clk-gate2.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
#include <linux/string.h>
#include "clk.h"
#include "common.h"
#include "hardware.h"

/**
* DOC: basic gatable clock which can gate and ungate it's ouput
Expand Down Expand Up @@ -58,7 +59,7 @@ static void clk_gate2_do_shared_clks(struct clk_hw *hw, bool enable)
{
struct clk_gate2 *gate = to_clk_gate2(hw);

if (imx_src_is_m4_enabled()) {
if (imx_src_is_m4_enabled() && cpu_is_imx6sx()) {
#ifdef CONFIG_SOC_IMX6SX
if (!amp_power_mutex || !shared_mem) {
if (enable)
Expand Down
3 changes: 2 additions & 1 deletion arch/arm/mach-imx/clk-pfd.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
#include <linux/err.h>
#include "clk.h"
#include "common.h"
#include "hardware.h"

/**
* struct clk_pfd - IMX PFD clock
Expand Down Expand Up @@ -53,7 +54,7 @@ static void clk_pfd_do_shared_clks(struct clk_hw *hw, bool enable)
{
struct clk_pfd *pfd = to_clk_pfd(hw);

if (imx_src_is_m4_enabled()) {
if (imx_src_is_m4_enabled() && cpu_is_imx6sx()) {
#ifdef CONFIG_SOC_IMX6SX
if (!amp_power_mutex || !shared_mem) {
if (enable)
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-imx/clk-pllv3.c
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ static int clk_pllv3_do_hardware(struct clk_hw *hw, bool enable)

static void clk_pllv3_do_shared_clks(struct clk_hw *hw, bool enable)
{
if (imx_src_is_m4_enabled()) {
if (imx_src_is_m4_enabled() && cpu_is_imx6sx()) {
#ifdef CONFIG_SOC_IMX6SX
if (!amp_power_mutex || !shared_mem) {
if (enable)
Expand Down

0 comments on commit 02a2e8d

Please sign in to comment.