public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: jani.nikula@intel.com
Subject: [PATCH 1/2] drm/i915/dp: there is no audio on port A on non-DDI platforms
Date: Mon,  4 May 2015 17:20:48 +0300	[thread overview]
Message-ID: <1430749249-15565-1-git-send-email-jani.nikula@intel.com> (raw)

The eDP port A register on PCH split platforms has a slightly different
register layout from the other ports, with bit 6 being either alternate
scrambler reset or reserved, depending on the generation. Our
misinterpretation of the bit as audio has lead to warnings.

Fix this by not enabling audio on port A on non-DDI platforms. The check
could be made more specific, but this corresponds to the audio codec
enabling code which emits the warning for port A.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89958
Reported-and-tested-by: Chris Bainbridge <chris.bainbridge@gmail.com>
Cc: stable@vger.kernel.org
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
---
 drivers/gpu/drm/i915/intel_dp.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index 937ba31d8dde..fa71fb4d6542 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -1355,7 +1355,8 @@ intel_dp_compute_config(struct intel_encoder *encoder,
 
 	pipe_config->has_dp_encoder = true;
 	pipe_config->has_drrs = false;
-	pipe_config->has_audio = intel_dp->has_audio;
+	if (HAS_DDI(dev) || port != PORT_A)
+		pipe_config->has_audio = intel_dp->has_audio;
 
 	if (is_edp(intel_dp) && intel_connector->panel.fixed_mode) {
 		intel_fixed_panel_mode(intel_connector->panel.fixed_mode,
@@ -2228,7 +2229,7 @@ static void intel_dp_get_config(struct intel_encoder *encoder,
 	int dotclock;
 
 	tmp = I915_READ(intel_dp->output_reg);
-	if (tmp & DP_AUDIO_OUTPUT_ENABLE)
+	if (port != PORT_A && tmp & DP_AUDIO_OUTPUT_ENABLE)
 		pipe_config->has_audio = true;
 
 	if ((port == PORT_A) || !HAS_PCH_CPT(dev)) {
-- 
2.1.4

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

             reply	other threads:[~2015-05-04 14:18 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-04 14:20 Jani Nikula [this message]
2015-05-04 14:20 ` [PATCH 2/2] drm/i915/audio: do not mess with audio registers if port is invalid Jani Nikula
2015-05-04 20:45   ` shuang.he
2015-05-05  5:33   ` Sivakumar Thulasimani
2015-05-06 11:11     ` Daniel Vetter
2015-05-05  5:31 ` [PATCH 1/2] drm/i915/dp: there is no audio on port A on non-DDI platforms Sivakumar Thulasimani
2015-05-05  9:09   ` Jani Nikula
2015-05-05 12:18     ` Sivakumar Thulasimani
2015-05-05 13:32       ` Jani Nikula
2015-05-05 13:38         ` Sivakumar Thulasimani
2015-05-05 13:43         ` Sivakumar Thulasimani
2015-05-06  9:30           ` Jani Nikula
2015-05-06 11:11         ` Daniel Vetter

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=1430749249-15565-1-git-send-email-jani.nikula@intel.com \
    --to=jani.nikula@intel.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox