Commit f76dab80 authored by Wright Feng's avatar Wright Feng Committed by Greg Kroah-Hartman

brcmfmac: keep SDIO watchdog running when console_interval is non-zero

[ Upstream commit eccbf46b ]

brcmfmac host driver makes SDIO bus sleep and stops SDIO watchdog if no
pending event or data. As a result, host driver does not poll firmware
console buffer before buffer overflow, which leads to missing firmware
logs. We should not stop SDIO watchdog if console_interval is non-zero
in debug build.
Signed-off-by: default avatarWright Feng <wright.feng@cypress.com>
Signed-off-by: default avatarChi-hsien Lin <chi-hsien.lin@cypress.com>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/20200604071835.3842-4-wright.feng@cypress.comSigned-off-by: default avatarSasha Levin <sashal@kernel.org>
parent abfa9c47
...@@ -3633,6 +3633,10 @@ static void brcmf_sdio_bus_watchdog(struct brcmf_sdio *bus) ...@@ -3633,6 +3633,10 @@ static void brcmf_sdio_bus_watchdog(struct brcmf_sdio *bus)
if (bus->idlecount > bus->idletime) { if (bus->idlecount > bus->idletime) {
brcmf_dbg(SDIO, "idle\n"); brcmf_dbg(SDIO, "idle\n");
sdio_claim_host(bus->sdiodev->func1); sdio_claim_host(bus->sdiodev->func1);
#ifdef DEBUG
if (!BRCMF_FWCON_ON() ||
bus->console_interval == 0)
#endif
brcmf_sdio_wd_timer(bus, false); brcmf_sdio_wd_timer(bus, false);
bus->idlecount = 0; bus->idlecount = 0;
brcmf_sdio_bus_sleep(bus, true, false); brcmf_sdio_bus_sleep(bus, true, false);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment