dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm/panel: otm8009a: add delay at the end of initialization
@ 2019-03-21  8:04 Yannick Fertré
  2019-03-26 12:48 ` Philippe CORNU
  2019-04-03 16:22 ` Thierry Reding
  0 siblings, 2 replies; 3+ messages in thread
From: Yannick Fertré @ 2019-03-21  8:04 UTC (permalink / raw)
  To: Yannick Fertre, Philippe Cornu, Thierry Reding, David Airlie,
	Daniel Vetter, dri-devel, linux-kernel, linux-stm32

At the end of initialization, a delay is required by the panel.
Without this delay, the panel could received a frame early &
generate a crash of panel (black screen).

Signed-off-by: Yannick Fertré <yannick.fertre@st.com>
---
 drivers/gpu/drm/panel/panel-orisetech-otm8009a.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c b/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c
index 87fa316..58ccf64 100644
--- a/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c
+++ b/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c
@@ -248,6 +248,9 @@ static int otm8009a_init_sequence(struct otm8009a *ctx)
 	/* Send Command GRAM memory write (no parameters) */
 	dcs_write_seq(ctx, MIPI_DCS_WRITE_MEMORY_START);
 
+	/* Wait a short while to let the panel be ready before the 1st frame */
+	mdelay(10);
+
 	return 0;
 }
 
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] drm/panel: otm8009a: add delay at the end of initialization
  2019-03-21  8:04 [PATCH] drm/panel: otm8009a: add delay at the end of initialization Yannick Fertré
@ 2019-03-26 12:48 ` Philippe CORNU
  2019-04-03 16:22 ` Thierry Reding
  1 sibling, 0 replies; 3+ messages in thread
From: Philippe CORNU @ 2019-03-26 12:48 UTC (permalink / raw)
  To: Yannick FERTRE, Thierry Reding, David Airlie, Daniel Vetter,
	dri-devel, linux-kernel, linux-stm32

Dear Yannick,
Many thanks for your patch.

Reviewed-by: Philippe Cornu <philippe.cornu@st.com>
Tested-by: Philippe Cornu <philippe.cornu@st.com>

Best regards,
Philippe

On 3/21/19 9:04 AM, Yannick Fertré wrote:
> At the end of initialization, a delay is required by the panel.
> Without this delay, the panel could received a frame early &
> generate a crash of panel (black screen).
> 
> Signed-off-by: Yannick Fertré <yannick.fertre@st.com>
> ---
>   drivers/gpu/drm/panel/panel-orisetech-otm8009a.c | 3 +++
>   1 file changed, 3 insertions(+)
> 
> diff --git a/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c b/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c
> index 87fa316..58ccf64 100644
> --- a/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c
> +++ b/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c
> @@ -248,6 +248,9 @@ static int otm8009a_init_sequence(struct otm8009a *ctx)
>   	/* Send Command GRAM memory write (no parameters) */
>   	dcs_write_seq(ctx, MIPI_DCS_WRITE_MEMORY_START);
>   
> +	/* Wait a short while to let the panel be ready before the 1st frame */
> +	mdelay(10);
> +
>   	return 0;
>   }
>   
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] drm/panel: otm8009a: add delay at the end of initialization
  2019-03-21  8:04 [PATCH] drm/panel: otm8009a: add delay at the end of initialization Yannick Fertré
  2019-03-26 12:48 ` Philippe CORNU
@ 2019-04-03 16:22 ` Thierry Reding
  1 sibling, 0 replies; 3+ messages in thread
From: Thierry Reding @ 2019-04-03 16:22 UTC (permalink / raw)
  To: Yannick Fertré
  Cc: David Airlie, Philippe Cornu, dri-devel, linux-kernel, linux-stm32


[-- Attachment #1.1: Type: text/plain, Size: 665 bytes --]

On Thu, Mar 21, 2019 at 09:04:05AM +0100, Yannick Fertré wrote:
> At the end of initialization, a delay is required by the panel.
> Without this delay, the panel could received a frame early &
> generate a crash of panel (black screen).
> 
> Signed-off-by: Yannick Fertré <yannick.fertre@st.com>
> ---
>  drivers/gpu/drm/panel/panel-orisetech-otm8009a.c | 3 +++
>  1 file changed, 3 insertions(+)

Applied. You might want to go over this panel and replace some of the
mdelay() calls with msleep(). There are some that busy loop for 120 ms,
which is somewhat rude. Even the mdelay(10) in this driver should be
safe to convert to msleep().

Thierry

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-04-03 16:22 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-21  8:04 [PATCH] drm/panel: otm8009a: add delay at the end of initialization Yannick Fertré
2019-03-26 12:48 ` Philippe CORNU
2019-04-03 16:22 ` Thierry Reding

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).