wlcore: Use generic runtime pm calls for wowlan elp configuration
Quoted 16 lines
Quoted 3 lines
Quoted 3 lines
With runtime PM enabled, we can now use generic calls to
pm_generic_runtime_suspendandpm_generic_runtime_resumeforenabling elp
Quoted 7 lines
Quoted 2 lines
during suspend when wowlan is enabled and waking the chip from elp on resume.
Sry, but not sure you can :(
These functions are not used by drivers directly because system suspend are not synchronized with PM runtime, so if you call
pm_generic_runtime_suspend()Quoted 4 lines
and, at the same time, there is
pm_runtime_get_()in progress --> race ...The
pm_runtime_force_()APIs have to be used, or
PM runtime drivers functions can be called directly, but only if it possible to
Quoted 8 lines
be
Quoted 1 line
sure no other PM runtime calls active which is usually true at
suspend_noirqstage.Oh right, those are subsystem calls. Seems like pm_runtime_force_suspend/resume() should work here, Eyal?
Oh, nice, wasn't aware of the pm_runtime_force_() calls. For some reason they are not documented in:
https://www.kernel.org/doc/Documentation/power/runtime_pm.txt
Perhaps they should be?
Anyway I have tried them instead of pm_generic_runtime_() and they seem To work fine on my platform.
Will test some more and submit a v2.
Best Regards,
Eyal
Quoted 25 lines · Reizer, Eyal
Quoted 16 lines
Quoted 3 lines
Quoted 3 lines
With runtime PM enabled, we can now use generic calls to
pm_generic_runtime_suspendandpm_generic_runtime_resumeforenabling elp
Quoted 7 lines
Quoted 2 lines
during suspend when wowlan is enabled and waking the chip from elp on resume.
Sry, but not sure you can :(
These functions are not used by drivers directly because system suspend are not synchronized with PM runtime, so if you call
pm_generic_runtime_suspend()Quoted 4 lines
and, at the same time, there is
pm_runtime_get_()in progress --> race ...The
pm_runtime_force_()APIs have to be used, or
PM runtime drivers functions can be called directly, but only if it possible toQuoted 8 lines
be
Quoted 1 line
sure no other PM runtime calls active which is usually true at
suspend_noirqstage.Oh right, those are subsystem calls. Seems like pm_runtime_force_suspend/resume() should work here, Eyal?
Quoted 4 lines
Oh, nice, wasn't aware of the
pm_runtime_force_()calls. For some reason they are not documented in:
https://www.kernel.org/doc/Documentation/power/runtime_pm.txt
Perhaps they should be?
Sure why not submit a patch for that.
Quoted 3 lines
Anyway I have tried them instead of
pm_generic_runtime_()and they seem To work fine on my platform.
Will test some more and submit a v2.
OK I'll your pick v2 into my series.
Regards,
Tony