Commit 0ad91e9c authored by Ravikumar Kattekola's avatar Ravikumar Kattekola Committed by Greg Kroah-Hartman

ARM: dts: DRA7x: Fix the bypass clock source for dpll_iva and others

commit d2192ea0 upstream.

Fixes: ee6c7507 (ARM: dts: dra7 clock data)

On DRA7x, For DPLL_IVA, the ref clock(CLKINP) is connected to sys_clk1 and
the bypass input(CLKINPULOW) is connected to iva_dpll_hs_clk_div clock.
But the bypass input is not directly routed to bypass clkout instead
both CLKINP and CLKINPULOW are connected to bypass clkout via a mux.

This mux is controlled by the bit - CM_CLKSEL_DPLL_IVA[23]:DPLL_BYP_CLKSEL
and it's POR value is zero which selects the CLKINP as bypass clkout.
which means iva_dpll_hs_clk_div is not the bypass clock for dpll_iva_ck

Fix this by adding another mux clock as parent in bypass mode.

This design is common to most of the PLLs and the rest have only one bypass
clock. Below is a list of the DPLLs that need this fix:

DPLL_IVA, DPLL_DDR,
DPLL_DSP, DPLL_EVE,
DPLL_GMAC, DPLL_PER,
DPLL_USB and DPLL_CORE
Signed-off-by: default avatarRavikumar Kattekola <rk@ti.com>
Acked-by: default avatarTero Kristo <t-kristo@ti.com>
Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent ce0edb9a
...@@ -243,10 +243,18 @@ dpll_abe_m3x2_ck: dpll_abe_m3x2_ck { ...@@ -243,10 +243,18 @@ dpll_abe_m3x2_ck: dpll_abe_m3x2_ck {
ti,invert-autoidle-bit; ti,invert-autoidle-bit;
}; };
dpll_core_byp_mux: dpll_core_byp_mux {
#clock-cells = <0>;
compatible = "ti,mux-clock";
clocks = <&sys_clkin1>, <&dpll_abe_m3x2_ck>;
ti,bit-shift = <23>;
reg = <0x012c>;
};
dpll_core_ck: dpll_core_ck { dpll_core_ck: dpll_core_ck {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "ti,omap4-dpll-core-clock"; compatible = "ti,omap4-dpll-core-clock";
clocks = <&sys_clkin1>, <&dpll_abe_m3x2_ck>; clocks = <&sys_clkin1>, <&dpll_core_byp_mux>;
reg = <0x0120>, <0x0124>, <0x012c>, <0x0128>; reg = <0x0120>, <0x0124>, <0x012c>, <0x0128>;
}; };
...@@ -309,10 +317,18 @@ dsp_dpll_hs_clk_div: dsp_dpll_hs_clk_div { ...@@ -309,10 +317,18 @@ dsp_dpll_hs_clk_div: dsp_dpll_hs_clk_div {
clock-div = <1>; clock-div = <1>;
}; };
dpll_dsp_byp_mux: dpll_dsp_byp_mux {
#clock-cells = <0>;
compatible = "ti,mux-clock";
clocks = <&sys_clkin1>, <&dsp_dpll_hs_clk_div>;
ti,bit-shift = <23>;
reg = <0x0240>;
};
dpll_dsp_ck: dpll_dsp_ck { dpll_dsp_ck: dpll_dsp_ck {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "ti,omap4-dpll-clock"; compatible = "ti,omap4-dpll-clock";
clocks = <&sys_clkin1>, <&dsp_dpll_hs_clk_div>; clocks = <&sys_clkin1>, <&dpll_dsp_byp_mux>;
reg = <0x0234>, <0x0238>, <0x0240>, <0x023c>; reg = <0x0234>, <0x0238>, <0x0240>, <0x023c>;
}; };
...@@ -335,10 +351,18 @@ iva_dpll_hs_clk_div: iva_dpll_hs_clk_div { ...@@ -335,10 +351,18 @@ iva_dpll_hs_clk_div: iva_dpll_hs_clk_div {
clock-div = <1>; clock-div = <1>;
}; };
dpll_iva_byp_mux: dpll_iva_byp_mux {
#clock-cells = <0>;
compatible = "ti,mux-clock";
clocks = <&sys_clkin1>, <&iva_dpll_hs_clk_div>;
ti,bit-shift = <23>;
reg = <0x01ac>;
};
dpll_iva_ck: dpll_iva_ck { dpll_iva_ck: dpll_iva_ck {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "ti,omap4-dpll-clock"; compatible = "ti,omap4-dpll-clock";
clocks = <&sys_clkin1>, <&iva_dpll_hs_clk_div>; clocks = <&sys_clkin1>, <&dpll_iva_byp_mux>;
reg = <0x01a0>, <0x01a4>, <0x01ac>, <0x01a8>; reg = <0x01a0>, <0x01a4>, <0x01ac>, <0x01a8>;
}; };
...@@ -361,10 +385,18 @@ iva_dclk: iva_dclk { ...@@ -361,10 +385,18 @@ iva_dclk: iva_dclk {
clock-div = <1>; clock-div = <1>;
}; };
dpll_gpu_byp_mux: dpll_gpu_byp_mux {
#clock-cells = <0>;
compatible = "ti,mux-clock";
clocks = <&sys_clkin1>, <&dpll_abe_m3x2_ck>;
ti,bit-shift = <23>;
reg = <0x02e4>;
};
dpll_gpu_ck: dpll_gpu_ck { dpll_gpu_ck: dpll_gpu_ck {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "ti,omap4-dpll-clock"; compatible = "ti,omap4-dpll-clock";
clocks = <&sys_clkin1>, <&dpll_abe_m3x2_ck>; clocks = <&sys_clkin1>, <&dpll_gpu_byp_mux>;
reg = <0x02d8>, <0x02dc>, <0x02e4>, <0x02e0>; reg = <0x02d8>, <0x02dc>, <0x02e4>, <0x02e0>;
}; };
...@@ -398,10 +430,18 @@ core_dpll_out_dclk_div: core_dpll_out_dclk_div { ...@@ -398,10 +430,18 @@ core_dpll_out_dclk_div: core_dpll_out_dclk_div {
clock-div = <1>; clock-div = <1>;
}; };
dpll_ddr_byp_mux: dpll_ddr_byp_mux {
#clock-cells = <0>;
compatible = "ti,mux-clock";
clocks = <&sys_clkin1>, <&dpll_abe_m3x2_ck>;
ti,bit-shift = <23>;
reg = <0x021c>;
};
dpll_ddr_ck: dpll_ddr_ck { dpll_ddr_ck: dpll_ddr_ck {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "ti,omap4-dpll-clock"; compatible = "ti,omap4-dpll-clock";
clocks = <&sys_clkin1>, <&dpll_abe_m3x2_ck>; clocks = <&sys_clkin1>, <&dpll_ddr_byp_mux>;
reg = <0x0210>, <0x0214>, <0x021c>, <0x0218>; reg = <0x0210>, <0x0214>, <0x021c>, <0x0218>;
}; };
...@@ -416,10 +456,18 @@ dpll_ddr_m2_ck: dpll_ddr_m2_ck { ...@@ -416,10 +456,18 @@ dpll_ddr_m2_ck: dpll_ddr_m2_ck {
ti,invert-autoidle-bit; ti,invert-autoidle-bit;
}; };
dpll_gmac_byp_mux: dpll_gmac_byp_mux {
#clock-cells = <0>;
compatible = "ti,mux-clock";
clocks = <&sys_clkin1>, <&dpll_abe_m3x2_ck>;
ti,bit-shift = <23>;
reg = <0x02b4>;
};
dpll_gmac_ck: dpll_gmac_ck { dpll_gmac_ck: dpll_gmac_ck {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "ti,omap4-dpll-clock"; compatible = "ti,omap4-dpll-clock";
clocks = <&sys_clkin1>, <&dpll_abe_m3x2_ck>; clocks = <&sys_clkin1>, <&dpll_gmac_byp_mux>;
reg = <0x02a8>, <0x02ac>, <0x02b4>, <0x02b0>; reg = <0x02a8>, <0x02ac>, <0x02b4>, <0x02b0>;
}; };
...@@ -482,10 +530,18 @@ eve_dpll_hs_clk_div: eve_dpll_hs_clk_div { ...@@ -482,10 +530,18 @@ eve_dpll_hs_clk_div: eve_dpll_hs_clk_div {
clock-div = <1>; clock-div = <1>;
}; };
dpll_eve_byp_mux: dpll_eve_byp_mux {
#clock-cells = <0>;
compatible = "ti,mux-clock";
clocks = <&sys_clkin1>, <&eve_dpll_hs_clk_div>;
ti,bit-shift = <23>;
reg = <0x0290>;
};
dpll_eve_ck: dpll_eve_ck { dpll_eve_ck: dpll_eve_ck {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "ti,omap4-dpll-clock"; compatible = "ti,omap4-dpll-clock";
clocks = <&sys_clkin1>, <&eve_dpll_hs_clk_div>; clocks = <&sys_clkin1>, <&dpll_eve_byp_mux>;
reg = <0x0284>, <0x0288>, <0x0290>, <0x028c>; reg = <0x0284>, <0x0288>, <0x0290>, <0x028c>;
}; };
...@@ -1249,10 +1305,18 @@ apll_pcie_m2_ck: apll_pcie_m2_ck { ...@@ -1249,10 +1305,18 @@ apll_pcie_m2_ck: apll_pcie_m2_ck {
clock-div = <1>; clock-div = <1>;
}; };
dpll_per_byp_mux: dpll_per_byp_mux {
#clock-cells = <0>;
compatible = "ti,mux-clock";
clocks = <&sys_clkin1>, <&per_dpll_hs_clk_div>;
ti,bit-shift = <23>;
reg = <0x014c>;
};
dpll_per_ck: dpll_per_ck { dpll_per_ck: dpll_per_ck {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "ti,omap4-dpll-clock"; compatible = "ti,omap4-dpll-clock";
clocks = <&sys_clkin1>, <&per_dpll_hs_clk_div>; clocks = <&sys_clkin1>, <&dpll_per_byp_mux>;
reg = <0x0140>, <0x0144>, <0x014c>, <0x0148>; reg = <0x0140>, <0x0144>, <0x014c>, <0x0148>;
}; };
...@@ -1275,10 +1339,18 @@ func_96m_aon_dclk_div: func_96m_aon_dclk_div { ...@@ -1275,10 +1339,18 @@ func_96m_aon_dclk_div: func_96m_aon_dclk_div {
clock-div = <1>; clock-div = <1>;
}; };
dpll_usb_byp_mux: dpll_usb_byp_mux {
#clock-cells = <0>;
compatible = "ti,mux-clock";
clocks = <&sys_clkin1>, <&usb_dpll_hs_clk_div>;
ti,bit-shift = <23>;
reg = <0x018c>;
};
dpll_usb_ck: dpll_usb_ck { dpll_usb_ck: dpll_usb_ck {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "ti,omap4-dpll-j-type-clock"; compatible = "ti,omap4-dpll-j-type-clock";
clocks = <&sys_clkin1>, <&usb_dpll_hs_clk_div>; clocks = <&sys_clkin1>, <&dpll_usb_byp_mux>;
reg = <0x0180>, <0x0184>, <0x018c>, <0x0188>; reg = <0x0180>, <0x0184>, <0x018c>, <0x0188>;
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment