aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/hda/patch_realtek.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/pci/hda/patch_realtek.c')
-rw-r--r--sound/pci/hda/patch_realtek.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index f210ca7575b2..c85899d50404 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -360,7 +360,7 @@ static void update_shared_mic_hp(struct hda_codec *codec, bool set_as_mic)
360 360
361/* select the given imux item; either unmute exclusively or select the route */ 361/* select the given imux item; either unmute exclusively or select the route */
362static int alc_mux_select(struct hda_codec *codec, unsigned int adc_idx, 362static int alc_mux_select(struct hda_codec *codec, unsigned int adc_idx,
363 unsigned int idx, bool force) 363 unsigned int idx)
364{ 364{
365 struct alc_spec *spec = codec->spec; 365 struct alc_spec *spec = codec->spec;
366 const struct hda_input_mux *imux; 366 const struct hda_input_mux *imux;
@@ -372,7 +372,7 @@ static int alc_mux_select(struct hda_codec *codec, unsigned int adc_idx,
372 372
373 if (idx >= imux->num_items) 373 if (idx >= imux->num_items)
374 idx = imux->num_items - 1; 374 idx = imux->num_items - 1;
375 if (spec->cur_mux[adc_idx] == idx && !force) 375 if (spec->cur_mux[adc_idx] == idx)
376 return 0; 376 return 0;
377 377
378 path = get_nid_path(codec, spec->imux_pins[spec->cur_mux[adc_idx]], 378 path = get_nid_path(codec, spec->imux_pins[spec->cur_mux[adc_idx]],
@@ -407,7 +407,7 @@ static int alc_mux_enum_put(struct snd_kcontrol *kcontrol,
407 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); 407 struct hda_codec *codec = snd_kcontrol_chip(kcontrol);
408 unsigned int adc_idx = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id); 408 unsigned int adc_idx = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id);
409 return alc_mux_select(codec, adc_idx, 409 return alc_mux_select(codec, adc_idx,
410 ucontrol->value.enumerated.item[0], false); 410 ucontrol->value.enumerated.item[0]);
411} 411}
412 412
413/* 413/*
@@ -624,11 +624,11 @@ static void alc_mic_automute(struct hda_codec *codec, struct hda_jack_tbl *jack)
624 624
625 for (i = spec->am_num_entries - 1; i > 0; i--) { 625 for (i = spec->am_num_entries - 1; i > 0; i--) {
626 if (snd_hda_jack_detect(codec, spec->am_entry[i].pin)) { 626 if (snd_hda_jack_detect(codec, spec->am_entry[i].pin)) {
627 alc_mux_select(codec, 0, spec->am_entry[i].idx, false); 627 alc_mux_select(codec, 0, spec->am_entry[i].idx);
628 return; 628 return;
629 } 629 }
630 } 630 }
631 alc_mux_select(codec, 0, spec->am_entry[0].idx, false); 631 alc_mux_select(codec, 0, spec->am_entry[0].idx);
632} 632}
633 633
634/* update the master volume per volume-knob's unsol event */ 634/* update the master volume per volume-knob's unsol event */