aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/hda/hda_generic.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/pci/hda/hda_generic.c')
-rw-r--r--sound/pci/hda/hda_generic.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c
index b36f6c5a92df..092c6a7c2ff3 100644
--- a/sound/pci/hda/hda_generic.c
+++ b/sound/pci/hda/hda_generic.c
@@ -727,7 +727,8 @@ static int create_mixer(struct hda_codec *codec, struct hda_gnode *node,
727 if (is_loopback) 727 if (is_loopback)
728 add_input_loopback(codec, node->nid, HDA_INPUT, index); 728 add_input_loopback(codec, node->nid, HDA_INPUT, index);
729 snd_printdd("[%s] NID=0x%x, DIR=IN, IDX=0x%x\n", name, node->nid, index); 729 snd_printdd("[%s] NID=0x%x, DIR=IN, IDX=0x%x\n", name, node->nid, index);
730 err = snd_hda_ctl_add(codec, snd_ctl_new1(&knew, codec)); 730 err = snd_hda_ctl_add(codec, node->nid,
731 snd_ctl_new1(&knew, codec));
731 if (err < 0) 732 if (err < 0)
732 return err; 733 return err;
733 created = 1; 734 created = 1;
@@ -737,7 +738,8 @@ static int create_mixer(struct hda_codec *codec, struct hda_gnode *node,
737 if (is_loopback) 738 if (is_loopback)
738 add_input_loopback(codec, node->nid, HDA_OUTPUT, 0); 739 add_input_loopback(codec, node->nid, HDA_OUTPUT, 0);
739 snd_printdd("[%s] NID=0x%x, DIR=OUT\n", name, node->nid); 740 snd_printdd("[%s] NID=0x%x, DIR=OUT\n", name, node->nid);
740 err = snd_hda_ctl_add(codec, snd_ctl_new1(&knew, codec)); 741 err = snd_hda_ctl_add(codec, node->nid,
742 snd_ctl_new1(&knew, codec));
741 if (err < 0) 743 if (err < 0)
742 return err; 744 return err;
743 created = 1; 745 created = 1;
@@ -751,7 +753,8 @@ static int create_mixer(struct hda_codec *codec, struct hda_gnode *node,
751 (node->amp_in_caps & AC_AMPCAP_NUM_STEPS)) { 753 (node->amp_in_caps & AC_AMPCAP_NUM_STEPS)) {
752 knew = (struct snd_kcontrol_new)HDA_CODEC_VOLUME(name, node->nid, index, HDA_INPUT); 754 knew = (struct snd_kcontrol_new)HDA_CODEC_VOLUME(name, node->nid, index, HDA_INPUT);
753 snd_printdd("[%s] NID=0x%x, DIR=IN, IDX=0x%x\n", name, node->nid, index); 755 snd_printdd("[%s] NID=0x%x, DIR=IN, IDX=0x%x\n", name, node->nid, index);
754 err = snd_hda_ctl_add(codec, snd_ctl_new1(&knew, codec)); 756 err = snd_hda_ctl_add(codec, node->nid,
757 snd_ctl_new1(&knew, codec));
755 if (err < 0) 758 if (err < 0)
756 return err; 759 return err;
757 created = 1; 760 created = 1;
@@ -759,7 +762,8 @@ static int create_mixer(struct hda_codec *codec, struct hda_gnode *node,
759 (node->amp_out_caps & AC_AMPCAP_NUM_STEPS)) { 762 (node->amp_out_caps & AC_AMPCAP_NUM_STEPS)) {
760 knew = (struct snd_kcontrol_new)HDA_CODEC_VOLUME(name, node->nid, 0, HDA_OUTPUT); 763 knew = (struct snd_kcontrol_new)HDA_CODEC_VOLUME(name, node->nid, 0, HDA_OUTPUT);
761 snd_printdd("[%s] NID=0x%x, DIR=OUT\n", name, node->nid); 764 snd_printdd("[%s] NID=0x%x, DIR=OUT\n", name, node->nid);
762 err = snd_hda_ctl_add(codec, snd_ctl_new1(&knew, codec)); 765 err = snd_hda_ctl_add(codec, node->nid,
766 snd_ctl_new1(&knew, codec));
763 if (err < 0) 767 if (err < 0)
764 return err; 768 return err;
765 created = 1; 769 created = 1;
@@ -857,7 +861,7 @@ static int build_input_controls(struct hda_codec *codec)
857 } 861 }
858 862
859 /* create input MUX if multiple sources are available */ 863 /* create input MUX if multiple sources are available */
860 err = snd_hda_ctl_add(codec, snd_ctl_new1(&cap_sel, codec)); 864 err = snd_hda_ctl_add(codec, 0, snd_ctl_new1(&cap_sel, codec));
861 if (err < 0) 865 if (err < 0)
862 return err; 866 return err;
863 867
@@ -875,7 +879,8 @@ static int build_input_controls(struct hda_codec *codec)
875 HDA_CODEC_VOLUME(name, adc_node->nid, 879 HDA_CODEC_VOLUME(name, adc_node->nid,
876 spec->input_mux.items[i].index, 880 spec->input_mux.items[i].index,
877 HDA_INPUT); 881 HDA_INPUT);
878 err = snd_hda_ctl_add(codec, snd_ctl_new1(&knew, codec)); 882 err = snd_hda_ctl_add(codec, adc_node->nid,
883 snd_ctl_new1(&knew, codec));
879 if (err < 0) 884 if (err < 0)
880 return err; 885 return err;
881 } 886 }