[PATCH 1/3] ALSA: hda/via - Disable broken dynamic power control

From: Takashi Iwai
Date: Fri May 31 2013 - 07:54:10 EST


Since the transition to the generic parser, the actual routes used
there don't match always with the assumed static paths in some
set_widgets_power_state callbacks. This results in the wrong power
setup in the end. As a temporary workaround, we need to disable the
calls together with the non-functional dynamic power control enum.

Reported-by: Alex Riesen <raa.lkml@xxxxxxxxx>
Cc: <stable@xxxxxxxxxxxxxxx> [v3.9]
Signed-off-by: Takashi Iwai <tiwai@xxxxxxx>
---
sound/pci/hda/patch_via.c | 7 +++++++
1 file changed, 7 insertions(+)

diff --git a/sound/pci/hda/patch_via.c b/sound/pci/hda/patch_via.c
index e0dadcf..2f16605 100644
--- a/sound/pci/hda/patch_via.c
+++ b/sound/pci/hda/patch_via.c
@@ -231,9 +231,14 @@ static void vt1708_update_hp_work(struct hda_codec *codec)

static void set_widgets_power_state(struct hda_codec *codec)
{
+#if 0 /* FIXME: the assumed connections don't match always with the
+ * actual routes by the generic parser, so better to disable
+ * the control for safety.
+ */
struct via_spec *spec = codec->spec;
if (spec->set_widgets_power_state)
spec->set_widgets_power_state(codec);
+#endif
}

static void update_power_state(struct hda_codec *codec, hda_nid_t nid,
@@ -435,8 +440,10 @@ static int via_build_controls(struct hda_codec *codec)
if (err < 0)
return err;

+#if 0 /* FIXME: no dynamic power control, see set_widgets_power_state() */
if (spec->set_widgets_power_state)
spec->mixers[spec->num_mixers++] = via_pin_power_ctl_enum;
+#endif

for (i = 0; i < spec->num_mixers; i++) {
err = snd_hda_add_new_ctls(codec, spec->mixers[i]);
--
1.8.3


--Multipart_Fri_May_31_15:05:00_2013-1
Content-Type: text/plain; charset=US-ASCII


--Multipart_Fri_May_31_15:05:00_2013-1
Content-Type: application/octet-stream; type=patch
Content-Disposition: attachment; filename="0002-ALSA-hda-Allow-setting-automute-automic-hooks-after-.patch"