aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/sunxi/base-files/etc/board.d
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2015-12-04 14:32:52 +0000
committerJo-Philipp Wich <jow@openwrt.org>2015-12-04 14:32:52 +0000
commitb6a9c5c40095701eeaf48819e047ba231a3f2748 (patch)
tree4a87aa89dd2d6a6e96aaa108882b1f056cdb05b0 /target/linux/sunxi/base-files/etc/board.d
parentca00bd2be44037fa9acbb43b6b29e7f06eb855d9 (diff)
downloadupstream-b6a9c5c40095701eeaf48819e047ba231a3f2748.tar.gz
upstream-b6a9c5c40095701eeaf48819e047ba231a3f2748.tar.bz2
upstream-b6a9c5c40095701eeaf48819e047ba231a3f2748.zip
sunxi: switch from uci-defaults to board.d
Signed-off-by: Jo-Philipp Wich <jow@openwrt.org> SVN-Revision: 47758
Diffstat (limited to 'target/linux/sunxi/base-files/etc/board.d')
-rw-r--r--target/linux/sunxi/base-files/etc/board.d/02_network26
1 files changed, 26 insertions, 0 deletions
diff --git a/target/linux/sunxi/base-files/etc/board.d/02_network b/target/linux/sunxi/base-files/etc/board.d/02_network
new file mode 100644
index 0000000000..59af55c7a1
--- /dev/null
+++ b/target/linux/sunxi/base-files/etc/board.d/02_network
@@ -0,0 +1,26 @@
+#!/bin/sh
+#
+# Copyright (C) 2013-2015 OpenWrt.org
+#
+
+. /lib/sunxi.sh
+. /lib/functions/uci-defaults-new.sh
+
+board_config_update
+
+case "$( sunxi_board_name )" in
+"olinuxino-micro"*)
+ ucidef_set_interface_lan 'wlan0'
+ ;;
+"lamobo-r1")
+ ucidef_add_switch "switch0" \
+ "4:lan:1" "0:lan:2" "1:lan:3" "2:lan:4" "3:wan" "8@eth0"
+ ;;
+*)
+ ucidef_set_interface_lan 'eth0'
+ ;;
+esac
+
+board_config_flush
+
+exit 0