[Solved] WRT32X: How can I get DFS channels to work?

I've got a Linksys WRT32X running OpenWRT 19.07.2. It's a UK model and according to Linksys is capable of up to channel 140 at 160 Hz width. I'm located in Belgium, but I believe the legal frequency channels still follow the same legislation. However, when I try to change to any channel higher than 48 the WiFi adapter gets disabled.

Here's a snippet of what I think are the relevant logs:

Sun Apr 19 11:36:31 2020 daemon.notice hostapd: wlan0: interface state HT_SCAN->DFS
Sun Apr 19 11:36:31 2020 daemon.notice hostapd: wlan0: DFS-CAC-START freq=5660 chan=132 sec_chan=1, width=0, seg0=134, seg1=0, cac_time=60s
Sun Apr 19 11:36:31 2020 daemon.err hostapd: DFS start_dfs_cac() failed, -1
Sun Apr 19 11:36:31 2020 daemon.err hostapd: Interface initialization failed
Sun Apr 19 11:36:31 2020 daemon.notice hostapd: wlan0: interface state DFS->DISABLED
Sun Apr 19 11:36:31 2020 daemon.notice hostapd: wlan0: AP-DISABLED
Sun Apr 19 11:36:31 2020 daemon.notice hostapd: wlan0: interface state DISABLED->DISABLED
Sun Apr 19 11:36:31 2020 daemon.notice hostapd: wlan0: AP-DISABLED
Sun Apr 19 11:36:31 2020 daemon.notice hostapd: wlan0: CTRL-EVENT-TERMINATING
Sun Apr 19 11:36:31 2020 daemon.err hostapd: hostapd_free_hapd_data: Interface wlan0 wasn't started
Sun Apr 19 11:36:31 2020 daemon.notice hostapd: nl80211: deinit ifname=wlan0 disabled_11b_rates=0

I'm not sure what this exactly means. Is DFS something I need to enable manually? Or is there something wrong with my hardware?

I found this older thread that seems to be the same issue but there wasn't any resolution.

DFS is said to be one of the weak points of mwlwifi, which probably won't get fixed anymore. Yes, it works on paper, but the DFS algorithms are way too sensitive and flag unrelated noise as DFS events - and off you are (apparently it also doesn't recover too gracefully).

1 Like

I found this github discussion talking about issues with the mwlwifi driver. It's way beyond my current understanding as a curious novice user.

It looks like various people have implemented fixes for this driver, but that these fixes have not (and likely will not) been merged into the master branch.

And if I understand correctly the OEM mwlwifi driver for WRT32X-UK works with the DFS channels.

Is it possible for me to somehow use the original OEM driver with OpenWRT or even to install one of these drivers discussed in the github page without building my own package?

I gotcha. Do you know which drivers have better support for DFS (or just better support in general)? In case I decide to buy a new router.

I've never had issues with DFS on ath10k.

1 Like

Cool, thanks

the DFS algorithms (on mwlwifi) are way too sensitive and flag unrelated noise as DFS events

Let's not guess, let's ask the OP for the system log (show all the lines about hostapd and +/- 1 minute near them). It would clearly show all DFS events. E.g. on my TP-Link Archer C7 v2 (with ath10k), it looks like this:

