You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

36 lines
719 B
Bash

#!/bin/sh
. /lib/functions/leds.sh
. /lib/functions/uci-defaults.sh
set_wifi_led() {
ucidef_set_led_netdev "wifi_led" "wifi" "${1}" "${2:-wlan0}"
}
board=$(board_name)
boardname="${board##*,}"
board_config_update
led_wlan="$(get_dt_led wlan)"
[ -n "$led_wlan" ] && ucidef_set_led_wlan "wifi_led" "wifi" "$led_wlan" "phy0tpt"
case $board in
belkin,f9k1109v1)
ucidef_set_led_usbport "usb" "USB" "$boardname:green:usb1" "usb1-port1"
ucidef_set_led_netdev "lan" "lan" "$boardname:blue:wps" "eth0"
;;
edimax,br-6475nd)
set_wifi_led "$boardname:amber:wlan"
;;
omnima,hpm)
ucidef_set_led_netdev "eth" "ETH" "$boardname:green:eth" "eth0"
set_wifi_led "$boardname:green:wifi"
;;
esac
board_config_flush
exit 0