Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UniFi 6 LR status page - internal server error 500 #3020

Closed
Djfe opened this issue Oct 14, 2023 · 9 comments · Fixed by #3223
Closed

UniFi 6 LR status page - internal server error 500 #3020

Djfe opened this issue Oct 14, 2023 · 9 comments · Fixed by #3223
Assignees

Comments

@Djfe
Copy link
Contributor

Djfe commented Oct 14, 2023

Bug report

What is the problem?
the status page on a UniFi 6 LR errors like this (probably affects all version, this one is a v3, PR pending)
see http://[2a03:2260:3006:115:6222:32ff:fe6a:37d5]/cgi-bin/status

500 Interner Serverfehler

Entschuldigung, auf dem Server ist ein unerwarteter Fehler aufgetreten.

Failed to execute dispatcher target for entry '/'.
The called action terminated with an exception:
/usr/lib/lua/gluon/web/template.lua:43: Failed to execute template 'status-page'.
A runtime error occurred: /usr/lib/lua/gluon/wireless.lua:26: attempt to concatenate field '?' (a nil value)

What is the expected behaviour?
Status page should render

Gluon Version:
1b6ddac (master 2 weeks ago)

Site Configuration:
https://github.com/ffac/site/tree/v2023.2.0-5

Custom patches:
quite a few, but none affecting gluon-core
https://github.com/ffac/site/tree/v2023.2.0-5/patches

I started debugging the issue, line 26 is effectively this one:

return 'phy' .. device_phy_idxs[tonumber(phy_offset) + 1]

The issue appears to stem from a line above:
local phy_idx = v:match('^phy(%d+)$')

If I understand it correctly, it expects wiphys to contain phy in their name in order to extract the correct phy_idx.
This device has (atleast since OpenWrt 23) the phy names wl0 and wl1

root@DN-Viktoria-Str-46:/sys/devices# find . | grep ieee80211
./platform/18000000.wmac/ieee80211
./platform/18000000.wmac/ieee80211/wl0
./platform/18000000.wmac/ieee80211/wl0/uevent
./platform/18000000.wmac/ieee80211/wl0/power
./platform/18000000.wmac/ieee80211/wl0/power/runtime_active_time
./platform/18000000.wmac/ieee80211/wl0/power/runtime_status
./platform/18000000.wmac/ieee80211/wl0/power/autosuspend_delay_ms
./platform/18000000.wmac/ieee80211/wl0/power/runtime_suspended_time
./platform/18000000.wmac/ieee80211/wl0/power/control
./platform/18000000.wmac/ieee80211/wl0/macaddress
./platform/18000000.wmac/ieee80211/wl0/device
./platform/18000000.wmac/ieee80211/wl0/index
./platform/18000000.wmac/ieee80211/wl0/hwmon0
./platform/18000000.wmac/ieee80211/wl0/hwmon0/uevent
./platform/18000000.wmac/ieee80211/wl0/hwmon0/of_node
./platform/18000000.wmac/ieee80211/wl0/hwmon0/power
./platform/18000000.wmac/ieee80211/wl0/hwmon0/power/runtime_active_time
./platform/18000000.wmac/ieee80211/wl0/hwmon0/power/runtime_status
./platform/18000000.wmac/ieee80211/wl0/hwmon0/power/autosuspend_delay_ms
./platform/18000000.wmac/ieee80211/wl0/hwmon0/power/runtime_suspended_time
./platform/18000000.wmac/ieee80211/wl0/hwmon0/power/control
./platform/18000000.wmac/ieee80211/wl0/hwmon0/device
./platform/18000000.wmac/ieee80211/wl0/hwmon0/subsystem
./platform/18000000.wmac/ieee80211/wl0/hwmon0/temp1_input
./platform/18000000.wmac/ieee80211/wl0/hwmon0/name
./platform/18000000.wmac/ieee80211/wl0/addresses
./platform/18000000.wmac/ieee80211/wl0/subsystem
./platform/18000000.wmac/ieee80211/wl0/address_mask
./platform/18000000.wmac/ieee80211/wl0/name
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/uevent
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/power
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/power/runtime_active_time
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/power/runtime_status
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/power/autosuspend_delay_ms
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/power/runtime_suspended_time
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/power/control
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/macaddress
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/device
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/index
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/cooling_device
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/addresses
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/subsystem
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/address_mask
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/uevent
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/of_node
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/power
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/power/runtime_active_time
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/power/runtime_status
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/power/autosuspend_delay_ms
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/power/runtime_suspended_time
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/power/control
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/temp1_crit
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/device
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/throttle1
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/subsystem
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/temp1_input
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/temp1_max
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/hwmon1/name
./platform/1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/ieee80211/wl1/name
@Djfe
Copy link
Contributor Author

