ipq806x: add support for GL.iNet GL-B1300
[openwrt/openwrt.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 glinet,gl-b1300)
20 ucidef_set_led_wlan "wlan" "WLAN" "${boardname}:green:wlan" "phy0tpt"
21 ;;
22 netgear,d7800 |\
23 netgear,r7500 |\
24 netgear,r7500v2 |\
25 netgear,r7800)
26 ucidef_set_led_usbport "usb1" "USB 1" "${boardname}:white:usb1" "usb1-port1" "usb2-port1"
27 ucidef_set_led_usbport "usb2" "USB 2" "${boardname}:white:usb2" "usb3-port1" "usb4-port1"
28 ucidef_set_led_netdev "wan" "WAN" "${boardname}:white:wan" "eth0"
29 ucidef_set_led_ide "esata" "eSATA" "${boardname}:white:esata"
30 ;;
31 tplink,c2600)
32 ucidef_set_led_usbport "usb1" "USB 1" "${boardname}:white:usb_2" "usb1-port1" "usb2-port1"
33 ucidef_set_led_usbport "usb2" "USB 2" "${boardname}:white:usb_4" "usb3-port1" "usb4-port1"
34 ucidef_set_led_switch "wan" "wan" "${boardname}:white:wan" "switch0" "0x20"
35 ucidef_set_led_switch "lan" "lan" "${boardname}:white:lan" "switch0" "0x1e"
36 ;;
37 tplink,vr2600v)
38 ucidef_set_led_usbport "usb" "USB" "${boardname}:white:usb" "usb1-port1" "usb2-port1" "usb3-port1" "usb4-port1"
39 ucidef_set_led_switch "lan" "lan" "${boardname}:white:lan" "switch0" "0x1e"
40 ucidef_set_led_wlan "wlan2g" "WLAN2G" "${boardname}:white:wlan2g" "phy0tpt"
41 ucidef_set_led_wlan "wlan5g" "WLAN5G" "${boardname}:white:wlan5g" "phy1tpt"
42 ucidef_set_led_switch "wan" "wan" "${boardname}:white:wan" "switch0" "0x20"
43 ;;
44 zyxel,nbg6817)
45 ucidef_set_led_wlan "wlan2g" "WLAN2G" "${boardname}:amber:wifi2g" "phy1tpt"
46 ucidef_set_led_wlan "wlan5g" "WLAN5G" "${boardname}:amber:wifi5g" "phy0tpt"
47 ucidef_set_led_netdev "wan" "WAN" "${boardname}:white:internet" "eth1"
48 ;;
49 *)
50 ;;
51 esac
52
53 board_config_flush
54
55 exit 0