openwrtv4/target/linux/mediatek/base-files/etc/board.d/02_network
Jo-Philipp Wich ea269c37b8 ar71xx/ipq806x/mediatek/mvebu: fix network defaults
After "73d923e base-files: emit tagged switch configuration by default"
some default network configurations are broken because the lan and wan
ifnames are forcibly set to untagged netdevs.

Adjust the offending set_interfaces_lan_wan() calls to use the proper
tagged device names.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2017-02-07 09:32:28 +01:00

28 lines
475 B
Bash
Executable file

#!/bin/sh
. /lib/functions.sh
. /lib/mediatek.sh
. /lib/functions/uci-defaults.sh
. /lib/functions/system.sh
mediatek_setup_interfaces()
{
local board="$1"
case $board in
eMMC | \
NAND | \
mt7623_evb)
ucidef_set_interfaces_lan_wan "eth0.1" "eth1.2"
ucidef_add_switch "switch0" \
"0:lan" "1:lan" "2:lan" "3:lan" "4:wan" "6@eth0" "5@eth1"
;;
esac
}
board_config_update
board=$(mediatek_board_name)
mediatek_setup_interfaces $board
board_config_flush
exit 0