Djfe commented Oct 14, 2023

Related commits from Oct. 14th 2022:
https://github.com/openwrt/openwrt/commits?author=nbd168&before=359a6e36e972c06845ffff750f200bca3a95c724+251
openwrt/openwrt@4d32330

I assume, we can use get_board_phy_name() from netifd now

@rotanid
Copy link
Member

rotanid commented Oct 14, 2023

@neocturne what do you think, editing the match-regex to include wl* or using something like get_board_phy_name() method?

@neocturne
Copy link
Member

I would like to understand where this name change comes from first. Is hostapd or some related script doing this? Can we be sure that all PHYs are always consistently renamed? Can we have a phyX and wlX devices with the same X?

@rotanid
Copy link
Member

rotanid commented Oct 16, 2023

I would like to understand where this name change comes from first. Is hostapd or some related script doing this? Can we be sure that all PHYs are always consistently renamed? Can we have a phyX and wlX devices with the same X?

hm, @Djfe linked the commits, did you see them?

@rotanid rotanid added this to the v2023.2 milestone Dec 3, 2023
@blocktrron blocktrron self-assigned this Dec 12, 2023
@blocktrron
Copy link
Member

Can't reproduce with a v1. This image is from the Gluon CI.

@Djfe Please build an image with the minimal-site from the Gluon repo and see if you can reproduce the problem.

As this issue does not affect devices already supported by Gluon (This ticket is for a not-yet supported revision), I remove it from the milestone and would like to close it in the next days if no objections arise.

