Cudy X6 v2: 5GHz radio (MT7975DN) fails to bring interface UP on OpenWrt 24.10.4

Cudy X6 v2: 5GHz radio (MT7975DN) fails to bring interface UP on OpenWrt 24.10.4

Device Information

  • Device: Cudy X6
    Architecture MediaTek MT7621 ver:1 eco:3
    Target Platform ramips/mt7621
  • Chipsets:
    • 2.4 GHz: MediaTek MT7905DAN (working)
    • 5 GHz: MediaTek MT7975DN (NOT working)
  • Working firmware: OpenWrt 22.03.0 r19685-512e76967f version provided by Cudy manufacturer
  • Broken firmware: OpenWrt 24.10.4 official release

Problem Description

After upgrading from Cudy's OpenWrt release to official OpenWrt 24.10.4, the 5 GHz radio (phy1) is detected by the system but fails to activate. The 2.4 GHz radio works perfectly.

Symptoms

  • iw list shows both phy0 (2.4GHz) and phy1 (5GHz) correctly
  • Driver mt7915e loads without errors
  • Interface phy1-ap0 cannot be brought UP
  • Error: SIOCSIFFLAGS: Address not available

Diagnostic Commands Output

1. Hardware Detection (WORKING)

root@OpenWrt:~# lsmod | grep mt7915
cfg80211              323584  4 mt7915e,mt76_connac_lib,mt76,mac80211
hwmon                  16384  1 mt7915e
mac80211              647168  3 mt7915e,mt76_connac_lib,mt76
mt76                   69632  2 mt7915e,mt76_connac_lib
mt76_connac_lib        49152  1 mt7915e
mt7915e               126976  0

2. Firmware Loaded Successfully

root@OpenWrt:~# dmesg | grep mt7915
[   12.823066] mt7915e_hif 0000:01:00.0: enabling device (0000 -> 0002)
[   12.835730] mt7915e 0000:02:00.0: enabling device (0000 -> 0002)
[   13.062966] mt7915e 0000:02:00.0: HW/SW Version: 0x8a108a10, Build Time: 20211222184017a
[   13.458109] mt7915e 0000:02:00.0: WM Firmware Version: ____000000, Build Time: 20211222184052
[   13.561205] mt7915e 0000:02:00.0: WA Firmware Version: DEV_000000, Build Time: 20211222184111
[   13.680317] mt7915e 0000:02:00.0: registering led 'mt76-phy0'
[   13.750869] mt7915e 0000:02:00.0: registering led 'mt76-phy1'

3. Both Radios Detected by iw list

root@OpenWrt:~# iw list
Wiphy phy1  # 5GHz - Shows all capabilities correctly
        Band 2:
                Frequencies:
                        * 5180.0 MHz [36] (20.0 dBm)
                        * 5200.0 MHz [40] (20.0 dBm)
                        [... all 5GHz channels listed ...]

Wiphy phy0  # 2.4GHz - Working
        Band 1:
                Frequencies:
                        * 2412.0 MHz [1] (20.0 dBm)
                        [... all 2.4GHz channels listed ...]

4. Interface Fails to Come UP

root@OpenWrt:~# logread | grep -i "phy1"
daemon.notice hostapd: Configuration file: <inline> (phy phy1) --> new PHY
daemon.err hostapd: Could not set interface phy1-ap0 flags (UP): Address not available
daemon.err hostapd: nl80211: Could not set interface 'phy1-ap0' UP
daemon.notice hostapd: nl80211: deinit ifname=phy1-ap0 disabled_11b_rates=0
daemon.notice hostapd: phy1-ap0: CTRL-EVENT-TERMINATING
daemon.err hostapd: hostapd_free_hapd_data: Interface phy1-ap0 wasn't started
daemon.notice hostapd: hostapd.add_iface failed for phy phy1 ifname=phy1-ap0

5. Manual Interface Creation Also Fails

root@OpenWrt:~# iw phy phy1 interface add test1 type managed
root@OpenWrt:~# ip link set test1 up
ip: SIOCSIFFLAGS: Address not available  # <-- FAILS

6. WiFi Status

root@OpenWrt:~# wifi status
{
        "radio0": {
                "up": true,
                "disabled": false,
                # ... 2.4GHz WORKING
        },
        "radio1": {
                "up": false,
                "disabled": true,  # Auto-disabled after failure
                "retry_setup_failed": false,
                # ... 5GHz NOT WORKING
        }
}

7. Regulatory Domain (Correct)

root@OpenWrt:~# iw reg get
country IT: DFS-ETSI
        (2400 - 2483 @ 40), (N/A, 20), (N/A)
        (5150 - 5250 @ 80), (N/A, 23), (N/A), NO-OUTDOOR, AUTO-BW
        (5250 - 5350 @ 80), (N/A, 20), (0 ms), NO-OUTDOOR, DFS, AUTO-BW
        (5470 - 5725 @ 160), (N/A, 26), (0 ms), DFS
        (5725 - 5875 @ 80), (N/A, 13), (N/A)

Troubleshooting Steps Attempted

1. Configuration Check

  • Verified option disabled '0' in /etc/config/wireless
  • Set option country 'IT' for both radios
  • Tried different channels (36, 149)
  • Configuration is correct

2. Antenna Configuration

# Noticed mismatch in iw list output:
Available Antennas: TX 0x3 RX 0x3
Configured Antennas: TX 0xc RX 0xc  # MISMATCH

# Attempted fix:
iw phy phy1 set antenna 3 3
# Did not resolve the issue

3. Firmware Replacement

  • Backed up original OpenWrt 24.10.4 firmware files
  • Copied firmware from working Cudy version:
    • mt7915_rom_patch.bin (144544 bytes, Build: 20211222)
    • mt7915_wa.bin (116368 bytes, Build: 20211222)
    • mt7915_wm.bin (1260960 bytes, Build: 20211222)
  • Rebooted
  • Result: Firmware loaded correctly but problem persists

4. Interface Recreation

