mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-11-04 13:30:08 -05:00
ucm: add cdev
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
parent
cdc9dd50bf
commit
aaf55f1641
3 changed files with 19 additions and 3 deletions
|
|
@ -188,6 +188,7 @@ static int parse_supported_device(snd_use_case_mgr_t *uc_mgr ATTRIBUTE_UNUSED,
|
|||
*
|
||||
* Sequence controls elements are in the following form:-
|
||||
*
|
||||
* cdev "hw:0,0"
|
||||
* cset "element_id_syntax value_syntax"
|
||||
* usleep time
|
||||
* exec "any unix command with arguments"
|
||||
|
|
@ -233,6 +234,16 @@ static int parse_sequence(snd_use_case_mgr_t *uc_mgr ATTRIBUTE_UNUSED,
|
|||
return -ENOMEM;
|
||||
list_add_tail(&curr->list, base);
|
||||
|
||||
if (strcmp(cmd, "cdev") == 0) {
|
||||
curr->type = SEQUENCE_ELEMENT_TYPE_CDEV;
|
||||
err = parse_string(n, &curr->data.cdev);
|
||||
if (err < 0) {
|
||||
uc_error("error: cdev requires a string!");
|
||||
return err;
|
||||
}
|
||||
continue;
|
||||
}
|
||||
|
||||
if (strcmp(cmd, "cset") == 0) {
|
||||
curr->type = SEQUENCE_ELEMENT_TYPE_CSET;
|
||||
err = parse_string(n, &curr->data.cset);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue