[RFC PATCH] brcmfmac: add 43751 SDIO ids and initialization

Marc Gonzalez marc.w.gonzalez at free.fr
Tue Mar 7 06:40:05 PST 2023


On 06/03/2023 11:41, Marc Gonzalez wrote:

> On 06/03/2023 11:24, Marc Gonzalez wrote:
> 
>> # cat /sys/bus/sdio/devices/mmc2:0001:1/uevent
>> OF_NAME=wifi
>> OF_FULLNAME=/soc/sd at ffe03000/wifi at 1
>> OF_COMPATIBLE_0=brcm,bcm4329-fmac
>> OF_COMPATIBLE_N=1
>> SDIO_CLASS=00
>> SDIO_ID=02D0:AAE7
>> SDIO_REVISION=0.0
>> MODALIAS=sdio:c00v02D0dAAE7
>>
>> 0xaae7 = 43751
>>
>> Isn't there some overlap between:
>> include/linux/mmc/sdio_ids.h and
>> drivers/net/wireless/broadcom/brcm80211/include/brcm_hw_ids.h ?
>>
>> Reference used: commit d2587c57ffd8dc
>> "brcmfmac: add 43752 SDIO ids and initialization"
>>
>> Looking at all the occurrences of 43752 to insert a 43751,
>> could someone comment whether this looks reasonable?
> 
> Obviously, the commit message would have to be rewritten
> for a real patch.

Help. I am thoroughly confused... :(


Through the SDIO bus, the WiFi chip reports 0xaae7 (i.e. 43751)
hence the /sys/bus/sdio/devices output above.

sdio_read_func_cis() -> sdio_read_cis() which sets
func->vendor/func->device to 2d0/aae7


But when brcmf_chip_recognition() calls ci->ops->read32()
i.e. brcmf_sdio_buscore_read32()
[ vs brcmf_sdiod_readl() in brcmf_sdio_probe_attach() ]

[    1.177283] brcmfmac: F1 signature read @0x18000000=0x1042aae8
[    1.182912] found AXI chip: BCM43752/2
[    1.186384] BCM43752/2: chip=aae8 rev=2 type=1

Here it reports 0xaae8 (i.e. 43752)

Why the discrepancy?
Can it cause issues?
(Sometimes, the whole SDIO bus doesn't probe at boot.
I am still investigating these intermittent problems.)

Should I use 43751 or 43752 firmware...?

Regards.





More information about the linux-amlogic mailing list