forked from openwrt/openwrt
-
-
Notifications
You must be signed in to change notification settings - Fork 5
/
02_network
executable file
·52 lines (46 loc) · 1019 Bytes
/
02_network
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
#!/bin/sh
#
# Copyright (C) 2014-2016 OpenWrt.org
# Copyright (C) 2016 LEDE-Project.org
#
. /lib/functions/uci-defaults.sh
board_config_update
board=$(board_name)
case "$board" in
cznic,turris-omnia)
ucidef_set_interface_lan "lan0 lan1 lan2 lan3 lan4"
ucidef_set_interface_wan "eth2"
;;
linksys,caiman|\
linksys,cobra|\
linksys,mamba|\
linksys,rango|\
linksys,shelby|\
linksys,venom)
ucidef_set_interfaces_lan_wan "lan1 lan2 lan3 lan4" "wan"
;;
marvell,a385-db-ap)
ucidef_set_interfaces_lan_wan "eth0 eth1" "eth2"
;;
marvell,axp-gp)
ucidef_set_interface_lan "eth0 eth1 eth2 eth3"
;;
solidrun,clearfog-a1|\
solidrun,clearfog-pro-a1)
# eth0 is standalone ethernet
# eth1 is switch
# eth2 is SFP
ucidef_set_interfaces_lan_wan "lan1 lan2 lan3 lan4 lan5 lan6" "eth0 eth2"
;;
solidrun,clearfog-base-a1)
# eth0 is standalone ethernet
# eth1 is standalone ethernet
# eth2 is SFP
ucidef_set_interfaces_lan_wan "eth1" "eth0 eth2"
;;
*)
ucidef_set_interface_lan "eth0"
;;
esac
board_config_flush
exit 0