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 45efcbadb23cf002cfa09e21c2fa38d9e8497245..f4d96d277ed5b2b1492bab0db07bca33d33a30db 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 af8e88830221cdab102b534acc502e7979f9a39b..7a13bf2aa439e608b12bb3b70c6f11c7c85bc10d 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 ea534efa790d367beade9a27e8a93d27431f208f..0f0ced69835a066e9358f1ca08a04853b71d33df 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 987017ea36b64ef31179fd1d4a671958daba3200..c7c64162a30991c49010cab808cff3c953a13173 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 d6274c58f496b6eb79d0bfb3c040c627af5d3952..e8a0f95fb24a5648f79ccfa2535e38f2bd40a5b1 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 957e0dc1dc0f62ceb8507acf115c76f06e8ea8dd..149da0f123eeb9ebff4ea9b9bb1cd37e8cb85bff 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 8453501c256ebd1eaaae72836a2633d3d43d801a..08816fb474f5d552dec09b381839bcf7278e221b 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 c21d1c7d16cd19b32496c359b46ac6a61eddb395..ad2e242365ccada6e32800a381da45540a7cffac 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 {