mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Vincent ABRIOU <vincent.abriou@st.com>
To: Philippe CORNU <philippe.cornu@st.com>,
	Thierry Reding <thierry.reding@gmail.com>,
	David Airlie <airlied@linux.ie>,
	"dri-devel@lists.freedesktop.org"
	<dri-devel@lists.freedesktop.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Cc: Andrzej Hajda <a.hajda@samsung.com>,
	Yannick FERTRE <yannick.fertre@st.com>,
	Benjamin Gaignard <benjamin.gaignard@linaro.org>,
	Alexandre TORGUE <alexandre.torgue@st.com>
Subject: Re: [PATCH 2/4] drm/panel: otm8009a: fix glitches by moving backlight enable to otm8009a_enable()
Date: Mon, 14 May 2018 08:37:52 +0000	[thread overview]
Message-ID: <14a3dc6e-0a59-7c63-5195-95d6c1da7c54@st.com> (raw)
In-Reply-To: <20180423141054.13128-3-philippe.cornu@st.com>

Hi Philippe,

Reviewed-by: Vincent Abriou <vincent.abriou@st.com>

BR
Vincent

On 04/23/2018 04:10 PM, Philippe Cornu wrote:
> The backlight 1st update was in the otm8009a_prepare() function
> for a bad reason: backlight was not working in video mode and the
> otm8009a_prepare() is in command mode for the init sequence. As the
> backlight is now fixed (no lpm), it is good to put it back in the
> otm8009a_enable() function, avoiding also image glitches visible
> on some "slow" devices.
> 
> Signed-off-by: Philippe Cornu <philippe.cornu@st.com>
> ---
>   drivers/gpu/drm/panel/panel-orisetech-otm8009a.c | 17 ++++++++++-------
>   1 file changed, 10 insertions(+), 7 deletions(-)
> 
> diff --git a/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c b/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c
> index 0fd2e0144d2b..de4a16d5275c 100644
> --- a/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c
> +++ b/drivers/gpu/drm/panel/panel-orisetech-otm8009a.c
> @@ -330,13 +330,6 @@ static int otm8009a_prepare(struct drm_panel *panel)
>   
>   	ctx->prepared = true;
>   
> -	/*
> -	 * Power on the backlight. Note: end-user still controls brightness
> -	 * Note: ctx->prepared must be true before updating the backlight.
> -	 */
> -	ctx->bl_dev->props.power = FB_BLANK_UNBLANK;
> -	backlight_update_status(ctx->bl_dev);
> -
>   	return 0;
>   }
>   
> @@ -344,6 +337,16 @@ static int otm8009a_enable(struct drm_panel *panel)
>   {
>   	struct otm8009a *ctx = panel_to_otm8009a(panel);
>   
> +	if (ctx->enabled)
> +		return 0;
> +
> +	/*
> +	 * Power on the backlight. Note: end-user still controls brightness
> +	 * Note: ctx->prepared must be true before updating the backlight.
> +	 */
> +	ctx->bl_dev->props.power = FB_BLANK_UNBLANK;
> +	backlight_update_status(ctx->bl_dev);
> +
>   	ctx->enabled = true;
>   
>   	return 0;
> 

  reply	other threads:[~2018-05-14  8:38 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-23 14:10 [PATCH 0/4] drm/panel: otm8009a: backlight fixes & improvements Philippe Cornu
2018-04-23 14:10 ` [PATCH 1/4] drm/panel: otm8009a: fix backlight updates Philippe Cornu
2018-05-14  8:36   ` Vincent ABRIOU
2018-04-23 14:10 ` [PATCH 2/4] drm/panel: otm8009a: fix glitches by moving backlight enable to otm8009a_enable() Philippe Cornu
2018-05-14  8:37   ` Vincent ABRIOU [this message]
2018-04-23 14:10 ` [PATCH 3/4] drm/panel: otm8009a: no message if probe success Philippe Cornu
2018-05-14  8:38   ` Vincent ABRIOU
2018-04-23 14:10 ` [PATCH 4/4] drm/panel: otm8009a: use new backlight api Philippe Cornu
2018-05-14  8:39   ` Vincent ABRIOU

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=14a3dc6e-0a59-7c63-5195-95d6c1da7c54@st.com \
    --to=vincent.abriou@st.com \
    --cc=a.hajda@samsung.com \
    --cc=airlied@linux.ie \
    --cc=alexandre.torgue@st.com \
    --cc=benjamin.gaignard@linaro.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=philippe.cornu@st.com \
    --cc=thierry.reding@gmail.com \
    --cc=yannick.fertre@st.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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®