root@68d79a45b465:/sys/devices# find . | grep ieee80211 | grep wl
root@68d79a45b465:/sys/devices# cat /etc/os-release 
NAME="OpenWrt"
VERSION="23.05-SNAPSHOT"
ID="openwrt"
ID_LIKE="lede openwrt"
PRETTY_NAME="OpenWrt 23.05-SNAPSHOT"
VERSION_ID="23.05-snapshot"
HOME_URL="https://openwrt.org/"
BUG_URL="https://bugs.openwrt.org/"
SUPPORT_URL="https://forum.openwrt.org/"
BUILD_ID="r23661+7-efdafcc974"
OPENWRT_BOARD="mediatek/mt7622"
OPENWRT_ARCH="aarch64_cortex-a53"
OPENWRT_TAINTS=""
OPENWRT_DEVICE_MANUFACTURER="OpenWrt"
OPENWRT_DEVICE_MANUFACTURER_URL="https://openwrt.org/"
OPENWRT_DEVICE_PRODUCT="Generic"
OPENWRT_DEVICE_REVISION="v0"
OPENWRT_RELEASE="OpenWrt 23.05-SNAPSHOT r23661+7-efdafcc974"
root@68d79a45b465:/sys/devices# iw phy
Wiphy phy1
	wiphy index: 1
	max # scan SSIDs: 4
	max scan IEs length: 2190 bytes
	max # sched scan SSIDs: 0
	max # match sets: 0
	Retry short limit: 7
	Retry long limit: 4
	Coverage class: 0 (up to 0m)
	Device supports AP-side u-APSD.
	Device supports T-DLS.
	Available Antennas: TX 0xf RX 0xf
	Configured Antennas: TX 0xf RX 0xf
	Supported interface modes:
		 * IBSS
		 * managed
		 * AP
		 * AP/VLAN
		 * monitor
		 * mesh point
		 * P2P-client
		 * P2P-GO
	Band 2:
		Capabilities: 0x9ff
			RX LDPC
			HT20/HT40
			SM Power Save disabled
			RX Greenfield
			RX HT20 SGI
			RX HT40 SGI
			TX STBC
			RX STBC 1-stream
			Max AMSDU length: 7935 bytes
			No DSSS/CCK HT40
		Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
		Minimum RX AMPDU time spacing: 4 usec (0x05)
		HT TX/RX MCS rate indexes supported: 0-31
		VHT Capabilities (0x739b79f1):
			Max MPDU length: 7991
			Supported Channel Width: 160Mhz (1/2 NSS) 
			RX LDPC
			short GI (80 MHz)
			short GI (160/80+80 MHz)
			TX STBC
			SU Beamformer
			SU Beamformee
			MU Beamformer
			MU Beamformee
			RX antenna pattern consistency
			TX antenna pattern consistency
		VHT RX MCS set:
			1 streams: MCS 0-9
			2 streams: MCS 0-9
			3 streams: MCS 0-9
			4 streams: MCS 0-9
			5 streams: not supported
			6 streams: not supported
			7 streams: not supported
			8 streams: not supported
		VHT RX highest supported: 0 Mbps
		VHT TX MCS set:
			1 streams: MCS 0-9
			2 streams: MCS 0-9
			3 streams: MCS 0-9
			4 streams: MCS 0-9
			5 streams: not supported
			6 streams: not supported
			7 streams: not supported
			8 streams: not supported
		VHT TX highest supported: 0 Mbps
		VHT extended NSS: supported
		HE Iftypes: managed
			HE MAC Capabilities (0x08011a000040):
				+HTC HE Supported
				Trigger Frame MAC Padding Duration: 2
				OM Control
				Maximum A-MPDU Length Exponent: 3
				A-MSDU in A-MPDU
			HE PHY Capabilities: (0x4c700e126d00f3164e3f00):
				HE40/HE80/5GHz
				HE160/5GHz
				242 tone RUs/5GHz
				Device Class: 1
				LDPC Coding in Payload
				HE SU PPDU with 1x HE-LTF and 0.8us GI
				NDP with 4x HE-LTF and 3.2us GI
				STBC Tx <= 80MHz
				STBC Rx <= 80MHz
				DCM Max Constellation: 2
				DCM Max Constellation Rx: 2
				SU Beamformee
				Beamformee STS <= 80Mhz: 3
				Beamformee STS > 80Mhz: 3
				Codebook Size SU Feedback
				Codebook Size MU Feedback
				Triggered CQI Feedback
				Partial Bandwidth Extended Range
				Partial Bandwidth DL MU-MIMO
				PPE Threshold Present
				Power Boost Factor ar
				HE SU PPDU & HE PPDU 4x HE-LTF 0.8us GI
				Max NC: 2
				20MHz in 40MHz HE PPDU 2.4GHz
				20MHz in 160/80+80MHz HE PPDU
				80MHz in 160/80+80MHz HE PPDU
				DCM Max BW: 1
				Longer Than 16HE SIG-B OFDM Symbols
				Non-Triggered CQI Feedback
				TX 1024-QAM
				RX 1024-QAM
				RX Full BW SU Using HE MU PPDU with Compression SIGB
				RX Full BW SU Using HE MU PPDU with Non-Compression SIGB
			HE RX MCS and NSS set <= 80 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: MCS 0-11
				4 streams: MCS 0-11
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
			HE TX MCS and NSS set <= 80 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: MCS 0-11
				4 streams: MCS 0-11
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
			HE RX MCS and NSS set 160 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: not supported
				4 streams: not supported
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
			HE TX MCS and NSS set 160 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: not supported
				4 streams: not supported
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
			PPE Threshold 0x3b 0x1c 0xc7 0x71 0x1c 0xc7 0x71 0x1c 0xc7 0x71 
		EHT Iftypes: managed
			EHT MAC Capabilities (0x0000):
			EHT PHY Capabilities: (0x0000000000000000):
			EHT MCS/NSS: (0x):
			EHT bw <= 80 MHz, max NSS for MCS 8-9: Rx=0, Tx=0
			EHT bw <= 80 MHz, max NSS for MCS 10-11: Rx=0, Tx=0
			EHT bw <= 80 MHz, max NSS for MCS 12-13: Rx=0, Tx=0
			EHT bw=160 MHz, max NSS for MCS 8-9: Rx=0, Tx=0
			EHT bw=160 MHz, max NSS for MCS 10-11: Rx=0, Tx=0
			EHT bw=160 MHz, max NSS for MCS 12-13: Rx=0, Tx=0
		HE Iftypes: AP
			HE MAC Capabilities (0x00051a081044):
				+HTC HE Supported
				TWT Responder
				BSR
				OM Control
				Maximum A-MPDU Length Exponent: 3
				BQR
				A-MSDU in A-MPDU
				OM Control UL MU Data Disable RX
			HE PHY Capabilities: (0x0c200e926f0baf10000c00):
				HE40/HE80/5GHz
				HE160/5GHz
				LDPC Coding in Payload
				NDP with 4x HE-LTF and 3.2us GI
				STBC Tx <= 80MHz
				STBC Rx <= 80MHz
				DCM Max Constellation: 2
				DCM Max Constellation Rx: 2
				SU Beamformer
				SU Beamformee
				MU Beamformer
				Beamformee STS <= 80Mhz: 3
				Beamformee STS > 80Mhz: 3
				Sounding Dimensions <= 80Mhz: 3
				Sounding Dimensions > 80Mhz: 1
				Codebook Size SU Feedback
				Codebook Size MU Feedback
				Triggered SU Beamforming Feedback
				Triggered MU Beamforming Feedback
				Partial Bandwidth Extended Range
				PPE Threshold Present
				Max NC: 2
				TX 1024-QAM
				RX 1024-QAM
			HE RX MCS and NSS set <= 80 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: MCS 0-11
				4 streams: MCS 0-11
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
			HE TX MCS and NSS set <= 80 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: MCS 0-11
				4 streams: MCS 0-11
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
			HE RX MCS and NSS set 160 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: not supported
				4 streams: not supported
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
			HE TX MCS and NSS set 160 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: not supported
				4 streams: not supported
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
			PPE Threshold 0x3b 0x1c 0xc7 0x71 0x1c 0xc7 0x71 0x1c 0xc7 0x71 
		EHT Iftypes: AP
			EHT MAC Capabilities (0x0000):
			EHT PHY Capabilities: (0x0000000000000000):
			EHT MCS/NSS: (0x):
			EHT bw <= 80 MHz, max NSS for MCS 8-9: Rx=0, Tx=0
			EHT bw <= 80 MHz, max NSS for MCS 10-11: Rx=0, Tx=0
			EHT bw <= 80 MHz, max NSS for MCS 12-13: Rx=0, Tx=0
			EHT bw=160 MHz, max NSS for MCS 8-9: Rx=0, Tx=0
			EHT bw=160 MHz, max NSS for MCS 10-11: Rx=0, Tx=0
			EHT bw=160 MHz, max NSS for MCS 12-13: Rx=0, Tx=0
		HE Iftypes: mesh point
			HE MAC Capabilities (0x00011a000040):
				+HTC HE Supported
				OM Control
				Maximum A-MPDU Length Exponent: 3
				A-MSDU in A-MPDU
			HE PHY Capabilities: (0x0c200c0000000000008000):
				HE40/HE80/5GHz
				HE160/5GHz
				LDPC Coding in Payload
				STBC Tx <= 80MHz
				STBC Rx <= 80MHz
			HE RX MCS and NSS set <= 80 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: MCS 0-11
				4 streams: MCS 0-11
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
			HE TX MCS and NSS set <= 80 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: MCS 0-11
				4 streams: MCS 0-11
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
			HE RX MCS and NSS set 160 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: not supported
				4 streams: not supported
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
			HE TX MCS and NSS set 160 MHz
				1 streams: MCS 0-11
				2 streams: MCS 0-11
				3 streams: not supported
				4 streams: not supported
				5 streams: not supported
				6 streams: not supported
				7 streams: not supported
				8 streams: not supported
		EHT Iftypes: mesh point
			EHT MAC Capabilities (0x0000):
			EHT PHY Capabilities: (0x0000000000000000):
			EHT MCS/NSS: (0x):
			EHT bw <= 80 MHz, max NSS for MCS 8-9: Rx=0, Tx=0
			EHT bw <= 80 MHz, max NSS for MCS 10-11: Rx=0, Tx=0
			EHT bw <= 80 MHz, max NSS for MCS 12-13: Rx=0, Tx=0
			EHT bw=160 MHz, max NSS for MCS 8-9: Rx=0, Tx=0
			EHT bw=160 MHz, max NSS for MCS 10-11: Rx=0, Tx=0
			EHT bw=160 MHz, max NSS for MCS 12-13: Rx=0, Tx=0
		Frequencies:
			* 5180 MHz [36] (23.0 dBm)
			* 5200 MHz [40] (23.0 dBm)
			* 5220 MHz [44] (23.0 dBm)
			* 5240 MHz [48] (23.0 dBm)
			* 5260 MHz [52] (20.0 dBm) (radar detection)
			* 5280 MHz [56] (20.0 dBm) (radar detection)
			* 5300 MHz [60] (20.0 dBm) (radar detection)
			* 5320 MHz [64] (20.0 dBm) (radar detection)
			* 5500 MHz [100] (26.0 dBm) (radar detection)
			* 5520 MHz [104] (26.0 dBm) (radar detection)
			* 5540 MHz [108] (26.0 dBm) (radar detection)
			* 5560 MHz [112] (26.0 dBm) (radar detection)
			* 5580 MHz [116] (26.0 dBm) (radar detection)
			* 5600 MHz [120] (26.0 dBm) (radar detection)
			* 5620 MHz [124] (26.0 dBm) (radar detection)
			* 5640 MHz [128] (26.0 dBm) (radar detection)
			* 5660 MHz [132] (26.0 dBm) (radar detection)
			* 5680 MHz [136] (26.0 dBm) (radar detection)
			* 5700 MHz [140] (26.0 dBm) (radar detection)
			* 5720 MHz [144] (13.0 dBm) (radar detection)
			* 5745 MHz [149] (13.0 dBm)
			* 5765 MHz [153] (13.0 dBm)
			* 5785 MHz [157] (13.0 dBm)
			* 5805 MHz [161] (13.0 dBm)
			* 5825 MHz [165] (13.0 dBm)
			* 5845 MHz [169] (13.0 dBm)
			* 5865 MHz [173] (13.0 dBm)
			* 5885 MHz [177] (disabled)
	valid interface combinations:
		 * #{ IBSS } <= 1, #{ AP, mesh point } <= 16, #{ managed } <= 19,
		   total <= 19, #channels <= 1, STA/AP BI must match, radar detect widths: { 20 MHz (no HT), 20 MHz, 40 MHz, 80 MHz, 160 MHz }

	HT Capability overrides:
		 * MCS: ff ff ff ff ff ff ff ff ff ff
		 * maximum A-MSDU length
		 * supported channel width
		 * short GI for 40 MHz
		 * max A-MPDU length exponent
		 * min MPDU start spacing
	max # scan plans: 1
	max scan plan interval: -1
	max scan plan iterations: 0
	Supported extended features:
		* [ VHT_IBSS ]: VHT-IBSS
		* [ RRM ]: RRM
		* [ BEACON_RATE_LEGACY ]: legacy beacon rate setting
		* [ BEACON_RATE_HT ]: HT beacon rate setting
		* [ BEACON_RATE_VHT ]: VHT beacon rate setting
		* [ FILS_STA ]: STA FILS (Fast Initial Link Setup)
		* [ CQM_RSSI_LIST ]: multiple CQM_RSSI_THOLD records
		* [ CONTROL_PORT_OVER_NL80211 ]: control port over nl80211
		* [ ACK_SIGNAL_SUPPORT ]: ack signal level support
		* [ TXQS ]: FQ-CoDel-enabled intermediate TXQs
		* [ SCAN_RANDOM_SN ]: use random sequence numbers in scans
		* [ SCAN_MIN_PREQ_CONTENT ]: use probe request with only rate IEs in scans
		* [ CAN_REPLACE_PTK0 ]: can safely replace PTK 0 when rekeying
		* [ AIRTIME_FAIRNESS ]: airtime fairness scheduling
		* [ AQL ]: Airtime Queue Limits (AQL)
		* [ CONTROL_PORT_NO_PREAUTH ]: disable pre-auth over nl80211 control port support
		* [ DEL_IBSS_STA ]: deletion of IBSS station support
		* [ SCAN_FREQ_KHZ ]: scan on kHz frequency support
		* [ CONTROL_PORT_OVER_NL80211_TX_STATUS ]: tx status for nl80211 control port support
		* [ FILS_DISCOVERY ]: FILS discovery frame transmission support
		* [ UNSOL_BCAST_PROBE_RESP ]: unsolicated broadcast probe response transmission support
		* [ BEACON_RATE_HE ]: HE beacon rate support (AP/mesh)
		* [ BSS_COLOR ]: BSS coloring support
		* [ RADAR_BACKGROUND ]: Radar background support
