openwrt / openwrt/mt76

Wifi unstable and wan connection drops on Xiaomi MI router 4c on SoC MediaTek MT7628AN running on OpenWrt 21.02.0-rc2 stable release

Open
#547 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
888
Forks
436
PR merge metrics
No merged PRs in 30d

Description

system log attached below:

wifi disconnect
Thu Jun 3 19:55:06 2021 kern.info kernel: [21337.734846] rt3050-esw 10110000.esw: link changed 0x06

after restarting wifi radio
Thu Jun 3 20:00:24 2021 daemon.notice hostapd: Remove interface 'wlan0'
Thu Jun 3 20:00:24 2021 daemon.notice hostapd: wlan0: interface state ENABLED->DISABLED
Thu Jun 3 20:00:24 2021 daemon.notice hostapd: wlan0: AP-STA-DISCONNECTED 26:0f:41:a2:14:99
Thu Jun 3 20:00:24 2021 daemon.notice hostapd: wlan0: AP-DISABLED
Thu Jun 3 20:00:24 2021 daemon.notice hostapd: wlan0: CTRL-EVENT-TERMINATING
Thu Jun 3 20:00:24 2021 daemon.notice hostapd: nl80211: deinit ifname=wlan0 disabled_11b_rates=0
Thu Jun 3 20:00:24 2021 kern.info kernel: [21655.465888] device wlan0 left promiscuous mode
Thu Jun 3 20:00:24 2021 kern.info kernel: [21655.470650] br-lan: port 2(wlan0) entered disabled state
Thu Jun 3 20:00:27 2021 kern.err kernel: [21658.906057] mt76_wmac 10300000.wmac: MCU message 08 (seq 7) timed out
Thu Jun 3 20:00:29 2021 daemon.notice netifd: Network device 'wlan0' link is down
Thu Jun 3 20:00:31 2021 daemon.notice hostapd: Configuration file: /var/run/hostapd-phy0.conf (phy wlan0) --> new PHY
Thu Jun 3 20:00:34 2021 kern.err kernel: [21665.817985] mt76_wmac 10300000.wmac: MCU message 08 (seq 8) timed out
Thu Jun 3 20:00:36 2021 kern.info kernel: [21667.884073] br-lan: port 2(wlan0) entered blocking state
Thu Jun 3 20:00:36 2021 kern.info kernel: [21667.889549] br-lan: port 2(wlan0) entered disabled state
Thu Jun 3 20:00:36 2021 kern.info kernel: [21667.895378] device wlan0 entered promiscuous mode
Thu Jun 3 20:00:36 2021 daemon.notice hostapd: wlan0: interface state UNINITIALIZED->COUNTRY_UPDATE
Thu Jun 3 20:00:36 2021 daemon.notice hostapd: wlan0: interface state COUNTRY_UPDATE->HT_SCAN
Thu Jun 3 20:00:39 2021 kern.err kernel: [21670.937919] mt76_wmac 10300000.wmac: MCU message 08 (seq 9) timed out
Thu Jun 3 20:00:44 2021 kern.err kernel: [21676.057867] mt76_wmac 10300000.wmac: MCU message 08 (seq 10) timed out
Thu Jun 3 20:00:49 2021 kern.err kernel: [21681.177788] mt76_wmac 10300000.wmac: MCU message 08 (seq 11) timed out
Thu Jun 3 20:00:55 2021 kern.err kernel: [21686.297726] mt76_wmac 10300000.wmac: MCU message 08 (seq 12) timed out
Thu Jun 3 20:01:00 2021 kern.err kernel: [21691.417664] mt76_wmac 10300000.wmac: MCU message 08 (seq 13) timed out
Thu Jun 3 20:01:05 2021 kern.err kernel: [21696.537602] mt76_wmac 10300000.wmac: MCU message 08 (seq 14) timed out
Thu Jun 3 20:01:10 2021 kern.err kernel: [21701.657538] mt76_wmac 10300000.wmac: MCU message 08 (seq 15) timed out
Thu Jun 3 20:01:15 2021 kern.err kernel: [21706.777479] mt76_wmac 10300000.wmac: MCU message 08 (seq 1) timed out
Thu Jun 3 20:01:20 2021 kern.err kernel: [21711.897424] mt76_wmac 10300000.wmac: MCU message 08 (seq 2) timed out
Thu Jun 3 20:01:25 2021 kern.err kernel: [21717.017355] mt76_wmac 10300000.wmac: MCU message 08 (seq 3) timed out
Thu Jun 3 20:01:30 2021 kern.err kernel: [21722.137291] mt76_wmac 10300000.wmac: MCU message 08 (seq 4) timed out
Thu Jun 3 20:01:36 2021 kern.err kernel: [21727.257229] mt76_wmac 10300000.wmac: MCU message 08 (seq 5) timed out
Thu Jun 3 20:01:41 2021 kern.err kernel: [21732.377165] mt76_wmac 10300000.wmac: MCU message 08 (seq 6) timed out
Thu Jun 3 20:01:46 2021 kern.err kernel: [21737.497107] mt76_wmac 10300000.wmac: MCU message 08 (seq 7) timed out
Thu Jun 3 20:01:51 2021 kern.err kernel: [21742.873039] mt76_wmac 10300000.wmac: MCU message 08 (seq 8) timed out
Thu Jun 3 20:01:53 2021 kern.info kernel: [21744.922760] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
Thu Jun 3 20:01:53 2021 kern.info kernel: [21744.929532] br-lan: port 2(wlan0) entered blocking state
Thu Jun 3 20:01:53 2021 kern.info kernel: [21744.934979] br-lan: port 2(wlan0) entered forwarding state
Thu Jun 3 20:01:53 2021 daemon.notice netifd: Network device 'wlan0' link is up
Thu Jun 3 20:01:53 2021 daemon.notice hostapd: wlan0: interface state HT_SCAN->ENABLED
Thu Jun 3 20:01:53 2021 daemon.notice hostapd: wlan0: AP-ENABLED

