2023-05-08 03:20 AM
Hello everyone,
I am trying to integrate the Murata Wi-Fi/BT combo module 1YN in a custom board design based on stm32mp1. The BT part works fine, while the Wi-Fi is not initialized by the system.
Apparently, the chipset variant CYW43439 is not supported by the current OpenSTLinux distribution based on kernel 5.15. Could you please provide instructions on how to support the new chipset?
So far, I tried to apply the following patches to kernel
but I am getting the following error at boot time:
[ 15.312838] brcmfmac: brcmf_fw_alloc_request: Unknown chip BCM43439/5
Does ST plan to release patches to support the new CYW43439 chipset?
Thanks in advance!
2023-05-11 04:17 AM
I've found out that Inineon provides patches for the new chipset CYW4349 here
Cypress Linux WiFi Driver Release (FMAC) [2023-02-... - Infineon Developer Community
but the kernel source to which the patches are applied is quite different from the OpenSTLinux one, can you provide support on the integration of these patches?
2023-05-23 05:09 AM
Any news on this on the ST side?
2023-05-23 06:54 AM
Hi,
I'm not expert, it is up to chipset vendor to manage their Linux drivers.
As far as I know, seems there is two IDs for same chipset one from Broadcom, one for Cypress (0xa9af and 0xbd3d).
See history of https://github.com/torvalds/linux/blob/master/include/linux/mmc/sdio_ids.h
maybe this is enough: https://github.com/torvalds/linux/commit/cc4cffc3c142d57df48c07851862444e1d33bdaa
Regards.
In order to give better visibility on the answered topics, please click on 'Select as Best' on the reply which solved your issue or answered your question. See also 'Best Answers'
2023-06-06 08:12 AM
Hello @PatrickF ,
I managed to compile the driver modules out-of-tree in a workspace, using devtool. To do so, I had to disable some features of my kernel using menuconfig. I automatized these procedure using fragments and linux-stm32mp_%.bbappend recipe. (let's call the output of this recipe "kernel A")
Then, I worked out the recipe for the target modules using devtools and built it. The output of this recipe are the patched .ko modules and a new uImage of my kernel. (let's call it "kernel B")
When I try to manually insert the patched .ko modules in kernel A, I obtain:
root@tiger:~/infineon# insmod compat.ko
[ 361.738713] compat: disagrees about version of symbol module_layout
insmod: ERROR: could not insert module compat.ko: Invalid module format
root@tiger:~/infineon# uname -ar
Linux tiger 5.15.24 #1 SMP PREEMPT Wed Feb 16 11:56:41 UTC 2022 armv7l armv7l armv7l GNU/Linux
root@tiger:~/infineon# modinfo compat.ko
filename: /home/root/infineon/compat.ko
version: backported from Linux (v5.15.58-2023_0222-0-gd4d1a61163b5) using backports v5.15.58-1-0-g42a95ce7
license: GPL
description: Kernel backport module
author: Luis R. Rodriguez
srcversion: B4DC065C5A4358B469C48C1
depends:
name: compat
vermagic: 5.15.24 preempt mod_unload modversions ARMv7 p2v8
parm: backported_kernel_name:The kernel tree name that was used for this backport (Linux) (charp)
parm: backported_kernel_version:The kernel version that was used for this backport (v5.15.58-2023_0222-0-gd4d1a61163b5) (charp)
parm: backports_version:The git version of the backports tree used to generate this backport (v5.15.58-1-0-g42a95ce7) (charp)
So, I decided to give a shot and load kernel B into my custom board
root@tiger:~/infineon# insmod compat.ko
[ 305.068441] compat: loading out-of-tree module taints kernel.
[ 305.073041] compat: module verification failed: signature and/or required key missing - tainting kernel
[ 305.150118] Loading modules backported from Linux version v5.15.58-2023_0222-0-gd4d1a61163b5
[ 305.198075] Backport generated by backports.git v5.15.58-1-0-g42a95ce7
root@tiger:~/infineon# insmod cfg80211.ko
[ 309.628293] cfg80211: Loading compiled-in X.509 certificates for regulatory database
[ 309.746817] cfg80211: Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7'
root@tiger:~/infineon# insmod brcmutil.ko
root@tiger:~/infineon# insmod brcmfmac.ko
[ 316.903579] brcmfmac: brcmf_fw_alloc_request: using cypress/cyfmac43439-sdio for chip BCM43439/5
[ 316.925578] brcmfmac: brcmf_fw_request_firmware: no board-specific nvram available (ret=-2), device will use cypress/cyfmac43439-sdio.txt
[ 316.956418] usbcore: registered new interface driver brcmfmac
[ 317.223759] brcmfmac: brcmf_fw_alloc_request: using cypress/cyfmac43439-sdio for chip BCM43439/5
[ 317.313898] brcmfmac: brcmf_c_preinit_dcmds: Firmware: BCM43439/5 wl0: Jul 27 2022 21:09:12 version 7.95.55 (68e5ffa CY) FWID 01-5b0a1ea
root@tiger:~/infineon# ip link ls
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DEFAULT group default qlen 1000
link/ether 26:d4:12:1d:46:53 brd ff:ff:ff:ff:ff:ff
3: wlan0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000
link/ether dc:fe:23:b7:bb:b6 brd ff:ff:ff:ff:ff:ff
root@tiger:~/infineon# uname -ar
Linux tiger 5.15.24 #1 PREEMPT Wed Feb 16 11:56:41 UTC 2022 armv7l armv7l armv7l GNU/Linux
The problem is that, using kernel B most of my other original drivers are incompatible
root@tiger:~/infineon# dmesg | grep -i layout
[ 0.238055] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[ 0.238093] nfs4flexfilelayout_init: NFSv4 Flexfile Layout Driver Registering...
[ 9.776700] ipv6: disagrees about version of symbol module_layout
[ 9.790907] x_tables: disagrees about version of symbol module_layout
[ 14.119506] ipv6: disagrees about version of symbol module_layout
[ 14.201227] ipv6: disagrees about version of symbol module_layout
[ 14.314643] ipv6: disagrees about version of symbol module_layout
[ 14.917343] sch_fq_codel: disagrees about version of symbol module_layout
[ 20.547354] soundcore: disagrees about version of symbol module_layout
[ 20.767534] snd_soc_stm32_sai: disagrees about version of symbol module_layout
[ 20.855474] libaes: disagrees about version of symbol module_layout
[ 20.929297] stm32_adc_core: disagrees about version of symbol module_layout
[ 22.365380] libcomposite: disagrees about version of symbol module_layout
[ 22.668061] soundcore: disagrees about version of symbol module_layout
[ 29.094058] cfg80211: disagrees about version of symbol module_layout
[ 33.086785] ipv6: disagrees about version of symbol module_layout
[ 34.475737] ipv6: disagrees about version of symbol module_layout
[ 34.629709] ipv6: disagrees about version of symbol module_layout
[ 327.124645] libaes: disagrees about version of symbol module_layout
What I would like to do is to apply my workspace recipe (the one producing the patched ko modules) on top of linux-stm32mp_%.bbappend recipe, so that the compatiblity with kernel A is preserved. What is the best way to do so?