]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
arm64: dts: amlogic: t7: khadas-vim4: add PWM-driven status LED
authorRonald Claveau <linux-kernel-dev@aliel.fr>
Wed, 13 May 2026 10:43:55 +0000 (12:43 +0200)
committerNeil Armstrong <neil.armstrong@linaro.org>
Tue, 2 Jun 2026 07:49:46 +0000 (09:49 +0200)
The VIM4 board exposes a status LED wired to the PWM_AO_C_D output.
Enable the pwm_ao_cd controller with its pinmux, and declare a
pwm-leds node with a heartbeat trigger.

Signed-off-by: Ronald Claveau <linux-kernel-dev@aliel.fr>
Link: https://patch.msgid.link/20260513-add-kvim4-sysled-v2-3-3ec9779e8875@aliel.fr
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
arch/arm64/boot/dts/amlogic/amlogic-t7-a311d2-khadas-vim4.dts

index fd1b983354a016cbb87d7a389552b36d65aeb98b..c41525a34b721d77d03771815f27c6fbdb44a065 100644 (file)
                regulator-always-on;
        };
 
+       pwm-leds {
+               compatible = "pwm-leds";
+
+               status {
+                       linux,default-trigger="heartbeat";
+                       max-brightness = <255>;
+                       pwms = <&pwm_ao_cd 0 30040 0>;
+               };
+       };
+
        sd_3v3: regulator-sdcard-3v3 {
                compatible = "regulator-fixed";
                regulator-name = "SD_3V3";
        pinctrl-names = "default";
 };
 
+&pwm_ao_cd {
+       status = "okay";
+       pinctrl-0 = <&pwm_ao_c_d_pins>;
+       pinctrl-names = "default";
+};
+
 /* SDIO */
 &sd_emmc_a {
        status = "okay";