From: David Henningsson <david.henningsson@canonical.com>
To: mengdong.lin@intel.com
Cc: tiwai@suse.de, alsa-devel@alsa-project.org,
Xingchao Wang <xingchao.wang@intel.com>
Subject: Re: [PATCH v3 1/1] ALSA: hda - bug fix for invalid connection list of Haswell HDMI codec pins
Date: Tue, 15 Jan 2013 11:51:23 +0100 [thread overview]
Message-ID: <50F534AB.3010207@canonical.com> (raw)
In-Reply-To: <1355867955-2391-1-git-send-email-mengdong.lin@intel.com>
On 12/18/2012 10:59 PM, mengdong.lin@intel.com wrote:
> From: Mengdong Lin <mengdong.lin@intel.com>
>
> Haswell HDMI codec pins may report invalid connection list entries, which
> will cause failure to play audio via HDMI or Display Port.
>
> So this patch adds fixup for Haswell to workaround this hardware issue:
> enable DP1.2 mode and override the pins' connection list entries with proper
> value.
>
> Signed-off-by: Mengdong Lin <mengdong.lin@intel.com>
> Signed-off-by: Xingchao Wang <xingchao.wang@intel.com>
>
> diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c
> index 71555cc..59abe73 100644
> --- a/sound/pci/hda/patch_hdmi.c
> +++ b/sound/pci/hda/patch_hdmi.c
> @@ -1687,6 +1687,30 @@ static const struct hda_codec_ops generic_hdmi_patch_ops = {
> .unsol_event = hdmi_unsol_event,
> };
>
> +static void intel_haswell_fixup_connect_list(struct hda_codec *codec)
> +{
> + unsigned int vendor_param;
> + hda_nid_t list[3] = {0x2, 0x3, 0x4};
> +
> + vendor_param = snd_hda_codec_read(codec, 0x08, 0, 0xf81, 0);
> + if (vendor_param == -1 || vendor_param & 0x02)
> + return;
> +
> + /* enable DP1.2 mode */
> + vendor_param |= 0x02;
> + snd_hda_codec_read(codec, 0x08, 0, 0x781, vendor_param);
Hi,
When trying to get Haswell HDMI audio working, I discovered that this
verb when executed can get pins to change state from D0 to D3.
As the fixup is executed after hda_call_codec_resume this means that the
pins will remain in D3. I'm not entirely sure of this, but I think we
have no runtime power transitions if we are on AC power, so this could
potentially be for a very long time.
> + /* override 3 pins connection list */
> + snd_hda_override_conn_list(codec, 0x05, 3, list);
> + snd_hda_override_conn_list(codec, 0x06, 3, list);
> + snd_hda_override_conn_list(codec, 0x07, 3, list);
So before the DP 1.2 verb is executed, the connections are
just 5 -> 2, 6 -> 3, 7 -> 4, but afterwards, every pin node can connect
to every cvt node, and connection select verbs must change as a result?
--
David Henningsson, Canonical Ltd.
https://launchpad.net/~diwic
next prev parent reply other threads:[~2013-01-15 10:51 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-18 21:59 [PATCH v3 1/1] ALSA: hda - bug fix for invalid connection list of Haswell HDMI codec pins mengdong.lin
2012-12-18 10:06 ` Takashi Iwai
2013-01-15 10:51 ` David Henningsson [this message]
2013-01-15 11:33 ` Takashi Iwai
2013-01-17 5:32 ` Lin, Mengdong
2013-01-17 3:23 ` Lin, Mengdong
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=50F534AB.3010207@canonical.com \
--to=david.henningsson@canonical.com \
--cc=alsa-devel@alsa-project.org \
--cc=mengdong.lin@intel.com \
--cc=tiwai@suse.de \
--cc=xingchao.wang@intel.com \
/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.