diff mbox series

[v2] mmc: sdio: add a delay to call sdio_irq_work when sdio bus resume

Message ID 1597835959-22402-1-git-send-email-haibo.chen@nxp.com
State New
Headers show
Series [v2] mmc: sdio: add a delay to call sdio_irq_work when sdio bus resume | expand

Commit Message

Bough Chen Aug. 19, 2020, 11:19 a.m. UTC
From: Haibo Chen <haibo.chen@nxp.com>

Find this issue on i.MX7D-sdb board with broadcom sdio wifi.
When system resume, sometimes this wifi meet the tuning fail issue.
All tuning command get command timeout error. This is because
sdio_irq_work on system_wq was executed before the broadcom
wifi driver resume. Due to broadcom wifi driver set the wifi in
Sleep sate in system suspend, need to set the wifi to Wake state
first. So need to make sure wifi driver resume first, then do the

Fixes: 51133850bce2 ("mmc: core: Fixup processing of SDIO IRQs during system suspend/resume")
Signed-off-by: Haibo Chen <haibo.chen@nxp.com>
 drivers/mmc/core/sdio.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series


diff --git a/drivers/mmc/core/sdio.c b/drivers/mmc/core/sdio.c
index 7b40553d3934..101632617f69 100644
--- a/drivers/mmc/core/sdio.c
+++ b/drivers/mmc/core/sdio.c
@@ -1047,7 +1047,7 @@  static int mmc_sdio_resume(struct mmc_host *host)
 		if (!(host->caps2 & MMC_CAP2_SDIO_IRQ_NOTHREAD))
 		else if (host->caps & MMC_CAP_SDIO_IRQ)
-			queue_delayed_work(system_wq, &host->sdio_irq_work, 0);
+			queue_delayed_work(system_wq, &host->sdio_irq_work, 1);