[pull] radeon and amdgpu drm-next-4.9
Lukas Wunner
lukas at wunner.de
Fri Sep 16 21:38:48 UTC 2016
On Fri, Sep 16, 2016 at 04:42:43PM -0400, Alex Deucher wrote:
> drm/amdgpu: skip suspend/resume on DRM_SWITCH_POWER_DYNAMIC_OFF
> drm/radeon: skip suspend/resume on DRM_SWITCH_POWER_DYNAMIC_OFF
Those two are unnecessary, it can't happen that the ->suspend hook
is executed with the device runtime suspended.
Since commit d14d2a8453d6 ("drm: Remove dev_pm_ops from drm_class"),
DRM devices are afforded direct_complete, i.e. if the GPU is runtime
suspended upon system sleep, it is left in this state. The only
callbacks that are executed are the ->prepare and the ->complete hook.
All the callbacks in-between, like ->suspend, are skipped.
Even if direct_complete is not afforded for some reason, the PM core
will automatically runtime resume the device before executing ->suspend.
That ->suspend is skipped in the DRM_SWITCH_POWER_OFF case was done
because the device is suspended behind the PM core's back if runpm=0
is set. (And it doesn't work properly because the PCI core will
invalidate the saved_state during ->resume_noirq. That could be
solved by returning 1 from the ->prepare hook in the DRM_SWITCH_POWER_OFF
case, but that's a different story.)
(Sorry for not raising this earlier, I'm not subscribed to amd-gfx.)
Best regards,
Lukas
More information about the amd-gfx
mailing list