diff options
author | Jo-Philipp Wich <jow@openwrt.org> | 2015-12-04 12:32:36 +0000 |
---|---|---|
committer | Jo-Philipp Wich <jow@openwrt.org> | 2015-12-04 12:32:36 +0000 |
commit | 708c0212e790732c4c9107a1aec94a0134744aae (patch) | |
tree | c7d31ebf100226d046fb4d90aea64a58ee8425b4 /target/linux/brcm63xx/base-files/etc/board.d | |
parent | 08848936ddc73119d0651ab127d858637f1d04da (diff) | |
download | upstream-708c0212e790732c4c9107a1aec94a0134744aae.tar.gz upstream-708c0212e790732c4c9107a1aec94a0134744aae.tar.bz2 upstream-708c0212e790732c4c9107a1aec94a0134744aae.zip |
brcm63xx: switch from uci-defaults to board.d
Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>
Acked-by: Jonas Gorski <jogo@openwrt.org>
SVN-Revision: 47754
Diffstat (limited to 'target/linux/brcm63xx/base-files/etc/board.d')
-rwxr-xr-x | target/linux/brcm63xx/base-files/etc/board.d/01_leds | 58 | ||||
-rwxr-xr-x | target/linux/brcm63xx/base-files/etc/board.d/02_network | 138 |
2 files changed, 196 insertions, 0 deletions
diff --git a/target/linux/brcm63xx/base-files/etc/board.d/01_leds b/target/linux/brcm63xx/base-files/etc/board.d/01_leds new file mode 100755 index 0000000000..4955efdf27 --- /dev/null +++ b/target/linux/brcm63xx/base-files/etc/board.d/01_leds @@ -0,0 +1,58 @@ +#!/bin/sh +# +# Copyright (C) 2013-2015 OpenWrt.org +# + +. /lib/functions/uci-defaults-new.sh +. /lib/brcm63xx.sh + +board_config_update + +case "$(brcm63xx_board_name)" in +a4001n1) + ucidef_set_led_netdev "lan" "LAN" "A4001N1:green:eth" "eth0" + ucidef_set_led_usbdev "usb" "USB" "A4001N1:green:3g" "1-1" + ;; +a4001n) + ucidef_set_led_usbdev "usb" "USB" "A4001N:green:usb" "1-1" + ;; +dgnd3700v1_dgnd3800b) + ucidef_set_led_netdev "lan" "LAN" "DGND3700v1_3800B:green:lan" "eth0.1" + ucidef_set_led_netdev "wan" "WAN" "DGND3700v1_3800B:green:inet" "eth0.2" + ucidef_set_led_netdev "wlan0" "WIFI2G" "DGND3700v1_3800B:green:wifi2g" "wlan0" + ucidef_set_led_netdev "wlan1" "WIFI5G" "DGND3700v1_3800B:blue:wifi5g" "wlan1" + ucidef_set_led_usbdev "usb1" "USB1" "DGND3700v1_3800B:green:usb-back" "1-1" + ucidef_set_led_usbdev "usb2" "USB2" "DGND3700v1_3800B:green:usb-front" "1-2" + ;; +fast2704n) + ucidef_set_led_netdev "wan" "WAN" "F@ST2704N:green:inet" "eth0.2" + ;; +fast2704v2) + ucidef_set_led_usbdev "usb" "USB" "F@ST2704V2:green:usb" "1-1" + ;; +hg553) + ucidef_set_led_netdev "lan" "LAN" "HW553:blue:lan" "eth0" + ucidef_set_led_usbdev "usb1" "USB1" "HW553:red:hspa" "1-1" + ucidef_set_led_usbdev "usb2" "USB2" "HW553:blue:hspa" "1-2" + ;; +hg556a_*) + ucidef_set_led_netdev "lan" "LAN" "HW556:red:dsl" "eth0" + ucidef_set_led_usbdev "usb" "USB" "HW556:red:hspa" "1-2" + ;; +hg655b) + ucidef_set_led_usbdev "usb" "USB" "HW65x:green:usb" "1-2" + ;; +homehub2a) + ucidef_set_led_netdev "lan" "LAN" "HOMEHUB2A:blue:broadband" "eth0.1" + ucidef_set_led_netdev "wlan0" "WIFI" "HOMEHUB2A:green:wireless" "wlan0" + ucidef_set_led_usbdev "usb1" "USB1" "HOMEHUB2A:blue:phone" "1-1" + ucidef_set_led_usbdev "usb2" "USB2" "HOMEHUB2A:green:phone" "2-1" + ;; +r5010un_v2) + ucidef_set_led_usbdev "usb" "USB" "R5010UNv2:green:usb" "1-1" + ;; +esac + +board_config_flush + +exit 0 diff --git a/target/linux/brcm63xx/base-files/etc/board.d/02_network b/target/linux/brcm63xx/base-files/etc/board.d/02_network new file mode 100755 index 0000000000..2098d988a3 --- /dev/null +++ b/target/linux/brcm63xx/base-files/etc/board.d/02_network @@ -0,0 +1,138 @@ +#!/bin/sh +# +# Copyright (C) 2012-2015 OpenWrt.org +# + +. /lib/functions/uci-defaults-new.sh +. /lib/brcm63xx.sh + +board_config_update + +case "$(brcm63xx_board_name)" in + +cvg834g |\ +rta770bw |\ +rta770w |\ +spw303v |\ +spw500v) + ucidef_set_interface_lan "eth0" + ;; + +ar1004g |\ +bcm96338gw |\ +bcm96338w |\ +cpva642 |\ +ct-5365 |\ +ct-536p_5621t |\ +ct-6373 |\ +dg834g_v4 |\ +dsl-2640b-b |\ +dsl-2640u |\ +fast2604 |\ +rta1320 |\ +v2110) + ucidef_add_switch "switch0" \ + "0:lan:4" "1:lan:3" "2:lan:2" "3:lan:1" "5@eth0" + ;; + +agpf-s0 |\ +bcm96348gw |\ +bcm96348gw-10 |\ +bcm96348gw-11 |\ +bcm96358vw |\ +bcm96358vw2 |\ +cpva502p |\ +dg834gt |\ +dmv-s0 |\ +dsl-2650u |\ +dv-201amr |\ +f5d7633 |\ +fast2404 |\ +magic |\ +rg100a |\ +rta1025W |\ +td-w8900gb |\ +usr9108 |\ +v2500v_bb) + ucidef_set_interfaces_lan_wan "eth1" "eth0" + ucidef_add_switch "switch0" \ + "0:lan:4" "1:lan:3" "2:lan:2" "3:lan:1" "5@eth1" + ;; + +dsl-274xb-c |\ +hg553 |\ +hg556a_* |\ +homehub2a) + ucidef_add_switch "switch0" \ + "0:lan:1" "1:lan:2" "2:lan:3" "3:lan:4" "5t@eth0" + ;; + +dva-g3810bn |\ +hg520 |\ +neufbox4) + ucidef_set_interfaces_lan_wan "eth1.1" "eth0" + ucidef_add_switch "switch0" \ + "0:lan:4" "1:lan:3" "2:lan:2" "3:lan:1" "5t@eth1" + ;; + +a4001n1 |\ +a4001n |\ +ar-5381u |\ +ar-5387un |\ +bcm963281tan |\ +bcm96328avng |\ +bcm96368mvngr |\ +dsl-274xb-f |\ +dsl-275xb-d |\ +fast2504n |\ +fast2704v2 |\ +hg655b |\ +p870hw-51a_v2 |\ +r5010un_v2 |\ +vr-3025un |\ +vr-3025u |\ +vr-3026e) + ucidef_add_switch "switch0" \ + "0:lan:1" "1:lan:2" "2:lan:3" "3:lan:4" "8t@eth0" + ;; + +bcm96368mvwg) + ucidef_add_switch "switch0" \ + "1:lan" "2:lan" "4:lan" "5:lan" "8t@eth0" + ;; + +wap-5813n) + ucidef_add_switch "switch0" \ + "0:lan" "1:lan" "2:lan" "3:lan" "4:wan" "5t@eth0" + ;; + +fast2704n |\ +dgnd3700v1_dgnd3800b) + ucidef_add_switch "switch0" \ + "1:lan:1" "2:lan:2" "3:lan:3" "4:lan:4" "0:wan" "8t@eth0" + ;; + +neufbox6) + ucidef_add_switch "switch0" \ + "1:lan" "2:lan" "3:lan" "4:lan" "0:wan" "9t@eth0" + ;; + +vg50) + ucidef_add_switch "switch0" \ + "0:lan" "1:lan" "2:lan" "3:lan" "4:wan" "8t@eth0" + ;; + +bcm963268bu_p300) + ucidef_add_switch "switch0" \ + "0:lan" "3:lan" "4:lan" "5:lan" "6:lan" "7:lan" "8t@eth0" + ;; + +*) + ucidef_set_interfaces_lan_wan "eth1" "eth0" + ;; + +esac + +board_config_flush + +exit 0 |