Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

yasa_4608926
Level 4
Level 4
100 sign-ins 10 replies posted 10 questions asked

Hi,

I am evaluating the FMAC driver using following.

- FMAC v4.14.77-2019_0503

- CYW4343W (SDIO)

- Ubuntu 16.04

I would like to implement the recovery operation when CYW4343W(firmware) hangs or freezes.

I have a few questions.

1.

Is there an event(or interrupt) that occurs when CYW4343W(firmware) hangs or freezes?

If there is no event, How can I know that a hang or freeze has occurred?

2.

I think a timeout error will occur in the SDIO driver if there is no response from the CYW4343W(firmware) for some reason.

Is this correct?

Best regards,

Yasa

1 Solution

Also when a firmware freezes, the message "resumed on timeout" is observed in the console. This is called by brcmf_sdio_bus_rxctl(). There could be a firmware trap indicated by brcmf_sdio_checkdied(). You can obtain WLAN firmware logs for further debugging by enabling the debug flag BRCMF_FWCON_VAL or 0x00100000 during WLAN bring-up or insmod brcmfmac.ko debug=0x00100000.

View solution in original post

4 Replies
GauravS_31
Moderator
Moderator
Moderator
250 solutions authored 250 sign-ins First comment on KBA

1. If the firmware hangs, it will not respond to the IOVAR calls from the driver. Here is the sequence of calls from IOVAR being set:

brcmf_fil_iovar_int_set() fwil.c

brcmf_fil_iovar_data_set() fwil.c

brcmf_fil_cmd_data() fwil.c

brcmf_proto_set_dcmd() fwil.c

brcmf_proto_bcdc_msg() bcdc.c

brcmf_bus_txctl() bcdc.c

brcmf_sdio_bus_txctl() sdio.c

You can consider debugging along the path. You can consider enabling the following debug flags in debug.h:

BRCMF_SDIO_VAL

BRCMF_FIL_VAL

Also there is brcmf_sdiod_ib_irqhandler() and brcmf_sdiod_oob_irqhandler() for in-band and OOB interrupts respectively. You can enable BRCMF_INTR_VAL to enable interrupt debugging.

2. Yes. There is timeout error -ETIMEDOUT that is returned by brcmf_sdio_bus_txctl() and brcmf_sdio_bus_rxctl() if there is a timeout. This error can be traced back to brcmf_fil_iovar_int_set() since this is a returning function. The debug function brcmf_err() can be enabled to check for return values.

Thank you for your information.

I will check the C source and behavior.

Best regards,

Yasa

0 Likes

Also when a firmware freezes, the message "resumed on timeout" is observed in the console. This is called by brcmf_sdio_bus_rxctl(). There could be a firmware trap indicated by brcmf_sdio_checkdied(). You can obtain WLAN firmware logs for further debugging by enabling the debug flag BRCMF_FWCON_VAL or 0x00100000 during WLAN bring-up or insmod brcmfmac.ko debug=0x00100000.

Thank you for your update.

I'm sorry for my late reply. It is very helpful.

I will use the information related to timeout.

Best regards,

Yasa

0 Likes