MT76 driver issues V19.07 - Feedback

Hi Everyone,

So im just doing this thread to get some feedback from owners of the mediatek routers that use the MT76 driver:

https://github.com/openwrt/mt76 - branch v19.07

At this point it doesnt matter what router you have with this chipset, there are a couple of issues in the V19.07 stable branch that haven't been seen in the V18.06 - from my experience so far.

I own and try to fix issues with my two routers, Unielec U7621-01 and Xiaomi Mir4A Gigabit.

Both boards have identical issue in terms of the wifi config issues.

There is two issues so far and a few minor annonyances:

  1. Setting Country code in the wireless/device configuration/advanced section, creates a situation where the clients connecting will keep doing this:

deauthenticating from *:*:*:*0f:A9 by local choice (Reason: 3=DEAUTH_LEAVING)

Which makes me believe there is some sort of driver > country code issue going on? - mismatch of codes?

This was not an issue on the V18.06 mt76 driver?

Using the hostapd not wpad

  1. Setting the 'Allow legacy 802.11b rates' limits the 'Maximum transmit power' to 13dBm and not the 20dBm its capable of?

Niggling issues:

The

hostapd: ACS: Survey is missing noise floor

spamming the kernel/system log area.

Well this issue is due to the fact for some reason? this is missing the code in the current V19.07 branch of the MT76 git repo?

I'm not sure what happened, but it seems this branch was cherry picked and missed out a load of important patches?

There are pull requests in that repo confirming the issue, but no response of acknowledgment has happened?

https://github.com/openwrt/mt76/issues/88

So feel free to add to this thread, any issue you may have only for V19.07 releases!

Then I can try and submit patches to fix these issues.

So the noise survey check routine is missing in the V19.07 branch, but in the compat branch

Unfortunatley there is missing patches that need this to work correctly.

Is there a fix to this error?

Fri Oct 30 22:04:29 2020 kern.info kernel: [178756.287278] mt76x2e 0000:01:00.0: Firmware Version: 0.0.00
Fri Oct 30 22:04:29 2020 kern.info kernel: [178756.292855] mt76x2e 0000:01:00.0: Build: 1
Fri Oct 30 22:04:29 2020 kern.info kernel: [178756.297108] mt76x2e 0000:01:00.0: Build Time: 201507311614____
Fri Oct 30 22:04:29 2020 kern.info kernel: [178756.325698] mt76x2e 0000:01:00.0: Firmware running!
Fri Oct 30 22:04:29 2020 kern.info kernel: [178756.335884] ieee80211 phy1: Hardware restart was requested
Fri Oct 30 22:04:32 2020 kern.info kernel: [178759.827186] mt76x2e 0000:01:00.0: Firmware Version: 0.0.00
Fri Oct 30 22:04:32 2020 kern.info kernel: [178759.832763] mt76x2e 0000:01:00.0: Build: 1
Fri Oct 30 22:04:32 2020 kern.info kernel: [178759.837002] mt76x2e 0000:01:00.0: Build Time: 201507311614____
Fri Oct 30 22:04:32 2020 kern.info kernel: [178759.865576] mt76x2e 0000:01:00.0: Firmware running!
Fri Oct 30 22:04:32 2020 kern.info kernel: [178759.875742] ieee80211 phy1: Hardware restart was requested

This issue had this workaround added

This is the reason you see this happening. The older mt76 drivers never had this workaround so was silently restarting without the user noticing.

The actual issue is that the PSU doesnt have enough juice, so what happens is the wifi chips are pooping out. My advise is change to a 12v 3A psu. Fixed this issue, based on feedback i've recieved.

If the problem is the PSU, why with the stock firmware in the Xiaomi Mi 4A Gigabit router this Wi-Fi disconnection error does not appear?

Really old kernel 3.10 and there own mt76 driver, your probably find your router is quietly restarting its wifi chip.

The openwrt later mt76 code has more diag messages, so the reason people have noticed these errors come up.

I've had user feedback saying a better psu has fixed this issue for them.

If this hasn't fixed it for you, then my new changes coming might help?

Just a note about this, the git commit for V19.07.4 for the mt76 driver seems to be missing alot of key patches, i'm hoping my new build with the patches applied will fix your issue?

1 Like

I hope your patches help, by the way, thank you for your work.

1 Like

I'd be interested in how you arrived at the conclusion this change would help here?
Is there some pre-processing of this setting that results in bad info being put into /var/run/hostapd-phy0.conf ?

All that country setting does (AFAIK) is limit the choices in the UI (and UCI) for channels / widths, etc. to maintain regulatory compliance with the specified country.
Your 'fix' might be due to the driver defaulting to 'world' as the 'region' and it's using channels & other settings (in 'auto') that work better than the ones you are limited to for PL.

Since I also see plenty of connect disconnect sequences, I'm interested in fixing those. But this is a bit suspect.

Here's what I see in my logs:

Mon Dec  7 16:44:40 2020 daemon.notice hostapd: wlan0: AP-STA-DISCONNECTED 00:51:ed:f2:cc:96
Mon Dec  7 16:44:40 2020 daemon.notice hostapd: wlan0: AP-STA-CONNECTED 00:51:ed:f2:cc:96
Mon Dec  7 16:44:40 2020 daemon.notice hostapd: wlan0: AP-STA-DISCONNECTED 00:51:ed:f2:cc:96
Mon Dec  7 16:45:13 2020 daemon.notice hostapd: wlan0: AP-STA-CONNECTED 00:51:ed:f2:cc:96
Mon Dec  7 16:46:08 2020 daemon.notice hostapd: wlan0: AP-STA-DISCONNECTED 00:51:ed:f2:cc:96
Mon Dec  7 16:46:08 2020 daemon.notice hostapd: wlan0: AP-STA-CONNECTED 00:51:ed:f2:cc:96
Mon Dec  7 16:46:08 2020 daemon.notice hostapd: wlan0: AP-STA-DISCONNECTED 00:51:ed:f2:cc:96
Mon Dec  7 16:46:10 2020 daemon.notice hostapd: wlan0: AP-STA-CONNECTED 00:51:ed:f2:cc:96

So based on my first experience on the V19.07 branch of the mt76 git repo.

The two routers using this driver, would keep disconnecting client with this message, if the country code is other than 'World' setting.

Your assumption is probably correct and that the world settings satisfy the frequencies it needs. There was so much broken functionality on this V19.07 branch, i switched to the 'compat' branch then backported recent fixes.

From then on i no longer had this issue. There was so many missing patches in the V19.07 branch, i just used the compat in the end.

I'm in the process of porting across the mtwifi drivers, these are drivers from a chinese git repo, they seem to compatible with the V19.07 branch. Only issue is they have their own luci interface for changing wireless control.

But i just wanted to see how good the drivers are.

3 Likes

I have the same issues on my Newifi D2 (similar hardware), along with client disconnects, the switch driver(?) seems to crash. I'm happy to help test or may try and follow your path of building something on my own @db260179, although I'm more of a hack and will have to brush up on what it would take to compile and patch things. Let us know if you succeed in porting the mtwifi drivers.

1 Like

I have the same issue on a Newifi D2 too. Have you tried to upgrade the power supply or could you fix it somehow?

Welcome to the forum @helicida! I did try a 3 amp power supply with no success. Padavan firmware does work great on the device, but I would prefer OpenWRT for many reasons.

2 Likes