Skip to content

Commit

Permalink
ucm: add support for sof-glkda7219max
Browse files Browse the repository at this point in the history
Signed-off-by: Amery Song <[email protected]>
  • Loading branch information
Amery Song committed Jan 19, 2020
1 parent f083700 commit 6a45d0e
Show file tree
Hide file tree
Showing 5 changed files with 237 additions and 0 deletions.
31 changes: 31 additions & 0 deletions ucm/sof-glkda7219max/Hdmi1.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
SectionVerb {

EnableSequence [
cdev "hw:sofglkda7219max"
]

DisableSequence [
cdev "hw:sofglkda7219max"
]
}

SectionDevice."HDMI1" {
Comment "HDMI1/DP1 Playback"

Value {
PlaybackPCM "hw:sofglkda7219max,5"
PlaybackChannels "2"
JackControl "HDMI/DP,pcm=5 Jack"
PlaybackPriority "300"
}

EnableSequence [
cdev "hw:sofglkda7219max"
cset "name='IEC958 Playback Switch' on"
]

DisableSequence [
cdev "hw:sofglkda7219max"
cset "name='IEC958 Playback Switch' off"
]
}
31 changes: 31 additions & 0 deletions ucm/sof-glkda7219max/Hdmi2.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
SectionVerb {

EnableSequence [
cdev "hw:sofglkda7219max"
]

DisableSequence [
cdev "hw:sofglkda7219max"
]
}

SectionDevice."HDMI2" {
Comment "HDMI2/DP2 Playback"

Value {
PlaybackPCM "hw:sofglkda7219max,6"
PlaybackChannels "2"
JackControl "HDMI/DP,pcm=6 Jack"
PlaybackPriority "400"
}

EnableSequence [
cdev "hw:sofglkda7219max"
cset "name='IEC958 Playback Switch',index=1 on"
]

DisableSequence [
cdev "hw:sofglkda7219max"
cset "name='IEC958 Playback Switch',index=1 off"
]
}
31 changes: 31 additions & 0 deletions ucm/sof-glkda7219max/Hdmi3.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
SectionVerb {

EnableSequence [
cdev "hw:sofglkda7219max"
]

DisableSequence [
cdev "hw:sofglkda7219max"
]
}

SectionDevice."HDMI3" {
Comment "HDMI3/DP3 Playback"

Value {
PlaybackPCM "hw:sofglkda7219max,7"
PlaybackChannels "2"
JackControl "HDMI/DP,pcm=7 Jack"
PlaybackPriority "500"
}

EnableSequence [
cdev "hw:sofglkda7219max"
cset "name='IEC958 Playback Switch',index=2 on"
]

DisableSequence [
cdev "hw:sofglkda7219max"
cset "name='IEC958 Playback Switch',index=2 on"
]
}
112 changes: 112 additions & 0 deletions ucm/sof-glkda7219max/HiFi.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,112 @@
SectionVerb {

EnableSequence [
cdev "hw:sofglkda7219max"
]

DisableSequence [
cdev "hw:sofglkda7219max"
]
}

SectionDevice."Speaker" {
Comment "Speaker Playback"

Value {
PlaybackPCM "hw:sofglkda7219max,0"
PlaybackChannels "2"
}

EnableSequence [
cdev "hw:sofglkda7219max"
cset "name='Spk Switch' on"
]

DisableSequence [
cdev "hw:sofglkda7219max"
cset "name='Spk Switch' off"
]
}

SectionDevice."Headset Playback" {
Comment "Headset Playback"

Value {
PlaybackPCM "hw:sofglkda7219max,1"
PlaybackChannels "2"
JackName "sofglkda7219max Headset Jack"
JackControl "Headset Jack"
JackType "gpio"
}

EnableSequence [
cdev "hw:sofglkda7219max"
cset "name='Headphone Switch' on"
cset "name='Headphone Jack Switch' on"
cset "name='Playback Digital Switch' on"
cset "name='Mixer Out FilterL DACL Switch' on"
cset "name='Mixer Out FilterR DACR Switch' on"
]

DisableSequence [
cdev "hw:sofglkda7219max"
cset "name='Headphone Switch' off"
cset "name='Headphone Jack Switch' off"
cset "name='Playback Digital Switch' off"
cset "name='Mixer Out FilterL DACL Switch' off"
cset "name='Mixer Out FilterR DACR Switch' off"
]
}

SectionDevice."Mic" {
Comment "Headset Capture"

Value {
CapturePCM "hw:sofglkda7219max,1"
CaptureChannels "2"
JackName "sofglkda7219max Headset Jack"
JackControl "Headset Jack"
JackType "gpio"
}

EnableSequence [
cdev "hw:sofglkda7219max"
cset "name='Headphone Switch' on"
cset "name='Headset Mic Switch' on"
cset "name='Headphone Jack Switch' on"
cset "name='Mixer In Mic Switch' on"
cset "name='Capture Digital Switch' on"
cset "name='Mixer In Mic Switch' on"
cset "name='Mixin Switch' on"
cset "name='Mic Switch' on"
]

DisableSequence [
cdev "hw:sofglkda7219max"
cset "name='Headphone Switch' off"
cset "name='Headset Mic Switch' off"
cset "name='Headphone Jack Switch' off"
cset "name='Mixer In Mic Switch' off"
cset "name='Capture Digital Switch' off"
cset "name='Mixer In Mic Switch' off"
cset "name='Mixin Switch' off"
cset "name='Mic Switch' off"
]
}

SectionDevice."DMIC" {
Comment "DMIC Capture"

Value {
CapturePCM "hw:sofglkda7219max,99"
CaptureChannels "4"
}

EnableSequence [
cdev "hw:sofglkda7219max"
]

DisableSequence [
cdev "hw:sofglkda7219max"
]
}
32 changes: 32 additions & 0 deletions ucm/sof-glkda7219max/sof-glkda7219max.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
SectionUseCase."HiFi" {
File "HiFi.conf"
Comment "Default"
}

SectionUseCase."Hdmi1" {
File "Hdmi1.conf"
Comment "Play to Hdmi1"
}

SectionUseCase."Hdmi2" {
File "Hdmi2.conf"
Comment "Play to Hdmi2"
}

SectionUseCase."Hdmi3" {
File "Hdmi3.conf"
Comment "Play to Hdmi3"
}

SectionDefaults [
cdev "hw:sofglkda7219max"
cset "name='Headphone Switch' off"
cset "name='Headphone Jack Switch' off"
cset "name='Mic Volume' 50"
cset "name='Out DACL Mux' DAIL"
cset "name='Out DACR Mux' DAIR"
cset "name='Out DAIL Mux' ADC"
cset "name='Out DAIR Mux' ADC"
cset "name='Gain Ramp Rate' 1"
cset "name='Playback Digital Volume' 115"
]

0 comments on commit 6a45d0e

Please sign in to comment.