imx6: move imx6.sh to /lib/ for consistency
[openwrt.git] / target / linux / imx6 / base-files / etc / uci-defaults / 02_network
1 #!/bin/sh
2 #
3 # Copyright (C) 2013 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/imx6.sh
12
13 board=$(imx6_board_name)
14
15 ucidef_set_interface_loopback
16
17 case "$board" in
18 "gw51xx" |\
19 "gw52xx")
20         ucidef_set_interface_lan 'eth0'
21         ;;
22 "gw53xx" |\
23 "gw54xx")
24         ucidef_set_interfaces_lan_wan 'eth0' 'eth1'
25         ;;
26 "wandboard")
27         ucidef_set_interface_wan 'eth0'
28         ;;
29 esac
30
31 uci commit network
32
33 exit 0