[Letux-kernel] omap_hsmmc + gta04 + sdio irq + runtime_suspend + 4 bit = trouble

Tony Lindgren tony at atomide.com
Mon Nov 12 21:49:48 CET 2018

* Andreas Kemnade <andreas at kemnade.info> [181112 19:45]:
> Tony Lindgren <tony at atomide.com> wrote:
> > Looking at the commit above, looks like the sdio irq handling is
> > missing runtime PM calls.. So I wonder if we can just do the
> > following?
> Well, if we have runtime PM calls there, the device will never
> runtime-suspend with sdio irq enabled, so we do not need a working
> wakeup irq.

It should, as it calls this at the end:


So the device should stay awake for a while, the default
value seems to be 100ms.

> > In theory setting the wlan mmc instance autosuspend_timeout_ms to -1
> > in sysfs should then do what your patch is doing except for enabling
> > sdio irq even without a wakeirq configured.
> > 
> Well, if sdio irq is not enabled, then the mentioned functions will
> never be called, so the patch will not change anything...
> But what might be a better idea is to guard this thing by 
> if (host->wakeirq)

If there's no wakeirq configured, then yes an additional
pm_runtime_get() should be done like your patch is doing
to prevent system from idling. From what I recall, the
sdio irq will only work if no idle state is ever entered.



More information about the Letux-kernel mailing list