rockchip: add Orange Pi R1 Plus support
[openwrt/staging/stintel.git] / target / linux / rockchip / patches-5.15 / 107-arm64-dts-rockchip-Update-LED-properties-for-Orange-.patch
1 From d2166e3b3680bd2b206aebf1e1ce4c0d346f3c50 Mon Sep 17 00:00:00 2001
2 From: Tianling Shen <cnsztl@gmail.com>
3 Date: Fri, 19 May 2023 12:10:52 +0800
4 Subject: [PATCH] arm64: dts: rockchip: Update LED properties for Orange Pi R1
5 Plus
6
7 Add OpenWrt's LED aliases for showing system status.
8 Also replace function/color with legacy label as OpenWrt relys on it
9 to update LED settings.
10
11 Signed-off-by: Tianling Shen <cnsztl@gmail.com>
12 ---
13 .../dts/rockchip/rk3328-orangepi-r1-plus.dts | 17 +++++++++--------
14 1 file changed, 9 insertions(+), 8 deletions(-)
15
16 --- a/arch/arm64/boot/dts/rockchip/rk3328-orangepi-r1-plus.dts
17 +++ b/arch/arm64/boot/dts/rockchip/rk3328-orangepi-r1-plus.dts
18 @@ -17,6 +17,11 @@
19 aliases {
20 ethernet1 = &rtl8153;
21 mmc0 = &sdmmc;
22 +
23 + led-boot = &status_led;
24 + led-failsafe = &status_led;
25 + led-running = &status_led;
26 + led-upgrade = &status_led;
27 };
28
29 chosen {
30 @@ -36,22 +41,18 @@
31 pinctrl-names = "default";
32
33 led-0 {
34 - function = LED_FUNCTION_LAN;
35 - color = <LED_COLOR_ID_GREEN>;
36 gpios = <&gpio2 RK_PB7 GPIO_ACTIVE_HIGH>;
37 + label = "green:lan";
38 };
39
40 - led-1 {
41 - function = LED_FUNCTION_STATUS;
42 - color = <LED_COLOR_ID_RED>;
43 + status_led: led-1 {
44 gpios = <&gpio3 RK_PC5 GPIO_ACTIVE_HIGH>;
45 - linux,default-trigger = "heartbeat";
46 + label = "red:status";
47 };
48
49 led-2 {
50 - function = LED_FUNCTION_WAN;
51 - color = <LED_COLOR_ID_GREEN>;
52 gpios = <&gpio2 RK_PC2 GPIO_ACTIVE_HIGH>;
53 + label = "green:wan";
54 };
55 };
56