Skip to contentSkip to conversation

riscv: dts: enable more DA9063 functions for the SiFive HiFive Unmatched

PATCH In review Aurelien Jarno 3 participants 4 messages Nov 8, 2021 – Dec 14, 2021

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 riscv: dts: enable more DA9063 functions for the SiFive HiFive Unmatched

The DA9063 PMIC found on the SiFive HiFive Unmatched also provides an RTC, a watchdog and the power button input.

---
 arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts | 12 ++++++++++++
 1 file changed, 12 insertions(+)
arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts +12 -0
index 2e4ea84f27e7..c357b48582f7 100644
@@ -70,6 +70,10 @@ pmic@58 {
 		interrupts = <1 IRQ_TYPE_LEVEL_LOW>;
 		interrupt-controller;
 
+		onkey {
+			compatible = "dlg,da9063-onkey";
+		};
+
 		regulators {
 			vdd_bcore1: bcore1 {
 				regulator-min-microvolt = <900000>;
@@ -205,6 +209,14 @@ vdd_ldo11: ldo11 {
 				regulator-always-on;
 			};
 		};
+
+		rtc {
+			compatible = "dlg,da9063-rtc";
+		};
+
+		wdt {
+			compatible = "dlg,da9063-watchdog";
+		};
 	};
 };
 
Signature · 1 line
2.30.2
maintainer
#1 lore raw
Quoted 27 lines · On Mon, 08 Nov 2021 13:46:29 PST (-0800), [email protected] wrote:

The DA9063 PMIC found on the SiFive HiFive Unmatched also provides an RTC, a watchdog and the power button input.

---
 arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts | 12 ++++++++++++
 1 file changed, 12 insertions(+)
arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts +4 -0
index 2e4ea84f27e7..c357b48582f7 100644
@@ -70,6 +70,10 @@ pmic@58 {
 		interrupts = <1 IRQ_TYPE_LEVEL_LOW>;
 		interrupt-controller;
 
+		onkey {
+			compatible = "dlg,da9063-onkey";
+		};
+
 		regulators {
 			vdd_bcore1: bcore1 {
 				regulator-min-microvolt = <900000>;
@@ -205,6 +209,14 @@ vdd_ldo11: ldo11 {
 				regulator-always-on;
 			};
 		};

arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts vdd_ldo11: ldo11 { · line 221

Quoted 10 lines
arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts +8 -0
+
+		rtc {
+			compatible = "dlg,da9063-rtc";
+		};
+
+		wdt {
+			compatible = "dlg,da9063-watchdog";
+		};
 	};
 };

Thanks, this is on for-next.

#2 lore raw
Quoted 30 lines · Palmer Dabbelt
Quoted 29 lines · On Mon, 08 Nov 2021 13:46:29 PST (-0800), [email protected] wrote:

The DA9063 PMIC found on the SiFive HiFive Unmatched also provides an RTC, a watchdog and the power button input.

---
 arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts | 12 ++++++++++++
 1 file changed, 12 insertions(+)
arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts +6 -0
index 2e4ea84f27e7..c357b48582f7 100644
@@ -70,6 +70,10 @@ pmic@58 {
 		interrupts = <1 IRQ_TYPE_LEVEL_LOW>;
 		interrupt-controller;
 
+		onkey {
+			compatible = "dlg,da9063-onkey";
+		};
+
 		regulators {
 			vdd_bcore1: bcore1 {
 				regulator-min-microvolt = <900000>;
@@ -205,6 +209,14 @@ vdd_ldo11: ldo11 {
 				regulator-always-on;
 			};
 		};
+
+		rtc {
Quoted 8 lines

arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts vdd_ldo11: ldo11 { · line 221

Quoted 8 lines
arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts +6 -0
+			compatible = "dlg,da9063-rtc";
+		};
+
+		wdt {
+			compatible = "dlg,da9063-watchdog";
+		};
 	};
 };

Thanks. However, wouldn't be better to merged this patch and the whole series instead:

http://lists.infradead.org/pipermail/linux-riscv/2021-November/010234.html

Regards,
Aurelien

Signature · 2 lines
Aurelien Jarno                          GPG: 4096R/1DDD8C9B
[email protected]                 http://www.aurel32.net
#3 lore raw
Quoted 43 lines · Aurelien Jarno
Quoted 30 lines · Palmer Dabbelt
Quoted 29 lines · On Mon, 08 Nov 2021 13:46:29 PST (-0800), [email protected] wrote:

The DA9063 PMIC found on the SiFive HiFive Unmatched also provides an RTC, a watchdog and the power button input.

---
 arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts | 12 ++++++++++++
 1 file changed, 12 insertions(+)
arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts +6 -0
index 2e4ea84f27e7..c357b48582f7 100644
@@ -70,6 +70,10 @@ pmic@58 {
 		interrupts = <1 IRQ_TYPE_LEVEL_LOW>;
 		interrupt-controller;
 
+		onkey {
+			compatible = "dlg,da9063-onkey";
+		};
+
 		regulators {
 			vdd_bcore1: bcore1 {
 				regulator-min-microvolt = <900000>;
@@ -205,6 +209,14 @@ vdd_ldo11: ldo11 {
 				regulator-always-on;
 			};
 		};
+
+		rtc {
Quoted 8 lines

arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts vdd_ldo11: ldo11 { · line 221

Quoted 8 lines
arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts +6 -0
+			compatible = "dlg,da9063-rtc";
+		};
+
+		wdt {
+			compatible = "dlg,da9063-watchdog";
+		};
 	};
 };  

Thanks. However, wouldn't be better to merged this patch and the whole series instead:

Quoted 1 line

http://lists.infradead.org/pipermail/linux-riscv/2021-November/010234.html

My apologies about this, by the way: I had prepared that patch stack last summer and was witholding it until the IRQ-fires-only-once situation was resolved (it does affect at least the onkey subfunction, although in a non-obvious way when the event triggers a shutdown or a reboot). I did not think of checking recent submissions until it was too late.

Signature · 2 lines
Vincent Pelletier
GPG fingerprint 983A E8B7 3B91 1598 7A92 3845 CAC9 3691 4257 B0C1