aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ramips/base-files/lib
diff options
context:
space:
mode:
authorKevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>2017-09-25 15:24:38 +0100
committerMathias Kresin <dev@kresin.me>2017-09-28 07:23:18 +0200
commit972c126eb6390f3dcc34220d42c24843ee79c375 (patch)
treefa6d36405b8fcaf890abc25fd0cd883d940d35e8 /target/linux/ramips/base-files/lib
parent36fd53f9a9184de4583499b3dc119f33952cf04e (diff)
downloadupstream-972c126eb6390f3dcc34220d42c24843ee79c375.tar.gz
upstream-972c126eb6390f3dcc34220d42c24843ee79c375.tar.bz2
upstream-972c126eb6390f3dcc34220d42c24843ee79c375.zip
ramips: mt7621: fix failsafe mode networking
Disable VLANs on mt7621 boards with mt7530 switches on failsafe entry. Allows failsafe networking to work correctly. Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk> [fixed default case syntax error] Signed-off-by: Mathias Kresin <dev@kresin.me>
Diffstat (limited to 'target/linux/ramips/base-files/lib')
-rw-r--r--target/linux/ramips/base-files/lib/preinit/07_set_preinit_iface_ramips9
1 files changed, 7 insertions, 2 deletions
diff --git a/target/linux/ramips/base-files/lib/preinit/07_set_preinit_iface_ramips b/target/linux/ramips/base-files/lib/preinit/07_set_preinit_iface_ramips
index 452b1b203f..5048dacb4f 100644
--- a/target/linux/ramips/base-files/lib/preinit/07_set_preinit_iface_ramips
+++ b/target/linux/ramips/base-files/lib/preinit/07_set_preinit_iface_ramips
@@ -6,17 +6,22 @@
. /lib/ramips.sh
ramips_set_preinit_iface() {
- RT3X5X=`cat /proc/cpuinfo | egrep "(RT3.5|RT5350|MT7628|MT7688|MT7620)"`
+ RT3X5X=`cat /proc/cpuinfo | egrep "(RT3.5|RT5350|MT7628|MT7688|MT7620|MT7621)"`
if [ -n "${RT3X5X}" ]; then
# The ethernet switch driver enables VLAN by default, but
# failsafe uses eth0, making the device unreachable:
# https://dev.openwrt.org/ticket/18768
- ralink_switchdev=rt305x
case "${RT3X5X}" in
*MT7620*)
ralink_switchdev=mt7620
;;
+ *MT7621*)
+ ralink_switchdev=mt7530
+ ;;
+ *)
+ ralink_switchdev=rt305x
+ ;;
esac
swconfig dev $ralink_switchdev set reset 1
swconfig dev $ralink_switchdev set enable_vlan 0