@@ -13,7 +13,17 @@ If.spkdev {
Type String
Empty "${var:SpeakerCodec1}"
}
- False.Include.spkdev.File "/sof-soundwire/${var:SpeakerCodec1}-${var:SpeakerAmps1}.conf"
+ False {
+ If.simplespeaker {
+ Condition {
+ Type RegexMatch
+ Regex "(rt1308|rt1316|rt1318)"
+ String "${var:SpeakerCodec1}"
+ }
+ True.Include.spkdev.File "/sof-soundwire/${var:SpeakerCodec1}-${var:SpeakerAmps1}.conf"
+ False.Include.spkdev.File "/sof-soundwire/${var:SpeakerCodec1}.conf"
+ }
+ }
}
If.micdev {
new file mode 100644
@@ -0,0 +1,123 @@
+# Use case Configuration for sof-soundwire card
+
+SectionDevice."Speaker" {
+ Comment "Speaker"
+
+ If.amp1 {
+ Condition {
+ Type ControlExists
+ Control "name='AMP1 Speaker Switch'"
+ }
+ True {
+ EnableSequence [
+ cset "name='AMP1 Speaker Switch' 1"
+ ]
+ DisableSequence [
+ cset "name='AMP1 Speaker Switch' 0"
+ ]
+ }
+ }
+ If.amp2 {
+ Condition {
+ Type ControlExists
+ Control "name='AMP2 Speaker Switch'"
+ }
+ True {
+ EnableSequence [
+ cset "name='AMP2 Speaker Switch' 1"
+ ]
+ DisableSequence [
+ cset "name='AMP2 Speaker Switch' 0"
+ ]
+ }
+ }
+ If.amp3 {
+ Condition {
+ Type ControlExists
+ Control "name='AMP3 Speaker Switch'"
+ }
+ True {
+ EnableSequence [
+ cset "name='AMP3 Speaker Switch' 1"
+ ]
+ DisableSequence [
+ cset "name='AMP3 Speaker Switch' 0"
+ ]
+ }
+ }
+ If.amp4 {
+ Condition {
+ Type ControlExists
+ Control "name='AMP4 Speaker Switch'"
+ }
+ True {
+ EnableSequence [
+ cset "name='AMP4 Speaker Switch' 1"
+ ]
+ DisableSequence [
+ cset "name='AMP4 Speaker Switch' 0"
+ ]
+ }
+ }
+ If.amp5 {
+ Condition {
+ Type ControlExists
+ Control "name='AMP5 Speaker Switch'"
+ }
+ True {
+ EnableSequence [
+ cset "name='AMP5 Speaker Switch' 1"
+ ]
+ DisableSequence [
+ cset "name='AMP5 Speaker Switch' 0"
+ ]
+ }
+ }
+ If.amp6 {
+ Condition {
+ Type ControlExists
+ Control "name='AMP6 Speaker Switch'"
+ }
+ True {
+ EnableSequence [
+ cset "name='AMP6 Speaker Switch' 1"
+ ]
+ DisableSequence [
+ cset "name='AMP6 Speaker Switch' 0"
+ ]
+ }
+ }
+ If.amp7 {
+ Condition {
+ Type ControlExists
+ Control "name='AMP7 Speaker Switch'"
+ }
+ True {
+ EnableSequence [
+ cset "name='AMP7 Speaker Switch' 1"
+ ]
+ DisableSequence [
+ cset "name='AMP7 Speaker Switch' 0"
+ ]
+ }
+ }
+ If.amp8 {
+ Condition {
+ Type ControlExists
+ Control "name='AMP8 Speaker Switch'"
+ }
+ True {
+ EnableSequence [
+ cset "name='AMP8 Speaker Switch' 1"
+ ]
+ DisableSequence [
+ cset "name='AMP8 Speaker Switch' 0"
+ ]
+ }
+ }
+
+ Value {
+ PlaybackPriority 100
+ PlaybackPCM "hw:${CardId},2"
+ }
+}
cs35l56 is a boosted speaker amp, add UCM support for configurations with up to 8 amps. This also updates the default naming for the speaker amp UCM file to remove the number of amps. Special cases are added for the existing amps that require different UCM for different numbers of amps, but future additions will defaults to not including it in the naming. Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> --- ucm2/sof-soundwire/HiFi.conf | 12 +++- ucm2/sof-soundwire/cs35l56.conf | 123 ++++++++++++++++++++++++++++++++ 2 files changed, 134 insertions(+), 1 deletion(-) create mode 100644 ucm2/sof-soundwire/cs35l56.conf