mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-24 07:46:48 +00:00
ramips: define Yuncore AX820 switch LEDs
This patch defines the two switch LED to bring them under user control.
Fixes: a0e1d3ab7b
("ramips: improve YunCore AX820 LEDs")
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
[rmilecki: leave "label"s in place]
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
This commit is contained in:
parent
18a2b29aa1
commit
7bee10a7d2
@ -4,6 +4,7 @@
|
|||||||
|
|
||||||
#include <dt-bindings/gpio/gpio.h>
|
#include <dt-bindings/gpio/gpio.h>
|
||||||
#include <dt-bindings/input/input.h>
|
#include <dt-bindings/input/input.h>
|
||||||
|
#include <dt-bindings/leds/common.h>
|
||||||
|
|
||||||
/ {
|
/ {
|
||||||
compatible = "yuncore,ax820", "mediatek,mt7621-soc";
|
compatible = "yuncore,ax820", "mediatek,mt7621-soc";
|
||||||
@ -47,6 +48,18 @@
|
|||||||
gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
|
gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
|
||||||
linux,default-trigger = "phy1radio";
|
linux,default-trigger = "phy1radio";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
wan {
|
||||||
|
color = <LED_COLOR_ID_GREEN>;
|
||||||
|
function = LED_FUNCTION_WAN;
|
||||||
|
gpios = <&switch0 0 GPIO_ACTIVE_LOW>;
|
||||||
|
};
|
||||||
|
|
||||||
|
lan {
|
||||||
|
color = <LED_COLOR_ID_GREEN>;
|
||||||
|
function = LED_FUNCTION_LAN;
|
||||||
|
gpios = <&switch0 3 GPIO_ACTIVE_LOW>;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
watchdog {
|
watchdog {
|
||||||
@ -147,6 +160,9 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
&switch0 {
|
&switch0 {
|
||||||
|
gpio-controller;
|
||||||
|
#gpio-cells = <2>;
|
||||||
|
|
||||||
ports {
|
ports {
|
||||||
port@1 {
|
port@1 {
|
||||||
status = "okay";
|
status = "okay";
|
||||||
|
@ -162,6 +162,10 @@ xiaomi,redmi-router-ac2100)
|
|||||||
youhua,wr1200js)
|
youhua,wr1200js)
|
||||||
ucidef_set_led_netdev "internet" "INTERNET" "green:wan" "wan"
|
ucidef_set_led_netdev "internet" "INTERNET" "green:wan" "wan"
|
||||||
;;
|
;;
|
||||||
|
yuncore,ax820)
|
||||||
|
ucidef_set_led_netdev "lan" "LAN" "green:lan" "lan"
|
||||||
|
ucidef_set_led_netdev "wan" "WAN" "green:wan" "wan"
|
||||||
|
;;
|
||||||
zbtlink,zbt-wg1608-16m)
|
zbtlink,zbt-wg1608-16m)
|
||||||
ucidef_set_led_netdev "lan1" "LAN1" "green:lan-1" "lan1"
|
ucidef_set_led_netdev "lan1" "LAN1" "green:lan-1" "lan1"
|
||||||
ucidef_set_led_netdev "lan2" "LAN2" "green:lan-2" "lan2"
|
ucidef_set_led_netdev "lan2" "LAN2" "green:lan-2" "lan2"
|
||||||
|
Loading…
Reference in New Issue
Block a user