* [PATCH] drm/tilcdc: restore correct display mode and contents on pm resume
@ 2014-03-03 19:08 Felipe Balbi
2014-04-24 17:58 ` Felipe Balbi
2014-04-24 20:48 ` Rob Clark
0 siblings, 2 replies; 3+ messages in thread
From: Felipe Balbi @ 2014-03-03 19:08 UTC (permalink / raw)
To: airlied
Cc: airlied, robdclark, bparrot, dri-devel,
Linux Kernel Mailing List, Darren Etheridge
From: Darren Etheridge <detheridge@ti.com>
On resume the screen contents were not being restored properly. Looking at
other DRM drivers it seems a call to drm_helper_resume_force_mode() is needed
in the resume handler to force restoration of the mode and framebuffer data.
Signed-off-by: Darren Etheridge <detheridge@ti.com>
---
drivers/gpu/drm/tilcdc/tilcdc_drv.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/drivers/gpu/drm/tilcdc/tilcdc_drv.c b/drivers/gpu/drm/tilcdc/tilcdc_drv.c
index 171a820..1a5ddfa 100644
--- a/drivers/gpu/drm/tilcdc/tilcdc_drv.c
+++ b/drivers/gpu/drm/tilcdc/tilcdc_drv.c
@@ -563,6 +563,13 @@ static int tilcdc_pm_resume(struct device *dev)
if (registers[i].save && (priv->rev >= registers[i].rev))
tilcdc_write(ddev, registers[i].reg, priv->saved_register[n++]);
+ /*
+ * if this call isn't here, the display is blank on return from
+ * suspend. With this call here the contents of the framebuffer
+ * during suspend are restored correctly.
+ */
+ drm_helper_resume_force_mode(ddev);
+
drm_kms_helper_poll_enable(ddev);
return 0;
--
1.9.0
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] drm/tilcdc: restore correct display mode and contents on pm resume
2014-03-03 19:08 [PATCH] drm/tilcdc: restore correct display mode and contents on pm resume Felipe Balbi
@ 2014-04-24 17:58 ` Felipe Balbi
2014-04-24 20:48 ` Rob Clark
1 sibling, 0 replies; 3+ messages in thread
From: Felipe Balbi @ 2014-04-24 17:58 UTC (permalink / raw)
To: Felipe Balbi
Cc: airlied, airlied, robdclark, bparrot, dri-devel,
Linux Kernel Mailing List, Darren Etheridge
[-- Attachment #1: Type: text/plain, Size: 1549 bytes --]
On Mon, Mar 03, 2014 at 01:08:56PM -0600, Felipe Balbi wrote:
> From: Darren Etheridge <detheridge@ti.com>
>
> On resume the screen contents were not being restored properly. Looking at
> other DRM drivers it seems a call to drm_helper_resume_force_mode() is needed
> in the resume handler to force restoration of the mode and framebuffer data.
>
> Signed-off-by: Darren Etheridge <detheridge@ti.com>
ping
> ---
> drivers/gpu/drm/tilcdc/tilcdc_drv.c | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_drv.c b/drivers/gpu/drm/tilcdc/tilcdc_drv.c
> index 171a820..1a5ddfa 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_drv.c
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_drv.c
> @@ -563,6 +563,13 @@ static int tilcdc_pm_resume(struct device *dev)
> if (registers[i].save && (priv->rev >= registers[i].rev))
> tilcdc_write(ddev, registers[i].reg, priv->saved_register[n++]);
>
> + /*
> + * if this call isn't here, the display is blank on return from
> + * suspend. With this call here the contents of the framebuffer
> + * during suspend are restored correctly.
> + */
> + drm_helper_resume_force_mode(ddev);
> +
> drm_kms_helper_poll_enable(ddev);
>
> return 0;
> --
> 1.9.0
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
--
balbi
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] drm/tilcdc: restore correct display mode and contents on pm resume
2014-03-03 19:08 [PATCH] drm/tilcdc: restore correct display mode and contents on pm resume Felipe Balbi
2014-04-24 17:58 ` Felipe Balbi
@ 2014-04-24 20:48 ` Rob Clark
1 sibling, 0 replies; 3+ messages in thread
From: Rob Clark @ 2014-04-24 20:48 UTC (permalink / raw)
To: Felipe Balbi
Cc: David Airlie, airlied, Benoit Parrot, dri-devel,
Linux Kernel Mailing List, Darren Etheridge
On Mon, Mar 3, 2014 at 2:08 PM, Felipe Balbi <balbi@ti.com> wrote:
> From: Darren Etheridge <detheridge@ti.com>
>
> On resume the screen contents were not being restored properly. Looking at
> other DRM drivers it seems a call to drm_helper_resume_force_mode() is needed
> in the resume handler to force restoration of the mode and framebuffer data.
>
> Signed-off-by: Darren Etheridge <detheridge@ti.com>
Reviewed-by: Rob Clark <robdclark@gmail.com>
> ---
> drivers/gpu/drm/tilcdc/tilcdc_drv.c | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_drv.c b/drivers/gpu/drm/tilcdc/tilcdc_drv.c
> index 171a820..1a5ddfa 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_drv.c
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_drv.c
> @@ -563,6 +563,13 @@ static int tilcdc_pm_resume(struct device *dev)
> if (registers[i].save && (priv->rev >= registers[i].rev))
> tilcdc_write(ddev, registers[i].reg, priv->saved_register[n++]);
>
> + /*
> + * if this call isn't here, the display is blank on return from
> + * suspend. With this call here the contents of the framebuffer
> + * during suspend are restored correctly.
> + */
> + drm_helper_resume_force_mode(ddev);
> +
> drm_kms_helper_poll_enable(ddev);
>
> return 0;
> --
> 1.9.0
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-04-24 20:48 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-03 19:08 [PATCH] drm/tilcdc: restore correct display mode and contents on pm resume Felipe Balbi
2014-04-24 17:58 ` Felipe Balbi
2014-04-24 20:48 ` Rob Clark
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®