Search Linux Wireless

Re: rtw89 driver and compressed firmware files

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 7/18/23 00:33, Takashi Iwai wrote:

Thanks Larry, but I guess that it happens only for multi versions such
as rtw8852b that have rtw8852a_fw.bin and rtw8852a_fw-1.bin, while
yours is rtw8851b that has only one firmware version.

And, the driver might look as if still "working".  IIUC, it's only
that the new firmware version won't be used as long as the firmware
files are compressed.

You can see more details by passing firmware_class.dyndbg=+p boot
option.

All of this was done using Tumbleweed. My next step will be to try
Leap 15.5 and Leap 15.4. I will report those tests later.

Note that the problem of the firmware loader is likely irrelevant with
the actual issue in the bugzilla entry above; I only gave as a
reference.

It seems that the bug there was due to the error:

   rtw89_8852be 0000:02:00.0: [ERR]pci config read 719
   rtw89_8852be 0000:02:00.0: [ERR] pcie autok fail -22
   rtw89_8852be 0000:02:00.0: failed to setup chip information

Since reloading the module works, this might be related with the PCI
power state or something else.  But it's a different topic from this
thread, which is about the firmware loader problem.

Takashi,

When I switched my NIC to an RTW8852BE, which does have 2 versions of the firmware, I still got a successful firmware load for Tumbleweed running the new kernel 6.4.3-1, on Leap 15.5, and on Leap 15.4. The only problem was that file rtw8852b_fw.bin.xz is loaded, and not the newer rtw8852b_fw-1.bin.xz, which is preferable. This was try for the drivers in kernel 6.4.3, 6.5.0-rc2, and in the GitHub repo.

When I stripped the code in rtw89_early_fw_feature_recognize() to never try to run request_partial_firmware_into_buf(), then the newest firmware is loaded. The logs showed the following:

[ 834.438601] firmware_class: __free_fw_priv: fw-rtw89/rtw8852b_fw.bin fw_priv=000000000849addc data=00000000fd3cabe2 size=1035232 [ 834.438658] firmware_class: fw_name_devm_release: fw_name-rtw89/rtw8852b_fw.bin devm-000000002d8c3343 released [ 846.992333] firmware_class: __allocate_fw_priv: fw-rtw89/rtw8852b_fw-1.bin fw_priv=000000009e1a6364 [ 846.992352] rtw89_8852be 0000:02:00.0: loading /lib/firmware/updates/6.4.3-1-default/rtw89/rtw8852b_fw-1.bin failed for no such file or directory. [ 846.992357] rtw89_8852be 0000:02:00.0: loading /lib/firmware/updates/rtw89/rtw8852b_fw-1.bin failed for no such file or directory. [ 846.992361] rtw89_8852be 0000:02:00.0: loading /lib/firmware/6.4.3-1-default/rtw89/rtw8852b_fw-1.bin failed for no such file or directory. [ 846.992366] rtw89_8852be 0000:02:00.0: loading /lib/firmware/rtw89/rtw8852b_fw-1.bin failed for no such file or directory. [ 846.992371] rtw89_8852be 0000:02:00.0: loading /lib/firmware/updates/6.4.3-1-default/rtw89/rtw8852b_fw-1.bin.zst failed for no such file or directory. [ 846.992375] rtw89_8852be 0000:02:00.0: loading /lib/firmware/updates/rtw89/rtw8852b_fw-1.bin.zst failed for no such file or directory. [ 846.992378] rtw89_8852be 0000:02:00.0: loading /lib/firmware/6.4.3-1-default/rtw89/rtw8852b_fw-1.bin.zst failed for no such file or directory. [ 846.992391] rtw89_8852be 0000:02:00.0: loading /lib/firmware/rtw89/rtw8852b_fw-1.bin.zst failed for no such file or directory. [ 846.992396] rtw89_8852be 0000:02:00.0: loading /lib/firmware/updates/6.4.3-1-default/rtw89/rtw8852b_fw-1.bin.xz failed for no such file or directory. [ 846.992399] rtw89_8852be 0000:02:00.0: loading /lib/firmware/updates/rtw89/rtw8852b_fw-1.bin.xz failed for no such file or directory. [ 846.992402] rtw89_8852be 0000:02:00.0: loading /lib/firmware/6.4.3-1-default/rtw89/rtw8852b_fw-1.bin.xz failed for no such file or directory. [ 846.997453] rtw89_8852be 0000:02:00.0: Loading firmware from /lib/firmware/rtw89/rtw8852b_fw-1.bin.xz
[  846.997456] rtw89_8852be 0000:02:00.0: f/w decompressing rtw89/rtw8852b_fw-1.bin
[ 847.014261] firmware_class: fw_set_page_data: fw-rtw89/rtw8852b_fw-1.bin fw_priv=000000009e1a6364 data=00000000fd3cabe2 size=1184992 [ 847.019276] rtw89_8852be 0000:02:00.0: Loaded FW: rtw89/rtw8852b_fw-1.bin, sha256: 8539efc75f513f4585cf0cd6e79e6507da47fce87225f2d0de391a03aefe9ac8
[  847.019280] rtw89_8852be 0000:02:00.0: loaded firmware rtw89/rtw8852b_fw-1.bin
[ 847.021436] rtw89_8852be 0000:02:00.0: Firmware version 0.29.29.1, cmd version 0, type 5 [ 847.021442] rtw89_8852be 0000:02:00.0: Firmware version 0.29.29.1, cmd version 0, type 3
[  847.362658] rtw89_8852be 0000:02:00.0: chip rfe_type is 1
[  847.397754] rtw89_8852be 0000:02:00.0 wls1: renamed from wlan0

I want Ping-Ke to look at my patch. If he agrees, I will push it to GitHub, and it will be picked up in the openSUSE repos for 15.4 and 15.5.

Larry





[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux