1 From 2c2d8ac8c124a2938c9326c14b2dffd46d76b4a8 Mon Sep 17 00:00:00 2001
2 From: David Abdurachmanov <david.abdurachmanov@sifive.com>
3 Date: Mon, 13 Sep 2021 02:15:37 -0700
4 Subject: [PATCH 3/7] riscv: sifive: unmatched: define PWM LEDs
6 Add D2 (RGB) and D12 (green) LEDs for SiFive Unmatched board.
8 Signed-off-by: David Abdurachmanov <david.abdurachmanov@sifive.com>
10 .../riscv/boot/dts/sifive/hifive-unmatched-a00.dts | 41 ++++++++++++++++++++++
11 1 file changed, 41 insertions(+)
13 --- a/arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts
14 +++ b/arch/riscv/boot/dts/sifive/hifive-unmatched-a00.dts
16 #include "fu740-c000.dtsi"
17 #include <dt-bindings/gpio/gpio.h>
18 #include <dt-bindings/interrupt-controller/irq.h>
19 +#include <dt-bindings/leds/common.h>
20 +#include <dt-bindings/pwm/pwm.h>
22 /* Clock frequency (in Hz) of the PCB crystal for rtcclk */
23 #define RTCCLK_FREQ 1000000
29 + compatible = "pwm-leds";
31 + label = "green:d12";
32 + color = <LED_COLOR_ID_GREEN>;
33 + pwms = <&pwm0 0 7812500 PWM_POLARITY_INVERTED>;
35 + max-brightness = <255>;
36 + linux,default-trigger = "none";
41 + color = <LED_COLOR_ID_GREEN>;
42 + pwms = <&pwm0 1 7812500 PWM_POLARITY_INVERTED>;
44 + max-brightness = <255>;
45 + linux,default-trigger = "none";
50 + color = <LED_COLOR_ID_RED>;
51 + pwms = <&pwm0 2 7812500 PWM_POLARITY_INVERTED>;
53 + max-brightness = <255>;
54 + linux,default-trigger = "none";
59 + color = <LED_COLOR_ID_BLUE>;
60 + pwms = <&pwm0 3 7812500 PWM_POLARITY_INVERTED>;
62 + max-brightness = <255>;
63 + linux,default-trigger = "none";
69 compatible = "fixed-clock";