powerpc/dts: Add and fix 1588 timer node for eTSEC
authorYangbo Lu <yangbo.lu@freescale.com>
Wed, 29 Jul 2015 07:12:38 +0000 (15:12 +0800)
committerScott Wood <scottwood@freescale.com>
Fri, 16 Oct 2015 23:45:11 +0000 (18:45 -0500)
Add 1588 timer node in files:
arch/powerpc/boot/dts/bsc9131rdb.dtsi
arch/powerpc/boot/dts/bsc9132qds.dtsi
arch/powerpc/boot/dts/p1010rdb.dtsi
arch/powerpc/boot/dts/p1020rdb-pd.dts
arch/powerpc/boot/dts/p1021rdb-pc.dtsi
arch/powerpc/boot/dts/p1022ds.dtsi
arch/powerpc/boot/dts/p1025twr.dtsi
For P2020RDB-PC, registers' values should be calculated
based on default 1588 reference clock(300MHz) not 250MHz,
and fix this in file:
arch/powerpc/boot/dts/p2020rdb-pc.dtsi

Signed-off-by: Yangbo Lu <yangbo.lu@freescale.com>
Signed-off-by: Scott Wood <scottwood@freescale.com>
arch/powerpc/boot/dts/bsc9131rdb.dtsi
arch/powerpc/boot/dts/bsc9132qds.dtsi
arch/powerpc/boot/dts/p1010rdb.dtsi
arch/powerpc/boot/dts/p1020rdb-pd.dts
arch/powerpc/boot/dts/p1021rdb-pc.dtsi
arch/powerpc/boot/dts/p1022ds.dtsi
arch/powerpc/boot/dts/p1025twr.dtsi
arch/powerpc/boot/dts/p2020rdb-pc.dtsi

index 45efcba..f4d96d2 100644 (file)
                status = "disabled";
        };
 
+       ptp_clock@b0e00 {
+               compatible = "fsl,etsec-ptp";
+               reg = <0xb0e00 0xb0>;
+               interrupts = <68 2 0 0 69 2 0 0>;
+               fsl,tclk-period = <5>;
+               fsl,tmr-prsc    = <2>;
+               fsl,tmr-add     = <0xcccccccd>;
+               fsl,tmr-fiper1  = <999999995>;
+               fsl,tmr-fiper2  = <99990>;
+               fsl,max-adj     = <249999999>;
+       };
+
        enet0: ethernet@b0000 {
                phy-handle = <&phy0>;
                phy-connection-type = "rgmii-id";
index af8e888..7a13bf2 100644 (file)
                };
        };
 
+       ptp_clock@b0e00 {
+               compatible = "fsl,etsec-ptp";
+               reg = <0xb0e00 0xb0>;
+               interrupts = <68 2 0 0 69 2 0 0>;
+               fsl,tclk-period = <5>;
+               fsl,tmr-prsc    = <2>;
+               fsl,tmr-add     = <0xcccccccd>;
+               fsl,tmr-fiper1  = <999999995>;
+               fsl,tmr-fiper2  = <99990>;
+               fsl,max-adj     = <249999999>;
+       };
+
        enet0: ethernet@b0000 {
                phy-handle = <&phy0>;
                tbi-handle = <&tbi0>;
index ea534ef..0f0ced6 100644 (file)
                };
        };
 
+       ptp_clock@b0e00 {
+               compatible = "fsl,etsec-ptp";
+               reg = <0xb0e00 0xb0>;
+               interrupts = <68 2 0 0 69 2 0 0>;
+               fsl,tclk-period = <10>;
+               fsl,tmr-prsc    = <2>;
+               fsl,tmr-add     = <0x80000016>;
+               fsl,tmr-fiper1  = <999999990>;
+               fsl,tmr-fiper2  = <99990>;
+               fsl,max-adj     = <199999999>;
+       };
+
        enet0: ethernet@b0000 {
                phy-handle = <&phy0>;
                phy-connection-type = "rgmii-id";
index 987017e..c7c6416 100644 (file)
                        };
                };
 
+               ptp_clock@b0e00 {
+                       compatible = "fsl,etsec-ptp";
+                       reg = <0xb0e00 0xb0>;
+                       interrupts = <68 2 0 0 69 2 0 0>;
+                       fsl,tclk-period = <10>;
+                       fsl,tmr-prsc    = <2>;
+                       fsl,tmr-add     = <0x80000016>;
+                       fsl,tmr-fiper1  = <999999990>;
+                       fsl,tmr-fiper2  = <99990>;
+                       fsl,max-adj     = <199999999>;
+               };
+
                enet0: ethernet@b0000 {
                        fixed-link = <1 1 1000 0 0>;
                        phy-connection-type = "rgmii-id";
index d6274c5..e8a0f95 100644 (file)
                };
        };
 
+       ptp_clock@b0e00 {
+               compatible = "fsl,etsec-ptp";
+               reg = <0xb0e00 0xb0>;
+               interrupts = <68 2 0 0 69 2 0 0>;
+               fsl,tclk-period = <10>;
+               fsl,tmr-prsc    = <2>;
+               fsl,tmr-add     = <0x80000016>;
+               fsl,tmr-fiper1  = <999999990>;
+               fsl,tmr-fiper2  = <99990>;
+               fsl,max-adj     = <199999999>;
+       };
+
        enet0: ethernet@b0000 {
                fixed-link = <1 1 1000 0 0>;
                phy-connection-type = "rgmii-id";
index 957e0dc..149da0f 100644 (file)
                };
        };
 
+       ptp_clock@b0e00 {
+               compatible = "fsl,etsec-ptp";
+               reg = <0xb0e00 0xb0>;
+               interrupts = <68 2 0 0 69 2 0 0>;
+               fsl,tclk-period = <5>;
+               fsl,tmr-prsc    = <2>;
+               fsl,tmr-add     = <0xc01ebd3d>;
+               fsl,tmr-fiper1  = <999999995>;
+               fsl,tmr-fiper2  = <99990>;
+               fsl,max-adj     = <266499999>;
+       };
+
        ethernet@b0000 {
                phy-handle = <&phy0>;
                phy-connection-type = "rgmii-id";
index 8453501..08816fb 100644 (file)
                };
        };
 
+       ptp_clock@b0e00 {
+               compatible = "fsl,etsec-ptp";
+               reg = <0xb0e00 0xb0>;
+               interrupts = <68 2 0 0 69 2 0 0>;
+               fsl,tclk-period = <10>;
+               fsl,tmr-prsc    = <2>;
+               fsl,tmr-add     = <0xc0000021>;
+               fsl,tmr-fiper1  = <999999990>;
+               fsl,tmr-fiper2  = <99990>;
+               fsl,max-adj     = <133333332>;
+       };
+
        enet0: ethernet@b0000 {
                phy-handle = <&phy0>;
                phy-connection-type = "rgmii-id";
index c21d1c7..ad2e242 100644 (file)
        };
 
        ptp_clock@24e00 {
-               fsl,tclk-period = <5>;
-               fsl,tmr-prsc = <200>;
-               fsl,tmr-add = <0xCCCCCCCD>;
-               fsl,tmr-fiper1 = <0x3B9AC9FB>;
-               fsl,tmr-fiper2 = <0x0001869B>;
-               fsl,max-adj = <249999999>;
+               fsl,tclk-period = <5>;
+               fsl,tmr-prsc    = <2>;
+               fsl,tmr-add     = <0xaaaaaaab>;
+               fsl,tmr-fiper1  = <999999995>;
+               fsl,tmr-fiper2  = <99990>;
+               fsl,max-adj     = <299999999>;
        };
 
        enet0: ethernet@24000 {