Wiphy phy0
	wiphy index: 0
	max # scan SSIDs: 4
	max scan IEs length: 2304 bytes
	max # sched scan SSIDs: 0
	max # match sets: 0
	Retry short limit: 7
	Retry long limit: 4
	Coverage class: 0 (up to 0m)
	Device supports AP-side u-APSD.
	Device supports T-DLS.
	Available Antennas: TX 0xf RX 0xf
	Configured Antennas: TX 0xf RX 0xf
	Supported interface modes:
		 * IBSS
		 * managed
		 * AP
		 * AP/VLAN
		 * monitor
		 * mesh point
		 * P2P-client
		 * P2P-GO
	Band 1:
		Capabilities: 0x1ff
			RX LDPC
			HT20/HT40
			SM Power Save disabled
			RX Greenfield
			RX HT20 SGI
			RX HT40 SGI
			TX STBC
			RX STBC 1-stream
			Max AMSDU length: 3839 bytes
			No DSSS/CCK HT40
		Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
		Minimum RX AMPDU time spacing: No restriction (0x00)
		HT TX/RX MCS rate indexes supported: 0-31
		Frequencies:
			* 2412 MHz [1] (20.0 dBm)
			* 2417 MHz [2] (20.0 dBm)
			* 2422 MHz [3] (20.0 dBm)
			* 2427 MHz [4] (20.0 dBm)
			* 2432 MHz [5] (20.0 dBm)
			* 2437 MHz [6] (20.0 dBm)
			* 2442 MHz [7] (20.0 dBm)
			* 2447 MHz [8] (20.0 dBm)
			* 2452 MHz [9] (20.0 dBm)
			* 2457 MHz [10] (20.0 dBm)
			* 2462 MHz [11] (20.0 dBm)
			* 2467 MHz [12] (20.0 dBm)
			* 2472 MHz [13] (20.0 dBm)
			* 2484 MHz [14] (disabled)
	valid interface combinations:
		 * #{ IBSS } <= 1, #{ managed, AP, mesh point, P2P-client, P2P-GO } <= 16,
		   total <= 16, #channels <= 1, STA/AP BI must match, radar detect widths: { 20 MHz (no HT), 20 MHz, 40 MHz, 80 MHz, 80+80 MHz, 160 MHz }

	HT Capability overrides:
		 * MCS: ff ff ff ff ff ff ff ff ff ff
		 * maximum A-MSDU length
		 * supported channel width
		 * short GI for 40 MHz
		 * max A-MPDU length exponent
		 * min MPDU start spacing
	max # scan plans: 1
	max scan plan interval: 0
	max scan plan iterations: 0
	Supported extended features:
		* [ VHT_IBSS ]: VHT-IBSS
		* [ RRM ]: RRM
		* [ SET_SCAN_DWELL ]: scan dwell setting
		* [ FILS_STA ]: STA FILS (Fast Initial Link Setup)
		* [ CQM_RSSI_LIST ]: multiple CQM_RSSI_THOLD records
		* [ CONTROL_PORT_OVER_NL80211 ]: control port over nl80211
		* [ TXQS ]: FQ-CoDel-enabled intermediate TXQs
		* [ CAN_REPLACE_PTK0 ]: can safely replace PTK 0 when rekeying
		* [ AIRTIME_FAIRNESS ]: airtime fairness scheduling
		* [ AQL ]: Airtime Queue Limits (AQL)
		* [ CONTROL_PORT_NO_PREAUTH ]: disable pre-auth over nl80211 control port support
		* [ DEL_IBSS_STA ]: deletion of IBSS station support
		* [ SCAN_FREQ_KHZ ]: scan on kHz frequency support
		* [ CONTROL_PORT_OVER_NL80211_TX_STATUS ]: tx status for nl80211 control port support
