Linux-RISC-V Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Inochi Amaoto <inochiama@gmail.com>
To: Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Paul Walmsley <paul.walmsley@sifive.com>,
	Palmer Dabbelt <palmer@dabbelt.com>,
	Albert Ou <aou@eecs.berkeley.edu>,
	Alexandre Ghiti <alex@ghiti.fr>,
	Chen Wang <unicorn_wang@outlook.com>,
	Inochi Amaoto <inochiama@gmail.com>,
	Richard Cochran <richardcochran@gmail.com>,
	Longbin Li <looong.bin@gmail.com>
Cc: Han Gao <rabenda.cn@gmail.com>,
	devicetree@vger.kernel.org, linux-riscv@lists.infradead.org,
	sophgo@lists.linux.dev, linux-kernel@vger.kernel.org,
	netdev@vger.kernel.org, Yixun Lan <dlan@gentoo.org>
Subject: [PATCH 11/11] riscv: dts: sophgo: add pwm controller for SG2044
Date: Mon,  9 Jun 2025 07:28:35 +0800	[thread overview]
Message-ID: <20250608232836.784737-12-inochiama@gmail.com> (raw)
In-Reply-To: <20250608232836.784737-1-inochiama@gmail.com>

From: Longbin Li <looong.bin@gmail.com>

Add pwm device node for SG2044.

Signed-off-by: Longbin Li <looong.bin@gmail.com>
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
---
 arch/riscv/boot/dts/sophgo/sg2044-sophgo-srd3-10.dts |  4 ++++
 arch/riscv/boot/dts/sophgo/sg2044.dtsi               | 10 ++++++++++
 2 files changed, 14 insertions(+)

diff --git a/arch/riscv/boot/dts/sophgo/sg2044-sophgo-srd3-10.dts b/arch/riscv/boot/dts/sophgo/sg2044-sophgo-srd3-10.dts
index 01340f21848f..b50c3a872d8b 100644
--- a/arch/riscv/boot/dts/sophgo/sg2044-sophgo-srd3-10.dts
+++ b/arch/riscv/boot/dts/sophgo/sg2044-sophgo-srd3-10.dts
@@ -63,6 +63,10 @@ mcu: syscon@17 {
 	};
 };
 
+&pwm {
+	status = "okay";
+};
+
 &sd {
 	bus-width = <4>;
 	no-sdio;
diff --git a/arch/riscv/boot/dts/sophgo/sg2044.dtsi b/arch/riscv/boot/dts/sophgo/sg2044.dtsi
index b65e491deb8f..f88cabe75790 100644
--- a/arch/riscv/boot/dts/sophgo/sg2044.dtsi
+++ b/arch/riscv/boot/dts/sophgo/sg2044.dtsi
@@ -347,6 +347,16 @@ portc: gpio-controller@0 {
 			};
 		};
 
+		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>;
-- 
2.49.0


_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

  parent reply	other threads:[~2025-06-09  0:38 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-08 23:28 [PATCH 00/11] riscv: sophgo: sg2044: add DTS support for all available devices Inochi Amaoto
2025-06-08 23:28 ` [PATCH 01/11] riscv: dts: sophgo: sg2044: Add system controller device Inochi Amaoto
2025-06-08 23:28 ` [PATCH 02/11] riscv: dts: sophgo: sg2044: Add clock " Inochi Amaoto
2025-06-08 23:28 ` [PATCH 03/11] riscv: dts: sophgo: sg2044: Add GPIO device Inochi Amaoto
2025-06-08 23:28 ` [PATCH 04/11] riscv: dts: sophgo: sg2044: Add I2C device Inochi Amaoto
2025-06-08 23:28 ` [PATCH 05/11] riscv: dts: sophgo: sg2044: add DMA controller device Inochi Amaoto
2025-06-08 23:28 ` [PATCH 06/11] riscv: dts: sophgo: sg2044: Add MMC " Inochi Amaoto
2025-06-08 23:28 ` [PATCH 07/11] riscv: dts: sophgo: sophgo-srd3-10: add HWMON MCU device Inochi Amaoto
2025-06-08 23:28 ` [PATCH 08/11] riscv: dts: sophgo: sg2044: Add ethernet control device Inochi Amaoto
2025-06-08 23:28 ` [PATCH 09/11] riscv: dts: sophgo: sg2044: Add pinctrl device Inochi Amaoto
2025-06-08 23:28 ` [PATCH 10/11] riscv: dts: sophgo: add SG2044 SPI NOR controller driver Inochi Amaoto
2025-06-08 23:28 ` Inochi Amaoto [this message]
2025-06-11  9:53   ` [PATCH 11/11] riscv: dts: sophgo: add pwm controller for SG2044 Chen Wang
2025-06-11 10:17     ` Inochi Amaoto
2025-06-17  5:07 ` [PATCH 00/11] riscv: sophgo: sg2044: add DTS support for all available devices Inochi Amaoto

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250608232836.784737-12-inochiama@gmail.com \
    --to=inochiama@gmail.com \
    --cc=alex@ghiti.fr \
    --cc=aou@eecs.berkeley.edu \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dlan@gentoo.org \
    --cc=krzk+dt@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=looong.bin@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=palmer@dabbelt.com \
    --cc=paul.walmsley@sifive.com \
    --cc=rabenda.cn@gmail.com \
    --cc=richardcochran@gmail.com \
    --cc=robh@kernel.org \
    --cc=sophgo@lists.linux.dev \
    --cc=unicorn_wang@outlook.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox