Modify

Opened 3 years ago

Last modified 12 months ago

#18768 new defect

Nexx WT3020 Failsafe does not work

Reported by: probono Owned by: developers
Priority: normal Milestone:
Component: packages Version: Trunk
Keywords: Cc:

Description

Failsafe mode appears to be broken as of r43977.

I suspect that TCP connections are not working when VLAN is disabled just like on other MediaTek/Ralink chipsets. Possibly some code along the lines of https://lists.openwrt.org/pipermail/openwrt-devel/2014-August/027316.html needs to be added in order for OpenWrt Failsafe to work on this device.

However, the configuration is different enough so that I couldn't figure it out on my own. Hence I have documented the details on http://wiki.openwrt.org/toh/nexx/wt3020?&#openwrt_failsafe

Attachments (0)

Change History (23)

comment:1 Changed 2 years ago by anonymous

Please fix the failsafe for this great device

comment:3 Changed 2 years ago by anonymous

...and possibly also related to https://forum.openwrt.org/viewtopic.php?id=56276

comment:5 Changed 2 years ago by marcin1j

The problem is that the switch on MT7620 has VLANs enabled by default and in this mode, eth0 won't receive any packet unless you create at least one eth0.x device for VLANs and bring it up.
Therefore, you have to either:

  1. Create at least eth0.1 and use it as default failsafe device, bringing eth0 up (this is what the preinit script does for rt305x switch),
  2. Turn off VLAN support - easier approach, the following patch will fix network in failsafe mode:
    • target/linux/ramips/base-files/lib/preinit/07_set_preinit_iface_ramips

      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 cae6396..42e3386 100644
      a b ramips_set_preinit_iface() { 
      2626               vconfig add eth0 1 
      2727               ifconfig eth0 up 
      2828               ifname=eth0.1 
       29       elif grep MT7620 /proc/cpuinfo; then 
       30               swconfig dev mt7620 set reset 1 
       31               swconfig dev mt7620 set enable_vlan 0 
       32               swconfig dev mt7620 set apply 
       33               ifname=eth0 
      2934       else 
      3035               ifname=eth0 
      3136       fi 

I can't tell which solution conforms better to OpenWrt code base, but for some reason the MT7620 switch driver enables VLAN when probing for device (see gsw_mt7620a.c - the third parameter of mt7530_probe() enables or disables VLAN):

int mt7620_gsw_config(struct fe_priv *priv)
{
        struct mt7620_gsw *gsw = (struct mt7620_gsw *) priv->soc->swpriv;

        /* is the mt7530 internal or external */
        if (priv->mii_bus && priv->mii_bus->phy_map[0x1f]) {
                mt7530_probe(priv->device, gsw->base, NULL, 0);
                mt7530_probe(priv->device, NULL, priv->mii_bus, 1);
        } else {
                mt7530_probe(priv->device, gsw->base, NULL, 1);
        }

        return 0;
}

comment:6 follow-up: Changed 2 years ago by daniel.petre@…

Seems the factory image is broken for wt3020 8M with r45973 , i don't have serial console and neither factory nor sysupgrade flashing work! Luckily i installed the web interfaced uboot so i can recover..

comment:7 Changed 2 years ago by wbr@…

Any update on this issue? Would love to be able to use failsafe on this little box.

comment:8 in reply to: ↑ 6 Changed 2 years ago by micmon

Replying to daniel.petre@…:

Seems the factory image is broken for wt3020 8M with r45973 , i don't have serial console

Do you mean access by serial console connection is broken or are you just missing the console converter/cable?

comment:9 Changed 2 years ago by ekstazyst@…

This bug also exists for xiaomi miwifi router mini

comment:10 Changed 2 years ago by anonymous

MT7621 based devices are also affected.

comment:11 Changed 2 years ago by merpmerp

just ran into this problem myself, would love to see this fixed!

comment:12 Changed 2 years ago by dev.openwrt.org@…

subscribe myself for updates

comment:13 Changed 2 years ago by anonymous

I've been using the patch to "target/linux/ramips/base-files/lib/preinit/07_set_preinit_iface_ramips" above and it works flawlessly

comment:14 Changed 2 years ago by kobayashison

subscribed

comment:15 Changed 23 months ago by anonymous

Could this patch be applied then to trunk?

comment:16 Changed 22 months ago by ReganGunther

I'd love to see this fixed in trunk too. It would be a huge help to give peace of mind that failsafe can be used easily on this device.

comment:17 Changed 22 months ago by jofi

Why is no one applying the patch to trunk? Any devs here?

comment:20 follow-up: Changed 16 months ago by dev.openwrt.org@…

apparently, this was fixed in r48772

please confirm or disconfirm

comment:21 Changed 16 months ago by dev.openwrt.org@…

It's not applied to Chaos Chalmer yet. That should definitely be done.

comment:22 Changed 15 months ago by anonymous

Would be great if anyone shared their vanilla CC build with this fix.

comment:23 in reply to: ↑ 20 Changed 12 months ago by ondrej@…

Replying to dev.openwrt.org@…:

apparently, this was fixed in r48772

Wouldn't this change introduce a WAN-LAN leakage during router booting? Maybe better approach would be to enable VLANs as usual and use only VLAN 1.

Add Comment

Modify Ticket

Action
as new .
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.