wifi down
iw phy phy1 interface add wlan1 type managed
ip link set wlan1 up  # FAILS with same error

Firmware Version Comparison

Cudy OpenWrt (WORKING):

mt7915_wa.bin: 116368 bytes, Build Time: 20211222184111

OpenWrt 24.10.4 (NOT WORKING):

mt7915_wa.bin: 113712 bytes, Build Time: 20240429200812

Note: After replacing with Cudy firmware files, the system loads them correctly but the issue remains, indicating a driver-level problem, not firmware.

Root Cause Analysis

The issue is not:

  • Configuration (verified multiple times)
  • Firmware files (tested with both versions)
  • Hardware detection (phy1 is detected correctly)
  • Regulatory domain (set correctly to IT)

The issue is:

  • Driver mt7915e in OpenWrt 24.10.4 cannot bring the interface UP
  • Error occurs at kernel/driver level: SIOCSIFFLAGS: Address not available
  • Specific to MT7975DN chipset (MT7905DAN 2.4GHz works fine)

Comparison with Working Version

On Cudy's OpenWrt version, the same hardware works perfectly with identical configuration. This suggests:

  1. Cudy's OpenWrt build includes patches/modifications for MT7975DN support
  2. Official OpenWrt 24.10.4 has a regression or lacks necessary patches for this specific chipset

Requested Help

  1. Is this a known issue with MT7975DN on 24.10.4?
  2. Are there any patches or kernel parameters to try?
  3. Should I test with a snapshot version?
  4. Can this be fixed, or should I stick with Cudy's OpenWrt build?

Thank you for any tip!

Please connect to your OpenWrt device using ssh and copy the output of the following commands and post it here using the "Preformatted text </> " button (red circle; this works best in the 'Markdown' composer view in the blue oval):

Screenshot 2025-10-20 at 8.14.14 PM

Remember to redact passwords, VPN keys, MAC addresses and any public IP addresses you may have:

ubus call system board
cat /etc/config/network
cat /etc/config/wireless
cat /etc/config/dhcp
cat /etc/config/firewall

Now the device runs the cudy openwrt version and send this output:

