Skip to content

Commit 4da1c67

Browse files
Poddar, SouravTero Kristo
authored andcommitted
ARM: dts: am43x-clock: add tbclk data for ehrpwm
We need "tbclk" clock data for the functioning of ehrpwm module. Hence, populating the required clock information in clock dts file. Signed-off-by: Sourav Poddar <sourav.poddar@ti.com> Acked-by: Tero Kristo <t-kristo@ti.com> Signed-off-by: Tero Kristo <t-kristo@ti.com>
1 parent 9e100eb commit 4da1c67

2 files changed

Lines changed: 54 additions & 0 deletions

File tree

‎arch/arm/boot/dts/am43xx-clocks.dtsi‎

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,54 @@
8787
clock-mult = <1>;
8888
clock-div = <1>;
8989
};
90+
91+
ehrpwm0_tbclk: ehrpwm0_tbclk {
92+
#clock-cells = <0>;
93+
compatible = "ti,gate-clock";
94+
clocks = <&dpll_per_m2_ck>;
95+
ti,bit-shift = <0>;
96+
reg = <0x0664>;
97+
};
98+
99+
ehrpwm1_tbclk: ehrpwm1_tbclk {
100+
#clock-cells = <0>;
101+
compatible = "ti,gate-clock";
102+
clocks = <&dpll_per_m2_ck>;
103+
ti,bit-shift = <1>;
104+
reg = <0x0664>;
105+
};
106+
107+
ehrpwm2_tbclk: ehrpwm2_tbclk {
108+
#clock-cells = <0>;
109+
compatible = "ti,gate-clock";
110+
clocks = <&dpll_per_m2_ck>;
111+
ti,bit-shift = <2>;
112+
reg = <0x0664>;
113+
};
114+
115+
ehrpwm3_tbclk: ehrpwm3_tbclk {
116+
#clock-cells = <0>;
117+
compatible = "ti,gate-clock";
118+
clocks = <&dpll_per_m2_ck>;
119+
ti,bit-shift = <4>;
120+
reg = <0x0664>;
121+
};
122+
123+
ehrpwm4_tbclk: ehrpwm4_tbclk {
124+
#clock-cells = <0>;
125+
compatible = "ti,gate-clock";
126+
clocks = <&dpll_per_m2_ck>;
127+
ti,bit-shift = <5>;
128+
reg = <0x0664>;
129+
};
130+
131+
ehrpwm5_tbclk: ehrpwm5_tbclk {
132+
#clock-cells = <0>;
133+
compatible = "ti,gate-clock";
134+
clocks = <&dpll_per_m2_ck>;
135+
ti,bit-shift = <6>;
136+
reg = <0x0664>;
137+
};
90138
};
91139
&prcm_clocks {
92140
clk_32768_ck: clk_32768_ck {

‎drivers/clk/ti/clk-43xx.c‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,12 @@ static struct ti_dt_clk am43xx_clks[] = {
105105
DT_CLK(NULL, "func_12m_clk", "func_12m_clk"),
106106
DT_CLK(NULL, "vtp_clk_div", "vtp_clk_div"),
107107
DT_CLK(NULL, "usbphy_32khz_clkmux", "usbphy_32khz_clkmux"),
108+
DT_CLK("48300200.ehrpwm", "tbclk", "ehrpwm0_tbclk"),
109+
DT_CLK("48302200.ehrpwm", "tbclk", "ehrpwm1_tbclk"),
110+
DT_CLK("48304200.ehrpwm", "tbclk", "ehrpwm2_tbclk"),
111+
DT_CLK("48306200.ehrpwm", "tbclk", "ehrpwm3_tbclk"),
112+
DT_CLK("48308200.ehrpwm", "tbclk", "ehrpwm4_tbclk"),
113+
DT_CLK("4830a200.ehrpwm", "tbclk", "ehrpwm5_tbclk"),
108114
{ .node_name = NULL },
109115
};
110116

0 commit comments

Comments
 (0)