diff options
author | James <> | 2015-11-04 11:49:21 +0000 |
---|---|---|
committer | James <> | 2015-11-04 11:49:21 +0000 |
commit | 716ca530e1c4515d8683c9d5be3d56b301758b66 (patch) | |
tree | 700eb5bcc1a462a5f21dcec15ce7c97ecfefa772 /target/linux/sunxi/base-files/etc/uci-defaults/02_network | |
download | trunk-47381-master.tar.gz trunk-47381-master.tar.bz2 trunk-47381-master.zip |
Diffstat (limited to 'target/linux/sunxi/base-files/etc/uci-defaults/02_network')
-rw-r--r-- | target/linux/sunxi/base-files/etc/uci-defaults/02_network | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/target/linux/sunxi/base-files/etc/uci-defaults/02_network b/target/linux/sunxi/base-files/etc/uci-defaults/02_network new file mode 100644 index 0000000..372fed9 --- /dev/null +++ b/target/linux/sunxi/base-files/etc/uci-defaults/02_network @@ -0,0 +1,32 @@ +#!/bin/sh +# +# Copyright (C) 2013-2014 OpenWrt.org +# + +[ -e /etc/config/network ] && exit 0 + +touch /etc/config/network + +. /lib/sunxi.sh +. /lib/functions/uci-defaults.sh + +ucidef_set_interface_loopback + +case "$( sunxi_board_name )" in +"olinuxino-micro"*) + ucidef_set_interface_lan 'wlan0' + ;; +"lamobo-r1") + ucidef_set_interfaces_lan_wan "eth0.1" "eth0.2" + ucidef_add_switch "switch0" "1" "1" + ucidef_add_switch_vlan "switch0" "1" "4 0 1 2 8t" + ucidef_add_switch_vlan "switch0" "2" "3 8t" + ;; +*) + ucidef_set_interface_lan 'eth0' + ;; +esac + +uci commit network + +exit 0 |