mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-12-19 08:57:14 -05:00
acp: Probe and set up HW volume for cards detected through UCM
The codepath `pa_alsa_ucm_add_ports` -> `probe_volumes` ->
`pa_alsa_path_probe` was never called leading to no HW volume being set
up when loading a card through UCM. PulseAudio calls this from
`card_set_profile` -> `pa_alsa_{sink,source}_new`.
This commit is contained in:
parent
d636cadbb8
commit
44882f5ab3
1 changed files with 11 additions and 6 deletions
|
|
@ -249,9 +249,12 @@ static void add_profiles(pa_card *impl)
|
||||||
init_device(impl, dev, PA_ALSA_DIRECTION_OUTPUT, m, n_devices++);
|
init_device(impl, dev, PA_ALSA_DIRECTION_OUTPUT, m, n_devices++);
|
||||||
pa_dynarray_append(&impl->out.devices, dev);
|
pa_dynarray_append(&impl->out.devices, dev);
|
||||||
}
|
}
|
||||||
if (impl->use_ucm)
|
if (impl->use_ucm) {
|
||||||
pa_alsa_ucm_add_ports_combination(dev->ports, &m->ucm_context,
|
pa_alsa_ucm_add_ports_combination(NULL, &m->ucm_context,
|
||||||
true, impl->ports, ap, NULL);
|
true, impl->ports, ap, NULL);
|
||||||
|
pa_alsa_ucm_add_ports(&dev->ports, m->proplist, &m->ucm_context,
|
||||||
|
true, impl, dev->pcm_handle, impl->profile_set->ignore_dB);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
pa_alsa_path_set_add_ports(m->output_path_set, ap, impl->ports,
|
pa_alsa_path_set_add_ports(m->output_path_set, ap, impl->ports,
|
||||||
dev->ports, NULL);
|
dev->ports, NULL);
|
||||||
|
|
@ -268,10 +271,12 @@ static void add_profiles(pa_card *impl)
|
||||||
pa_dynarray_append(&impl->out.devices, dev);
|
pa_dynarray_append(&impl->out.devices, dev);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (impl->use_ucm)
|
if (impl->use_ucm) {
|
||||||
pa_alsa_ucm_add_ports_combination(dev->ports, &m->ucm_context,
|
pa_alsa_ucm_add_ports_combination(NULL, &m->ucm_context,
|
||||||
false, impl->ports, ap, NULL);
|
false, impl->ports, ap, NULL);
|
||||||
else
|
pa_alsa_ucm_add_ports(&dev->ports, m->proplist, &m->ucm_context,
|
||||||
|
false, impl, dev->pcm_handle, impl->profile_set->ignore_dB);
|
||||||
|
} else
|
||||||
pa_alsa_path_set_add_ports(m->input_path_set, ap, impl->ports,
|
pa_alsa_path_set_add_ports(m->input_path_set, ap, impl->ports,
|
||||||
dev->ports, NULL);
|
dev->ports, NULL);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue