Thread (3 messages) 3 messages, 3 authors, 2014-10-30

[RFC 1/2] PM / Domains: Power on domain early during system resume

From: Krzysztof Kozlowski <hidden>
Date: 2014-10-30 07:36:41
Also in: dri-devel, linux-pm, linux-samsung-soc, lkml

On ?ro, 2014-10-29 at 10:46 -0700, Kevin Hilman wrote:
Krzysztof Kozlowski [off-list ref] writes:
quoted
When resuming the system the power domain has to be powered on early so
any runtime PM aware devices could resume.

This fixes following scenario reproduced on Exynos DRM:
1. Power domain is off before suspending the system.
2. System is suspended to RAM.
3. Resuming starts. The Exynos DRM driver resume callback is called.
4. The Exynos DRM driver calls drm_helper_resume_force_mode which turns
   the screen on by calling exynos_dsi_dpms with DRM_MODE_DPMS_ON.
Dumb Q: if the device (and power domain) were off before (and during)
suspend, why are they being resumed?

Shouldn't the resume path restore things to the same state they were
before suspend?
One could expect that... but the Exynos DRM driver behaves differently
(and some other drivers also). In resume method it calls
drm_helper_resume_force_mode() which forces restoring mode setting
configuration. Apparently setting a mode needs DPMS on:
static void exynos_drm_crtc_commit(struct drm_crtc *crtc)
{
	...
	exynos_drm_crtc_dpms(crtc, DRM_MODE_DPMS_ON);
	...

The previous DPMS status (status during suspend) is completely ignored
here.

I dunno why... maybe someone from DRM could share some thoughts?


Best regards,
Krzysztof
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help