Sun Apr 19 13:34:43 2020 daemon.err hostapd: Configuration file: /var/run/hostapd-phy0.conf
Sun Apr 19 13:34:45 2020 kern.warn kernel: [1543051.510204] ath10k_pci 0000:00:00.0: 10.1 wmi init: vdevs: 16  peers: 127  tid: 256
Sun Apr 19 13:34:45 2020 kern.info kernel: [1543051.527845] ath10k_pci 0000:00:00.0: wmi print 'P 128 V 8 T 410'
Sun Apr 19 13:34:45 2020 kern.info kernel: [1543051.534163] ath10k_pci 0000:00:00.0: wmi print 'msdu-desc: 1424  sw-crypt: 0 ct-sta: 0'
Sun Apr 19 13:34:45 2020 kern.info kernel: [1543051.542507] ath10k_pci 0000:00:00.0: wmi print 'alloc rem: 20920 iram: 26344'
Sun Apr 19 13:34:45 2020 kern.warn kernel: [1543051.611219] ath10k_pci 0000:00:00.0: pdev param 0 not supported by firmware
Sun Apr 19 13:34:45 2020 kern.info kernel: [1543051.626790] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
Sun Apr 19 13:34:45 2020 kern.info kernel: [1543051.660735] br-lan: port 2(wlan0) entered blocking state
Sun Apr 19 13:34:45 2020 kern.info kernel: [1543051.666383] br-lan: port 2(wlan0) entered disabled state
Sun Apr 19 13:34:45 2020 kern.info kernel: [1543051.672204] device wlan0 entered promiscuous mode
Sun Apr 19 13:34:45 2020 daemon.notice hostapd: wlan0: interface state UNINITIALIZED->COUNTRY_UPDATE
Sun Apr 19 13:34:45 2020 daemon.notice hostapd: wlan0: interface state COUNTRY_UPDATE->HT_SCAN
Sun Apr 19 13:34:46 2020 daemon.notice hostapd: wlan0: interface state HT_SCAN->DFS
Sun Apr 19 13:34:46 2020 daemon.notice hostapd: wlan0: DFS-CAC-START freq=5280 chan=56 sec_chan=-1, width=1, seg0=58, seg1=0, cac_time=60s
Sun Apr 19 13:35:47 2020 daemon.notice hostapd: wlan0: DFS-CAC-COMPLETED success=1 freq=5280 ht_enabled=0 chan_offset=0 chan_width=3 cf1=5290 cf2=0
Sun Apr 19 13:35:47 2020 daemon.err hostapd: Using interface wlan0 with hwaddr e8:de:27:f6:28:d5 and ssid "t503"
Sun Apr 19 13:35:47 2020 kern.info kernel: [1543113.255855] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
Sun Apr 19 13:35:47 2020 kern.info kernel: [1543113.262756] br-lan: port 2(wlan0) entered blocking state
Sun Apr 19 13:35:47 2020 kern.info kernel: [1543113.268372] br-lan: port 2(wlan0) entered forwarding state
Sun Apr 19 13:35:47 2020 daemon.notice hostapd: wlan0: interface state DFS->ENABLED
Sun Apr 19 13:35:47 2020 daemon.notice hostapd: wlan0: AP-ENABLED
Sun Apr 19 13:35:47 2020 daemon.notice netifd: Network device 'wlan0' link is up

Oh, and I forgot: DFS is incompatible with the "Allow legacy 802.11b rates" advanced setting which is on by default.

Oh, and I forgot: DFS is incompatible with the "Allow legacy 802.11b rates" advanced setting which is on by default.

This is great to know. I'll try again with this disabled and post my logs if it doesn't make it work.

Here are my logs after unchecking "Allow legacy 812.11b rates"

