0
0
mirror of https://git.openwrt.org/openwrt/openwrt.git synced 2024-11-25 22:46:15 +00:00
openwrt/target/linux/ramips/rt305x/base-files/etc/board.d/01_leds
Adrian Schmutzler 85b1f4d8ca treewide: remove execute bit and shebang from board.d files
So far, board.d files were having execute bit set and contained a
shebang. However, they are just sourced in board_detect, with an
apparantly unnecessary check for execute permission beforehand.

Replace this check by one for existance and make the board.d files
"normal" files, as would be expected in /etc anyway.

Note:

This removes an apparantly unused '#!/bin/sh /etc/rc.common' in
target/linux/bcm47xx/base-files/etc/board.d/01_network

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-03-06 11:30:06 +01:00

105 lines
2.8 KiB
Plaintext

. /lib/functions/leds.sh
. /lib/functions/uci-defaults.sh
board=$(board_name)
board_config_update
case $board in
7links,px-4885-4m|\
7links,px-4885-8m|\
fon,fonera-20n)
ucidef_set_led_netdev "wifi_led" "wifi" "orange:wifi" "wlan0"
;;
airlive,air3gii|\
aximcom,mr-102n|\
edimax,3g-6200nl|\
netgear,wnce2001)
ucidef_set_led_netdev "wifi_led" "wifi" "green:wlan" "wlan0"
;;
alfa-network,w502u|\
dlink,dir-300-b1|\
dlink,dir-300-b7|\
dlink,dir-320-b1|\
dlink,dir-600-b1|\
dlink,dir-610-a1|\
dlink,dir-615-h1|\
dlink,dir-620-a1|\
engenius,esr-9753|\
hilink,hlk-rm04|\
nexx,wt1520-4m|\
nexx,wt1520-8m|\
skyline,sl-r7205|\
tenda,w306r-v2|\
zyxel,keenetic-start|\
zyxel,keenetic|\
zyxel,nbg-419n-v2)
ucidef_set_led_netdev "wifi_led" "wifi" "rt2800pci-phy0::radio" "wlan0"
;;
allnet,all0256n-4m|\
allnet,all0256n-8m)
ucidef_set_rssimon "wlan0" "200000" "1"
ucidef_set_led_rssi "rssilow" "RSSILOW" "green:rssilow" "wlan0" "1" "40" "0" "6"
ucidef_set_led_rssi "rssimedium" "RSSIMEDIUM" "green:rssimed" "wlan0" "30" "80" "-29" "5"
ucidef_set_led_rssi "rssihigh" "RSSIHIGH" "green:rssihigh" "wlan0" "70" "100" "-69" "8"
ucidef_set_led_netdev "wifi_led" "wifi" "rt2800pci-phy0::radio" "wlan0"
;;
alphanetworks,asl26555-8m|\
alphanetworks,asl26555-16m)
ucidef_set_led_netdev "eth" "ETH" "green:eth" "eth0"
ucidef_set_led_netdev "wifi_led" "wifi" "green:wlan" "wlan0"
;;
asiarf,awapn2403)
ucidef_set_led_netdev "wifi_led" "wifi" "rt2800soc-phy0::radio" "wlan0"
;;
dlink,dcs-930l-b1)
ucidef_set_led_netdev "wifi" "WiFi" "blue:wps"
;;
dlink,dir-615-d)
ucidef_set_led_netdev "wan" "WAN (green)" "green:wan" "eth0.2"
ucidef_set_led_netdev "wifi_led" "wifi" "rt2800soc-phy0::radio" "wlan0"
;;
dlink,dir-620-d1|\
trendnet,tew-714tru)
ucidef_set_led_netdev "wifi_led" "wifi" "green:wifi" "wlan0"
;;
edimax,3g-6200n|\
planex,mzk-w300nh2)
ucidef_set_led_netdev "wifi_led" "wifi" "amber:wlan" "wlan0"
;;
hauppauge,broadway)
ucidef_set_led_netdev "wifi_led" "wifi" "red:wps_active" "wlan0"
;;
hootoo,ht-tm02)
ucidef_set_led_netdev "eth" "Ethernet" "green:lan" "eth0"
ucidef_set_led_netdev "wifi_led" "wifi" "blue:wlan" "wlan0"
;;
huawei,hg255d)
ucidef_set_led_netdev "wifi_led" "wifi" "green:wlan" "wlan0"
ucidef_set_led_netdev "internet" "internet" "green:internet" "eth0.2"
;;
intenso,memory2move)
ucidef_set_led_netdev "wifi_led" "wifi" "blue:wifi" "wlan0"
ucidef_set_led_netdev "eth" "Ethernet" "green:wan" "eth0"
;;
omnima,miniembplug)
ucidef_set_led_netdev "wifi_led" "wifi" "red:wlan" "wlan0"
;;
vocore,vocore-8m|\
vocore,vocore-16m)
ucidef_set_led_netdev "eth" "ETH" "orange:eth" "eth0"
;;
zorlik,zl5900v2)
ucidef_set_led_netdev "lan" "lan" "green:lan" "eth0"
;;
zte,mf283plus)
ucidef_set_led_wlan "wifi" "wifi" "rt2800soc-phy0::radio" "phy0tpt"
ucidef_set_led_netdev "wwan" "wwan" "blue:wwan" "wwan0"
;;
esac
board_config_flush
exit 0