Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

clk: st: Adds divmux and prediv clock binding

Signed-off-by: Gabriel Fernandez <gabriel.fernandez@st.com>
Signed-off-by: Mike Turquette <mturquette@linaro.org>

authored by

Gabriel FERNANDEZ and committed by
Mike Turquette
be10afcd ab35dc13

+168
+49
Documentation/devicetree/bindings/clock/st/st,clkgen-divmux.txt
··· 1 + Binding for a ST divider and multiplexer clock driver. 2 + 3 + This binding uses the common clock binding[1]. 4 + Base address is located to the parent node. See clock binding[2] 5 + 6 + [1] Documentation/devicetree/bindings/clock/clock-bindings.txt 7 + [2] Documentation/devicetree/bindings/clock/st/st,clkgen.txt 8 + 9 + Required properties: 10 + 11 + - compatible : shall be: 12 + "st,clkgena-divmux-c65-hs", "st,clkgena-divmux" 13 + "st,clkgena-divmux-c65-ls", "st,clkgena-divmux" 14 + "st,clkgena-divmux-c32-odf0", "st,clkgena-divmux" 15 + "st,clkgena-divmux-c32-odf1", "st,clkgena-divmux" 16 + "st,clkgena-divmux-c32-odf2", "st,clkgena-divmux" 17 + "st,clkgena-divmux-c32-odf3", "st,clkgena-divmux" 18 + 19 + - #clock-cells : From common clock binding; shall be set to 1. 20 + 21 + - clocks : From common clock binding 22 + 23 + - clock-output-names : From common clock binding. 24 + 25 + Example: 26 + 27 + clockgenA@fd345000 { 28 + reg = <0xfd345000 0xb50>; 29 + 30 + CLK_M_A1_DIV1: CLK_M_A1_DIV1 { 31 + #clock-cells = <1>; 32 + compatible = "st,clkgena-divmux-c32-odf1", 33 + "st,clkgena-divmux"; 34 + 35 + clocks = <&CLK_M_A1_OSC_PREDIV>, 36 + <&CLK_M_A1_PLL0 1>, /* PLL0 PHI1 */ 37 + <&CLK_M_A1_PLL1 1>; /* PLL1 PHI1 */ 38 + 39 + clock-output-names = "CLK_M_RX_ICN_TS", 40 + "CLK_M_RX_ICN_VDP_0", 41 + "", /* Unused */ 42 + "CLK_M_PRV_T1_BUS", 43 + "CLK_M_ICN_REG_12", 44 + "CLK_M_ICN_REG_10", 45 + "", /* Unused */ 46 + "CLK_M_ICN_ST231"; 47 + }; 48 + }; 49 +
+36
Documentation/devicetree/bindings/clock/st/st,clkgen-prediv.txt
··· 1 + Binding for a ST pre-divider clock driver. 2 + 3 + This binding uses the common clock binding[1]. 4 + Base address is located to the parent node. See clock binding[2] 5 + 6 + [1] Documentation/devicetree/bindings/clock/clock-bindings.txt 7 + [2] Documentation/devicetree/bindings/clock/st/st,clkgen.txt 8 + 9 + Required properties: 10 + 11 + - compatible : shall be: 12 + "st,clkgena-prediv-c65", "st,clkgena-prediv" 13 + "st,clkgena-prediv-c32", "st,clkgena-prediv" 14 + 15 + - #clock-cells : From common clock binding; shall be set to 0. 16 + 17 + - clocks : From common clock binding 18 + 19 + - clock-output-names : From common clock binding. 20 + 21 + Example: 22 + 23 + clockgenA@fd345000 { 24 + reg = <0xfd345000 0xb50>; 25 + 26 + CLK_M_A2_OSC_PREDIV: CLK_M_A2_OSC_PREDIV { 27 + #clock-cells = <0>; 28 + compatible = "st,clkgena-prediv-c32", 29 + "st,clkgena-prediv"; 30 + 31 + clocks = <&CLK_SYSIN>; 32 + 33 + clock-output-names = "CLK_M_A2_OSC_PREDIV"; 34 + }; 35 + }; 36 +
+83
Documentation/devicetree/bindings/clock/st/st,clkgen.txt
··· 1 + Binding for a Clockgen hardware block found on 2 + certain STMicroelectronics consumer electronics SoC devices. 3 + 4 + A Clockgen node can contain pll, diviser or multiplexer nodes. 5 + 6 + We will find only the base address of the Clockgen, this base 7 + address is common of all subnode. 8 + 9 + clockgen_node { 10 + reg = <>; 11 + 12 + pll_node { 13 + ... 14 + }; 15 + 16 + prediv_node { 17 + ... 18 + }; 19 + 20 + divmux_node { 21 + ... 22 + }; 23 + 24 + quadfs_node { 25 + ... 26 + }; 27 + ... 28 + }; 29 + 30 + This binding uses the common clock binding[1]. 31 + Each subnode should use the binding discribe in [2]..[4] 32 + 33 + [1] Documentation/devicetree/bindings/clock/clock-bindings.txt 34 + [2] Documentation/devicetree/bindings/clock/st,quadfs.txt 35 + [3] Documentation/devicetree/bindings/clock/st,quadfs.txt 36 + [4] Documentation/devicetree/bindings/clock/st,quadfs.txt 37 + 38 + Required properties: 39 + - reg : A Base address and length of the register set. 40 + 41 + Example: 42 + 43 + clockgenA@fee62000 { 44 + 45 + reg = <0xfee62000 0xb48>; 46 + 47 + CLK_S_A0_PLL: CLK_S_A0_PLL { 48 + #clock-cells = <1>; 49 + compatible = "st,clkgena-plls-c65"; 50 + 51 + clocks = <&CLK_SYSIN>; 52 + 53 + clock-output-names = "CLK_S_A0_PLL0_HS", 54 + "CLK_S_A0_PLL0_LS", 55 + "CLK_S_A0_PLL1"; 56 + }; 57 + 58 + CLK_S_A0_OSC_PREDIV: CLK_S_A0_OSC_PREDIV { 59 + #clock-cells = <0>; 60 + compatible = "st,clkgena-prediv-c65", 61 + "st,clkgena-prediv"; 62 + 63 + clocks = <&CLK_SYSIN>; 64 + 65 + clock-output-names = "CLK_S_A0_OSC_PREDIV"; 66 + }; 67 + 68 + CLK_S_A0_HS: CLK_S_A0_HS { 69 + #clock-cells = <1>; 70 + compatible = "st,clkgena-divmux-c65-hs", 71 + "st,clkgena-divmux"; 72 + 73 + clocks = <&CLK_S_A0_OSC_PREDIV>, 74 + <&CLK_S_A0_PLL 0>, /* PLL0 HS */ 75 + <&CLK_S_A0_PLL 2>; /* PLL1 */ 76 + 77 + clock-output-names = "CLK_S_FDMA_0", 78 + "CLK_S_FDMA_1", 79 + ""; /* CLK_S_JIT_SENSE */ 80 + /* Fourth output unused */ 81 + }; 82 + }; 83 +