OpenWrt/LEDE Project

  • Status Unconfirmed
  • Percent Complete
    0%
  • Task Type Bug Report
  • Category Base system
  • Assigned To No-one
  • Operating System All
  • Severity Medium
  • Priority Very Low
  • Reported Version Trunk
  • Due in Version Undecided
  • Due Date Undecided
  • Private
Attached to Project: OpenWrt/LEDE Project
Opened by Marcin Jurkowski - 01.11.2020

FS#3421 - netifd: tries to claim VAP device before it's created

This is obviously a general issue but the problem was reported on Netgear RT6220. There are two 5 GHz (radio1, non-DFS channel) VAPs and five VAPs in total. Netifd debug log is attached.

When netifd tries to claim second 5 GHz VAP (wl1-gst) it fails with error message:

device_claim(447): claim Network device wl1-gst failed: -1

It seems that the second VAP had not been (yet) created by hostapd when netifd tried to claim it as if it lacked a proper synchronization with hostapd.

As a result:

  • wl1-gst device is never added as bridge member,
  • it permanently stays in “down” state:
# ubus call network.device status '{ "name": "wl1-gst" }'
{
	"external": true,
	"present": true,
	"type": "Network device",
	"up": false,
	"carrier": true,
	"statistics": {
                ...
	}
}
  • the second 5 GHz VAP is pretty much useless.

There’s no easy way to workaround this since each wifi reload command triggers the same routine.

Is it possible to fix netifd without a major rewrite? It seems that to consider each VAP ready as soon as hostapd is started, which is obviously not the case.

The problem was originally reported in FS#2698 but the workaround in https://github.com/openwrt/openwrt/pull/2848 treats only some symptoms. The root cause is still unaddressed.


Project Manager
Alexander Couzens commented on 08.01.2021 17:39

Can you check again?

The commit "system-linux: add retry for adding member devices to a bridge" should fixed it.

https://git.openwrt.org/?p=project/netifd.git;a=commit;h=3abe1fc87151fae570fc1232053c73d1a5505664

Marcin Jurkowski commented on 10.01.2021 20:54

Netifd version 2020-11-30-42c48866-1 seems to be working just fine (tested on two ramips devices).

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing