[Banana BPI-R4] Wifi7 status

Guys, so i have a mt7925e card on the R4. Installed openwrt's snapshot from yesterday, 2024-07-22. Installed the kmod for mt7925e and also downloaded the respective firmware in /lib/firmware/mediatek/mt7925/, when loading the module i got this:

root@OpenWrt:/# modprobe  mt7925e
[  274.685725] mt7925e 0000:01:00.0: assign IRQ: got 112
[  274.690818] mt7925e 0000:01:00.0: enabling device (0000 -> 0002)
[  274.696842] mt7925e 0000:01:00.0: enabling bus mastering
[  274.702238] mtk-pcie-gen3 11300000.pcie: msi#0x1 address_hi 0x0 address_lo 0x11300c00 data 1
[  274.762882] mt7925e 0000:01:00.0: ASIC revision: 79250000
root@OpenWrt:/# [  274.866523] mt7925e 0000:01:00.0: HW/SW Version: 0x8a108a10, Build Time: 20231227093012a
[  274.866523]
[  274.906177] pcieport 0000:00:00.0: AER: Multiple Corrected error message received from 0000:00:00.0
[  274.915242] pcieport 0000:00:00.0: PCIe Bus Error: severity=Corrected, type=Physical Layer, (Receiver ID)
[  274.924800] pcieport 0000:00:00.0:   device [14c3:7988] error status/mask=00000081/00006000
[  274.933146] pcieport 0000:00:00.0:    [ 0] RxErr
[  274.939229] pcieport 0000:00:00.0:    [ 7] BadDLLP
[  275.224206] mt7925e 0000:01:00.0: WM Firmware Version: ____000000, Build Time: 20231227093232

The card does not show up in "ip a". Am i missing some step?

@Casulo it was mentioned in this thread that mt7925 card is supported by kernel 6.7+ Im not sure if with actual OpenWrt snapshot is working...

It is: Linux OpenWrt 6.6.41

But the module do gets loaded, it's just the card does not show up.

BTW, i just went to https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/tree/mediatek/mt7925 and downloaded the fiels via plain mode.

If I do:

dmesg | grep 7925

I can see that I get a probe error with the mt7925e card in OpenWRT snapshot 6.6.x.x

Well, this is kernel 6.6, and so, very early driver for the mt7925.

Probably you need to call wifi.
I got something like that in the /etc/rc.local

modprobe mt7925e
sleep 3
wifi up radio2

exit 0

Of course, check first what radio is used by mt7925.
I'm using firmware that is available in OpenWRT when I build an image. I push it to my repo

Ok, i installed luci and configure ap mode from there, but the network takes a long time to show up on my phone. Same behaviour if i use debian and configure hostapd. So, i just guess the drivers are not very stable yet. Maybe they are ok client mode, but not ap.

Got mt7925e up and running on Banana pi R4 (and raspberry pi) on OpenWRT snapshot today :slight_smile:

Using SNAPSHOT (r27064-f20987c161) and after installing the available 7925 packages I downloaded the correct firmware from git.kernel.org

AP mode 6 GHz 160 Mhz available :slight_smile:
(but probably not working right now)

1 Like

How to install firmware from git.kernel.org?

I'm a Linux beginner, but I have BPI-R4 and I want my 7925 to work with Openwrt.

If you are connected to the Banana pi with ssh, you write:

cd /lib/firmware/mediatek/

make a new folder for the mt7925e firmware:

mkdir mt7925

go to that folder:

cd mt7925

The firmware files are available here:

https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/tree/mediatek/mt7925

You can right klick on the file where it says "plain" and copy the link - then just write "wget" and paste the link - like this:

wget https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/plain/mediatek/mt7925/BT_RAM_CODE_MT7925_1_1_hdr.bin

do it with all three files so you have them all in your folder.

then reboot - after the reboot write:

modprobe mt7925e

and your 7925 card should be working :slight_smile:

3 Likes

Thank you, I will use this new knowledge acquired for other needs.

I performed all the commands, when I perform the last command “modprobe mt7925e” the system freezes, I believe I can find out the reason. My adapter is the MT7925B22M, it is different. Can I install it with this procedure?

No, thats the same card I have so it cant be the reason :slight_smile:

The only thing i can think of is that i also have installed the drivers for mt7921.

I have both mt7921 and mt7922 and you have to install the drivers for 7921 to get 7922 to work.

