1*4882a593SmuzhiyunBinding for Texas Instruments gate clock. 2*4882a593Smuzhiyun 3*4882a593SmuzhiyunBinding status: Unstable - ABI compatibility may be broken in the future 4*4882a593Smuzhiyun 5*4882a593SmuzhiyunThis binding uses the common clock binding[1]. This clock is 6*4882a593Smuzhiyunquite much similar to the basic gate-clock [2], however, 7*4882a593Smuzhiyunit supports a number of additional features. If no register 8*4882a593Smuzhiyunis provided for this clock, the code assumes that a clockdomain 9*4882a593Smuzhiyunwill be controlled instead and the corresponding hw-ops for 10*4882a593Smuzhiyunthat is used. 11*4882a593Smuzhiyun 12*4882a593Smuzhiyun[1] Documentation/devicetree/bindings/clock/clock-bindings.txt 13*4882a593Smuzhiyun[2] Documentation/devicetree/bindings/clock/gpio-gate-clock.txt 14*4882a593Smuzhiyun[3] Documentation/devicetree/bindings/clock/ti/clockdomain.txt 15*4882a593Smuzhiyun 16*4882a593SmuzhiyunRequired properties: 17*4882a593Smuzhiyun- compatible : shall be one of: 18*4882a593Smuzhiyun "ti,gate-clock" - basic gate clock 19*4882a593Smuzhiyun "ti,wait-gate-clock" - gate clock which waits until clock is active before 20*4882a593Smuzhiyun returning from clk_enable() 21*4882a593Smuzhiyun "ti,dss-gate-clock" - gate clock with DSS specific hardware handling 22*4882a593Smuzhiyun "ti,am35xx-gate-clock" - gate clock with AM35xx specific hardware handling 23*4882a593Smuzhiyun "ti,clkdm-gate-clock" - clockdomain gate clock, which derives its functional 24*4882a593Smuzhiyun clock directly from a clockdomain, see [3] how 25*4882a593Smuzhiyun to map clockdomains properly 26*4882a593Smuzhiyun "ti,hsdiv-gate-clock" - gate clock with OMAP36xx specific hardware handling, 27*4882a593Smuzhiyun required for a hardware errata 28*4882a593Smuzhiyun "ti,composite-gate-clock" - composite gate clock, to be part of composite 29*4882a593Smuzhiyun clock 30*4882a593Smuzhiyun "ti,composite-no-wait-gate-clock" - composite gate clock that does not wait 31*4882a593Smuzhiyun for clock to be active before returning 32*4882a593Smuzhiyun from clk_enable() 33*4882a593Smuzhiyun- #clock-cells : from common clock binding; shall be set to 0 34*4882a593Smuzhiyun- clocks : link to phandle of parent clock 35*4882a593Smuzhiyun- reg : offset for register controlling adjustable gate, not needed for 36*4882a593Smuzhiyun ti,clkdm-gate-clock type 37*4882a593Smuzhiyun 38*4882a593SmuzhiyunOptional properties: 39*4882a593Smuzhiyun- ti,bit-shift : bit shift for programming the clock gate, invalid for 40*4882a593Smuzhiyun ti,clkdm-gate-clock type 41*4882a593Smuzhiyun- ti,set-bit-to-disable : inverts default gate programming. Setting the bit 42*4882a593Smuzhiyun gates the clock and clearing the bit ungates the clock. 43*4882a593Smuzhiyun 44*4882a593SmuzhiyunExamples: 45*4882a593Smuzhiyun mmchs2_fck: mmchs2_fck@48004a00 { 46*4882a593Smuzhiyun #clock-cells = <0>; 47*4882a593Smuzhiyun compatible = "ti,gate-clock"; 48*4882a593Smuzhiyun clocks = <&core_96m_fck>; 49*4882a593Smuzhiyun reg = <0x0a00>; 50*4882a593Smuzhiyun ti,bit-shift = <25>; 51*4882a593Smuzhiyun }; 52*4882a593Smuzhiyun 53*4882a593Smuzhiyun uart4_fck_am35xx: uart4_fck_am35xx { 54*4882a593Smuzhiyun #clock-cells = <0>; 55*4882a593Smuzhiyun compatible = "ti,wait-gate-clock"; 56*4882a593Smuzhiyun clocks = <&core_48m_fck>; 57*4882a593Smuzhiyun reg = <0x0a00>; 58*4882a593Smuzhiyun ti,bit-shift = <23>; 59*4882a593Smuzhiyun }; 60*4882a593Smuzhiyun 61*4882a593Smuzhiyun dss1_alwon_fck_3430es2: dss1_alwon_fck_3430es2@48004e00 { 62*4882a593Smuzhiyun #clock-cells = <0>; 63*4882a593Smuzhiyun compatible = "ti,dss-gate-clock"; 64*4882a593Smuzhiyun clocks = <&dpll4_m4x2_ck>; 65*4882a593Smuzhiyun reg = <0x0e00>; 66*4882a593Smuzhiyun ti,bit-shift = <0>; 67*4882a593Smuzhiyun }; 68*4882a593Smuzhiyun 69*4882a593Smuzhiyun emac_ick: emac_ick@4800259c { 70*4882a593Smuzhiyun #clock-cells = <0>; 71*4882a593Smuzhiyun compatible = "ti,am35xx-gate-clock"; 72*4882a593Smuzhiyun clocks = <&ipss_ick>; 73*4882a593Smuzhiyun reg = <0x059c>; 74*4882a593Smuzhiyun ti,bit-shift = <1>; 75*4882a593Smuzhiyun }; 76*4882a593Smuzhiyun 77*4882a593Smuzhiyun emu_src_ck: emu_src_ck { 78*4882a593Smuzhiyun #clock-cells = <0>; 79*4882a593Smuzhiyun compatible = "ti,clkdm-gate-clock"; 80*4882a593Smuzhiyun clocks = <&emu_src_mux_ck>; 81*4882a593Smuzhiyun }; 82*4882a593Smuzhiyun 83*4882a593Smuzhiyun dpll4_m2x2_ck: dpll4_m2x2_ck@48004d00 { 84*4882a593Smuzhiyun #clock-cells = <0>; 85*4882a593Smuzhiyun compatible = "ti,hsdiv-gate-clock"; 86*4882a593Smuzhiyun clocks = <&dpll4_m2x2_mul_ck>; 87*4882a593Smuzhiyun ti,bit-shift = <0x1b>; 88*4882a593Smuzhiyun reg = <0x0d00>; 89*4882a593Smuzhiyun ti,set-bit-to-disable; 90*4882a593Smuzhiyun }; 91*4882a593Smuzhiyun 92*4882a593Smuzhiyun vlynq_gate_fck: vlynq_gate_fck { 93*4882a593Smuzhiyun #clock-cells = <0>; 94*4882a593Smuzhiyun compatible = "ti,composite-gate-clock"; 95*4882a593Smuzhiyun clocks = <&core_ck>; 96*4882a593Smuzhiyun ti,bit-shift = <3>; 97*4882a593Smuzhiyun reg = <0x0200>; 98*4882a593Smuzhiyun }; 99*4882a593Smuzhiyun 100*4882a593Smuzhiyun sys_clkout2_src_gate: sys_clkout2_src_gate { 101*4882a593Smuzhiyun #clock-cells = <0>; 102*4882a593Smuzhiyun compatible = "ti,composite-no-wait-gate-clock"; 103*4882a593Smuzhiyun clocks = <&core_ck>; 104*4882a593Smuzhiyun ti,bit-shift = <15>; 105*4882a593Smuzhiyun reg = <0x0070>; 106*4882a593Smuzhiyun }; 107