diff mbox series

[1/2] drm/i915: Refine eDP aux backlight enable/disable sequence

Message ID 1560492565-30405-1-git-send-email-shawn.c.lee@intel.com (mailing list archive)
State New, archived
Headers show
Series [1/2] drm/i915: Refine eDP aux backlight enable/disable sequence | expand

Commit Message

Lee, Shawn C June 14, 2019, 6:09 a.m. UTC
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.

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/intel_dp_aux_backlight.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i915/intel_dp_aux_backlight.c b/drivers/gpu/drm/i915/intel_dp_aux_backlight.c
index 7ded95a334db..98210ae17285 100644
--- a/drivers/gpu/drm/i915/intel_dp_aux_backlight.c
+++ b/drivers/gpu/drm/i915/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,