]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
riscv: dts: sophgo: add pwm controller for SG2044
authorLongbin Li <looong.bin@gmail.com>
Sun, 8 Jun 2025 23:28:35 +0000 (07:28 +0800)
committerInochi Amaoto <inochiama@gmail.com>
Wed, 23 Jul 2025 01:55:14 +0000 (09:55 +0800)
Add pwm device node for SG2044.

Signed-off-by: Longbin Li <looong.bin@gmail.com>
Reviewed-by: Chen Wang <unicorn_wang@outlook.com>
Link: https://lore.kernel.org/r/20250608232836.784737-12-inochiama@gmail.com
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Chen Wang <unicorn_wang@outlook.com>
Signed-off-by: Chen Wang <wangchen20@iscas.ac.cn>
arch/riscv/boot/dts/sophgo/sg2044-sophgo-srd3-10.dts
arch/riscv/boot/dts/sophgo/sg2044.dtsi

index 01340f21848f497ae70277d0f1b4c33f95352a6e..b50c3a872d8b70635790e515cdfa39fda084f3f9 100644 (file)
        };
 };
 
+&pwm {
+       status = "okay";
+};
+
 &sd {
        bus-width = <4>;
        no-sdio;
index b65e491deb8ff1a5b77d057618a190e846ccff3e..f88cabe75790756a4f3337df6028012b05ecfd37 100644 (file)
                        };
                };
 
+               pwm: pwm@704000c000 {
+                       compatible = "sophgo,sg2044-pwm";
+                       reg = <0x70 0x4000c000 0x0 0x1000>;
+                       #pwm-cells = <3>;
+                       clocks = <&clk CLK_GATE_APB_PWM>;
+                       clock-names = "apb";
+                       resets = <&rst RST_PWM>;
+                       status = "disabled";
+               };
+
                syscon: syscon@7050000000 {
                        compatible = "sophgo,sg2044-top-syscon", "syscon";
                        reg = <0x70 0x50000000 0x0 0x1000>;