ARM: keystone: update dt and enable cpts support
Subsystems (2)
v2 cover ARM: keystone: update dt and enable cpts support
Hi Santosh,
This series is set of platform changes required to enable NETCP CPTS reference clock selection and final patch to enable CPTS for Keystone 66AK2E/L/HK SoCs.
Those patches were posted already [1] together with driver's changes, so this is re-send of DT/platform specific changes only, as driver's changes have been merged already.
Patches 1-5: CPTS DT nodes update for TI Keystone 2 66AK2HK/E/L SoCs. Patch 6: enables CPTS for TI Keystone 2 66AK2HK/E/L SoCs.
[1] https://patchwork.kernel.org/cover/10980037/
Grygorii Strashko (6):
ARM: dts: keystone-clocks: add input fixed clocks
ARM: dts: k2e-clocks: add input ext. fixed clocks tsipclka/b
ARM: dts: k2e-netcp: add cpts refclk_mux node
ARM: dts: k2hk-netcp: add cpts refclk_mux node
ARM: dts: k2l-netcp: add cpts refclk_mux node
ARM: configs: keystone: enable cpts
arch/arm/boot/dts/keystone-clocks.dtsi | 27 ++++++++++++++++++++++ arch/arm/boot/dts/keystone-k2e-clocks.dtsi | 20 ++++++++++++++++ arch/arm/boot/dts/keystone-k2e-netcp.dtsi | 21 +++++++++++++++-- arch/arm/boot/dts/keystone-k2hk-netcp.dtsi | 20 ++++++++++++++-- arch/arm/boot/dts/keystone-k2l-netcp.dtsi | 20 ++++++++++++++-- arch/arm/configs/keystone_defconfig | 1 + 6 files changed, 103 insertions(+), 6 deletions(-)
Signature · 1 line
2.17.1
PATCH RESEND v2 1/6 ARM: dts: keystone-clocks: add input fixed clocks
Add set of fixed, external input clocks definitions for TIMI0, TIMI1, TSREFCLK clocks. Such clocks can be used as reference clocks for some HW modules (as cpts, for example) by configuring corresponding clock muxes. For these clocks real frequencies have to be defined in board files.
--- arch/arm/boot/dts/keystone-clocks.dtsi | 27 ++++++++++++++++++++++++++ 1 file changed, 27 insertions(+)
arch/arm/boot/dts/keystone-clocks.dtsi +27 -0
@@ -408,4 +408,31 @@ clocks { reg-names = "control", "domain"; domain-id = <0>; }; + + /* + * Below are set of fixed, input clocks definitions, + * for which real frequencies have to be defined in board files. + * Those clocks can be used as reference clocks for some HW modules + * (as cpts, for example) by configuring corresponding clock muxes. + */ + timi0: timi0 { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <0>; + clock-output-names = "timi0"; + }; + + timi1: timi1 { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <0>; + clock-output-names = "timi1"; + }; + + tsrefclk: tsrefclk { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <0>; + clock-output-names = "tsrefclk"; + }; };
Signature · 1 line
2.17.1
PATCH RESEND v2 2/6 ARM: dts: k2e-clocks: add input ext. fixed clocks tsipclka/b
In reply to Grygorii StrashkoAdd set of fixed, external input clocks definitions for TSIPCLKA, TSIPCLKB clocks. Such clocks can be used as reference clocks for some HW modules (as cpts, for example) by configuring corresponding clock muxes. For these clocks real frequencies have to be defined in board files.
--- arch/arm/boot/dts/keystone-k2e-clocks.dtsi | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+)
arch/arm/boot/dts/keystone-k2e-clocks.dtsi +20 -0
@@ -71,4 +71,24 @@ clocks { reg-names = "control", "domain"; domain-id = <29>; }; + + /* + * Below are set of fixed, input clocks definitions, + * for which real frequencies have to be defined in board files. + * Those clocks can be used as reference clocks for some HW modules + * (as cpts, for example) by configuring corresponding clock muxes. + */ + tsipclka: tsipclka { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <0>; + clock-output-names = "tsipclka"; + }; + + tsipclkb: tsipclkb { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <0>; + clock-output-names = "tsipclkb"; + }; };
Signature · 1 line
2.17.1
PATCH RESEND v2 3/6 ARM: dts: k2e-netcp: add cpts refclk_mux node
In reply to Grygorii StrashkoKeyStone 66AK2E 1G Ethernet Switch Subsystems, can control an external multiplexer that selects one of up to 32 clocks for time sync reference (RFTCLK) clock. This feature can be configured through CPTS_RFTCLK_SEL register (offset: x08) in CPTS module and modelled as multiplexer clock.
Hence, add cpts-refclk-mux clock node which allows to mux one of SYSCLK2, SYSCLK3, TIMI0, TIMI1, TSIPCLKA, TSREFCLK, TSIPCLKB clocks as CPTS reference clock [1] and group all CPTS properties under "cpts" subnode.
[1] http://www.ti.com/lit/gpn/66ak2e05
--- arch/arm/boot/dts/keystone-k2e-netcp.dtsi | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-)
arch/arm/boot/dts/keystone-k2e-netcp.dtsi +19 -2
@@ -135,8 +135,8 @@ netcp: netcp@24000000 { /* NetCP address range */ ranges = <0 0x24000000 0x1000000>; - clocks = <&clkpa>, <&clkcpgmac>, <&chipclk12>; - clock-names = "pa_clk", "ethss_clk", "cpts"; + clocks = <&clkpa>, <&clkcpgmac>; + clock-names = "pa_clk", "ethss_clk"; dma-coherent; ti,navigator-dmas = <&dma_gbe 0>,
@@ -156,6 +156,23 @@ netcp: netcp@24000000 { tx-queue = <896>; tx-channel = "nettx"; + cpts { + clocks = <&cpts_refclk_mux>; + clock-names = "cpts"; + + cpts_refclk_mux: cpts-refclk-mux { + #clock-cells = <0>; + clocks = <&chipclk12>, <&chipclk13>, + <&timi0>, <&timi1>, + <&tsipclka>, <&tsrefclk>, + <&tsipclkb>; + ti,mux-tbl = <0x0>, <0x1>, <0x2>, + <0x3>, <0x4>, <0x8>, <0xC>; + assigned-clocks = <&cpts_refclk_mux>; + assigned-clock-parents = <&chipclk12>; + }; + }; + interfaces { gbe0: interface-0 { slave-port = <0>;
Signature · 1 line
2.17.1
PATCH RESEND v2 4/6 ARM: dts: k2hk-netcp: add cpts refclk_mux node
In reply to Grygorii StrashkoKeyStone 66AK2H/K 1G Ethernet Switch Subsystems, can control an external multiplexer that selects one of up to 32 clocks for time sync reference (RFTCLK) clock. This feature can be configured through CPTS_RFTCLK_SEL register (offset: x08) in CPTS module and modelled as multiplexer clock.
Hence, add cpts-refclk-mux clock node which allows to mux one of SYSCLK2, SYSCLK3, TIMI0, TIMI1, TSREFCLK clocks as CPTS reference clock [1] and group all CPTS properties under "cpts" subnode.
[1] http://www.ti.com/lit/gpn/66ak2h14
--- arch/arm/boot/dts/keystone-k2hk-netcp.dtsi | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-)
arch/arm/boot/dts/keystone-k2hk-netcp.dtsi +18 -2
@@ -152,8 +152,8 @@ netcp: netcp@2000000 { /* NetCP address range */ ranges = <0 0x2000000 0x100000>; - clocks = <&clkpa>, <&clkcpgmac>, <&chipclk12>; - clock-names = "pa_clk", "ethss_clk", "cpts"; + clocks = <&clkpa>, <&clkcpgmac>; + clock-names = "pa_clk", "ethss_clk"; dma-coherent; ti,navigator-dmas = <&dma_gbe 22>,
@@ -175,6 +175,22 @@ netcp: netcp@2000000 { tx-queue = <648>; tx-channel = "nettx"; + cpts { + clocks = <&cpts_refclk_mux>; + clock-names = "cpts"; + + cpts_refclk_mux: cpts-refclk-mux { + #clock-cells = <0>; + clocks = <&chipclk12>, <&chipclk13>, + <&timi0>, <&timi1>, + <&tsrefclk>; + ti,mux-tbl = <0x0>, <0x1>, <0x2>, + <0x3>, <0x8>; + assigned-clocks = <&cpts_refclk_mux>; + assigned-clock-parents = <&chipclk12>; + }; + }; + interfaces { gbe0: interface-0 { slave-port = <0>;
Signature · 1 line
2.17.1
PATCH RESEND v2 5/6 ARM: dts: k2l-netcp: add cpts refclk_mux node
In reply to Grygorii StrashkoKeyStone 66AK2L 1G Ethernet Switch Subsystems, can control an external multiplexer that selects one of up to 32 clocks for time sync reference (RFTCLK) clock. This feature can be configured through CPTS_RFTCLK_SEL register (offset: x08) in CPTS module and modelled as multiplexer clock.
Hence, add cpts-refclk-mux clock node which allows to mux one of SYSCLK2, SYSCLK3, TIMI0, TIMI1, TSREFCLK clocks as CPTS
reference clock [1] and group all CPTS properties under "cpts" subnode.
[1] http://www.ti.com/lit/gpn/66ak2l06
--- arch/arm/boot/dts/keystone-k2l-netcp.dtsi | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-)
arch/arm/boot/dts/keystone-k2l-netcp.dtsi +18 -2
@@ -134,8 +134,8 @@ netcp: netcp@26000000 { /* NetCP address range */ ranges = <0 0x26000000 0x1000000>; - clocks = <&clkpa>, <&clkcpgmac>, <&chipclk12>; - clock-names = "pa_clk", "ethss_clk", "cpts"; + clocks = <&clkpa>, <&clkcpgmac>; + clock-names = "pa_clk", "ethss_clk"; dma-coherent; ti,navigator-dmas = <&dma_gbe 0>,
@@ -155,6 +155,22 @@ netcp: netcp@26000000 { tx-queue = <896>; tx-channel = "nettx"; + cpts { + clocks = <&cpts_refclk_mux>; + clock-names = "cpts"; + + cpts_refclk_mux: cpts-refclk-mux { + #clock-cells = <0>; + clocks = <&chipclk12>, <&chipclk13>, + <&timi0>, <&timi1>, + <&tsrefclk>; + ti,mux-tbl = <0x0>, <0x1>, <0x2>, + <0x3>, <0x8>; + assigned-clocks = <&cpts_refclk_mux>; + assigned-clock-parents = <&chipclk12>; + }; + }; + interfaces { gbe0: interface-0 { slave-port = <0>;
Signature · 1 line
2.17.1
PATCH RESEND v2 6/6 ARM: configs: keystone: enable cpts
In reply to Grygorii StrashkoEnable CPTS support which is present in Network Coprocessor Gigabit Ethernet (GbE) Switch Subsystem.
--- arch/arm/configs/keystone_defconfig | 1 + 1 file changed, 1 insertion(+)
arch/arm/configs/keystone_defconfig +1 -0
@@ -136,6 +136,7 @@ CONFIG_BLK_DEV_SD=y CONFIG_NETDEVICES=y CONFIG_TI_KEYSTONE_NETCP=y CONFIG_TI_KEYSTONE_NETCP_ETHSS=y +CONFIG_TI_CPTS=y CONFIG_MARVELL_PHY=y CONFIG_SERIAL_8250=y CONFIG_SERIAL_8250_CONSOLE=y
Signature · 1 line
2.17.1
Quoted 14 lines · Grygorii Strashko
Hi Santosh,
This series is set of platform changes required to enable NETCP CPTS reference clock selection and final patch to enable CPTS for Keystone 66AK2E/L/HK SoCs.
Those patches were posted already [1] together with driver's changes, so this is re-send of DT/platform specific changes only, as driver's changes have been merged already.
Patches 1-5: CPTS DT nodes update for TI Keystone 2 66AK2HK/E/L SoCs. Patch 6: enables CPTS for TI Keystone 2 66AK2HK/E/L SoCs.
Quoted 8 lines
Grygorii Strashko (6):
ARM: dts: keystone-clocks: add input fixed clocks
ARM: dts: k2e-clocks: add input ext. fixed clocks tsipclka/b
ARM: dts: k2e-netcp: add cptsrefclk_muxnode
ARM: dts: k2hk-netcp: add cptsrefclk_muxnode
ARM: dts: k2l-netcp: add cptsrefclk_muxnode
ARM: configs: keystone: enable cpts
Will add these for 5.4 queue. Thanks !!
Regards,
Santosh
Quoted 23 lines · On 06/07/2019 05:18, [email protected] wrote:
Quoted 14 lines · Grygorii Strashko
Hi Santosh,
This series is set of platform changes required to enable NETCP CPTS reference clock selection and final patch to enable CPTS for Keystone 66AK2E/L/HK SoCs.
Those patches were posted already [1] together with driver's changes, so this is re-send of DT/platform specific changes only, as driver's changes have been merged already.
Patches 1-5: CPTS DT nodes update for TI Keystone 2 66AK2HK/E/L SoCs. Patch 6: enables CPTS for TI Keystone 2 66AK2HK/E/L SoCs.
Quoted 8 lines
Grygorii Strashko (6):
ARM: dts: keystone-clocks: add input fixed clocks
ARM: dts: k2e-clocks: add input ext. fixed clocks tsipclka/b
ARM: dts: k2e-netcp: add cptsrefclk_muxnode
ARM: dts: k2hk-netcp: add cptsrefclk_muxnode
ARM: dts: k2l-netcp: add cptsrefclk_muxnode
ARM: configs: keystone: enable cpts
Quoted 1 line
Will add these for 5.4 queue. Thanks !!
Thank you
Signature · 7 lines
Best regards, grygorii _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Hi Santosh,
Quoted 23 lines · On 06/07/2019 02:48, [email protected] wrote:
Quoted 14 lines · Grygorii Strashko
Hi Santosh,
This series is set of platform changes required to enable NETCP CPTS reference clock selection and final patch to enable CPTS for Keystone 66AK2E/L/HK SoCs.
Those patches were posted already [1] together with driver's changes, so this is re-send of DT/platform specific changes only, as driver's changes have been merged already.
Patches 1-5: CPTS DT nodes update for TI Keystone 2 66AK2HK/E/L SoCs. Patch 6: enables CPTS for TI Keystone 2 66AK2HK/E/L SoCs.
Quoted 8 lines
Grygorii Strashko (6):
ARM: dts: keystone-clocks: add input fixed clocks
ARM: dts: k2e-clocks: add input ext. fixed clocks tsipclka/b
ARM: dts: k2e-netcp: add cptsrefclk_muxnode
ARM: dts: k2hk-netcp: add cptsrefclk_muxnode
ARM: dts: k2l-netcp: add cptsrefclk_muxnode
ARM: configs: keystone: enable cpts
Quoted 1 line
Will add these for 5.4 queue. Thanks !!
Sry, that I'm disturbing you, but I do not see those patches applied?
Signature · 2 lines
Best regards, grygorii
Quoted 26 lines · Grygorii Strashko
Hi Santosh,
Quoted 23 lines · On 06/07/2019 02:48, [email protected] wrote:
Quoted 22 lines · Grygorii Strashko
Hi Santosh,
This series is set of platform changes required to enable NETCP CPTS reference clock selection and final patch to enable CPTS for Keystone 66AK2E/L/HK SoCs.
Those patches were posted already [1] together with driver's changes, so this is re-send of DT/platform specific changes only, as driver's changes have been merged already.
Patches 1-5: CPTS DT nodes update for TI Keystone 2 66AK2HK/E/L SoCs. Patch 6: enables CPTS for TI Keystone 2 66AK2HK/E/L SoCs.
[1] https://patchwork.kernel.org/cover/10980037/
Grygorii Strashko (6):
ARM: dts: keystone-clocks: add input fixed clocks
ARM: dts: k2e-clocks: add input ext. fixed clocks tsipclka/b
ARM: dts: k2e-netcp: add cptsrefclk_muxnode
ARM: dts: k2hk-netcp: add cptsrefclk_muxnode
ARM: dts: k2l-netcp: add cptsrefclk_muxnode
ARM: configs: keystone: enable cpts
Quoted 4 lines
Quoted 1 line
Will add these for 5.4 queue. Thanks !!
Sry, that I'm disturbing you, but I do not see those patches applied?
Sorry I missed this one. Will queue this up for next merge window. Will push this out to next early once rc1 is out. If you don't see it, please ping me.
Regards,
Santosh