[Intel-gfx] [PATCH v2 1/3] drm/i915: Reuse the aux_domain cached
José Roberto de Souza
jose.souza at intel.com
Mon Nov 5 20:25:50 UTC 2018
intel_dp_detect() caches the aux_domain in the beginning of the
function as it is used twice, so lets also use it as the aux_domain
don't change in runtime by jumping to the end of function when
retrain the link fails.
v2: jumping to the end of the function instead of just reuse
aux_domain
Cc: Imre Deak <imre.deak at intel.com>
Reviewed-by: Imre Deak <imre.deak at intel.com>
Reviewed-by: Ville Syrjälä <ville.syrjala at linux.intel.com>
Signed-off-by: José Roberto de Souza <jose.souza at intel.com>
---
drivers/gpu/drm/i915/intel_dp.c | 10 +++-------
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index 5258c9d654f4..c7814d53f70f 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -5165,13 +5165,9 @@ intel_dp_detect(struct drm_connector *connector,
* with an IRQ_HPD, so force a link status check.
*/
if (!intel_dp_is_edp(intel_dp)) {
- int ret;
-
- ret = intel_dp_retrain_link(encoder, ctx);
- if (ret) {
- intel_display_power_put(dev_priv,
- intel_aux_power_domain(dig_port));
- return ret;
+ if (intel_dp_retrain_link(encoder, ctx)) {
+ status = connector_status_disconnected;
+ goto out;
}
}
--
2.19.1
More information about the Intel-gfx
mailing list