Try installing every package that have "792" in the name - thats what I have :slight_smile:

1 Like

On OpenWrt 6.6.43 based on https://github.com/openwrt/openwrt/pull/15945/commits/1278a8bca1b66533ef1cdde0dc7cb89e00034764 we can build ath12k module but as mentioned there by hauke we should also build hostapd service with DRIVER_11BE_SUPPORT. Unfortunatelly we have 2 issues here:

  1. make world is not taking actual version of hostapd from github (git clone git://w1.fi/hostap.git) but version from 2024.03.09
  2. hostapd compilation fails with problem with MLD as below:
    /home/openwrt66/openwrt/build_dir/target-aarch64_cortex-a53_musl/hostapd-full-internal/hostapd-2024.03.09~695277a5/src/ap/sta_info.h: In function 'ap_sta_is_mld':
    /home/openwrt66/openwrt/build_dir/target-aarch64_cortex-a53_musl/hostapd-full-internal/hostapd-2024.03.09~695277a5/src/ap/sta_info.h:424:20: error: invalid use of undefined type 'struct hostapd_data'
    424 | return hapd->conf->mld_ap && sta && sta->mld_info.mld_sta;
    | ^~
    make[4]: *** [../src/build.rules:89: /home/openwrt66/openwrt/build_dir/target-aarch64_cortex-a53_musl/hostapd-full-internal/hostapd-2024.03.09~695277a5/build/hostapd/main.o] Error 1
    make[4]: Leaving directory '/home/openwrt66/openwrt/build_dir/target-aarch64_cortex-a53_musl/hostapd-full-internal/hostapd-2024.03.09~695277a5/hostapd'
1 Like

An update to hostapd v2.11/ d945ddd368085f255e68328f2d3b020ceea359af (2024-07-20) probably just depends on someone rebasing the (quite intensive) patchset and providing a tested PR. I wouldn't raise expectations for MLO and full wifi7 feature compatibility with that either, this is still a work in progress (on many fronts).

Thanks for you work - greatly appreciated :slight_smile:

Looking forward to try ath12k when it arrives :slight_smile:

Saw a changlelog for hostapd v2.11 that said:

2024-07-20 - v2.11 * EHT/IEEE 802.11be/Wi-Fi 7 - add preliminary support
Something is happening at least :slight_smile:

Could you please share screen from LUCI Wireless Overview page?

For those who compile images, there is my Makefile from ~/openwrt/package/kernel/mt76/ which allows also to install the firmware for mt7925. I dont know why in orginal one we have dependencies between 7921 and 7925 - I removed it in my file.

My observation 6G not working - perhaps due to changes above :wink:
Only in Legacy it works..

7925

This one ?

Yes, 6GHz does not work.

I installed it on a Nanopi R5S today without a problem, but with a Raspberry pi 5 it did not work - got a probe error.

Yesterday i got it working with Bananapi R4 and a Raspberry pi CM4 in a board with M.2 key e slot.

Hey folks,
I'm using also mt7925 and I don't have any issue to start wireless network on 2.4GHz, 5GHz (without DFS channels) or 6GHz.

config wifi-device 'radio2'
        option type 'mac80211'
        option path 'soc/11300000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0'
        option band '6g'
        option channel '53'
        option country 'PL'
        option cell_density '0'
        option txpower '22'
        option htmode 'HE80'

config wifi-iface 'wifinet3'
        option device 'radio2'
        option mode 'ap'
        option ssid 'Testtest'
        option encryption 'sae'
        option key 'testtest'
        option wnm_sleep_mode '1'
        option bss_transition '1'
        option network 'lan'
        option ieee80211k '1'
        option ocv '0'

All seems to work normally without DFS channels (and that will not work, due the card is a client card, not for production environment or routers dedicated one).

xback has updated hostapd in his staging tree

https://git.openwrt.org/?p=openwrt/staging/xback.git;a=commit;h=783c191ef5e19d2841fc07b437f7655130a18ba6

1 Like

@hauke
Do you (or are you aware of others that) have plans/capacity to update hostapd-common to 2.11/latest to build the foundation for 802.11be in OpenWRT?
(why? -> https://lists.infradead.org/pipermail/hostap/2024-July/042847.html)

Thanks for your fantastic work on OpenWRT! :+1:

1 Like