ar71xx: create TL-WR{841N-v1,941ND} network config from uci-defaults
SVN-Revision: 28824
This commit is contained in:
parent
9298c7afe5
commit
e866ba5753
3 changed files with 17 additions and 40 deletions
|
@ -1,20 +0,0 @@
|
|||
config interface loopback
|
||||
option ifname lo
|
||||
option proto static
|
||||
option ipaddr 127.0.0.1
|
||||
option netmask 255.0.0.0
|
||||
|
||||
config interface mac0
|
||||
option ifname eth0
|
||||
option proto none
|
||||
|
||||
config interface lan
|
||||
option ifname "lan1 lan2 lan3 lan4"
|
||||
option type bridge
|
||||
option proto static
|
||||
option ipaddr 192.168.1.1
|
||||
option netmask 255.255.255.0
|
||||
|
||||
config interface wan
|
||||
option ifname wan
|
||||
option proto dhcp
|
|
@ -1,20 +0,0 @@
|
|||
config interface loopback
|
||||
option ifname lo
|
||||
option proto static
|
||||
option ipaddr 127.0.0.1
|
||||
option netmask 255.0.0.0
|
||||
|
||||
config interface eth
|
||||
option ifname eth0
|
||||
option proto none
|
||||
|
||||
config interface lan
|
||||
option ifname "lan1 lan2 lan3 lan4"
|
||||
option type bridge
|
||||
option proto static
|
||||
option ipaddr 192.168.1.1
|
||||
option netmask 255.255.255.0
|
||||
|
||||
config interface wan
|
||||
option ifname wan
|
||||
option proto dhcp
|
|
@ -13,6 +13,17 @@ set network.loopback.netmask='255.0.0.0'
|
|||
EOF
|
||||
}
|
||||
|
||||
set_interface_raw() {
|
||||
local cfg=$1
|
||||
local ifname=$2
|
||||
|
||||
uci batch <<EOF
|
||||
set network.$cfg='interface'
|
||||
set network.$cfg.ifname='$ifname'
|
||||
set network.$cfg.proto='none'
|
||||
EOF
|
||||
}
|
||||
|
||||
set_interface_lan() {
|
||||
local ifname=$1
|
||||
|
||||
|
@ -99,6 +110,12 @@ routerstation-pro)
|
|||
add_switch_vlan "switch0" "1" "0 1 2 3 4"
|
||||
;;
|
||||
|
||||
tl-wr841n-v1|\
|
||||
tl-wr941nd)
|
||||
set_interface_raw "eth" "eth0"
|
||||
set_interfaces_lan_wan "lan1 lan2 lan3 lan4" "wan"
|
||||
;;
|
||||
|
||||
aw-nr580 |\
|
||||
bullet-m |\
|
||||
eap7660d |\
|
||||
|
|
Loading…
Reference in a new issue