All of lore.kernel.org
 help / color / mirror / Atom feed
From: Imre Deak <imre.deak@intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Subject: [PATCH 3/4] drm/i915/lspcon: Remove DPCD compare based resume time workaround
Date: Fri, 27 Jan 2017 11:39:20 +0200	[thread overview]
Message-ID: <1485509961-9010-4-git-send-email-imre.deak@intel.com> (raw)
In-Reply-To: <1485509961-9010-1-git-send-email-imre.deak@intel.com>

This effectively reverts
commit 489375c866c111f16cea93b2467ebe59c9022cc7
Author: Imre Deak <imre.deak@intel.com>
Date:   Mon Oct 24 19:33:31 2016 +0300

    drm/i915/lspcon: Add workaround for resuming in PCON mode

The workaround was added without considering that HPD is low during
the failed AUX transfers the WA fixed. Since the previous patch we
wait for HPD to get asserted. My tests also show that this happens
_after_ the DPCD reads start to return correct values. This
suggests that we don't need this WA any more, let's try to remove
it to reduce the clutter.

Cc: Shashank Sharma <shashank.sharma@intel.com>
Cc: Jani Nikula <jani.nikula@linux.intel.com>
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Imre Deak <imre.deak@intel.com>
---
 drivers/gpu/drm/i915/intel_drv.h    |  1 -
 drivers/gpu/drm/i915/intel_lspcon.c | 17 ++---------------
 2 files changed, 2 insertions(+), 16 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h
index b9cde11..b2882ff 100644
--- a/drivers/gpu/drm/i915/intel_drv.h
+++ b/drivers/gpu/drm/i915/intel_drv.h
@@ -989,7 +989,6 @@ struct intel_dp {
 struct intel_lspcon {
 	bool active;
 	enum drm_lspcon_mode mode;
-	bool desc_valid;
 };
 
 struct intel_digital_port {
diff --git a/drivers/gpu/drm/i915/intel_lspcon.c b/drivers/gpu/drm/i915/intel_lspcon.c
index c300647..71cbe9c 100644
--- a/drivers/gpu/drm/i915/intel_lspcon.c
+++ b/drivers/gpu/drm/i915/intel_lspcon.c
@@ -162,21 +162,8 @@ static void lspcon_resume_in_pcon_wa(struct intel_lspcon *lspcon)
 	struct drm_i915_private *dev_priv = to_i915(dig_port->base.base.dev);
 	unsigned long start = jiffies;
 
-	if (!lspcon->desc_valid)
-		return;
-
 	while (1) {
-		struct intel_dp_desc desc;
-
-		/*
-		 * The w/a only applies in PCON mode and we don't expect any
-		 * AUX errors.
-		 */
-		if (!__intel_dp_read_desc(intel_dp, &desc))
-			return;
-
-		if (intel_digital_port_connected(dev_priv, dig_port) &&
-		    !memcmp(&intel_dp->desc, &desc, sizeof(desc))) {
+		if (intel_digital_port_connected(dev_priv, dig_port)) {
 			DRM_DEBUG_KMS("LSPCON recovering in PCON mode after %u ms\n",
 				      jiffies_to_msecs(jiffies - start));
 			return;
@@ -253,7 +240,7 @@ bool lspcon_init(struct intel_digital_port *intel_dig_port)
 		return false;
 	}
 
-	lspcon->desc_valid = intel_dp_read_desc(dp);
+	intel_dp_read_desc(dp);
 
 	DRM_DEBUG_KMS("Success: LSPCON init\n");
 	return true;
-- 
2.5.0

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

  parent reply	other threads:[~2017-01-27  9:39 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-27  9:39 [PATCH 0/4] drm/i915/lspcon: Fix resume time init due to low HPD Imre Deak
2017-01-27  9:39 ` [PATCH 1/4] drm/i915/gen9+: Enable hotplug detection early Imre Deak
2017-01-27  9:39   ` Imre Deak
2017-01-28  4:54   ` Sharma, Shashank
2017-01-28  4:54     ` Sharma, Shashank
2017-01-28  7:54     ` Imre Deak
2017-01-28  7:54       ` Imre Deak
2017-01-29  4:56       ` Sharma, Shashank
2017-01-29  4:56         ` Sharma, Shashank
2017-01-27  9:39 ` [PATCH 2/4] drm/i915/lspcon: Fix resume time initialization due to unasserted HPD Imre Deak
2017-01-27  9:39   ` Imre Deak
2017-01-28  5:02   ` Sharma, Shashank
2017-01-28  5:02     ` Sharma, Shashank
2017-01-28  8:17     ` Imre Deak
2017-01-28  8:17       ` Imre Deak
2017-01-29  5:03       ` Sharma, Shashank
2017-01-29  5:03         ` Sharma, Shashank
2017-01-29 16:13         ` Imre Deak
2017-01-29 16:13           ` Imre Deak
2017-02-02 10:53           ` Sharma, Shashank
2017-02-02 10:53             ` Sharma, Shashank
2017-01-27  9:39 ` Imre Deak [this message]
2017-01-28  5:06   ` [PATCH 3/4] drm/i915/lspcon: Remove DPCD compare based resume time workaround Sharma, Shashank
2017-01-28  8:19     ` Imre Deak
2017-02-02 10:54       ` Sharma, Shashank
2017-01-27  9:39 ` [PATCH 4/4] drm/i915/gen5+, pch: Enable hotplug detection early Imre Deak
2017-01-28  5:09   ` Sharma, Shashank
2017-01-27 11:24 ` ✓ Fi.CI.BAT: success for drm/i915/lspcon: Fix resume time init due to low HPD Patchwork
2017-02-06 14:46   ` Imre Deak

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=1485509961-9010-4-git-send-email-imre.deak@intel.com \
    --to=imre.deak@intel.com \
    --cc=daniel.vetter@ffwll.ch \
    --cc=intel-gfx@lists.freedesktop.org \
    /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.