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

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

 



On 08/03/2023 18:21, Franky Lin wrote:
On Wed, Mar 8, 2023 at 4:48 AM Marc Gonzalez <marc.w.gonzalez@xxxxxxx> wrote:

On 08/03/2023 00:15, Franky Lin wrote:

On Tue, Mar 7, 2023 at 6:40 AM Marc Gonzalez wrote:

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...?

This question should be answered by the Cypress/Infineon folks but
unfortunately they have been quiet for a long time. In general we use
the id read from 0x18000000 to decide which firmware to load. But be
aware that the rev also matters. There are some examples in
brcmf_sdio_fwnames table that the different firmware name can be
derived from the same chip common id but different rev.

However sdio device enumeration happens before firmware download so
the intermittent problem you are facing probably is not related to
firmware version.

Disclosure: My knowledge of SDIO device enumeration is 0.

When the host sends the equivalent of an "identify yourself" message
on the SDIO bus, doesn't the reply come from the WiFi device?
Why would the device reply 0xaae7 instead of 0xaae8?

In other words, who is replying 0xaae7?

The enumeration response is done by the HW sdio core on the chip.  No
software involved.

Mark,

This would be the:
	BRCMF_SDIO_DEVICE(SDIO_DEVICE_ID_BROADCOM_CYPRESS_43751, CYW),
which is returned by the SDIO bus and associated the SDIO device with the brcmf driver.

All the other IDs are returned by reading registers/send commands to the SDIO device.

Neil

Regards,
- Franky




[Index of Archives]     [Linux Memonry Technology]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux