18c2ecf20Sopenharmony_ciBinding for Texas Instruments gate clock.
28c2ecf20Sopenharmony_ci
38c2ecf20Sopenharmony_ciBinding status: Unstable - ABI compatibility may be broken in the future
48c2ecf20Sopenharmony_ci
58c2ecf20Sopenharmony_ciThis binding uses the common clock binding[1]. This clock is
68c2ecf20Sopenharmony_ciquite much similar to the basic gate-clock [2], however,
78c2ecf20Sopenharmony_ciit supports a number of additional features. If no register
88c2ecf20Sopenharmony_ciis provided for this clock, the code assumes that a clockdomain
98c2ecf20Sopenharmony_ciwill be controlled instead and the corresponding hw-ops for
108c2ecf20Sopenharmony_cithat is used.
118c2ecf20Sopenharmony_ci
128c2ecf20Sopenharmony_ci[1] Documentation/devicetree/bindings/clock/clock-bindings.txt
138c2ecf20Sopenharmony_ci[2] Documentation/devicetree/bindings/clock/gpio-gate-clock.txt
148c2ecf20Sopenharmony_ci[3] Documentation/devicetree/bindings/clock/ti/clockdomain.txt
158c2ecf20Sopenharmony_ci
168c2ecf20Sopenharmony_ciRequired properties:
178c2ecf20Sopenharmony_ci- compatible : shall be one of:
188c2ecf20Sopenharmony_ci  "ti,gate-clock" - basic gate clock
198c2ecf20Sopenharmony_ci  "ti,wait-gate-clock" - gate clock which waits until clock is active before
208c2ecf20Sopenharmony_ci			 returning from clk_enable()
218c2ecf20Sopenharmony_ci  "ti,dss-gate-clock" - gate clock with DSS specific hardware handling
228c2ecf20Sopenharmony_ci  "ti,am35xx-gate-clock" - gate clock with AM35xx specific hardware handling
238c2ecf20Sopenharmony_ci  "ti,clkdm-gate-clock" - clockdomain gate clock, which derives its functional
248c2ecf20Sopenharmony_ci			  clock directly from a clockdomain, see [3] how
258c2ecf20Sopenharmony_ci			  to map clockdomains properly
268c2ecf20Sopenharmony_ci  "ti,hsdiv-gate-clock" - gate clock with OMAP36xx specific hardware handling,
278c2ecf20Sopenharmony_ci			  required for a hardware errata
288c2ecf20Sopenharmony_ci  "ti,composite-gate-clock" - composite gate clock, to be part of composite
298c2ecf20Sopenharmony_ci			      clock
308c2ecf20Sopenharmony_ci  "ti,composite-no-wait-gate-clock" - composite gate clock that does not wait
318c2ecf20Sopenharmony_ci				      for clock to be active before returning
328c2ecf20Sopenharmony_ci				      from clk_enable()
338c2ecf20Sopenharmony_ci- #clock-cells : from common clock binding; shall be set to 0
348c2ecf20Sopenharmony_ci- clocks : link to phandle of parent clock
358c2ecf20Sopenharmony_ci- reg : offset for register controlling adjustable gate, not needed for
368c2ecf20Sopenharmony_ci	ti,clkdm-gate-clock type
378c2ecf20Sopenharmony_ci
388c2ecf20Sopenharmony_ciOptional properties:
398c2ecf20Sopenharmony_ci- ti,bit-shift : bit shift for programming the clock gate, invalid for
408c2ecf20Sopenharmony_ci		 ti,clkdm-gate-clock type
418c2ecf20Sopenharmony_ci- ti,set-bit-to-disable : inverts default gate programming. Setting the bit
428c2ecf20Sopenharmony_ci  gates the clock and clearing the bit ungates the clock.
438c2ecf20Sopenharmony_ci
448c2ecf20Sopenharmony_ciExamples:
458c2ecf20Sopenharmony_ci	mmchs2_fck: mmchs2_fck@48004a00 {
468c2ecf20Sopenharmony_ci		#clock-cells = <0>;
478c2ecf20Sopenharmony_ci		compatible = "ti,gate-clock";
488c2ecf20Sopenharmony_ci		clocks = <&core_96m_fck>;
498c2ecf20Sopenharmony_ci		reg = <0x0a00>;
508c2ecf20Sopenharmony_ci		ti,bit-shift = <25>;
518c2ecf20Sopenharmony_ci	};
528c2ecf20Sopenharmony_ci
538c2ecf20Sopenharmony_ci	uart4_fck_am35xx: uart4_fck_am35xx {
548c2ecf20Sopenharmony_ci		#clock-cells = <0>;
558c2ecf20Sopenharmony_ci		compatible = "ti,wait-gate-clock";
568c2ecf20Sopenharmony_ci		clocks = <&core_48m_fck>;
578c2ecf20Sopenharmony_ci		reg = <0x0a00>;
588c2ecf20Sopenharmony_ci		ti,bit-shift = <23>;
598c2ecf20Sopenharmony_ci	};
608c2ecf20Sopenharmony_ci
618c2ecf20Sopenharmony_ci	dss1_alwon_fck_3430es2: dss1_alwon_fck_3430es2@48004e00 {
628c2ecf20Sopenharmony_ci		#clock-cells = <0>;
638c2ecf20Sopenharmony_ci		compatible = "ti,dss-gate-clock";
648c2ecf20Sopenharmony_ci		clocks = <&dpll4_m4x2_ck>;
658c2ecf20Sopenharmony_ci		reg = <0x0e00>;
668c2ecf20Sopenharmony_ci		ti,bit-shift = <0>;
678c2ecf20Sopenharmony_ci	};
688c2ecf20Sopenharmony_ci
698c2ecf20Sopenharmony_ci	emac_ick: emac_ick@4800259c {
708c2ecf20Sopenharmony_ci		#clock-cells = <0>;
718c2ecf20Sopenharmony_ci		compatible = "ti,am35xx-gate-clock";
728c2ecf20Sopenharmony_ci		clocks = <&ipss_ick>;
738c2ecf20Sopenharmony_ci		reg = <0x059c>;
748c2ecf20Sopenharmony_ci		ti,bit-shift = <1>;
758c2ecf20Sopenharmony_ci	};
768c2ecf20Sopenharmony_ci
778c2ecf20Sopenharmony_ci	emu_src_ck: emu_src_ck {
788c2ecf20Sopenharmony_ci		#clock-cells = <0>;
798c2ecf20Sopenharmony_ci		compatible = "ti,clkdm-gate-clock";
808c2ecf20Sopenharmony_ci		clocks = <&emu_src_mux_ck>;
818c2ecf20Sopenharmony_ci	};
828c2ecf20Sopenharmony_ci
838c2ecf20Sopenharmony_ci	dpll4_m2x2_ck: dpll4_m2x2_ck@48004d00 {
848c2ecf20Sopenharmony_ci		#clock-cells = <0>;
858c2ecf20Sopenharmony_ci		compatible = "ti,hsdiv-gate-clock";
868c2ecf20Sopenharmony_ci		clocks = <&dpll4_m2x2_mul_ck>;
878c2ecf20Sopenharmony_ci		ti,bit-shift = <0x1b>;
888c2ecf20Sopenharmony_ci		reg = <0x0d00>;
898c2ecf20Sopenharmony_ci		ti,set-bit-to-disable;
908c2ecf20Sopenharmony_ci	};
918c2ecf20Sopenharmony_ci
928c2ecf20Sopenharmony_ci	vlynq_gate_fck: vlynq_gate_fck {
938c2ecf20Sopenharmony_ci		#clock-cells = <0>;
948c2ecf20Sopenharmony_ci		compatible = "ti,composite-gate-clock";
958c2ecf20Sopenharmony_ci		clocks = <&core_ck>;
968c2ecf20Sopenharmony_ci		ti,bit-shift = <3>;
978c2ecf20Sopenharmony_ci		reg = <0x0200>;
988c2ecf20Sopenharmony_ci	};
998c2ecf20Sopenharmony_ci
1008c2ecf20Sopenharmony_ci	sys_clkout2_src_gate: sys_clkout2_src_gate {
1018c2ecf20Sopenharmony_ci		#clock-cells = <0>;
1028c2ecf20Sopenharmony_ci		compatible = "ti,composite-no-wait-gate-clock";
1038c2ecf20Sopenharmony_ci		clocks = <&core_ck>;
1048c2ecf20Sopenharmony_ci		ti,bit-shift = <15>;
1058c2ecf20Sopenharmony_ci		reg = <0x0070>;
1068c2ecf20Sopenharmony_ci	};
107