add support for board named RTA770W
[openwrt/staging/dedeckeh.git] / target / linux / brcm63xx / base-files / etc / uci-defaults / 02_network
1 #!/bin/sh
2 #
3 # Copyright (C) 2012 OpenWrt.org
4 #
5
6 [ -e /etc/config/network ] && exit 0
7
8 touch /etc/config/network
9
10 . /lib/functions/uci-defaults.sh
11 . /lib/brcm63xx.sh
12
13 ucidef_set_interface_loopback
14
15 case "$board_name" in
16
17 RTA770BW |\
18 RTA770W |\
19 96348W3 |\
20 96358-502V |\
21 SPW500V)
22 ucidef_set_interface_lan "eth0"
23 ;;
24
25 96338GW |\
26 96338W |\
27 96338W2_E7T |\
28 96348A-122 |\
29 96348W3 |\
30 CPVA642 |\
31 CT536_CT5621 |\
32 CT6373-1 |\
33 D-4P-W |\
34 "F@ST2604" |\
35 RTA1320_16M |\
36 V2110)
37 ucidef_set_interface_lan "eth0"
38 ucidef_add_switch "eth0" "1" "1"
39 ucidef_add_switch_vlan "eth0" "1" "0 1 2 3 4 5"
40 ;;
41
42 96348GW |\
43 96348GW-10 |\
44 96348GW-11 |\
45 96348GW-A |\
46 96358VW |\
47 96358VW2 |\
48 AGPF-S0 |\
49 "CPVA502+" |\
50 DV201AMR |\
51 DWV-S0 |\
52 "F@ST2404" |\
53 HW553 |\
54 MAGIC |\
55 RTA1025W_16 |\
56 V2500V_BB)
57 ucidef_set_interfaces_lan_wan "eth1" "eth0"
58 ucidef_add_switch "eth1" "1" "1"
59 ucidef_add_switch_vlan "eth1" "1" "0 1 2 3 4 5"
60 ;;
61
62 AW4139 |\
63 HW556*)
64 ucidef_set_interface_lan "eth0.1"
65 ucidef_add_switch "eth0" "1" "1"
66 ucidef_add_switch_vlan "eth0" "1" "0 1 2 3 4 5t"
67 ;;
68
69 NB4-* |\
70 DVG3810BN)
71 ucidef_set_interfaces_lan_wan "eth1.1" "eth0"
72 ucidef_add_switch "eth1" "1" "1"
73 ucidef_add_switch_vlan "eth1" "1" "0 1 2 3 4 5t"
74 ;;
75
76 96328avng |\
77 96328A-1241N |\
78 96328A-1441N1 |\
79 963281TAN |\
80 963281T_TEF |\
81 96368MVNgr)
82 ucidef_set_interface_lan "eth0.1"
83 ucidef_add_switch "eth0" "1" "1"
84 ucidef_add_switch_vlan "eth0" "1" "0 1 2 3 8t"
85 ;;
86
87 96368MVWG)
88 ucidef_set_interface_lan "eth0.1"
89 ucidef_add_switch "eth0" "1" "1"
90 ucidef_add_switch_vlan "eth0" "1" "1 2 4 5 8t"
91 ;;
92
93 NB6)
94 ucidef_set_interfaces_lan_wan "eth0.1" "eth0.2"
95 ucidef_add_switch "switch0" "1" "1"
96 ucidef_add_switch_vlan "switch0" "1" "1 2 3 4 9t"
97 ucidef_add_switch_vlan "switch0" "2" "0 9t"
98 ;;
99
100 *)
101 ucidef_set_interfaces_lan_wan "eth1" "eth0"
102 ;;
103
104 esac
105
106 uci commit network
107
108 exit 0