162306a36Sopenharmony_ciBinding for Texas Instruments gate clock. 262306a36Sopenharmony_ci 362306a36Sopenharmony_ciBinding status: Unstable - ABI compatibility may be broken in the future 462306a36Sopenharmony_ci 562306a36Sopenharmony_ciThis binding uses the common clock binding[1]. This clock is 662306a36Sopenharmony_ciquite much similar to the basic gate-clock [2], however, 762306a36Sopenharmony_ciit supports a number of additional features. If no register 862306a36Sopenharmony_ciis provided for this clock, the code assumes that a clockdomain 962306a36Sopenharmony_ciwill be controlled instead and the corresponding hw-ops for 1062306a36Sopenharmony_cithat is used. 1162306a36Sopenharmony_ci 1262306a36Sopenharmony_ci[1] Documentation/devicetree/bindings/clock/clock-bindings.txt 1362306a36Sopenharmony_ci[2] Documentation/devicetree/bindings/clock/gpio-gate-clock.yaml 1462306a36Sopenharmony_ci[3] Documentation/devicetree/bindings/clock/ti/clockdomain.txt 1562306a36Sopenharmony_ci 1662306a36Sopenharmony_ciRequired properties: 1762306a36Sopenharmony_ci- compatible : shall be one of: 1862306a36Sopenharmony_ci "ti,gate-clock" - basic gate clock 1962306a36Sopenharmony_ci "ti,wait-gate-clock" - gate clock which waits until clock is active before 2062306a36Sopenharmony_ci returning from clk_enable() 2162306a36Sopenharmony_ci "ti,dss-gate-clock" - gate clock with DSS specific hardware handling 2262306a36Sopenharmony_ci "ti,am35xx-gate-clock" - gate clock with AM35xx specific hardware handling 2362306a36Sopenharmony_ci "ti,clkdm-gate-clock" - clockdomain gate clock, which derives its functional 2462306a36Sopenharmony_ci clock directly from a clockdomain, see [3] how 2562306a36Sopenharmony_ci to map clockdomains properly 2662306a36Sopenharmony_ci "ti,hsdiv-gate-clock" - gate clock with OMAP36xx specific hardware handling, 2762306a36Sopenharmony_ci required for a hardware errata 2862306a36Sopenharmony_ci "ti,composite-gate-clock" - composite gate clock, to be part of composite 2962306a36Sopenharmony_ci clock 3062306a36Sopenharmony_ci "ti,composite-no-wait-gate-clock" - composite gate clock that does not wait 3162306a36Sopenharmony_ci for clock to be active before returning 3262306a36Sopenharmony_ci from clk_enable() 3362306a36Sopenharmony_ci- #clock-cells : from common clock binding; shall be set to 0 3462306a36Sopenharmony_ci- clocks : link to phandle of parent clock 3562306a36Sopenharmony_ci- reg : offset for register controlling adjustable gate, not needed for 3662306a36Sopenharmony_ci ti,clkdm-gate-clock type 3762306a36Sopenharmony_ci 3862306a36Sopenharmony_ciOptional properties: 3962306a36Sopenharmony_ci- clock-output-names : from common clock binding. 4062306a36Sopenharmony_ci- ti,bit-shift : bit shift for programming the clock gate, invalid for 4162306a36Sopenharmony_ci ti,clkdm-gate-clock type 4262306a36Sopenharmony_ci- ti,set-bit-to-disable : inverts default gate programming. Setting the bit 4362306a36Sopenharmony_ci gates the clock and clearing the bit ungates the clock. 4462306a36Sopenharmony_ci 4562306a36Sopenharmony_ciExamples: 4662306a36Sopenharmony_ci mmchs2_fck: mmchs2_fck@48004a00 { 4762306a36Sopenharmony_ci #clock-cells = <0>; 4862306a36Sopenharmony_ci compatible = "ti,gate-clock"; 4962306a36Sopenharmony_ci clocks = <&core_96m_fck>; 5062306a36Sopenharmony_ci reg = <0x0a00>; 5162306a36Sopenharmony_ci ti,bit-shift = <25>; 5262306a36Sopenharmony_ci }; 5362306a36Sopenharmony_ci 5462306a36Sopenharmony_ci uart4_fck_am35xx: uart4_fck_am35xx { 5562306a36Sopenharmony_ci #clock-cells = <0>; 5662306a36Sopenharmony_ci compatible = "ti,wait-gate-clock"; 5762306a36Sopenharmony_ci clocks = <&core_48m_fck>; 5862306a36Sopenharmony_ci reg = <0x0a00>; 5962306a36Sopenharmony_ci ti,bit-shift = <23>; 6062306a36Sopenharmony_ci }; 6162306a36Sopenharmony_ci 6262306a36Sopenharmony_ci dss1_alwon_fck_3430es2: dss1_alwon_fck_3430es2@48004e00 { 6362306a36Sopenharmony_ci #clock-cells = <0>; 6462306a36Sopenharmony_ci compatible = "ti,dss-gate-clock"; 6562306a36Sopenharmony_ci clocks = <&dpll4_m4x2_ck>; 6662306a36Sopenharmony_ci reg = <0x0e00>; 6762306a36Sopenharmony_ci ti,bit-shift = <0>; 6862306a36Sopenharmony_ci }; 6962306a36Sopenharmony_ci 7062306a36Sopenharmony_ci emac_ick: emac_ick@4800259c { 7162306a36Sopenharmony_ci #clock-cells = <0>; 7262306a36Sopenharmony_ci compatible = "ti,am35xx-gate-clock"; 7362306a36Sopenharmony_ci clocks = <&ipss_ick>; 7462306a36Sopenharmony_ci reg = <0x059c>; 7562306a36Sopenharmony_ci ti,bit-shift = <1>; 7662306a36Sopenharmony_ci }; 7762306a36Sopenharmony_ci 7862306a36Sopenharmony_ci emu_src_ck: emu_src_ck { 7962306a36Sopenharmony_ci #clock-cells = <0>; 8062306a36Sopenharmony_ci compatible = "ti,clkdm-gate-clock"; 8162306a36Sopenharmony_ci clocks = <&emu_src_mux_ck>; 8262306a36Sopenharmony_ci }; 8362306a36Sopenharmony_ci 8462306a36Sopenharmony_ci dpll4_m2x2_ck: dpll4_m2x2_ck@48004d00 { 8562306a36Sopenharmony_ci #clock-cells = <0>; 8662306a36Sopenharmony_ci compatible = "ti,hsdiv-gate-clock"; 8762306a36Sopenharmony_ci clocks = <&dpll4_m2x2_mul_ck>; 8862306a36Sopenharmony_ci ti,bit-shift = <0x1b>; 8962306a36Sopenharmony_ci reg = <0x0d00>; 9062306a36Sopenharmony_ci ti,set-bit-to-disable; 9162306a36Sopenharmony_ci }; 9262306a36Sopenharmony_ci 9362306a36Sopenharmony_ci vlynq_gate_fck: vlynq_gate_fck { 9462306a36Sopenharmony_ci #clock-cells = <0>; 9562306a36Sopenharmony_ci compatible = "ti,composite-gate-clock"; 9662306a36Sopenharmony_ci clocks = <&core_ck>; 9762306a36Sopenharmony_ci ti,bit-shift = <3>; 9862306a36Sopenharmony_ci reg = <0x0200>; 9962306a36Sopenharmony_ci }; 10062306a36Sopenharmony_ci 10162306a36Sopenharmony_ci sys_clkout2_src_gate: sys_clkout2_src_gate { 10262306a36Sopenharmony_ci #clock-cells = <0>; 10362306a36Sopenharmony_ci compatible = "ti,composite-no-wait-gate-clock"; 10462306a36Sopenharmony_ci clocks = <&core_ck>; 10562306a36Sopenharmony_ci ti,bit-shift = <15>; 10662306a36Sopenharmony_ci reg = <0x0070>; 10762306a36Sopenharmony_ci }; 108