]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
riscv: dts: spacemit: add gpio LED for system heartbeat
authorYixun Lan <dlan@gentoo.org>
Thu, 24 Apr 2025 09:40:51 +0000 (17:40 +0800)
committerYixun Lan <dlan@gentoo.org>
Wed, 14 May 2025 03:43:59 +0000 (11:43 +0800)
Leverage GPIO to support system LED to indicate activity of CPUs.

Link: https://lore.kernel.org/r/20250424-03-k1-gpio-v9-3-eaece8cc5a86@gentoo.org
Signed-off-by: Yixun Lan <dlan@gentoo.org>
arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts

index 1d617b40a2d51ee464b57234d248798aeb218643..816ef1bc358ec490aff184d5915d680dbd9f00cb 100644 (file)
        chosen {
                stdout-path = "serial0";
        };
+
+       leds {
+               compatible = "gpio-leds";
+
+               led1 {
+                       label = "sys-led";
+                       gpios = <&gpio K1_GPIO(96) GPIO_ACTIVE_HIGH>;
+                       linux,default-trigger = "heartbeat";
+                       default-state = "on";
+               };
+       };
 };
 
 &uart0 {