root@68d79a45b465:/sys/devices# 


@blocktrron blocktrron removed this from the v2023.2 milestone Dec 16, 2023
@maurerle
Copy link
Member

maurerle commented Jan 9, 2024

Seems like the interface names are nowadays taken from the board.json:
openwrt/openwrt@7f9d3a0#diff-65a80e521d1a8019e3118a4cb3eda1c5400643f0acf7c16a555514fb5563e770R655

This is enabled for some devices mt7622
openwrt/openwrt@34054e4

~# cat /etc/board.json 
{
	"model": {
		"id": "ubnt,unifi-6-lr-v3",
		"name": "Ubiquiti UniFi 6 LR v3"
	},
	"network": {
		"lan": {
			"device": "eth0",
			"protocol": "static"
		}
	},
	"wlan": {
		"wl0": {
			"path": "platform/18000000.wmac"
		},
		"wl1": {
			"path": "1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0"
		}
	}
}

I think this issue has also been seen on a NETGEAR WAX206.

@maurerle
Copy link
Member

maurerle commented Jan 9, 2024

Executing a script with:

. /lib/netifd/wireless/mac80211.sh
get_board_phy_name "platform/18000000.wmac"
get_board_phy_name "1a143000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0"

returns

wl0
wl1

So I think that moving to get_board_phy_name is the correct fix instead of the hardcoded "phy" in package/gluon-core/luasrc/usr/lib/lua/gluon/wireless.lua

UPDATE: Well I was wrong - get_board_phy_name does not return anything for devices which do not have the wifi information in the board.json :(

Why can't we just use something like ls /sys/class/ieee80211 to iterate over the names instead?

@kpanic23
Copy link
Contributor

Just replaced my node at home with a Xiaomi AX3200, it seems to be affected as well.

@rotanid
Copy link
Member

rotanid commented Mar 26, 2024

@Djfe @maurerle @kpanic23 this should be fixed in master branch after #3223

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants