On 11/6/2018 4:50 AM, Chi-Hsien Lin wrote:
From: Naveen Gupta <[email protected]>

The number of words that the read FIFO has to contain except
the end of frame before sends data back to the host.
Max watermark = (512B - 2* (BurstLength))/4 =
(512 - 128)/4 = 384/4 = 0x60
so if burst length (i.e. BurstLength = 64) is increased,
watermark has to be reduced. This is the optimal setting for this chip.

Nice formula. So could the BurstLength be retrieved from firmware so the driver can determine and update the F2 watermark in brcmf_sdio_bus_preinit().

Reviewed-by: Arend van Spriel <[email protected]>
Signed-off-by: Naveen Gupta <[email protected]>
Signed-off-by: Chi-Hsien Lin <[email protected]>
---
 drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

Reply via email to