Skip to content

Commit

Permalink
fff
Browse files Browse the repository at this point in the history
  • Loading branch information
csharper2005 committed Oct 29, 2023
1 parent 5e33fdf commit 6502dc1
Show file tree
Hide file tree
Showing 20 changed files with 451 additions and 175 deletions.
12 changes: 10 additions & 2 deletions target/linux/mediatek/dts/mt7981a-ubnt-unifi-6-plus.dts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
/dts-v1/;
#include "mt7981.dtsi"

#include <dt-bindings/leds/common.h>

/ {
model = "Ubiquiti UniFi 6 Plus";
compatible = "ubnt,unifi-6-plus", "mediatek,mt7981";
Expand Down Expand Up @@ -35,13 +37,19 @@
leds {
compatible = "gpio-leds";

led_blue: dome-blue {
led_blue: led-0 {
label = "blue:dome";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_STATUS;
function-enumerator = <0>;
gpios = <&pio 9 GPIO_ACTIVE_HIGH>;
};

led_white: dome-white {
led_white: led-1 {
label = "white:dome";
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_STATUS;
function-enumerator = <1>;
gpios = <&pio 34 GPIO_ACTIVE_HIGH>;
};
};
Expand Down
11 changes: 9 additions & 2 deletions target/linux/mediatek/dts/mt7981b-cetron-ct3003.dts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/dts-v1/;
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/leds/common.h>

#include "mt7981.dtsi"

Expand Down Expand Up @@ -45,13 +46,19 @@
leds {
compatible = "gpio-leds";

led_status_red: led_status_red {
led_status_red: led-0 {
label = "red:status";
color = <LED_COLOR_ID_RED>;
function = LED_FUNCTION_STATUS;
function-enumerator = <0>;
gpios = <&pio 3 GPIO_ACTIVE_LOW>;
};

led_status_green: led_status_green {
led_status_green: led-1 {
label = "green:status";
color = <LED_COLOR_ID_GREEN>;
function = LED_FUNCTION_STATUS;
function-enumerator = <1>;
gpios = <&pio 7 GPIO_ACTIVE_LOW>;
};
};
Expand Down
10 changes: 10 additions & 0 deletions target/linux/mediatek/dts/mt7981b-cmcc-rax3000m.dts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
/dts-v1/;
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/leds/common.h>

#include "mt7981.dtsi"

Expand Down Expand Up @@ -51,16 +52,25 @@

green_led: led-0 {
label = "green:status";
color = <LED_COLOR_ID_GREEN>;
function = LED_FUNCTION_STATUS;
function-enumerator = <0>;
gpios = <&pio 9 GPIO_ACTIVE_LOW>;
};

led-1 {
label = "blue:status";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_STATUS;
function-enumerator = <1>;
gpios = <&pio 12 GPIO_ACTIVE_LOW>;
};

red_led: led-2 {
label = "red:status";
color = <LED_COLOR_ID_RED>;
function = LED_FUNCTION_STATUS;
function-enumerator = <2>;
gpios = <&pio 35 GPIO_ACTIVE_LOW>;
};
};
Expand Down
55 changes: 37 additions & 18 deletions target/linux/mediatek/dts/mt7981b-cudy-wr3000-v1.dts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// SPDX-License-Identifier: (GPL-2.0 OR MIT)

/dts-v1/;
#include <dt-bindings/leds/common.h>

#include "mt7981.dtsi"

Expand Down Expand Up @@ -41,37 +42,55 @@
leds {
compatible = "gpio-leds";

led_status: led@0 {
label = "blue:status";
gpios = <&pio 10 GPIO_ACTIVE_LOW>;
};

led@1 {
label = "blue:internet";
gpios = <&pio 11 GPIO_ACTIVE_LOW>;
};

led@2 {
led-0 {
label = "blue:wan";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_WAN;
function-enumerator = <0>;
gpios = <&pio 5 GPIO_ACTIVE_LOW>;
};

led@3 {
label = "blue:lan";
gpios = <&pio 9 GPIO_ACTIVE_LOW>;
};

led@4 {
led-1 {
label = "blue:wifi2";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_WLAN;
function-enumerator = <0>;
gpios = <&pio 6 GPIO_ACTIVE_LOW>;
linux,default-trigger = "phy0tpt";
};

led@5 {
led-2 {
label = "blue:wifi5";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_WLAN;
function-enumerator = <1>;
gpios = <&pio 7 GPIO_ACTIVE_LOW>;
linux,default-trigger = "phy1tpt";
};

led-3 {
label = "blue:lan";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_LAN;
function-enumerator = <0>;
gpios = <&pio 9 GPIO_ACTIVE_LOW>;
};

led_status: led-4 {
label = "blue:status";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_STATUS;
function-enumerator = <0>;
gpios = <&pio 10 GPIO_ACTIVE_LOW>;
};

led-5 {
label = "blue:internet";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_WAN;
function-enumerator = <1>;
gpios = <&pio 11 GPIO_ACTIVE_LOW>;
};
};
};

Expand Down
19 changes: 13 additions & 6 deletions target/linux/mediatek/dts/mt7981b-glinet-gl-mt3000.dts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
/dts-v1/;
#include <dt-bindings/leds/common.h>

#include "mt7981.dtsi"

Expand Down Expand Up @@ -39,15 +40,21 @@
leds {
compatible = "gpio-leds";

led_lightblue: led@0 {
label = "blue:run";
gpios = <&pio 31 GPIO_ACTIVE_LOW>;
};

led_white: led@1 {
led_white: led-0 {
label = "white:system";
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_STATUS;
function-enumerator = <0>;
gpios = <&pio 30 GPIO_ACTIVE_LOW>;
};

led_lightblue: led-1 {
label = "blue:run";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_STATUS;
function-enumerator = <1>;
gpios = <&pio 31 GPIO_ACTIVE_LOW>;
};
};

fan_5v: regulator-fan-5v {
Expand Down
11 changes: 9 additions & 2 deletions target/linux/mediatek/dts/mt7981b-h3c-magic-nx30-pro.dts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/dts-v1/;
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/leds/common.h>

#include "mt7981.dtsi"

Expand Down Expand Up @@ -45,13 +46,19 @@
leds {
compatible = "gpio-leds";

led_status_green: green {
led_status_green: led-0 {
label = "green:status";
color = <LED_COLOR_ID_GREEN>;
function = LED_FUNCTION_STATUS;
function-enumerator = <0>;
gpios = <&pio 4 GPIO_ACTIVE_LOW>;
};

led_status_red: red {
led_status_red: led-1 {
label = "red:status";
color = <LED_COLOR_ID_RED>;
function = LED_FUNCTION_STATUS;
function-enumerator = <1>;
gpios = <&pio 5 GPIO_ACTIVE_LOW>;
};
};
Expand Down
11 changes: 9 additions & 2 deletions target/linux/mediatek/dts/mt7981b-qihoo-360t7.dts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/dts-v1/;
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/leds/common.h>

#include "mt7981.dtsi"

Expand Down Expand Up @@ -45,13 +46,19 @@
leds {
compatible = "gpio-leds";

led_status_red: red {
led_status_red: led-0 {
label = "red:status";
color = <LED_COLOR_ID_RED>;
function = LED_FUNCTION_STATUS;
function-enumerator = <0>;
gpios = <&pio 3 GPIO_ACTIVE_LOW>;
};

led_status_green: green {
led_status_green: led-1 {
label = "green:status";
color = <LED_COLOR_ID_GREEN>;
function = LED_FUNCTION_STATUS;
function-enumerator = <1>;
gpios = <&pio 7 GPIO_ACTIVE_LOW>;
};
};
Expand Down
21 changes: 17 additions & 4 deletions target/linux/mediatek/dts/mt7981b-xiaomi-mi-router-wr30u.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/dts-v1/;
#include <dt-bindings/input/input.h>
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/leds/common.h>

#include "mt7981.dtsi"

Expand Down Expand Up @@ -43,23 +44,35 @@
leds {
compatible = "gpio-leds";

led_system_blue: system_blue {
led_system_blue: led-0 {
label = "blue:system";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_STATUS;
function-enumerator = <0>;
gpios = <&pio 9 GPIO_ACTIVE_LOW>;
};

led_system_yellow: system_yellow {
led_system_yellow: led-1 {
label = "yellow:system";
color = <LED_COLOR_ID_YELLOW>;
function = LED_FUNCTION_STATUS;
function-enumerator = <1>;
gpios = <&pio 10 GPIO_ACTIVE_LOW>;
};

led_network_blue {
led-2 {
label = "blue:network";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_LAN;
function-enumerator = <0>;
gpios = <&pio 11 GPIO_ACTIVE_LOW>;
};

led_network_yellow {
led-3 {
label = "yellow:network";
color = <LED_COLOR_ID_YELLOW>;
function = LED_FUNCTION_LAN;
function-enumerator = <1>;
gpios = <&pio 12 GPIO_ACTIVE_LOW>;
};
};
Expand Down
16 changes: 13 additions & 3 deletions target/linux/mediatek/dts/mt7981b-zyxel-nwa50ax-pro.dts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
// SPDX-License-Identifier: (GPL-2.0-or-later OR MIT)
/dts-v1/;
#include <dt-bindings/leds/common.h>

#include "mt7981.dtsi"

Expand Down Expand Up @@ -33,18 +34,27 @@
leds {
compatible = "gpio-leds";

led_green: led@0 {
led_green: led-0 {
label = "green:system";
color = <LED_COLOR_ID_GREEN>;
function = LED_FUNCTION_STATUS;
function-enumerator = <0>;
gpios = <&pio 4 GPIO_ACTIVE_HIGH>;
};

led@1 {
led-1 {
label = "blue:system";
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_STATUS;
function-enumerator = <1>;
gpios = <&pio 6 GPIO_ACTIVE_HIGH>;
};

led_red: led@2 {
led_red: led-2 {
label = "red:system";
color = <LED_COLOR_ID_RED>;
function = LED_FUNCTION_STATUS;
function-enumerator = <2>;
gpios = <&pio 7 GPIO_ACTIVE_HIGH>;
};
};
Expand Down
Loading

0 comments on commit 6502dc1

Please sign in to comment.