[PATCH] ALSA: hda/generic: Use "Input Source" for the capture source selector
From: songxiebing
Date: Wed Oct 21 2026 - 22:58:28 EST
From: Bob Song <songxiebing@xxxxxxxxxx>
The generic parser names the capture-source selector "Capture Source" when a
single ADC is used, and "Input Source" when multiple ADCs are handled
(including the dynamic ADC switching case). Commit 624d914d091a
("ALSA: hda - Use "Capture Source" for single sources") introduced this
split to keep the nicer name for the common single-ADC case, because
"Capture Source" doesn't work well with the alsa-lib simple-mixer
abstraction when multiple instances are present.
However, alsa-lib expands a control named "Capture Source" into one
simple-mixer element per enum item (an exclusive capture switch per input),
so there is no enumerated simple-mixer element named "Capture Source" for
userspace to look up. PulseAudio's ALSA backend resolves its input-source
element by name via snd_mixer_find_selem() and therefore cannot find the
selector, leaving the capture source uncontrollable on such single-ADC
systems.
"Input Source" is mapped by alsa-lib to a single enumerated element and
works for both the single- and multi-ADC cases. Use it unconditionally.
Signed-off-by: Bob Song <songxiebing@xxxxxxxxxx>
---
sound/hda/codecs/generic.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/sound/hda/codecs/generic.c b/sound/hda/codecs/generic.c
index 6120f797b45a..75b6e2749157 100644
--- a/sound/hda/codecs/generic.c
+++ b/sound/hda/codecs/generic.c
@@ -3748,9 +3748,7 @@ static int create_capture_mixers(struct hda_codec *codec)
if (!spec->auto_mic && imux->num_items > 1) {
struct snd_kcontrol_new *knew;
- const char *name;
- name = nums > 1 ? "Input Source" : "Capture Source";
- knew = snd_hda_gen_add_kctl(spec, name, &cap_src_temp);
+ knew = snd_hda_gen_add_kctl(spec, "Input Source", &cap_src_temp);
if (!knew)
return -ENOMEM;
knew->count = nums;
--
2.25.1