Enabling DFS in OpenWrt 25.12.x

Jul 5, 2026

Been a while since I wrote so here I go...

I was looking into why OpenWrt wouldn't enable DFS when the radio was perfectly capable of DFS scanning.
Elelems were kinda meh to root cause this [1] .

Anyway, here is the sauce.

hostapd.sh looks at three variables to emit ieee80211h. You need to set country, hwmode and doth.
hwmode is deprecated and you are expected to use band but I guess the script is stale.

hostapd_prepare_device_config() {
  ...
  [ -n "$country" ] && {
    ...
    [ "$hwmode" = "a" -a "$doth" -gt 0 ] && append base_cfg "ieee80211h=1" "$N"
  }

So, your config would look like

config wifi-device 'radio1'
  option country 'XXX'
  option doth '1'
  option hwmode 'a'

  1. Claude thought the linux kernel did not support DFS scanning for
    FCC reg domain ↩︎