All of lore.kernel.org
 help / color / mirror / Atom feed
From: Lee Shawn C <shawn.c.lee@intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: Jani Nikula <jani.nikula@intel.com>,
	Cooper Chiou <cooper.chiou@intel.com>
Subject: [PATCH v2] drm/i915: Refine eDP aux backlight enable/disable sequence
Date: Thu, 20 Jun 2019 20:02:08 -0700	[thread overview]
Message-ID: <1561086128-19145-1-git-send-email-shawn.c.lee@intel.com> (raw)
In-Reply-To: <1560492565-30405-1-git-send-email-shawn.c.lee@intel.com>

Modify aux backlight enable/disable sequence just like what we
did for genernal eDP panel.
1. Setup PWM freq and brightness level before enable display backlight.
2. Set PWM to 0 after backlight enable was off.

v2: Code structure was changed. Modify this patch to align the latest.

Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: Jani Nikula <jani.nikula@intel.com>
Cc: Jose Roberto de Souza <jose.souza@intel.com>
Cc: Cooper Chiou <cooper.chiou@intel.com>

Signed-off-by: Lee Shawn C <shawn.c.lee@intel.com>
---
 drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
index 6b0b73479fb8..bbc579734238 100644
--- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
+++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
@@ -216,13 +216,14 @@ static void intel_dp_aux_enable_backlight(const struct intel_crtc_state *crtc_st
 		}
 	}
 
-	set_aux_backlight_enable(intel_dp, true);
 	intel_dp_aux_set_backlight(conn_state, connector->panel.backlight.level);
+	set_aux_backlight_enable(intel_dp, true);
 }
 
 static void intel_dp_aux_disable_backlight(const struct drm_connector_state *old_conn_state)
 {
 	set_aux_backlight_enable(enc_to_intel_dp(old_conn_state->best_encoder), false);
+	intel_dp_aux_set_backlight(old_conn_state, 0);
 }
 
 static int intel_dp_aux_setup_backlight(struct intel_connector *connector,
-- 
2.7.4

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  parent reply	other threads:[~2019-06-21  2:34 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-14  6:09 [PATCH 1/2] drm/i915: Refine eDP aux backlight enable/disable sequence Lee, Shawn C
2019-06-14  5:50 ` ✗ Fi.CI.SPARSE: warning for series starting with [1/2] " Patchwork
2019-06-14  6:09 ` [PATCH 2/2] drm/i915: Add backlight enable on/off delay for DP aux backlight control Lee, Shawn C
2019-06-14  8:09   ` Jani Nikula
2019-06-14  8:38     ` Lee, Shawn C
2019-06-14 18:09 ` ✓ Fi.CI.BAT: success for series starting with [1/2] drm/i915: Refine eDP aux backlight enable/disable sequence Patchwork
2019-06-15 10:59 ` ✓ Fi.CI.IGT: " Patchwork
2019-06-21  3:02 ` Lee Shawn C [this message]
2019-06-21  2:53   ` [PATCH v2] " Lee, Shawn C
2019-06-21  3:24 [PATCH] " Lee Shawn C
2019-06-25 15:35 ` [PATCH v2] " Lee Shawn C
2019-06-25 15:13   ` Jani Nikula
2019-06-25 15:29     ` Lee, Shawn C

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=1561086128-19145-1-git-send-email-shawn.c.lee@intel.com \
    --to=shawn.c.lee@intel.com \
    --cc=cooper.chiou@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jani.nikula@intel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.