diff mbox series

UCM SectionModifier doesn't like 'Comment'

Message ID 20210806224238.5D8E4F80271@alsa1.perex.cz (mailing list archive)
State New, archived
Headers show
Series UCM SectionModifier doesn't like 'Comment' | expand

Commit Message

GitHub issues - opened Aug. 6, 2021, 10:42 p.m. UTC
alsa-project/alsa-lib issue #167 was edited from plbossart:

Adding the following patch generates a crash with alsaucm

````
alsaucm -c sof-soundwire set _verb HiFi set _enadev Headphones
alsaucm: conf.c:4355: snd_config_iterator_first: Assertion `config->type == SND_CONFIG_TYPE_COMPOUND' failed.
Aborted (core dumped)
````

````diff
````

I am not sure if anyone ever used the SectionModifier, if it's a bug in alsa-lib or alsaucm.

SectionModifiers are part of the current proposal in PipeWire according to the documentation for "stream endpoints". https://docs.pipewire.org/page_objects_design.html 

"The available UCM modifiers for each UCM device will be added as streams, plus one "default" stream for accessing the device with no modifiers."

Issue URL     : https://github.com/alsa-project/alsa-lib/issues/167
Repository URL: https://github.com/alsa-project/alsa-lib
diff mbox series

Patch

diff --git a/ucm2/sof-soundwire/HiFi.conf b/ucm2/sof-soundwire/HiFi.conf
index e780ea4..fbadb65 100644
--- a/ucm2/sof-soundwire/HiFi.conf
+++ b/ucm2/sof-soundwire/HiFi.conf
@@ -29,3 +29,12 @@  If.hsdev {
 }
 
 <sof-soundwire/Hdmi.conf>
+
+SectionModifier."PlayMusic" {
+       # this works fine
+}
+
+SectionModifier."PlayRadio" {
+       # this doesn't
+       Comment "Play Radio"
+}