]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
ARM: dts: vf610: assign oscillator to clock module
authorStefan Agner <stefan@agner.ch>
Sun, 2 Nov 2014 20:36:44 +0000 (21:36 +0100)
committerShawn Guo <shawn.guo@linaro.org>
Sun, 23 Nov 2014 07:08:09 +0000 (15:08 +0800)
The clock controller module (CCM) has several clock inputs, which
are connected to external crystal oscillators. To reflect this,
assign these fixed clocks to the CCM node directly.

This especially resolves initialization order dependencies we had
with the earlier initialization code: When resolving of the fixed
clocks failed in clk-vf610, the code created fixed clocks with a
rate of 0.

Signed-off-by: Stefan Agner <stefan@agner.ch>
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Documentation/devicetree/bindings/clock/vf610-clock.txt
arch/arm/boot/dts/vf610-cosmic.dts
arch/arm/boot/dts/vf610-twr.dts
arch/arm/boot/dts/vf610.dtsi

index c80863d344ac0b81043edc885262cdc6d609d4df..63f9f1ac34390762b9950254ef478c9b6b6053a1 100644 (file)
@@ -5,6 +5,19 @@ Required properties:
 - reg: Address and length of the register set
 - #clock-cells: Should be <1>
 
+Optional properties:
+- clocks: list of clock identifiers which are external input clocks to the
+       given clock controller. Please refer the next section to find
+       the input clocks for a given controller.
+- clock-names: list of names of clocks which are exteral input clocks to the
+       given clock controller.
+
+Input clocks for top clock controller:
+       - sxosc (external crystal oscillator 32KHz, recommended)
+       - fxosc (external crystal oscillator 24MHz, recommended)
+       - audio_ext
+       - enet_ext
+
 The clock consumer should specify the desired clock by having the clock
 ID in its "clocks" phandle cell. See include/dt-bindings/clock/vf610-clock.h
 for the full list of VF610 clock IDs.
@@ -15,6 +28,8 @@ clks: ccm@4006b000 {
        compatible = "fsl,vf610-ccm";
        reg = <0x4006b000 0x1000>;
        #clock-cells = <1>;
+       clocks = <&sxosc>, <&fxosc>;
+       clock-names = "sxosc", "fxosc";
 };
 
 uart1: serial@40028000 {
index 3fd1b74e1216e1b028751ef64e4f84e7af65bcf3..b0ce8b8b2e0e4d2303ebfe2a36249c1af34caae6 100644 (file)
                reg = <0x80000000 0x10000000>;
        };
 
-       clocks {
-               enet_ext {
-                       compatible = "fixed-clock";
-                       #clock-cells = <0>;
-                       clock-frequency = <50000000>;
-               };
+       enet_ext: enet_ext {
+               compatible = "fixed-clock";
+               #clock-cells = <0>;
+               clock-frequency = <50000000>;
        };
+};
 
+&clks {
+       clocks = <&sxosc>, <&fxosc>, <&enet_ext>;
+       clock-names = "sxosc", "fxosc", "enet_ext";
 };
 
 &fec1 {
index 189b6975fe7d99eaca1941bf1e5725a353fbd52c..7d06d1a367a5e5a968e6afa851aaad5c4f1665d4 100644 (file)
                reg = <0x80000000 0x8000000>;
        };
 
-       clocks {
-               audio_ext {
-                       compatible = "fixed-clock";
-                       #clock-cells = <0>;
-                       clock-frequency = <24576000>;
-               };
+       audio_ext: mclk_osc {
+               compatible = "fixed-clock";
+               #clock-cells = <0>;
+               clock-frequency = <24576000>;
+       };
 
-               enet_ext {
-                       compatible = "fixed-clock";
-                       #clock-cells = <0>;
-                       clock-frequency = <50000000>;
-               };
+       enet_ext: eth_osc {
+               compatible = "fixed-clock";
+               #clock-cells = <0>;
+               clock-frequency = <50000000>;
        };
 
        regulators {
        status = "okay";
 };
 
+&clks {
+       clocks = <&sxosc>, <&fxosc>, <&enet_ext>, <&audio_ext>;
+       clock-names = "sxosc", "fxosc", "enet_ext", "audio_ext";
+};
+
 &dspi0 {
        bus-num = <0>;
        pinctrl-names = "default";
index 699da487222db66aa9accd9519d0c71f790563ac..ed12d9a7be3ec8b9f44808e347ba812971458e9c 100644 (file)
                };
        };
 
-       clocks {
-               #address-cells = <1>;
-               #size-cells = <0>;
-
-               sxosc {
-                       compatible = "fixed-clock";
-                       #clock-cells = <0>;
-                       clock-frequency = <32768>;
-               };
+       fxosc: fxosc {
+               compatible = "fixed-clock";
+               #clock-cells = <0>;
+               clock-frequency = <24000000>;
+       };
 
-               fxosc {
-                       compatible = "fixed-clock";
-                       #clock-cells = <0>;
-                       clock-frequency = <24000000>;
-               };
+       sxosc: sxosc {
+               compatible = "fixed-clock";
+               #clock-cells = <0>;
+               clock-frequency = <32768>;
        };
 
        soc {
                        clks: ccm@4006b000 {
                                compatible = "fsl,vf610-ccm";
                                reg = <0x4006b000 0x1000>;
+                               clocks = <&sxosc>, <&fxosc>;
+                               clock-names = "sxosc", "fxosc";
                                #clock-cells = <1>;
                        };