summaryrefslogtreecommitdiffstats
path: root/target/linux/ramips/base-files/etc/uci-defaults/leds
diff options
context:
space:
mode:
Diffstat (limited to 'target/linux/ramips/base-files/etc/uci-defaults/leds')
-rwxr-xr-xtarget/linux/ramips/base-files/etc/uci-defaults/leds17
1 files changed, 17 insertions, 0 deletions
diff --git a/target/linux/ramips/base-files/etc/uci-defaults/leds b/target/linux/ramips/base-files/etc/uci-defaults/leds
index e6c7e8456..d0a9ac071 100755
--- a/target/linux/ramips/base-files/etc/uci-defaults/leds
+++ b/target/linux/ramips/base-files/etc/uci-defaults/leds
@@ -16,12 +16,29 @@ commit system
EOF
}
+set_wifi_led() {
+ local sysfs="$1"
+
+ uci batch <<EOF
+set system.wifi_led=led
+set system.wifi_led.name='wifi'
+set system.wifi_led.sysfs='$sysfs'
+set system.wifi_led.trigger='netdev'
+set system.wifi_led.dev='wlan0'
+set system.wifi_led.mode='link rx tx'
+commit system
+EOF
+}
+
board=$(ramips_board_name)
case $board in
bc2)
set_usb_led "bc2:blue:usb"
;;
+ esr-9753)
+ set_wifi_led "rt2800pci-phy0::radio"
+ ;;
fonera20n)
set_usb_led "fonera20n:amber:usb"
;;