* [PATCH] arm64: dts: rockchip: Add buttons to Kobol Helios64
@ 2026-09-30 2:52 Igor Velkov via B4 Relay
2026-09-30 3:00 ` sashiko-bot
2026-10-04 21:17 ` Heiko Stuebner
0 siblings, 2 replies; 4+ messages in thread
From: Igor Velkov via B4 Relay @ 2026-09-30 2:52 UTC (permalink / raw)
To: Heiko Stuebner
Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, devicetree,
linux-arm-kernel, linux-rockchip, linux-kernel, Igor Velkov
From: Igor Velkov <iav@iav.lv>
The Helios64 front panel has Power and Recovery buttons. Power is
wired to GPIO0_A5 and Recovery to SARADC channel 1. The board also
routes a User1 button signal to GPIO0_A3 on front panel header P3.
Describe Power and User1 as gpio-keys and Recovery as adc-keys.
The SARADC reference is the 1V8_S3 rail from RK808 LDO_REG3, so add
that regulator.
Assisted-by: LLM
Signed-off-by: Igor Velkov <iav@iav.lv>
---
Tested on 7.3-rc5 with evtest: Power reports KEY_POWER, Recovery
reports BTN_1. Power wakes the board from s2idle. User1 has no button
on the enclosure and is untested.
---
.../boot/dts/rockchip/rk3399-kobol-helios64.dts | 64 ++++++++++++++++++++++
1 file changed, 64 insertions(+)
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-kobol-helios64.dts b/arch/arm64/boot/dts/rockchip/rk3399-kobol-helios64.dts
index b2de018a7d36..d146e5075b4f 100644
--- a/arch/arm64/boot/dts/rockchip/rk3399-kobol-helios64.dts
+++ b/arch/arm64/boot/dts/rockchip/rk3399-kobol-helios64.dts
@@ -11,6 +11,7 @@
*/
/dts-v1/;
+#include <dt-bindings/input/input.h>
#include "rk3399.dtsi"
/ {
@@ -23,6 +24,20 @@ aliases {
mmc1 = &sdhci;
};
+ adc-keys {
+ compatible = "adc-keys";
+ io-channels = <&saradc 1>;
+ io-channel-names = "buttons";
+ keyup-threshold-microvolt = <1800000>;
+ poll-interval = <100>;
+
+ button-recovery {
+ label = "Recovery";
+ linux,code = <BTN_1>;
+ press-threshold-microvolt = <100000>;
+ };
+ };
+
avdd_0v9_s0: regulator-avdd-0v9-s0 {
compatible = "regulator-fixed";
regulator-name = "avdd_0v9_s0";
@@ -68,6 +83,27 @@ fan2 {
cooling-levels = <0 80 170 255>;
};
+ gpio-keys {
+ compatible = "gpio-keys";
+ pinctrl-names = "default";
+ pinctrl-0 = <&pwr_btn &user1_btn>;
+
+ button-power {
+ debounce-interval = <100>;
+ gpios = <&gpio0 RK_PA5 GPIO_ACTIVE_LOW>;
+ label = "Power";
+ linux,code = <KEY_POWER>;
+ wakeup-source;
+ };
+
+ button-user1 {
+ debounce-interval = <100>;
+ gpios = <&gpio0 RK_PA3 GPIO_ACTIVE_LOW>;
+ label = "User Button 1";
+ linux,code = <BTN_0>;
+ };
+ };
+
leds {
compatible = "gpio-leds";
pinctrl-names = "default";
@@ -352,6 +388,19 @@ regulator-state-mem {
};
};
+ vcc1v8_s3: LDO_REG3 {
+ regulator-name = "vcc1v8_s3";
+ regulator-always-on;
+ regulator-boot-on;
+ regulator-min-microvolt = <1800000>;
+ regulator-max-microvolt = <1800000>;
+
+ regulator-state-mem {
+ regulator-on-in-suspend;
+ regulator-suspend-microvolt = <1800000>;
+ };
+ };
+
vcc_sdio_s0: LDO_REG4 {
regulator-name = "vcc_sdio_s0";
regulator-always-on;
@@ -434,6 +483,16 @@ &pcie0 {
};
&pinctrl {
+ buttons {
+ pwr_btn: pwr-btn {
+ rockchip,pins = <0 RK_PA5 RK_FUNC_GPIO &pcfg_pull_up>;
+ };
+
+ user1_btn: user1-btn {
+ rockchip,pins = <0 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>;
+ };
+ };
+
gmac {
gphy_reset: gphy-reset {
rockchip,pins = <3 RK_PB7 RK_FUNC_GPIO &pcfg_output_low>;
@@ -503,6 +562,11 @@ &pwm1 {
status = "okay";
};
+&saradc {
+ vref-supply = <&vcc1v8_s3>;
+ status = "okay";
+};
+
&sdhci {
bus-width = <8>;
mmc-hs200-1_8v;
---
base-commit: 23d8f49fcae5d72b77744c7f349c12462c3bb748
change-id: 20260930-helios64-buttons-b93ad4e8ee2e
Best regards,
--
Igor Velkov <iav@iav.lv>
^ permalink raw reply related [flat|nested] 4+ messages in thread* Re: [PATCH] arm64: dts: rockchip: Add buttons to Kobol Helios64
2026-09-30 2:52 [PATCH] arm64: dts: rockchip: Add buttons to Kobol Helios64 Igor Velkov via B4 Relay
@ 2026-09-30 3:00 ` sashiko-bot
2026-09-30 3:23 ` Igor Velkov
2026-10-04 21:17 ` Heiko Stuebner
1 sibling, 1 reply; 4+ messages in thread
From: sashiko-bot @ 2026-09-30 3:00 UTC (permalink / raw)
To: Igor Velkov; +Cc: conor+dt, robh, devicetree
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] dts: rockchip: floating User1 button causes interrupt storms
--
commit a839eb665d8bc992ebe29b10a50a8b7e57d5f4f5
Author: Igor Velkov <iav@iav.lv>
arm64: dts: rockchip: Add buttons to Kobol Helios64
The commit adds gpio-keys and adc-keys for the Power, User1, and Recovery
buttons on the Kobol Helios64 board. It also adds the vcc1v8_s3 regulator
reference for the SARADC.
> diff --git a/arch/arm64/boot/dts/rockchip/rk3399-kobol-helios64.dts b/arch/arm64/boot/dts/rockchip/rk3399-kobol-helios64.dts
> index b2de018a7d363..d146e5075b4f8 100644
> --- a/arch/arm64/boot/dts/rockchip/rk3399-kobol-helios64.dts
> +++ b/arch/arm64/boot/dts/rockchip/rk3399-kobol-helios64.dts
[ ... ]
> @@ -68,6 +83,27 @@ fan2 {
> cooling-levels = <0 80 170 255>;
> };
>
> + gpio-keys {
> + compatible = "gpio-keys";
> + pinctrl-names = "default";
> + pinctrl-0 = <&pwr_btn &user1_btn>;
> +
> + button-power {
> + debounce-interval = <100>;
> + gpios = <&gpio0 RK_PA5 GPIO_ACTIVE_LOW>;
> + label = "Power";
> + linux,code = <KEY_POWER>;
> + wakeup-source;
> + };
> +
> + button-user1 {
> + debounce-interval = <100>;
> + gpios = <&gpio0 RK_PA3 GPIO_ACTIVE_LOW>;
> + label = "User Button 1";
> + linux,code = <BTN_0>;
> + };
> + };
[ ... ]
> @@ -434,6 +483,16 @@ &pcie0 {
> };
>
> &pinctrl {
> + buttons {
> + pwr_btn: pwr-btn {
> + rockchip,pins = <0 RK_PA5 RK_FUNC_GPIO &pcfg_pull_up>;
> + };
> +
> + user1_btn: user1-btn {
> + rockchip,pins = <0 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>;
> + };
> + };
[Severity: High]
Since the user1 button GPIO (RK_PA3) is registered in gpio-keys as
GPIO_ACTIVE_LOW to generate edge interrupts, does disabling the internal pull-up
with &pcfg_pull_none leave the pin floating?
The commit message notes "User1 has no button on the enclosure and is
untested", meaning the pin is unconnected. Without an internal or external
pull-up, a floating pin will pick up ambient electromagnetic noise and cross the
logic threshold randomly, continuously generating spurious BTN_0 events.
Can this cause interrupt storms that degrade system performance or lead to
unresponsiveness?
Should the pinctrl configuration use &pcfg_pull_up here to prevent the pin from
floating, or should the node remain disabled by default?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260930-helios64-buttons-v1-1-d76249064003@iav.lv?part=1
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH] arm64: dts: rockchip: Add buttons to Kobol Helios64
2026-09-30 3:00 ` sashiko-bot
@ 2026-09-30 3:23 ` Igor Velkov
0 siblings, 0 replies; 4+ messages in thread
From: Igor Velkov @ 2026-09-30 3:23 UTC (permalink / raw)
To: sashiko-reviews
Cc: Heiko Stuebner, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
devicetree, linux-arm-kernel, linux-rockchip, linux-kernel
On Wed, Sep 30, 2026 at 03:00:34AM +0000, sashiko-bot@kernel.org wrote:
> Since the user1 button GPIO (RK_PA3) is registered in gpio-keys as
> GPIO_ACTIVE_LOW to generate edge interrupts, does disabling the internal pull-up
> with &pcfg_pull_none leave the pin floating?
Not floating: GPIO0_A3 (USR1_SWITCH#) has an external 4.75k pull-up
(R9) to 1V8_S3 on the SoC side of D11, sheet 29 of
https://wiki.kobol.io/helios64/files/schematics/Helios64_Schematics_Rev1.2.pdf
Armbian ships the same pinctrl; with no User1 button attached the
IRQ count stays 0 after 29 minutes of uptime.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] arm64: dts: rockchip: Add buttons to Kobol Helios64
2026-09-30 2:52 [PATCH] arm64: dts: rockchip: Add buttons to Kobol Helios64 Igor Velkov via B4 Relay
2026-09-30 3:00 ` sashiko-bot
@ 2026-10-04 21:17 ` Heiko Stuebner
1 sibling, 0 replies; 4+ messages in thread
From: Heiko Stuebner @ 2026-10-04 21:17 UTC (permalink / raw)
To: Igor Velkov
Cc: Heiko Stuebner, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
devicetree, linux-arm-kernel, linux-rockchip, linux-kernel
On Wed, 30 Sep 2026 05:52:03 +0300, Igor Velkov wrote:
> The Helios64 front panel has Power and Recovery buttons. Power is
> wired to GPIO0_A5 and Recovery to SARADC channel 1. The board also
> routes a User1 button signal to GPIO0_A3 on front panel header P3.
>
> Describe Power and User1 as gpio-keys and Recovery as adc-keys.
> The SARADC reference is the 1V8_S3 rail from RK808 LDO_REG3, so add
> that regulator.
>
> [...]
Applied, thanks!
[1/1] arm64: dts: rockchip: Add buttons to Kobol Helios64
commit: 1e0a0365c73177d55365cdde3a1a179b4897a77b
Best regards,
--
Heiko Stuebner <heiko@sntech.de>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2026-10-04 21:17 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-30 2:52 [PATCH] arm64: dts: rockchip: Add buttons to Kobol Helios64 Igor Velkov via B4 Relay
2026-09-30 3:00 ` sashiko-bot
2026-09-30 3:23 ` Igor Velkov
2026-10-04 21:17 ` Heiko Stuebner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox