mirror of
https://github.com/openwrt/openwrt.git
synced 2025-02-01 16:58:22 +00:00
mvebu: add LED support for GL.iNet GL-MV1000
This patch enables LED support for the GL.iNet GL-MV1000 Signed-off-by: Jeff Collins <jeffcollins9292@gmail.com> [add SPDX identifier on new file, add aliases, minor cosmetic issues] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
This commit is contained in:
parent
a6f7268dc7
commit
6e0c780eb3
18
target/linux/mvebu/cortexa53/base-files/etc/board.d/01_leds
Executable file
18
target/linux/mvebu/cortexa53/base-files/etc/board.d/01_leds
Executable file
@ -0,0 +1,18 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
# SPDX-License-Identifier: GPL-2.0-only
|
||||||
|
|
||||||
|
. /lib/functions/uci-defaults.sh
|
||||||
|
|
||||||
|
board_config_update
|
||||||
|
|
||||||
|
board=$(board_name)
|
||||||
|
|
||||||
|
case "$board" in
|
||||||
|
glinet,gl-mv1000)
|
||||||
|
ucidef_set_led_netdev "wan" "WAN" "green:wan" "wan"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
board_config_flush
|
||||||
|
|
||||||
|
exit 0
|
@ -8,6 +8,13 @@
|
|||||||
model = "GL.iNet GL-MV1000";
|
model = "GL.iNet GL-MV1000";
|
||||||
compatible = "glinet,gl-mv1000", "marvell,armada3720";
|
compatible = "glinet,gl-mv1000", "marvell,armada3720";
|
||||||
|
|
||||||
|
aliases {
|
||||||
|
led-boot = &led_power;
|
||||||
|
led-failsafe = &led_power;
|
||||||
|
led-running = &led_power;
|
||||||
|
led-upgrade = &led_power;
|
||||||
|
};
|
||||||
|
|
||||||
chosen {
|
chosen {
|
||||||
stdout-path = "serial0:115200n8";
|
stdout-path = "serial0:115200n8";
|
||||||
};
|
};
|
||||||
@ -29,6 +36,26 @@
|
|||||||
3300000 0x0>;
|
3300000 0x0>;
|
||||||
enable-active-high;
|
enable-active-high;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
leds {
|
||||||
|
compatible = "gpio-leds";
|
||||||
|
|
||||||
|
vpn {
|
||||||
|
label = "green:vpn";
|
||||||
|
gpios = <&gpionb 11 GPIO_ACTIVE_LOW>;
|
||||||
|
};
|
||||||
|
|
||||||
|
wan {
|
||||||
|
label = "green:wan";
|
||||||
|
gpios = <&gpionb 12 GPIO_ACTIVE_LOW>;
|
||||||
|
};
|
||||||
|
|
||||||
|
led_power: power {
|
||||||
|
label = "green:power";
|
||||||
|
gpios = <&gpionb 13 GPIO_ACTIVE_LOW>;
|
||||||
|
default-state = "on";
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
&spi0 {
|
&spi0 {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user