Sun Apr 19 17:29:37 2020 user.notice mac80211: Failed command: iw phy phy0 set antenna 0xffffffff 0xffffffff
Sun Apr 19 17:29:37 2020 daemon.notice netifd: radio0 (2489): command failed: Not supported (-95)
Sun Apr 19 17:29:37 2020 user.notice mac80211: Failed command: iw phy phy0 set distance 0
Sun Apr 19 17:29:37 2020 daemon.err hostapd: Configuration file: /var/run/hostapd-phy0.conf
Sun Apr 19 17:29:37 2020 kern.debug kernel: [89319.799539] ieee80211 phy0: change: 0xffffffff
Sun Apr 19 17:29:37 2020 kern.info kernel: [89319.912786] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
Sun Apr 19 17:29:37 2020 kern.info kernel: [89319.919866] br-lan: port 2(wlan0) entered blocking state
Sun Apr 19 17:29:37 2020 kern.info kernel: [89319.925267] br-lan: port 2(wlan0) entered disabled state
Sun Apr 19 17:29:37 2020 kern.info kernel: [89319.930701] device wlan0 entered promiscuous mode
Sun Apr 19 17:29:37 2020 daemon.notice hostapd: wlan0: interface state UNINITIALIZED->COUNTRY_UPDATE
Sun Apr 19 17:29:40 2020 daemon.notice hostapd: handle_probe_req: send failed
Sun Apr 19 17:29:40 2020 daemon.notice hostapd: handle_probe_req: send failed
Sun Apr 19 17:29:42 2020 daemon.notice hostapd: wlan0: interface state COUNTRY_UPDATE->HT_SCAN
Sun Apr 19 17:29:42 2020 kern.debug kernel: [89324.940128] ieee80211 phy0: change: 0x100
Sun Apr 19 17:29:42 2020 kern.debug kernel: [89324.953249] ieee80211 phy0: change: 0x60
Sun Apr 19 17:29:43 2020 kern.debug kernel: [89325.164460] ieee80211 phy0: change: 0x40
Sun Apr 19 17:29:43 2020 daemon.notice hostapd: wlan0: interface state HT_SCAN->DFS
Sun Apr 19 17:29:43 2020 daemon.notice hostapd: wlan0: DFS-CAC-START freq=5260 chan=52 sec_chan=1, width=1, seg0=58, seg1=0, cac_time=60s
Sun Apr 19 17:29:43 2020 daemon.err hostapd: DFS start_dfs_cac() failed, -1
Sun Apr 19 17:29:43 2020 daemon.err hostapd: Interface initialization failed
Sun Apr 19 17:29:43 2020 daemon.notice hostapd: wlan0: interface state DFS->DISABLED
Sun Apr 19 17:29:43 2020 daemon.notice hostapd: wlan0: AP-DISABLED
Sun Apr 19 17:29:43 2020 daemon.notice hostapd: wlan0: interface state DISABLED->DISABLED
Sun Apr 19 17:29:43 2020 daemon.notice hostapd: wlan0: AP-DISABLED
Sun Apr 19 17:29:43 2020 daemon.notice hostapd: wlan0: CTRL-EVENT-TERMINATING
Sun Apr 19 17:29:43 2020 daemon.err hostapd: hostapd_free_hapd_data: Interface wlan0 wasn't started
Sun Apr 19 17:29:43 2020 daemon.notice hostapd: nl80211: deinit ifname=wlan0 disabled_11b_rates=0
Sun Apr 19 17:29:43 2020 kern.debug kernel: [89325.374490] ieee80211 phy0: change: 0x60
Sun Apr 19 17:29:43 2020 kern.info kernel: [89325.414534] device wlan0 left promiscuous mode
Sun Apr 19 17:29:43 2020 kern.info kernel: [89325.419128] br-lan: port 2(wlan0) entered disabled state
Sun Apr 19 17:29:43 2020 kern.debug kernel: [89325.478571] ieee80211 phy0: change: 0x100
Sun Apr 19 17:29:43 2020 daemon.notice hostapd: ELOOP: remaining socket: sock=22 eloop_data=0xb6f6b710 user_data=0 handler=0x2b8e4
Sun Apr 19 17:29:43 2020 daemon.notice netifd: radio0 (2489): WARNING (wireless_add_process): executable path /usr/sbin/wpad does not match process 971 path ()
Sun Apr 19 17:29:43 2020 kern.debug kernel: [89325.690604] ieee80211 phy0: change: 0xffffffff
Sun Apr 19 17:29:43 2020 kern.info kernel: [89325.803423] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready

Reboot the router with the current (non-working) settings in effect, except channel (set it to 56) and bandwidth (set it to 80 MHz). If it still says "DFS start_dfs_cac() failed, -1", well, nothing can be done.

Yep, still getting daemon.err hostapd: DFS start_dfs_cac() failed, -1 unfortunately. Thanks for the help!

Question though, why did you recommend changing the channel to 56?

To match my known-working config as exactly as possible (even though it is for different hardware).

Makes sense. Thanks

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.