diff options
Diffstat (limited to 'sound/pci')
-rw-r--r-- | sound/pci/hda/patch_realtek.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index 36556b10357a..012435212e58 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c | |||
@@ -2517,7 +2517,10 @@ static int alc_build_controls(struct hda_codec *codec) | |||
2517 | if (!kctl) | 2517 | if (!kctl) |
2518 | kctl = snd_hda_find_mixer_ctl(codec, "Input Source"); | 2518 | kctl = snd_hda_find_mixer_ctl(codec, "Input Source"); |
2519 | for (i = 0; kctl && i < kctl->count; i++) { | 2519 | for (i = 0; kctl && i < kctl->count; i++) { |
2520 | err = snd_hda_add_nids(codec, kctl, i, spec->capsrc_nids, | 2520 | hda_nid_t *nids = spec->capsrc_nids; |
2521 | if (!nids) | ||
2522 | nids = spec->adc_nids; | ||
2523 | err = snd_hda_add_nids(codec, kctl, i, nids, | ||
2521 | spec->input_mux->num_items); | 2524 | spec->input_mux->num_items); |
2522 | if (err < 0) | 2525 | if (err < 0) |
2523 | return err; | 2526 | return err; |