ipq806x: Sort occurrences of boardame alphabetically
[openwrt/staging/chunkeey.git] / target / linux / ipq806x / base-files / etc / board.d / 01_leds
1 #!/bin/sh
2 #
3 # Copyright (C) 2015 OpenWrt.org
4 #
5
6 . /lib/functions/uci-defaults.sh
7
8 board_config_update
9
10 board=$(board_name)
11 boardname="${board##*,}"
12
13 case "$board" in
14 avm,fritzbox-4040)
15 ucidef_set_led_wlan "wlan" "WLAN" "fritz4040:green:wlan" "phy0tpt" "phy1tpt"
16 ucidef_set_led_netdev "wan" "WAN" "fritz4040:green:wan" "eth1"
17 ucidef_set_led_switch "lan" "LAN" "fritz4040:green:lan" "switch0" "0x1e"
18 ;;
19 netgear,d7800 |\
20 netgear,r7500 |\
21 netgear,r7500v2 |\
22 netgear,r7800)
23 ucidef_set_led_usbport "usb1" "USB 1" "${boardname}:white:usb1" "usb1-port1" "usb2-port1"
24 ucidef_set_led_usbport "usb2" "USB 2" "${boardname}:white:usb2" "usb3-port1" "usb4-port1"
25 ucidef_set_led_netdev "wan" "WAN" "${boardname}:white:wan" "eth0"
26 ucidef_set_led_ide "esata" "eSATA" "${boardname}:white:esata"
27 ;;
28 tplink,c2600)
29 ucidef_set_led_usbport "usb1" "USB 1" "${boardname}:white:usb_2" "usb1-port1" "usb2-port1"
30 ucidef_set_led_usbport "usb2" "USB 2" "${boardname}:white:usb_4" "usb3-port1" "usb4-port1"
31 ucidef_set_led_switch "wan" "wan" "${boardname}:white:wan" "switch0" "0x20"
32 ucidef_set_led_switch "lan" "lan" "${boardname}:white:lan" "switch0" "0x1e"
33 ;;
34 tplink,vr2600v)
35 ucidef_set_led_usbport "usb" "USB" "${boardname}:white:usb" "usb1-port1" "usb2-port1" "usb3-port1" "usb4-port1"
36 ucidef_set_led_switch "lan" "lan" "${boardname}:white:lan" "switch0" "0x1e"
37 ucidef_set_led_wlan "wlan2g" "WLAN2G" "${boardname}:white:wlan2g" "phy0tpt"
38 ucidef_set_led_wlan "wlan5g" "WLAN5G" "${boardname}:white:wlan5g" "phy1tpt"
39 ucidef_set_led_switch "wan" "wan" "${boardname}:white:wan" "switch0" "0x20"
40 ;;
41 zyxel,nbg6817)
42 ucidef_set_led_wlan "wlan2g" "WLAN2G" "${boardname}:amber:wifi2g" "phy1tpt"
43 ucidef_set_led_wlan "wlan5g" "WLAN5G" "${boardname}:amber:wifi5g" "phy0tpt"
44 ucidef_set_led_netdev "wan" "WAN" "${boardname}:white:internet" "eth1"
45 ;;
46 *)
47 ;;
48 esac
49
50 board_config_flush
51
52 exit 0