浏览代码

ALSA: hda - Set TLV_DB_SCALE_MUTE bit for cx5051 vmaster

Conexnat HD-audio driver has a workaround for cx5051 (aka CX20561)
chip to add fake mute controls to each amp (commit 3868137e).  This
implies the minimum-as-mute TLV bit in TLV for each corresponding
control.  Meanwhile we build the virtual master from these, but the
TLV bit is missing, even though the slaves have it.

This patch simply adds the missing TLV_DB_SCALE_MUTE bit for vmaster,
as already done in patch_sigmatel.c.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai 11 年之前
父节点
当前提交
61074c1a2d
共有 1 个文件被更改,包括 6 次插入0 次删除
  1. 6 0
      sound/pci/hda/patch_conexant.c

+ 6 - 0
sound/pci/hda/patch_conexant.c

@@ -26,6 +26,7 @@
 #include <linux/module.h>
 #include <linux/module.h>
 #include <sound/core.h>
 #include <sound/core.h>
 #include <sound/jack.h>
 #include <sound/jack.h>
+#include <sound/tlv.h>
 
 
 #include "hda_codec.h"
 #include "hda_codec.h"
 #include "hda_local.h"
 #include "hda_local.h"
@@ -859,6 +860,11 @@ static int patch_conexant_auto(struct hda_codec *codec)
 	if (err < 0)
 	if (err < 0)
 		goto error;
 		goto error;
 
 
+	if (codec->vendor_id == 0x14f15051) {
+		/* minimum value is actually mute */
+		spec->gen.vmaster_tlv[3] |= TLV_DB_SCALE_MUTE;
+	}
+
 	codec->patch_ops = cx_auto_patch_ops;
 	codec->patch_ops = cx_auto_patch_ops;
 
 
 	/* Some laptops with Conexant chips show stalls in S3 resume,
 	/* Some laptops with Conexant chips show stalls in S3 resume,