1#!/bin/sh 2# 3# Copyright (C) 2012-2015 OpenWrt.org 4# 5 6. /lib/functions/uci-defaults.sh 7. /lib/brcm63xx.sh 8 9board_config_update 10 11case "$(brcm63xx_board_name)" in 12 13cvg834g |\ 14evg2000 |\ 15rta770bw |\ 16rta770w |\ 17spw303v |\ 18spw500v) 19 ucidef_set_interface_lan "eth0" 20 ;; 21 22ar1004g |\ 23bcm96338gw |\ 24bcm96338w |\ 25cpva642 |\ 26ct-5365 |\ 27ct-536p_5621t |\ 28ct-6373 |\ 29dg834g_v4 |\ 30dsl-2640b-b |\ 31dsl-2640u |\ 32fast2604 |\ 33rta1320 |\ 34v2110) 35 ucidef_add_switch "switch0" \ 36 "0:lan:4" "1:lan:3" "2:lan:2" "3:lan:1" "5@eth0" 37 ;; 38 39agpf-s0 |\ 40bcm96348gw |\ 41bcm96348gw-10 |\ 42bcm96348gw-11 |\ 43bcm96358vw |\ 44bcm96358vw2 |\ 45cpva502p |\ 46dg834gt |\ 47dmv-s0 |\ 48dsl-2650u |\ 49dv-201amr |\ 50f5d7633 |\ 51fast2404 |\ 52magic |\ 53rg100a |\ 54rta1025W |\ 55td-w8900gb |\ 56usr9108 |\ 57v2500v_bb) 58 ucidef_set_interfaces_lan_wan "eth1" "eth0" 59 ucidef_add_switch "switch0" \ 60 "0:lan:4" "1:lan:3" "2:lan:2" "3:lan:1" "5@eth1" 61 ;; 62 63dsl-274xb-c |\ 64hg553 |\ 65hg556a_* |\ 66homehub2a) 67 ucidef_add_switch "switch0" \ 68 "0:lan:1" "1:lan:2" "2:lan:3" "3:lan:4" "5t@eth0" 69 ;; 70 71dva-g3810bn |\ 72hg520 |\ 73neufbox4) 74 ucidef_set_interfaces_lan_wan "eth1.1" "eth0" 75 ucidef_add_switch "switch0" \ 76 "0:lan:4" "1:lan:3" "2:lan:2" "3:lan:1" "5t@eth1" 77 ;; 78 79a4001n1 |\ 80a4001n |\ 81ar-5381u |\ 82ar-5387un |\ 83bcm963281tan |\ 84bcm96328avng |\ 85bcm96368mvngr |\ 86dsl-274xb-f |\ 87dsl-275xb-d |\ 88fast2504n |\ 89fast2704v2 |\ 90hg622 |\ 91hg655b |\ 92p870hw-51a_v2 |\ 93r5010un_v2 |\ 94vr-3025un |\ 95vr-3025u |\ 96vr-3026e) 97 ucidef_add_switch "switch0" \ 98 "0:lan:1" "1:lan:2" "2:lan:3" "3:lan:4" "8t@eth0" 99 ;; 100 101bcm96368mvwg) 102 ucidef_add_switch "switch0" \ 103 "1:lan" "2:lan" "4:lan" "5:lan" "8t@eth0" 104 ;; 105 106wap-5813n) 107 ucidef_add_switch "switch0" \ 108 "0:lan" "1:lan" "2:lan" "3:lan" "4:wan" "5t@eth0" 109 ;; 110 111fast2704n |\ 112dgnd3700v1_dgnd3800b) 113 ucidef_add_switch "switch0" \ 114 "1:lan:1" "2:lan:2" "3:lan:3" "4:lan:4" "0:wan" "8t@eth0" 115 ;; 116 117neufbox6) 118 ucidef_add_switch "switch0" \ 119 "1:lan" "2:lan" "3:lan" "4:lan" "0:wan" "9t@eth0" 120 ;; 121 122vg50) 123 ucidef_add_switch "switch0" \ 124 "0:lan" "1:lan" "2:lan" "3:lan" "4:wan" "8t@eth0" 125 ;; 126 127bcm963268bu_p300) 128 ucidef_add_switch "switch0" \ 129 "0:lan" "3:lan" "4:lan" "5:lan" "6:lan" "7:lan" "8t@eth0" 130 ;; 131 132*) 133 ucidef_set_interfaces_lan_wan "eth1" "eth0" 134 ;; 135 136esac 137 138board_config_flush 139 140exit 0 141