[PATCH 3/4] ALSA: HDA: Fixup unnecessary volume control index on Realtek ALC88x

David Henningsson david.henningsson at canonical.com
Fri Mar 4 14:22:25 CET 2011


Without this change, a volume control named "Surround" or "Side" would
get an unnecessary index, causing it to be ignored by the vmaster and
PulseAudio.

Tested-by: Bartłomiej Żogała <nusch88 at gmail.com>
Signed-off-by: David Henningsson <david.henningsson at canonical.com>
---
 sound/pci/hda/patch_realtek.c |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index fe45c61..f94b12f 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -5206,16 +5206,19 @@ static int alc880_auto_create_multi_out_ctls(struct alc_spec *spec,
 				return err;
 		} else {
 			const char *name = pfx;
-			if (!name)
+			int index = i;
+			if (!name) {
 				name = chname[i];
+				index = 0;
+			}
 			err = __add_pb_vol_ctrl(spec, ALC_CTL_WIDGET_VOL,
-						name, i,
+						name, index,
 					  HDA_COMPOSE_AMP_VAL(nid, 3, 0,
 							      HDA_OUTPUT));
 			if (err < 0)
 				return err;
 			err = __add_pb_sw_ctrl(spec, ALC_CTL_BIND_MUTE,
-					       name, i,
+					       name, index,
 					  HDA_COMPOSE_AMP_VAL(nid, 3, 2,
 							      HDA_INPUT));
 			if (err < 0)
-- 
1.7.1


--------------070904000204070302040307
Content-Type: text/x-patch;
 name="0004-ALSA-HDA-Realtek-ALC88x-Do-not-over-initialize-speak.patch"
Content-Transfer-Encoding: 8bit
Content-Disposition: attachment;
 filename*0="0004-ALSA-HDA-Realtek-ALC88x-Do-not-over-initialize-speak.pa";
 filename*1="tch"



More information about the Alsa-devel mailing list