drm/i915: Initialize the PPS HW before its first use
authorImre Deak <[email protected]>
Tue, 21 Jun 2016 08:51:48 +0000 (11:51 +0300)
committerImre Deak <[email protected]>
Wed, 22 Jun 2016 13:16:56 +0000 (16:16 +0300)
The initial DPCD read for eDP detection involves using the PPS, but so
far we only initialized the PPS registers after the DPCD read. The
reason this was done so far is to preserve a possible LVDS PPS HW setup
if LVDS is detected but eDP is not. This is not an issue any more after
the previous patch, so we can move the init earlier now.

This was caught by CI with the PPS sanity checks in place and the
initial eDP DPCD readout waiting for the panel power cycle timeout
without the PPS registers being initialized.

CC: Ville Syrjälä <[email protected]>
CC: Chris Wilson <[email protected]>
Signed-off-by: Imre Deak <[email protected]>
Reviewed-by: Chris Wilson <[email protected]>
Reviewed-by: Ville Syrjälä <[email protected]>
Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
drivers/gpu/drm/i915/intel_dp.c

index 9493c8f765383e0b53bfad9ee2e7b5a960b417e9..55b31934e96687b6db4486828cfb60cceeed4d34 100644 (file)
@@ -5328,6 +5328,7 @@ static bool intel_edp_init_connector(struct intel_dp *intel_dp,
 
        pps_lock(intel_dp);
        intel_edp_panel_vdd_sanitize(intel_dp);
+       intel_dp_init_panel_power_sequencer_registers(dev, intel_dp);
        pps_unlock(intel_dp);
 
        /* Cache DPCD and EDID for edp. */
@@ -5344,11 +5345,6 @@ static bool intel_edp_init_connector(struct intel_dp *intel_dp,
                return false;
        }
 
-       /* We now know it's not a ghost, init power sequence regs. */
-       pps_lock(intel_dp);
-       intel_dp_init_panel_power_sequencer_registers(dev, intel_dp);
-       pps_unlock(intel_dp);
-
        mutex_lock(&dev->mode_config.mutex);
        edid = drm_get_edid(connector, &intel_dp->aux.ddc);
        if (edid) {