openwrtv3/target/linux/kirkwood/base-files/etc/board.d/02_network
Paul Wassi f6b5df44d9 kirkwood: remove redundant code in etc/board.d/02_network
Remove redundant code: merge boards/cases that share
the same network configuration.
Also fix the alphabetical ordering of the cases.

Signed-off-by: Paul Wassi <p.wassi@gmx.at>
2016-10-26 12:37:45 +02:00

40 lines
619 B
Bash
Executable file

#!/bin/sh
#
# Copyright (C) 2012-2015 OpenWrt.org
#
. /lib/functions/uci-defaults.sh
. /lib/kirkwood.sh
board_config_update
board=$(kirkwood_board_name)
case "$board" in
"dockstar"|\
"goflexhome"|\
"goflexnet"|\
"ib62x0"|\
"iconnect"|\
"nsa310s"|\
"pogo_e02"|\
"sheevaplug"|\
"sheevaplug-esata")
ucidef_set_interface_lan "eth0" "dhcp"
;;
"linksys-audi"|\
"linksys-viper")
ucidef_add_switch "switch0" \
"0:lan" "1:lan" "2:lan" "3:lan" "4:wan" "5@eth0" "6@eth1"
;;
"guruplug-server-plus")
ucidef_set_interface_lan "eth0 eth1" "dhcp"
;;
*)
ucidef_set_interface_lan "eth0"
;;
esac
board_config_flush
exit 0