Atheros WiFi card, uses 40MHz bandwidth

I have a small PC with IPfire, it has miniPCI WiFi card Atheros AR9462, IPfire is 2.29 (x86_64) core 202.

# lspci | grep Atheros
03:00.0 Network controller: Qualcomm Atheros AR9462 Wireless Network Adapter (rev 01)

I configured blue interface and it works but I see that WiFi AP is configured to 40MHz bandwidth even I explicitly configured bandwidth to 20 MHz in hostapd. I see it on my Android phone that runs application ‘WiFi scanner’. And I see it in ipfire, at hostapd page…

I selected mode IEEEE 802.11an/gn @20 MHz but it is ignored and I see:

Interface blue0
 	ifindex 4
 	wdev 0x1
 	addr 34:23:87:23:51:51
 	ssid IPFIRE
 	type AP
 	wiphy 0
 	channel 11 (2462 MHz), width: 40 MHz, center1: 2452 MHz
 	txpower 16.00 dBm
 	multicast TXQ:
 		qsz-byt	qsz-pkt	flows	drops	marks	overlmt	hashcol	tx-bytes	tx-packets
 		0	0	0	0	0	0	0	0		0

MODE=HT20 means '802.11an/gn @ 20 MHz:

# grep MODE /var/ipfire/wlanap/settings 
HW_MODE=
APMODE=on
MODE=HT20

This mini PC is Fujitsu Futro S920 with CPU AMD GX-222GC and it is connected to gigabit optical internet and speedtest.net shows that it can handle this internet speed without speed degradation (green interface)…

@pslpsl

To check, change #MODE=HT20 (remove it) in the configuration file. If you can, then reboot and set it in the GUI.

I confirm then when I comment line with out MODE then WiFi start starts to use only 20 MHz bandwidth. The same happens when I configure hostapd to mode ‘IEEE 802.11a/g @ 20 MHz’, then MODE is set to 20, I see in both cases the same status:

Interface blue0
 	ifindex 4
 	wdev 0x1
 	addr 34:23:87:23:51:51
 	ssid IPFIRE
 	type AP
 	wiphy 0
 	channel 11 (2462 MHz), width: 20 MHz (no HT), center1: 2462 MHz
 	txpower 16.00 dBm
 	multicast TXQ:
 		qsz-byt	qsz-pkt	flows	drops	marks	overlmt	hashcol	tx-bytes	tx-packets
 		0	0	0	0	0	0	0	0		0

I assume when line with MODE is commented out than mode is configured to 802.11a/g.

The WiFi status can be printed from CLI with command iw blue0 info. I do not know how to get WiFi standard that is used (802.11a/g, 802.11an/gn, 802.11ac, 802.11ax, …)

I understand that after implementing the suggested changes, it works as expected.
I believe the handling of WLAN configuration has changed in newer versions of IPFire.
If you migrated, you should comment out or remove all entries in the /var/ipfire/wlanap/settings file.
All changes to WLAN parameters are made through the GUI.

if you want to check what the wlan interface can do, use the iw list command

Additionally, any change in the wlan configuration can be seen in the Wireless Access Point Configuration tab (gui WiFi Status)

Regards

This is fresh install, I installed 201, upgraded to 202 and then configured the gateway.

iw list reports this:

...
	Supported interface modes:
		 * IBSS
		 * managed
		 * AP
		 * AP/VLAN
		 * monitor
		 * mesh point
		 * P2P-client
		 * P2P-GO
		 * outside context of a BSS
	Band 1:
		Capabilities: 0x11ef
			RX LDPC
			HT20/HT40
			SM Power Save disabled
			RX HT20 SGI
			RX HT40 SGI
			TX STBC
			RX STBC 1-stream
			Max AMSDU length: 3839 bytes
			DSSS/CCK HT40
...
	Band 2:
		Capabilities: 0x11ef
			RX LDPC
			HT20/HT40
			SM Power Save disabled
			RX HT20 SGI
			RX HT40 SGI
			TX STBC
			RX STBC 1-stream
			Max AMSDU length: 3839 bytes
			DSSS/CCK HT40
...

The problem isn’t based on the card, but the hostapd start operation.
The CU202 file /etc/init.d/hostapd doesn’t set 20MHz bandwidth.
CU203 has the correction.

So live with 40MHz until CU203 is published.

I upgraded to C203 a few minutes ago and that was a big mistake. DNS is broken. I cannot upgrade packages, to upgrade hostpad, ipfire gateway cannot resolve DNS, it cannot upgrade new packages. I cannot recommend upgrade to C203, the replacement of unbind with knot was not an easy task and C203 is just broken… :frowning:

I see even error on ipfire CLI, when I try host google.com, I see some strange errors from “C code”, I cannot copy it here becouse I cannot access computer behind ipfire, I work on a backup internet connection…

I see that WiFi still uses 40MHz bandwith even it is configured to use 20MHz but it could be fixed once `hostapd`` will be upgraded (once I will fix DNS).

DNS documentation was no updated with information about knot


I rebooted IPfire gateway. I changed DNS configuration from “TLS” to UDP and I can use IPfire again. When I switch back to TLS I see some issues.

I updated hostapd to the latest version and the issue with 40MHz bandwidth was fixed.


This was the error I saw when C202 was upgraded to C203 and DNS was not working after the first reboot. C203 console:

[root@ipfire ~]# host google.com
;; communications error to 127.0.0.1#53: connection refused
host: src/unix/udp.c:292: uv__udp_recvmsg: Assertion `handle->recv_cb != NULL' failed.
Aborted                    host google.com

[root@ipfire ~]# khost google.com
;; WARNING: response timeout for 127.0.0.1@53(UDP)
;; WARNING: response timeout for 127.0.0.1@53(UDP)
;; ERROR: failed to query server 127.0.0.1@53(UDP)
;; WARNING: response timeout for 127.0.0.1@53(UDP)
;; WARNING: response timeout for 127.0.0.1@53(UDP)
;; ERROR: failed to query server 127.0.0.1@53(UDP)
;; WARNING: response timeout for 127.0.0.1@53(UDP)