aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorMichael Karcher <kernel@mkarcher.dialup.fu-berlin.de>2012-04-06 09:34:20 -0400
committerTakashi Iwai <tiwai@suse.de>2012-04-07 06:25:56 -0400
commit250f32747e62cb415b85083e247184188f24e566 (patch)
tree4fb762f0a5b4703771e8394ff92d5bae2c5abc29 /sound
parent51969d62c3b26e887dae734de421b320a296ac58 (diff)
ALSA: hda - clean up CX20549 test mixer setup
name pins consistently (MIC1/LINE1/HP-OUT/CD) on all controls affecting those pins. remove duplicate SET_AMP_GAIN_MUTE to 0x17/index 0 and 0x17/index 1 really select MIC1, not Mixer out for recording "Mixer out" for recording is not a "pin", adjust comment Signed-off-by: Michael Karcher <kernel@mkarcher.dialup.fu-berlin.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound')
-rw-r--r--sound/pci/hda/patch_conexant.c38
1 files changed, 17 insertions, 21 deletions
diff --git a/sound/pci/hda/patch_conexant.c b/sound/pci/hda/patch_conexant.c
index 84337e63fadf..3848711d89f7 100644
--- a/sound/pci/hda/patch_conexant.c
+++ b/sound/pci/hda/patch_conexant.c
@@ -930,10 +930,10 @@ static const struct snd_kcontrol_new cxt5045_test_mixer[] = {
930 /* Output controls */ 930 /* Output controls */
931 HDA_CODEC_VOLUME("Speaker Playback Volume", 0x10, 0x0, HDA_OUTPUT), 931 HDA_CODEC_VOLUME("Speaker Playback Volume", 0x10, 0x0, HDA_OUTPUT),
932 HDA_CODEC_MUTE("Speaker Playback Switch", 0x10, 0x0, HDA_OUTPUT), 932 HDA_CODEC_MUTE("Speaker Playback Switch", 0x10, 0x0, HDA_OUTPUT),
933 HDA_CODEC_VOLUME("Node 11 Playback Volume", 0x11, 0x0, HDA_OUTPUT), 933 HDA_CODEC_VOLUME("HP-OUT Playback Volume", 0x11, 0x0, HDA_OUTPUT),
934 HDA_CODEC_MUTE("Node 11 Playback Switch", 0x11, 0x0, HDA_OUTPUT), 934 HDA_CODEC_MUTE("HP-OUT Playback Switch", 0x11, 0x0, HDA_OUTPUT),
935 HDA_CODEC_VOLUME("Node 12 Playback Volume", 0x12, 0x0, HDA_OUTPUT), 935 HDA_CODEC_VOLUME("LINE1 Playback Volume", 0x12, 0x0, HDA_OUTPUT),
936 HDA_CODEC_MUTE("Node 12 Playback Switch", 0x12, 0x0, HDA_OUTPUT), 936 HDA_CODEC_MUTE("LINE1 Playback Switch", 0x12, 0x0, HDA_OUTPUT),
937 937
938 /* Modes for retasking pin widgets */ 938 /* Modes for retasking pin widgets */
939 CXT_PIN_MODE("HP-OUT pin mode", 0x11, CXT_PIN_DIR_INOUT), 939 CXT_PIN_MODE("HP-OUT pin mode", 0x11, CXT_PIN_DIR_INOUT),
@@ -944,16 +944,16 @@ static const struct snd_kcontrol_new cxt5045_test_mixer[] = {
944 944
945 /* Loopback mixer controls */ 945 /* Loopback mixer controls */
946 946
947 HDA_CODEC_VOLUME("Mixer-1 Volume", 0x17, 0x0, HDA_INPUT), 947 HDA_CODEC_VOLUME("PCM Volume", 0x17, 0x0, HDA_INPUT),
948 HDA_CODEC_MUTE("Mixer-1 Switch", 0x17, 0x0, HDA_INPUT), 948 HDA_CODEC_MUTE("PCM Switch", 0x17, 0x0, HDA_INPUT),
949 HDA_CODEC_VOLUME("Mixer-2 Volume", 0x17, 0x1, HDA_INPUT), 949 HDA_CODEC_VOLUME("MIC1 pin Volume", 0x17, 0x1, HDA_INPUT),
950 HDA_CODEC_MUTE("Mixer-2 Switch", 0x17, 0x1, HDA_INPUT), 950 HDA_CODEC_MUTE("MIC1 pin Switch", 0x17, 0x1, HDA_INPUT),
951 HDA_CODEC_VOLUME("Mixer-3 Volume", 0x17, 0x2, HDA_INPUT), 951 HDA_CODEC_VOLUME("LINE1 pin Volume", 0x17, 0x2, HDA_INPUT),
952 HDA_CODEC_MUTE("Mixer-3 Switch", 0x17, 0x2, HDA_INPUT), 952 HDA_CODEC_MUTE("LINE1 pin Switch", 0x17, 0x2, HDA_INPUT),
953 HDA_CODEC_VOLUME("Mixer-4 Volume", 0x17, 0x3, HDA_INPUT), 953 HDA_CODEC_VOLUME("HP-OUT pin Volume", 0x17, 0x3, HDA_INPUT),
954 HDA_CODEC_MUTE("Mixer-4 Switch", 0x17, 0x3, HDA_INPUT), 954 HDA_CODEC_MUTE("HP-OUT pin Switch", 0x17, 0x3, HDA_INPUT),
955 HDA_CODEC_VOLUME("Mixer-5 Volume", 0x17, 0x4, HDA_INPUT), 955 HDA_CODEC_VOLUME("CD pin Volume", 0x17, 0x4, HDA_INPUT),
956 HDA_CODEC_MUTE("Mixer-5 Switch", 0x17, 0x4, HDA_INPUT), 956 HDA_CODEC_MUTE("CD pin Switch", 0x17, 0x4, HDA_INPUT),
957 { 957 {
958 .iface = SNDRV_CTL_ELEM_IFACE_MIXER, 958 .iface = SNDRV_CTL_ELEM_IFACE_MIXER,
959 .name = "Input Source", 959 .name = "Input Source",
@@ -985,10 +985,6 @@ static const struct hda_verb cxt5045_test_init_verbs[] = {
985 {0x13, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT}, 985 {0x13, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
986 {0x18, AC_VERB_SET_DIGI_CONVERT_1, 0}, 986 {0x18, AC_VERB_SET_DIGI_CONVERT_1, 0},
987 987
988 /* Start with output sum widgets muted and their output gains at min */
989 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
990 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)},
991
992 /* Unmute retasking pin widget output buffers since the default 988 /* Unmute retasking pin widget output buffers since the default
993 * state appears to be output. As the pin mode is changed by the 989 * state appears to be output. As the pin mode is changed by the
994 * user the pin mode control will take care of enabling the pin's 990 * user the pin mode control will take care of enabling the pin's
@@ -1003,11 +999,11 @@ static const struct hda_verb cxt5045_test_init_verbs[] = {
1003 /* Set ADC connection select to match default mixer setting (mic1 999 /* Set ADC connection select to match default mixer setting (mic1
1004 * pin) 1000 * pin)
1005 */ 1001 */
1006 {0x1a, AC_VERB_SET_CONNECT_SEL, 0x00}, 1002 {0x1a, AC_VERB_SET_CONNECT_SEL, 0x01},
1007 {0x17, AC_VERB_SET_CONNECT_SEL, 0x00}, 1003 {0x17, AC_VERB_SET_CONNECT_SEL, 0x01},
1008 1004
1009 /* Mute all inputs to mixer widget (even unconnected ones) */ 1005 /* Mute all inputs to mixer widget (even unconnected ones) */
1010 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)}, /* Mixer pin */ 1006 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)}, /* Mixer */
1011 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)}, /* Mic1 pin */ 1007 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(1)}, /* Mic1 pin */
1012 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(2)}, /* Line pin */ 1008 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(2)}, /* Line pin */
1013 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(3)}, /* HP pin */ 1009 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(3)}, /* HP pin */