HDA: introduce HDA and NoACP open arguments
For debugging purposes, it is useful to force a UCM configuration for all HDA configurations. Note that these arguments are not supposed to be used as part of the stable UCM API; they are solely for debugging. Example: alsaucm -c "<<<HDA=1,NoACP=1>>>hw:0" dump text Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
parent
d2d810a35f
commit
c2d5f60c32
2 changed files with 31 additions and 14 deletions
|
|
@ -1,7 +1,7 @@
|
|||
Syntax 8
|
||||
|
||||
Define.Use "" # a non-empty string to use UCM configuration for HDA devices
|
||||
Define.Done "" # a non-empty string to skip the end error
|
||||
Define.Use "${var:@HDA}" # a non-empty string to use UCM configuration for HDA devices
|
||||
Define.Done "" # a non-empty string to skip the end error
|
||||
|
||||
Define.AcpCardId "$${find-card:field=name,return=id,regex='^acp(|6[23x]|-pdm-mach)$'}"
|
||||
Define.MicType "hda"
|
||||
|
|
@ -24,9 +24,15 @@ If.acp {
|
|||
Type String
|
||||
Empty "${var:AcpCardId}"
|
||||
}
|
||||
False {
|
||||
Define.Use y
|
||||
Define.MicType "acp"
|
||||
False.If.noacp {
|
||||
Condition {
|
||||
Type String
|
||||
Empty "${var:@NoACP}"
|
||||
}
|
||||
True {
|
||||
Define.Use y
|
||||
Define.MicType "acp"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -49,14 +55,24 @@ If.use {
|
|||
Control "name='Master Playback Switch'"
|
||||
}
|
||||
True {
|
||||
Include.led.File "/common/ctl/led.conf"
|
||||
Include.init.File "/HDA/init.conf"
|
||||
|
||||
Macro [
|
||||
{ CtlNew { Arg="name='Mic ACP LED Capture Switch' type=bool,count=1 off" } }
|
||||
{ SetLED { LED="mic" Action="attach" CtlId="Mic ACP LED Capture Switch" } }
|
||||
{ SetLED { LED="mic" Action="detach" CtlId="Capture Switch" } }
|
||||
]
|
||||
If.acp {
|
||||
Condition {
|
||||
Type String
|
||||
String1 "${var:MicType}"
|
||||
String2 "acp"
|
||||
}
|
||||
True {
|
||||
Include.led.File "/common/ctl/led.conf"
|
||||
|
||||
Macro [
|
||||
{ CtlNew { Arg="name='Mic ACP LED Capture Switch' type=bool,count=1 off" } }
|
||||
{ SetLED { LED="mic" Action="attach" CtlId="Mic ACP LED Capture Switch" } }
|
||||
{ SetLED { LED="mic" Action="detach" CtlId="Capture Switch" } }
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,10 +17,11 @@ If.analog {
|
|||
If.acp {
|
||||
Condition {
|
||||
Type String
|
||||
Empty "${var:AcpCardId}"
|
||||
String1 "${var:MicType}"
|
||||
String2 "acp"
|
||||
}
|
||||
True.Include.analog.File "/HDA/HiFi-analog.conf"
|
||||
False.Include {
|
||||
False.Include.analog.File "/HDA/HiFi-analog.conf"
|
||||
True.Include {
|
||||
acp.File "/HDA/HiFi-acp.conf"
|
||||
analog.File "/HDA/HiFi-analog.conf"
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue