From: Wu Fengguang <fengguang.wu@intel.com>
To: Takashi Iwai <tiwai@suse.de>
Cc: alsa-devel@alsa-project.org,
Wu Fengguang <fengguang.wu@intel.com>,
Shane W <shane-alsa@csy.ca>
Subject: [PATCH 5/5] intelhdmi - dont power off HDA link
Date: Fri, 11 Dec 2009 12:28:37 +0800 [thread overview]
Message-ID: <20091211043213.436814565@intel.com> (raw)
In-Reply-To: 20091211042832.691808920@intel.com
[-- Attachment #1: hdmi-dont-power-off-controller.patch --]
[-- Type: text/plain, Size: 2063 bytes --]
For codecs without EPSS support (G45/IbexPeak), the hotplug event will
be lost if the HDA is powered off during the time. After that the pin
presence detection verb returns inaccurate info.
So always power-on HDA link for !EPSS codecs.
Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
---
sound/pci/hda/hda_codec.h | 1 +
sound/pci/hda/hda_intel.c | 2 ++
sound/pci/hda/patch_intelhdmi.c | 11 +++++++++++
3 files changed, 14 insertions(+)
--- sound-2.6.orig/sound/pci/hda/hda_intel.c 2009-12-10 12:45:24.000000000 +0800
+++ sound-2.6/sound/pci/hda/hda_intel.c 2009-12-10 20:10:51.000000000 +0800
@@ -2079,6 +2079,8 @@ static void azx_power_notify(struct hda_
power_on = 1;
break;
}
+ if (c->power_keep_link_on)
+ power_save_controller = 0;
}
if (power_on)
azx_init_chip(chip);
--- sound-2.6.orig/sound/pci/hda/patch_intelhdmi.c 2009-12-10 12:56:41.000000000 +0800
+++ sound-2.6/sound/pci/hda/patch_intelhdmi.c 2009-12-10 20:19:32.000000000 +0800
@@ -391,6 +391,17 @@ static int intel_hdmi_parse_codec(struct
}
}
+ /*
+ * G45/IbexPeak don't support EPSS: the unsolicited pin hot plug event
+ * can be lost and presence sense verb will become inaccurate if the
+ * HDA link is powered off at hot plug or hw initialization time.
+ */
+#ifdef CONFIG_SND_HDA_POWER_SAVE
+ if (!(snd_hda_param_read(codec, codec->afg, AC_PAR_POWER_STATE) &
+ AC_PWRST_EPSS))
+ codec->power_keep_link_on = 1;
+#endif
+
return 0;
}
--- sound-2.6.orig/sound/pci/hda/hda_codec.h 2009-12-10 12:45:24.000000000 +0800
+++ sound-2.6/sound/pci/hda/hda_codec.h 2009-12-10 20:10:51.000000000 +0800
@@ -819,6 +819,7 @@ struct hda_codec {
#ifdef CONFIG_SND_HDA_POWER_SAVE
unsigned int power_on :1; /* current (global) power-state */
unsigned int power_transition :1; /* power-state in transition */
+ unsigned int power_keep_link_on :1; /* don't power off HDA link */
int power_count; /* current (global) power refcount */
struct delayed_work power_work; /* delayed task for powerdown */
unsigned long power_on_acct;
next prev parent reply other threads:[~2009-12-11 4:32 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-11 4:28 [PATCH 0/5] Intel HDMI fixes Wu Fengguang
2009-12-11 4:28 ` [PATCH 1/5] hda - show HBR(High Bit Rate) pin cap in procfs Wu Fengguang
2009-12-11 4:28 ` [PATCH 2/5] intelhdmi - accept DisplayPort pin Wu Fengguang
2009-12-11 4:28 ` [PATCH 3/5] intelhdmi - channel mapping applies to Pin Wu Fengguang
2009-12-11 4:28 ` [PATCH 4/5] intelhdmi - add channel mapping for typical configurations Wu Fengguang
2009-12-11 7:00 ` Takashi Iwai
2009-12-11 12:05 ` Wu Fengguang
2009-12-11 4:28 ` Wu Fengguang [this message]
2009-12-11 7:08 ` [PATCH 5/5] intelhdmi - dont power off HDA link Takashi Iwai
2009-12-11 12:15 ` Wu Fengguang
2009-12-11 7:10 ` [PATCH 0/5] Intel HDMI fixes Takashi Iwai
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=20091211043213.436814565@intel.com \
--to=fengguang.wu@intel.com \
--cc=alsa-devel@alsa-project.org \
--cc=shane-alsa@csy.ca \
--cc=tiwai@suse.de \
/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