root@OpenWrt:~# ubus call system board
{
        "kernel": "5.10.138",
        "hostname": "OpenWrt",
        "system": "MediaTek MT7621 ver:1 eco:3",
        "model": "CUDY X6",
        "board_name": "cudy,x6",
        "rootfs_type": "squashfs",
        "release": {
                "distribution": "OpenWrt",
                "version": "22.03.0",
                "revision": "r19685-512e76967f",
                "target": "ramips/mt7621",
                "description": "OpenWrt 22.03.0 r19685-512e76967f"
        }

root@OpenWrt:~# cat /etc/config/network

config interface 'loopback'
        option device 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config globals 'globals'
        option packet_steering '1'
        option ula_prefix 'fd1c:cc4a:e34c::/48'

config device
        option name 'br-lan'
        option type 'bridge'
        list ports 'lan1'
        list ports 'lan2'
        list ports 'lan3'
        list ports 'lan4'

config interface 'lan'
        option device 'br-lan'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option ip6assign '60'

config interface 'wan'
        option device 'wan'
        option proto 'dhcp'

config interface 'wan6'
        option device 'wan'
        option proto 'dhcpv6'
 cat /etc/config/wireless

config wifi-device 'radio0'
        option type 'mac80211'
        option path '1e140000.pcie/pci0000:00/0000:00:01.0/0000:02:00.0'
        option channel '1'
        option band '2g'
        option htmode 'HE20'
        option disabled '1'

config wifi-iface 'default_radio0'
        option device 'radio0'
        option network 'lan'
        option mode 'ap'
        option ssid 'OpenWrt'
        option encryption 'none'

config wifi-device 'radio1'
        option type 'mac80211'
        option path '1e140000.pcie/pci0000:00/0000:00:01.0/0000:02:00.0+1'
        option channel '36'
        option band '5g'
        option htmode 'HE80'

config wifi-iface 'default_radio1'
        option device 'radio1'
        option network 'lan'
        option mode 'ap'
        option ssid 'OpenWrt'
        option encryption 'none'


root@OpenWrt:~# cat /etc/config/dhcp

config dnsmasq
        option domainneeded '1'
        option boguspriv '1'
        option filterwin2k '0'
        option localise_queries '1'
        option rebind_protection '1'
        option rebind_localhost '1'
        option local '/lan/'
        option domain 'lan'
        option expandhosts '1'
        option nonegcache '0'
        option authoritative '1'
        option readethers '1'
        option leasefile '/tmp/dhcp.leases'
        option resolvfile '/tmp/resolv.conf.d/resolv.conf.auto'
        option nonwildcard '1'
        option localservice '1'
        option ednspacket_max '1232'

config dhcp 'lan'
        option interface 'lan'
        option start '100'
        option limit '150'
        option leasetime '12h'
        option dhcpv4 'server'
        option dhcpv6 'server'
        option ra 'server'
        option ra_slaac '1'
        list ra_flags 'managed-config'
        list ra_flags 'other-config'

config dhcp 'wan'
        option interface 'wan'
        option ignore '1'

config odhcpd 'odhcpd'
        option maindhcp '0'
        option leasefile '/tmp/hosts/odhcpd'
        option leasetrigger '/usr/sbin/odhcpd-update'
        option loglevel '4'

root@OpenWrt:~# cat /etc/config/dhcp

config dnsmasq
        option domainneeded '1'
        option boguspriv '1'
        option filterwin2k '0'
        option localise_queries '1'
        option rebind_protection '1'
        option rebind_localhost '1'
        option local '/lan/'
        option domain 'lan'
        option expandhosts '1'
        option nonegcache '0'
        option authoritative '1'
        option readethers '1'
        option leasefile '/tmp/dhcp.leases'
        option resolvfile '/tmp/resolv.conf.d/resolv.conf.auto'
        option nonwildcard '1'
        option localservice '1'
        option ednspacket_max '1232'

config dhcp 'lan'
        option interface 'lan'
        option start '100'
        option limit '150'
        option leasetime '12h'
        option dhcpv4 'server'
        option dhcpv6 'server'
        option ra 'server'
        option ra_slaac '1'
        list ra_flags 'managed-config'
        list ra_flags 'other-config'

config dhcp 'wan'
        option interface 'wan'
        option ignore '1'

config odhcpd 'odhcpd'
        option maindhcp '0'
        option leasefile '/tmp/hosts/odhcpd'
        option leasetrigger '/usr/sbin/odhcpd-update'
        option loglevel '4'

root@OpenWrt:~# cat /etc/config/firewallcat /etc/config/firewall
cat: can't open '/etc/config/firewallcat': No such file or directory
config defaults
        option syn_flood        1
        option input            ACCEPT
        option output           ACCEPT
        option forward          REJECT
# Uncomment this line to disable ipv6 rules
#       option disable_ipv6     1

config zone
        option name             lan
        list   network          'lan'
        option input            ACCEPT
        option output           ACCEPT
        option forward          ACCEPT

config zone
        option name             wan
        list   network          'wan'
        list   network          'wan6'
        option input            REJECT
        option output           ACCEPT
        option forward          REJECT
        option masq             1
        option mtu_fix          1

config forwarding
        option src              lan
        option dest             wan

# We need to accept udp packets on port 68,
# see https://dev.openwrt.org/ticket/4108
config rule
        option name             Allow-DHCP-Renew
        option src              wan
        option proto            udp
        option dest_port        68
        option target           ACCEPT
        option family           ipv4

# Allow IPv4 ping
config rule
        option name             Allow-Ping
        option src              wan
        option proto            icmp
        option icmp_type        echo-request
        option family           ipv4
        option target           ACCEPT

config rule
        option name             Allow-IGMP
        option src              wan
        option proto            igmp
        option family           ipv4
        option target           ACCEPT

# Allow DHCPv6 replies
# see https://github.com/openwrt/openwrt/issues/5066
config rule
        option name             Allow-DHCPv6
        option src              wan
        option proto            udp
        option dest_port        546
        option family           ipv6
        option target           ACCEPT

config rule
        option name             Allow-MLD
        option src              wan
        option proto            icmp
        option src_ip           fe80::/10
        list icmp_type          '130/0'
        list icmp_type          '131/0'
        list icmp_type          '132/0'
        list icmp_type          '143/0'
        option family           ipv6
        option target           ACCEPT

# Allow essential incoming IPv6 ICMP traffic
config rule
        option name             Allow-ICMPv6-Input
        option src              wan
        option proto    icmp
        list icmp_type          echo-request
        list icmp_type          echo-reply
        list icmp_type          destination-unreachable
        list icmp_type          packet-too-big
        list icmp_type          time-exceeded
        list icmp_type          bad-header
        list icmp_type          unknown-header-type
        list icmp_type          router-solicitation
        list icmp_type          neighbour-solicitation
        list icmp_type          router-advertisement
        list icmp_type          neighbour-advertisement
        option limit            1000/sec
        option family           ipv6
        option target           ACCEPT

# Allow essential forwarded IPv6 ICMP traffic
config rule
        option name             Allow-ICMPv6-Forward
        option src              wan
        option dest             *
        option proto            icmp
        list icmp_type          echo-request
        list icmp_type          echo-reply
        list icmp_type          destination-unreachable
        list icmp_type          packet-too-big
        list icmp_type          time-exceeded
        list icmp_type          bad-header
        list icmp_type          unknown-header-type
        option limit            1000/sec
        option family           ipv6
        option target           ACCEPT

config rule
        option name             Allow-IPSec-ESP
        option src              wan
        option dest             lan
        option proto            esp
        option target           ACCEPT

config rule
        option name             Allow-ISAKMP
        option src              wan
        option dest             lan
        option dest_port        500
        option proto            udp
        option target           ACCEPT


I can update to openwrt 24.10.4 and send the output

the cudy firmware config is irrelevant.

the openwrt 24.10.4 commands output

root@OpenWrt:~# ubus call system board
{
        "kernel": "6.6.110",
        "hostname": "OpenWrt",
        "system": "MediaTek MT7621 ver:1 eco:3",
        "model": "CUDY X6 v2",
        "board_name": "cudy,x6-v2",
        "rootfs_type": "squashfs",
        "release": {
                "distribution": "OpenWrt",
                "version": "24.10.4",
                "revision": "r28959-29397011cc",
                "target": "ramips/mt7621",
                "description": "OpenWrt 24.10.4 r28959-29397011cc",
                "builddate": "1760891865"
        }
}


root@OpenWrt:~# cat /etc/config/network

config interface 'loopback'
        option device 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config globals 'globals'
        option ula_prefix 'fddb:a920:b2fa::/48'
        option packet_steering '1'

config device
        option name 'br-lan'
        option type 'bridge'
        list ports 'lan1'
        list ports 'lan2'
        list ports 'lan3'
        list ports 'lan4'

config interface 'lan'
        option device 'br-lan'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option ip6assign '60'

config interface 'wan'
        option device 'wan'
        option proto 'dhcp'

config interface 'wan6'
        option device 'wan'
        option proto 'dhcpv6'
root@OpenWrt:~# cat /etc/config/wireless

config wifi-device 'radio0'
        option type 'mac80211'
        option path '1e140000.pcie/pci0000:00/0000:00:01.0/0000:02:00.0'
        option band '2g'
        option channel '1'
        option htmode 'HE20'

config wifi-iface 'default_radio0'
        option device 'radio0'
        option network 'lan'
        option mode 'ap'
        option ssid 'OpenWrt'
        option encryption 'none'

config wifi-device 'radio1'
        option type 'mac80211'
        option path '1e140000.pcie/pci0000:00/0000:00:01.0/0000:02:00.0+1'
        option band '5g'
        option channel '36'
        option htmode 'HE80'

config wifi-iface 'default_radio1'
        option device 'radio1'
        option network 'lan'
        option mode 'ap'
        option ssid 'OpenWrt'
        option encryption 'none'

root@OpenWrt:~# cat /etc/config/dhcp

config dnsmasq
        option domainneeded '1'
        option boguspriv '1'
        option filterwin2k '0'
        option localise_queries '1'
        option rebind_protection '1'
        option rebind_localhost '1'
        option local '/lan/'
        option domain 'lan'
        option expandhosts '1'
        option nonegcache '0'
        option cachesize '1000'
        option authoritative '1'
        option readethers '1'
        option leasefile '/tmp/dhcp.leases'
        option resolvfile '/tmp/resolv.conf.d/resolv.conf.auto'
        option nonwildcard '1'
        option localservice '1'
        option ednspacket_max '1232'
        option filter_aaaa '0'
        option filter_a '0'

config dhcp 'lan'
        option interface 'lan'
        option start '100'
        option limit '150'
        option leasetime '12h'
        option dhcpv4 'server'
        option dhcpv6 'server'
        option ra 'server'
        option ra_slaac '1'
        list ra_flags 'managed-config'
        list ra_flags 'other-config'

config dhcp 'wan'
        option interface 'wan'
        option ignore '1'

config odhcpd 'odhcpd'
        option maindhcp '0'
        option leasefile '/tmp/hosts/odhcpd'
        option leasetrigger '/usr/sbin/odhcpd-update'
        option loglevel '4'
        option piofolder '/tmp/odhcpd-piofolder'

root@OpenWrt:~# cat /etc/config/firewall
config defaults
        option syn_flood        1
        option input            REJECT
        option output           ACCEPT
        option forward          REJECT
# Uncomment this line to disable ipv6 rules
#       option disable_ipv6     1

config zone
        option name             lan
        list   network          'lan'
        option input            ACCEPT
        option output           ACCEPT
        option forward          ACCEPT

config zone
        option name             wan
        list   network          'wan'
        list   network          'wan6'
        option input            REJECT
        option output           ACCEPT
        option forward          REJECT
        option masq             1
        option mtu_fix          1

config forwarding
        option src              lan
        option dest             wan

# We need to accept udp packets on port 68,
# see https://dev.openwrt.org/ticket/4108
config rule
        option name             Allow-DHCP-Renew
        option src              wan
        option proto            udp
        option dest_port        68
        option target           ACCEPT
        option family           ipv4

# Allow IPv4 ping
config rule
        option name             Allow-Ping
        option src              wan
        option proto            icmp
        option icmp_type        echo-request
        option family           ipv4
        option target           ACCEPT

config rule
        option name             Allow-IGMP
        option src              wan
        option proto            igmp
        option family           ipv4
        option target           ACCEPT

# Allow DHCPv6 replies
# see https://github.com/openwrt/openwrt/issues/5066
config rule
        option name             Allow-DHCPv6
        option src              wan
        option proto            udp
        option dest_port        546
        option family           ipv6
        option target           ACCEPT

config rule
        option name             Allow-MLD
        option src              wan
        option proto            icmp
        option src_ip           fe80::/10
        list icmp_type          '130/0'
        list icmp_type          '131/0'
        list icmp_type          '132/0'
        list icmp_type          '143/0'
        option family           ipv6
        option target           ACCEPT

# Allow essential incoming IPv6 ICMP traffic
config rule
        option name             Allow-ICMPv6-Input
        option src              wan
        option proto    icmp
        list icmp_type          echo-request
        list icmp_type          echo-reply
        list icmp_type          destination-unreachable
        list icmp_type          packet-too-big
        list icmp_type          time-exceeded
        list icmp_type          bad-header
        list icmp_type          unknown-header-type
        list icmp_type          router-solicitation
        list icmp_type          neighbour-solicitation
        list icmp_type          router-advertisement
        list icmp_type          neighbour-advertisement
        option limit            1000/sec
        option family           ipv6
        option target           ACCEPT

# Allow essential forwarded IPv6 ICMP traffic
config rule
        option name             Allow-ICMPv6-Forward
        option src              wan
        option dest             *
        option proto            icmp
        list icmp_type          echo-request
        list icmp_type          echo-reply
        list icmp_type          destination-unreachable
        list icmp_type          packet-too-big
        list icmp_type          time-exceeded
        list icmp_type          bad-header
        list icmp_type          unknown-header-type
        option limit            1000/sec
        option family           ipv6
        option target           ACCEPT

config rule
        option name             Allow-IPSec-ESP
        option src              wan
        option dest             lan
        option proto            esp
        option target           ACCEPT

config rule
        option name             Allow-ISAKMP
        option src              wan
        option dest             lan
        option dest_port        500
        option proto            udp
        option target           ACCEPT




For one, you are missing your country code in /etc/config/wireless.

2 Likes

i put country code in /etc/config/wireless but not work

Additional elements detected:

  • OpenWrt 22.03 (WORKING): Interfaces are named wlan0 (2.4GHz) and wlan1 (5GHz)
  • OpenWrt 24.10.4 (NOT WORKING): Interfaces are named phy0-ap0 (2.4GHz) and phy1-ap0 (5GHz)
  • Critical Issue: In LuCI under Network β†’ Interfaces β†’ Devices, only phy0-ap0 is visible; phy1-ap0 does NOT appear even though phy1 is detected by iw list

inteface_cudy_openwrt22



Please stop referencing the Cudy stock firmware, it's not OpenWRT, you're comparing apples and oranges.

The elements included do not relate to the OEM stock firmware but to the custom version based on openwrt 22.03. I am trying to provide elements of analysis to solve the problem.

I just want to understand and resolve the issue with the phy1-ap0 (5GHz) interface, which works correctly with OpenWRT 22.03 but is not detected with OpenWRT 24.10.4.

Do you have any practical suggestions?

Here Openwrt 24.10.4 logs:

root@OpenWrt:~# logread -f
Thu Dec 11 22:17:12 2025 daemon.notice hostapd: Set new config for phy phy1:
Thu Dec 11 22:17:12 2025 daemon.notice wpa_supplicant[1691]: Set new config for phy phy1
Thu Dec 11 22:17:12 2025 daemon.notice netifd: Wireless device 'radio1' is now down
Thu Dec 11 22:17:14 2025 daemon.info dnsmasq[1]: read /etc/hosts - 12 names
Thu Dec 11 22:17:14 2025 daemon.info dnsmasq[1]: read /tmp/hosts/dhcp.cfg01411c - 4 names
Thu Dec 11 22:17:14 2025 daemon.info dnsmasq[1]: read /tmp/hosts/odhcpd - 2 names
Thu Dec 11 22:17:14 2025 daemon.info dnsmasq-dhcp[1]: read /etc/ethers - 0 addresses
Thu Dec 11 22:17:16 2025 daemon.warn odhcpd[1837]: No default route present, setting ra_lifetime to 0!
Thu Dec 11 22:17:22 2025 kern.info kernel: [  753.159620] mt7915e 0000:02:00.0 phy0-ap0: left allmulticast mode
Thu Dec 11 22:17:22 2025 kern.info kernel: [  753.165766] mt7915e 0000:02:00.0 phy0-ap0: left promiscuous mode
Thu Dec 11 22:17:22 2025 kern.info kernel: [  753.172116] br-lan: port 5(phy0-ap0) entered disabled state
Thu Dec 11 22:17:22 2025 daemon.notice hostapd: Set new config for phy phy0:
Thu Dec 11 22:17:22 2025 daemon.notice hostapd: Remove interface 'phy0'
Thu Dec 11 22:17:22 2025 daemon.notice hostapd: phy0-ap0: interface state ENABLED->DISABLED
Thu Dec 11 22:17:22 2025 daemon.notice hostapd: phy0-ap0: AP-DISABLED
Thu Dec 11 22:17:22 2025 daemon.notice hostapd: phy0-ap0: CTRL-EVENT-TERMINATING
Thu Dec 11 22:17:22 2025 daemon.err hostapd: rmdir[ctrl_interface=/var/run/hostapd]: Permission denied
Thu Dec 11 22:17:22 2025 daemon.notice hostapd: nl80211: deinit ifname=phy0-ap0 disabled_11b_rates=0
Thu Dec 11 22:17:22 2025 daemon.notice hostapd: nl80211: Failed to remove interface phy0-ap0 from bridge br-lan: Invalid argument
Thu Dec 11 22:17:22 2025 daemon.notice wpa_supplicant[1691]: Set new config for phy phy0
Thu Dec 11 22:17:22 2025 daemon.notice netifd: Wireless device 'radio0' is now down
Thu Dec 11 22:17:25 2025 daemon.info dnsmasq[1]: read /etc/hosts - 12 names
Thu Dec 11 22:17:25 2025 daemon.info dnsmasq[1]: read /tmp/hosts/dhcp.cfg01411c - 4 names
Thu Dec 11 22:17:25 2025 daemon.info dnsmasq[1]: read /tmp/hosts/odhcpd - 2 names
Thu Dec 11 22:17:25 2025 daemon.info dnsmasq-dhcp[1]: read /etc/ethers - 0 addresses
Thu Dec 11 22:17:26 2025 daemon.warn odhcpd[1837]: No default route present, setting ra_lifetime to 0!
Thu Dec 11 22:17:31 2025 daemon.notice netifd: radio0 (4719): WARNING: Variable 'data' does not exist or is not an array/object
Thu Dec 11 22:17:31 2025 daemon.notice hostapd: Set new config for phy phy0:
Thu Dec 11 22:17:31 2025 daemon.notice wpa_supplicant[1691]: Set new config for phy phy0
Thu Dec 11 22:17:32 2025 daemon.notice wpa_supplicant[1691]: Set new config for phy phy0
Thu Dec 11 22:17:32 2025 daemon.notice hostapd: Set new config for phy phy0: /var/run/hostapd-phy0.conf
Thu Dec 11 22:17:32 2025 daemon.notice hostapd: Restart interface for phy phy0
Thu Dec 11 22:17:32 2025 daemon.notice hostapd: Configuration file: <inline> (phy phy0) --> new PHY
Thu Dec 11 22:17:32 2025 daemon.notice hostapd: Configuration file: Reading configuration file '<inline>'
Thu Dec 11 22:17:32 2025 kern.info kernel: [  763.286593] br-lan: port 5(phy0-ap0) entered blocking state
Thu Dec 11 22:17:32 2025 kern.info kernel: [  763.292387] br-lan: port 5(phy0-ap0) entered disabled state
Thu Dec 11 22:17:32 2025 kern.info kernel: [  763.298225] mt7915e 0000:02:00.0 phy0-ap0: entered allmulticast mode
Thu Dec 11 22:17:32 2025 kern.info kernel: [  763.305360] mt7915e 0000:02:00.0 phy0-ap0: entered promiscuous mode
Thu Dec 11 22:17:32 2025 kern.info kernel: [  763.312416] br-lan: port 5(phy0-ap0) entered blocking state
Thu Dec 11 22:17:32 2025 kern.info kernel: [  763.318147] br-lan: port 5(phy0-ap0) entered forwarding state
Thu Dec 11 22:17:32 2025 kern.info kernel: [  763.325256] br-lan: port 5(phy0-ap0) entered disabled state
Thu Dec 11 22:17:32 2025 kern.info kernel: [  763.437245] br-lan: port 5(phy0-ap0) entered blocking state
Thu Dec 11 22:17:32 2025 kern.info kernel: [  763.442868] br-lan: port 5(phy0-ap0) entered forwarding state
Thu Dec 11 22:17:32 2025 daemon.notice netifd: Network device 'phy0-ap0' link is up
Thu Dec 11 22:17:32 2025 daemon.notice hostapd: phy0-ap0: interface state UNINITIALIZED->ENABLED
Thu Dec 11 22:17:32 2025 daemon.notice hostapd: phy0-ap0: AP-ENABLED
Thu Dec 11 22:17:32 2025 daemon.notice netifd: Wireless device 'radio0' is now up
Thu Dec 11 22:17:34 2025 daemon.info dnsmasq[1]: read /etc/hosts - 12 names
Thu Dec 11 22:17:34 2025 daemon.info dnsmasq[1]: read /tmp/hosts/dhcp.cfg01411c - 4 names
Thu Dec 11 22:17:34 2025 daemon.info dnsmasq[1]: read /tmp/hosts/odhcpd - 2 names
Thu Dec 11 22:17:34 2025 daemon.info dnsmasq-dhcp[1]: read /etc/ethers - 0 addresses
Thu Dec 11 22:17:35 2025 daemon.warn odhcpd[1837]: No default route present, setting ra_lifetime to 0!
Thu Dec 11 22:17:41 2025 daemon.notice netifd: radio1 (5084): WARNING: Variable 'data' does not exist or is not an array/object
Thu Dec 11 22:17:41 2025 daemon.notice hostapd: Set new config for phy phy1:
Thu Dec 11 22:17:41 2025 daemon.notice wpa_supplicant[1691]: Set new config for phy phy1
Thu Dec 11 22:17:42 2025 daemon.notice wpa_supplicant[1691]: Set new config for phy phy1
Thu Dec 11 22:17:42 2025 daemon.notice hostapd: Set new config for phy phy1: /var/run/hostapd-phy1.conf
Thu Dec 11 22:17:42 2025 daemon.notice hostapd: Restart interface for phy phy1
Thu Dec 11 22:17:42 2025 daemon.notice hostapd: Configuration file: <inline> (phy phy1) --> new PHY
Thu Dec 11 22:17:42 2025 daemon.notice hostapd: Configuration file: Reading configuration file '<inline>'
Thu Dec 11 22:17:42 2025 daemon.err hostapd: Could not set interface phy1-ap0 flags (UP): Address not available
Thu Dec 11 22:17:42 2025 daemon.err hostapd: nl80211: Could not set interface 'phy1-ap0' UP
Thu Dec 11 22:17:42 2025 daemon.notice hostapd: nl80211: deinit ifname=phy1-ap0 disabled_11b_rates=0
Thu Dec 11 22:17:42 2025 daemon.err hostapd: nl80211 driver initialization failed.
Thu Dec 11 22:17:42 2025 daemon.notice hostapd: phy1-ap0: CTRL-EVENT-TERMINATING
Thu Dec 11 22:17:42 2025 daemon.err hostapd: hostapd_free_hapd_data: Interface phy1-ap0 wasn't started
Thu Dec 11 22:17:42 2025 daemon.notice hostapd: hostapd.add_iface failed for phy phy1 ifname=phy1-ap0
Thu Dec 11 22:17:42 2025 daemon.notice netifd: Wireless device 'radio1' is now up
Thu Dec 11 22:17:43 2025 daemon.info dnsmasq[1]: read /etc/hosts - 12 names
Thu Dec 11 22:17:43 2025 daemon.info dnsmasq[1]: read /tmp/hosts/dhcp.cfg01411c - 4 names
Thu Dec 11 22:17:43 2025 daemon.info dnsmasq[1]: read /tmp/hosts/odhcpd - 2 names
Thu Dec 11 22:17:43 2025 daemon.info dnsmasq-dhcp[1]: read /etc/ethers - 0 addresses
Thu Dec 11 22:17:45 2025 daemon.warn odhcpd[1837]: No default route present, setting ra_lifetime to 0!

That still has nothing to do with OpenWrt and is utterly irrelevant and a distraction at best.

1 Like

I update to Openwrt 24.10.5 but the problem about 5Ghz antenna remains


root@OpenWrt:~# ubus call system board
{
        "kernel": "6.6.119",
        "hostname": "OpenWrt",
        "system": "MediaTek MT7621 ver:1 eco:3",
        "model": "CUDY X6 v2",
        "board_name": "cudy,x6-v2",
        "rootfs_type": "squashfs",
        "release": {
                "distribution": "OpenWrt",
                "version": "24.10.5",
                "revision": "r29087-d9c5716d1d",
                "target": "ramips/mt7621",
                "description": "OpenWrt 24.10.5 r29087-d9c5716d1d",
                "builddate": "1766005702"
        }
}
root@OpenWrt:~# logread -f
Sat Dec 20 18:46:23 2025 daemon.notice netifd: radio0 (5079): WARNING: Variable 'data' does not exist or is not an array/object
Sat Dec 20 18:46:24 2025 daemon.notice hostapd: Set new config for phy phy0:
Sat Dec 20 18:46:24 2025 daemon.notice wpa_supplicant[1674]: Set new config for phy phy0
Sat Dec 20 18:46:24 2025 daemon.notice wpa_supplicant[1674]: Set new config for phy phy0
Sat Dec 20 18:46:24 2025 daemon.notice hostapd: Set new config for phy phy0: /var/run/hostapd-phy0.conf
Sat Dec 20 18:46:24 2025 daemon.notice hostapd: Restart interface for phy phy0
Sat Dec 20 18:46:24 2025 daemon.notice hostapd: Configuration file: <inline> (phy phy0) --> new PHY
Sat Dec 20 18:46:24 2025 daemon.notice hostapd: Configuration file: Reading configuration file '<inline>'
Sat Dec 20 18:46:24 2025 kern.info kernel: [  494.945256] br-lan: port 5(phy0-ap0) entered blocking state
Sat Dec 20 18:46:24 2025 kern.info kernel: [  494.951073] br-lan: port 5(phy0-ap0) entered disabled state
Sat Dec 20 18:46:24 2025 kern.info kernel: [  494.956760] mt7915e 0000:02:00.0 phy0-ap0: entered allmulticast mode
Sat Dec 20 18:46:24 2025 kern.info kernel: [  494.963981] mt7915e 0000:02:00.0 phy0-ap0: entered promiscuous mode
Sat Dec 20 18:46:25 2025 daemon.notice netifd: Network device 'phy0-ap0' link is up
Sat Dec 20 18:46:25 2025 kern.info kernel: [  495.073954] br-lan: port 5(phy0-ap0) entered blocking state
Sat Dec 20 18:46:25 2025 kern.info kernel: [  495.079621] br-lan: port 5(phy0-ap0) entered forwarding state
Sat Dec 20 18:46:25 2025 daemon.notice hostapd: phy0-ap0: interface state UNINITIALIZED->ENABLED
Sat Dec 20 18:46:25 2025 daemon.notice hostapd: phy0-ap0: AP-ENABLED
Sat Dec 20 18:46:25 2025 daemon.notice netifd: Wireless device 'radio0' is now up
Sat Dec 20 18:46:26 2025 daemon.info dnsmasq[1]: read /etc/hosts - 12 names
Sat Dec 20 18:46:26 2025 daemon.info dnsmasq[1]: read /tmp/hosts/dhcp.cfg01411c - 4 names
Sat Dec 20 18:46:26 2025 daemon.info dnsmasq-dhcp[1]: read /etc/ethers - 0 addresses
Sat Dec 20 18:46:27 2025 daemon.warn odhcpd[1839]: No default route present, setting ra_lifetime to 0!
Sat Dec 20 18:46:32 2025 daemon.notice netifd: radio1 (5444): WARNING: Variable 'data' does not exist or is not an array/object
Sat Dec 20 18:46:32 2025 daemon.notice hostapd: Set new config for phy phy1:
Sat Dec 20 18:46:32 2025 daemon.notice wpa_supplicant[1674]: Set new config for phy phy1
Sat Dec 20 18:46:33 2025 daemon.notice wpa_supplicant[1674]: Set new config for phy phy1
Sat Dec 20 18:46:33 2025 daemon.notice hostapd: Set new config for phy phy1: /var/run/hostapd-phy1.conf
Sat Dec 20 18:46:33 2025 daemon.notice hostapd: Restart interface for phy phy1
Sat Dec 20 18:46:33 2025 daemon.notice hostapd: Configuration file: <inline> (phy phy1) --> new PHY
Sat Dec 20 18:46:33 2025 daemon.notice hostapd: Configuration file: Reading configuration file '<inline>'
Sat Dec 20 18:46:33 2025 daemon.err hostapd: Line 7: Invalid country_code '00'
Sat Dec 20 18:46:33 2025 daemon.err hostapd: Cannot enable IEEE 802.11d without setting the country_code
Sat Dec 20 18:46:33 2025 daemon.err hostapd: 2 errors found in configuration file '<inline>'
Sat Dec 20 18:46:33 2025 daemon.err hostapd: Failed to set up interface with data: driver=nl80211 logger_syslog=127 logger_syslog_level=2 logger_stdout=127 logger_stdout_level=2 country_code=00 ieee80211d=1 ieee80211h=1 hw_mode=a beacon_int=100 stationary_ap=1 chanlist=36 tx_queue_data2_burst=2.0 #num_global_macaddr=1 #macaddr_base= ieee80211n=1 ht_coex=0 ht_capab=[HT40+][LDPC][SHORT-GI-20][SHORT-GI-40][TX-STBC][RX-STBC1][MAX-AMSDU-7935] ieee80211ac=1 vht_oper_chwidth=1 vht_oper_centr_freq_seg0_idx=42 vht_capab=[RXLDPC][SHORT-GI-80][TX-STBC-2BY1][SU-BEAMFORMER][SU-BEAMFORMEE][MU-BEAMFORMER][MU-BEAMFORMEE][RX-ANTENNA-PATTERN][TX-ANTENNA-PATTERN][RX-STBC-1][SOUNDING-DIMENSION-2][BF-ANTENNA-2][MAX-MPDU-7991][MAX-A-MPDU-LEN-EXP7] ieee80211ax=1 he_oper_chwidth=1 he_oper_centr_freq_seg0_idx=42 he_su_beamformer=1 he_su_beamformee=1 he_mu_beamformer=1 he_bss_color=128 he_spr_sr_control=3 he_default_pe_duration=4 he_rts_threshold=1023 he_mu_edca_qos_info_param_count=0 he_mu_edca_qos_info_q_ack=0 he_mu_edca_qos_info_queue_request=0 h
Sat Dec 20 18:46:33 2025 daemon.notice hostapd: hostapd.add_iface failed for phy phy1 ifname=phy1-ap0
Sat Dec 20 18:46:33 2025 daemon.notice netifd: Wireless device 'radio1' is now up
Sat Dec 20 18:46:35 2025 daemon.info dnsmasq[1]: read /etc/hosts - 12 names
Sat Dec 20 18:46:35 2025 daemon.info dnsmasq[1]: read /tmp/hosts/dhcp.cfg01411c - 4 names
Sat Dec 20 18:46:35 2025 daemon.info dnsmasq-dhcp[1]: read /etc/ethers - 0 addresses
Sat Dec 20 18:46:36 2025 daemon.warn odhcpd[1839]: No default route present, setting ra_lifetime to 0!
^Croot@OpenWrt:~# cat /etc/config/wireless

config wifi-device 'radio0'
        option type 'mac80211'
        option path '1e140000.pcie/pci0000:00/0000:00:01.0/0000:02:00.0'
        option band '2g'
        option channel '1'
        option htmode 'HE20'

config wifi-iface 'default_radio0'
        option device 'radio0'
        option network 'lan'
        option mode 'ap'
        option ssid 'OpenWrt'
        option encryption 'none'

config wifi-device 'radio1'
        option type 'mac80211'
        option path '1e140000.pcie/pci0000:00/0000:00:01.0/0000:02:00.0+1'
        option band '5g'
        option channel '36'
        option htmode 'HE80'
        option country '00'
        option cell_density '0'

config wifi-iface 'default_radio1'
        option device 'radio1'
        option network 'lan'
        option mode 'ap'
        option ssid 'OpenWrt'
        option encryption 'none'

You forgot to set the country code to the right one for your location.
Please do so on both radios (2,4 and 5G).

1 Like

You are restoring cudy config on OpenWRT, that !ill never work.

Thanks for the suggestions. I set the country code, but it still didn't work. However, I tried again with the following commands
wifi down # Stops WiFi
rmmod mt7915e # Removes the driver module
sleep 3 # 3-second pause
modprobe mt7915e # Reloads the driver
wifi up # Restarts WiFi

and the 5GHz antenna works:

root@OpenWrt:~# wifi down
root@OpenWrt:~# rmmod mt7915e

root@OpenWrt:~# sleep 3

root@OpenWrt:~# modprobe mt7915e
root@OpenWrt:~# wifi up
root@OpenWrt:~# iw dev
phy#3
        Interface phy3-ap0
                ifindex 12
                wdev 0x300000001
                addr 00:00:00:00:00:00
                ssid OpenWrt
                type AP
                channel 36 (5180 MHz), width: 80 MHz, center1: 5210 MHz
                txpower 23.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
phy#2
        Interface phy2-ap0
                ifindex 11
                wdev 0x200000001
                addr 00:00:00:00:00:00
                ssid OpenWrt
                type AP
                channel 1 (2412 MHz), width: 20 MHz, center1: 2412 MHz
                txpower 20.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
root@OpenWrt:~# logread | tail -30
Sun Dec 21 21:27:17 2025 daemon.notice hostapd: Restart interface for phy phy2
Sun Dec 21 21:27:17 2025 daemon.notice hostapd: Configuration file: <inline> (phy phy2) --> new PHY
Sun Dec 21 21:27:17 2025 daemon.notice hostapd: Configuration file: Reading configuration file '<inline>'
Sun Dec 21 21:27:17 2025 kern.info kernel: [  583.830346] br-lan: port 5(phy2-ap0) entered blocking state
Sun Dec 21 21:27:17 2025 kern.info kernel: [  583.836007] br-lan: port 5(phy2-ap0) entered disabled state
Sun Dec 21 21:27:17 2025 kern.info kernel: [  583.841862] mt7915e 0000:02:00.0 phy2-ap0: entered allmulticast mode
Sun Dec 21 21:27:17 2025 kern.info kernel: [  583.849037] mt7915e 0000:02:00.0 phy2-ap0: entered promiscuous mode
Sun Dec 21 21:27:17 2025 daemon.notice hostapd: phy2-ap0: interface state UNINITIALIZED->COUNTRY_UPDATE
Sun Dec 21 21:27:17 2025 kern.info kernel: [  583.959621] br-lan: port 5(phy2-ap0) entered blocking state
Sun Dec 21 21:27:17 2025 kern.info kernel: [  583.965291] br-lan: port 5(phy2-ap0) entered forwarding state
Sun Dec 21 21:27:17 2025 daemon.notice netifd: Network device 'phy2-ap0' link is up
Sun Dec 21 21:27:17 2025 daemon.notice hostapd: phy2-ap0: interface state COUNTRY_UPDATE->ENABLED
Sun Dec 21 21:27:17 2025 daemon.notice hostapd: phy2-ap0: AP-ENABLED
Sun Dec 21 21:27:17 2025 daemon.notice hostapd: Set new config for phy phy3: /var/run/hostapd-phy3.conf
Sun Dec 21 21:27:17 2025 daemon.notice hostapd: Restart interface for phy phy3
Sun Dec 21 21:27:17 2025 daemon.notice hostapd: Configuration file: <inline> (phy phy3) --> new PHY
Sun Dec 21 21:27:17 2025 daemon.notice hostapd: Configuration file: Reading configuration file '<inline>'
Sun Dec 21 21:27:18 2025 kern.info kernel: [  584.146262] br-lan: port 6(phy3-ap0) entered blocking state
Sun Dec 21 21:27:18 2025 kern.info kernel: [  584.152158] br-lan: port 6(phy3-ap0) entered disabled state
Sun Dec 21 21:27:18 2025 kern.info kernel: [  584.158039] mt7915e 0000:02:00.0 phy3-ap0: entered allmulticast mode
Sun Dec 21 21:27:18 2025 kern.info kernel: [  584.165368] mt7915e 0000:02:00.0 phy3-ap0: entered promiscuous mode
Sun Dec 21 21:27:18 2025 kern.info kernel: [  584.172323] br-lan: port 6(phy3-ap0) entered blocking state
Sun Dec 21 21:27:18 2025 kern.info kernel: [  584.178010] br-lan: port 6(phy3-ap0) entered forwarding state
Sun Dec 21 21:27:18 2025 daemon.notice hostapd: phy3-ap0: interface state UNINITIALIZED->COUNTRY_UPDATE
Sun Dec 21 21:27:18 2025 daemon.notice hostapd: phy3-ap0: interface state COUNTRY_UPDATE->HT_SCAN
Sun Dec 21 21:27:18 2025 daemon.notice netifd: Wireless device 'radio0' is now up
Sun Dec 21 21:27:18 2025 daemon.notice netifd: Wireless device 'radio1' is now up
Sun Dec 21 21:27:18 2025 daemon.notice netifd: Network device 'phy3-ap0' link is up
Sun Dec 21 21:27:18 2025 daemon.notice hostapd: phy3-ap0: interface state HT_SCAN->ENABLED
Sun Dec 21 21:27:18 2025 daemon.notice hostapd: phy3-ap0: AP-ENABLED

However, when I restart, the antenna stops working again.

Suggestions?

Try resetting to defaults. Then log in and set only the country code. Then enable the wifi and see if it comes up.

Warning: this will be an open ssid, so don’t keep it this way beyond a few moments for testing.

Yes, the network is open to simplify testing.

For now, I have entered the commands in /etc/rc.local

sleep 8
wifi down
rmmod mt7915e 2>/dev/null
sleep 2
modprobe mt7915e
sleep 2
wifi up

It works!

Where did the script come from? Is it ai generated?

1 Like

options mt7915e disable_aspm=1

this can be added to (sysupgrade-preserved) /etc/modules.conf , otherwise it apllies only on 2nd iteration ohf your script.