[SRU][I/riscv][PATCH 3/6] riscv: sifive: unmatched: define LEDs color

Dimitri John Ledkov dimitri.ledkov at canonical.com
Tue Sep 7 00:39:29 UTC 2021


From: David Abdurachmanov <david.abdurachmanov at sifive.com>

Signed-off-by: David Abdurachmanov <david.abdurachmanov at sifive.com>
BugLink: https://bugs.launchpad.net/bugs/1942806
Signed-off-by: Dimitri John Ledkov <dimitri.ledkov at canonical.com>
---
 arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts b/arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts
index 56e6d8e8fe..200d022c75 100644
--- a/arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts
+++ b/arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts
@@ -3,6 +3,7 @@
 
 #include "fu740-c000.dtsi"
 #include <dt-bindings/interrupt-controller/irq.h>
+#include <dt-bindings/leds/common.h>
 #include <dt-bindings/pwm/pwm.h>
 
 /* Clock frequency (in Hz) of the PCB crystal for rtcclk */
@@ -35,6 +36,7 @@ pwmleds {
 		compatible = "pwm-leds";
 		green-d12 {
 			label = "green:d12";
+			color = <LED_COLOR_ID_GREEN>;
 			pwms = <&pwm0 0 7812500 PWM_POLARITY_INVERTED>;
 			active-low = <1>;
 			max-brightness = <255>;
@@ -43,6 +45,7 @@ green-d12 {
 
 		green-d2 {
 			label = "green:d2";
+			color = <LED_COLOR_ID_GREEN>;
 			pwms = <&pwm0 1 7812500 PWM_POLARITY_INVERTED>;
 			active-low = <1>;
 			max-brightness = <255>;
@@ -51,6 +54,7 @@ green-d2 {
 
 		red-d2 {
 			label = "red:d2";
+			color = <LED_COLOR_ID_RED>;
 			pwms = <&pwm0 2 7812500 PWM_POLARITY_INVERTED>;
 			active-low = <1>;
 			max-brightness = <255>;
@@ -59,6 +63,7 @@ red-d2 {
 
 		blue-d2 {
 			label = "blue:d2";
+			color = <LED_COLOR_ID_BLUE>;
 			pwms = <&pwm0 3 7812500 PWM_POLARITY_INVERTED>;
 			active-low = <1>;
 			max-brightness = <255>;
-- 
2.30.2




More information about the kernel-team mailing list