wan connection drop
Thu Jun 3 20:08:38 2021 kern.err kernel: [22150.164143] mt76_wmac 10300000.wmac: MCU message 08 (seq 9) timed out
Thu Jun 3 20:08:43 2021 kern.err kernel: [22154.516085] mt76_wmac 10300000.wmac: MCU message 08 (seq 10) timed out
Thu Jun 3 20:08:49 2021 kern.err kernel: [22160.660009] mt76_wmac 10300000.wmac: MCU message 08 (seq 11) timed out
Thu Jun 3 20:08:54 2021 kern.err kernel: [22165.779948] mt76_wmac 10300000.wmac: MCU message 08 (seq 12) timed out
Thu Jun 3 20:08:59 2021 kern.err kernel: [22170.899888] mt76_wmac 10300000.wmac: MCU message 08 (seq 13) timed out
Thu Jun 3 20:09:04 2021 kern.err kernel: [22176.019826] mt76_wmac 10300000.wmac: MCU message 08 (seq 14) timed out
Thu Jun 3 20:09:09 2021 kern.err kernel: [22181.139765] mt76_wmac 10300000.wmac: MCU message 08 (seq 15) timed out
Thu Jun 3 20:09:15 2021 kern.err kernel: [22186.259707] mt76_wmac 10300000.wmac: MCU message 08 (seq 1) timed out
Thu Jun 3 20:09:20 2021 kern.err kernel: [22191.379642] mt76_wmac 10300000.wmac: MCU message 08 (seq 2) timed out
Thu Jun 3 20:09:25 2021 kern.err kernel: [22196.499585] mt76_wmac 10300000.wmac: MCU message 08 (seq 3) timed out
Thu Jun 3 20:09:30 2021 kern.err kernel: [22201.619520] mt76_wmac 10300000.wmac: MCU message 08 (seq 4) timed out
Thu Jun 3 20:09:35 2021 kern.err kernel: [22206.739463] mt76_wmac 10300000.wmac: MCU message 08 (seq 5) timed out
Thu Jun 3 20:09:40 2021 kern.err kernel: [22211.859397] mt76_wmac 10300000.wmac: MCU message 08 (seq 6) timed out
Thu Jun 3 20:09:45 2021 kern.err kernel: [22216.979335] mt76_wmac 10300000.wmac: MCU message 08 (seq 7) timed out
Thu Jun 3 20:09:50 2021 kern.err kernel: [22222.099276] mt76_wmac 10300000.wmac: MCU message 08 (seq 8) timed out
Thu Jun 3 20:09:55 2021 kern.err kernel: [22227.219215] mt76_wmac 10300000.wmac: MCU message 08 (seq 9) timed out
Thu Jun 3 20:10:01 2021 kern.err kernel: [22232.339153] mt76_wmac 10300000.wmac: MCU message 08 (seq 10) timed out
Thu Jun 3 20:10:06 2021 kern.err kernel: [22237.459096] mt76_wmac 10300000.wmac: MCU message 08 (seq 11) timed out
Thu Jun 3 20:10:11 2021 kern.err kernel: [22242.579030] mt76_wmac 10300000.wmac: MCU message 08 (seq 12) timed out
Thu Jun 3 20:10:16 2021 kern.err kernel: [22247.698970] mt76_wmac 10300000.wmac: MCU message 08 (seq 13) timed out
Thu Jun 3 20:10:21 2021 kern.err kernel: [22252.818917] mt76_wmac 10300000.wmac: MCU message 08 (seq 14) timed out
Thu Jun 3 20:10:26 2021 kern.err kernel: [22257.938869] mt76_wmac 10300000.wmac: MCU message 08 (seq 15) timed out
Thu Jun 3 20:10:31 2021 kern.err kernel: [22263.058788] mt76_wmac 10300000.wmac: MCU message 08 (seq 1) timed out
Thu Jun 3 20:10:36 2021 kern.err kernel: [22268.178725] mt76_wmac 10300000.wmac: MCU message 08 (seq 2) timed out
Thu Jun 3 20:10:42 2021 kern.err kernel: [22273.298665] mt76_wmac 10300000.wmac: MCU message 08 (seq 3) timed out
Thu Jun 3 20:10:47 2021 kern.err kernel: [22278.418620] mt76_wmac 10300000.wmac: MCU message 08 (seq 4) timed out
Thu Jun 3 20:10:52 2021 kern.err kernel: [22283.538544] mt76_wmac 10300000.wmac: MCU message 08 (seq 5) timed out
Thu Jun 3 20:10:57 2021 kern.err kernel: [22288.658776] mt76_wmac 10300000.wmac: MCU message 08 (seq 6) timed out
Thu Jun 3 20:28:51 2021 kern.info kernel: [23362.924721] rt3050-esw 10110000.esw: link changed 0x04

Wifi disconnects randomly and gets restored after restarting the router.

I think there might be bug in kernel driver or implementation of the driver not done properly with openwrt stable release.
thank you

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the attached kernel logs for the Xiaomi MI Router 4C on MT7628AN and trace the mt76_wmac MCU message timeout path in the driver. Reproduce the Wi-Fi and WAN drops on OpenWrt 21.02.0-rc2, then confirm that the driver no longer produces the repeated timeouts and that connectivity remains stable after restarting the radio.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
embedded-iot, networking, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.