ucm2: MediaTek: mt8390-evk: Add alsa-ucm support

Add alsa-ucm support for the MediaTek mt8390-evk platform.

Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/321
Signed-off-by: Zoran Zhan <zoran.zhan@mediatek.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
Zoran Zhan 2023-06-01 15:37:14 +08:00 committed by Jaroslav Kysela
commit c5366bdff6
3 changed files with 211 additions and 0 deletions

View file

@ -0,0 +1,165 @@
SectionDevice."HDMI1" {
Comment "HDMI output"
Value {
PlaybackPriority 300
PlaybackPCM "hw:${CardId},5"
JackControl "HDMI Jack"
}
EnableSequence [
cset "name='HDMI_OUT_MUX' 1"
]
DisableSequence [
cset "name='HDMI_OUT_MUX' 0"
]
}
SectionDevice."HDMI2" {
Comment "DP output"
Value {
PlaybackPriority 300
PlaybackPCM "hw:${CardId},5"
JackControl "DP Jack"
}
EnableSequence [
cset "name='DPTX_OUT_MUX' 1"
]
DisableSequence [
cset "name='DPTX_OUT_MUX' 0"
]
}
SectionDevice."Speaker" {
Comment "Lineout speaker"
ConflictingDevice [
"Headphones"
]
EnableSequence [
cset "name='LOL Mux' Playback_L_DAC"
]
DisableSequence [
cset "name='LOL Mux' Open"
]
Value {
PlaybackPriority 400
PlaybackChannels 2
PlaybackPCM "hw:${CardId},0"
}
}
SectionDevice."Headphones" {
Comment "Earphone speaker"
ConflictingDevice [
"Speaker"
]
EnableSequence [
cset "name='HP Mux' Audio Playback"
]
DisableSequence [
cset "name='HP Mux' Open"
]
Value {
PlaybackPriority 500
PlaybackChannels 2
PlaybackPCM "hw:${CardId},0"
}
}
SectionDevice."Headset" {
Comment "Earphone microphone"
ConflictingDevice [
"Mic1"
]
EnableSequence [
cset "name='PGA_L_Mux' AIN1"
]
Value {
CapturePriority 500
CaptureChannels 1
CapturePCM "hw:${CardId},10"
}
}
SectionDevice."Mic1" {
Comment "Analog microphone"
ConflictingDevice [
"Headset"
]
EnableSequence [
cset "name='PGA_L_Mux' AIN0"
]
Value {
CapturePriority 400
CaptureChannels 1
CapturePCM "hw:${CardId},10"
}
}
SectionDevice."Mic2" {
Comment "Digital microphone"
Value {
CapturePriority 300
CaptureChannels 2
CapturePCM "hw:${CardId},14"
}
}
SectionDevice."Line1" {
Comment "PCM input"
Value {
CapturePriority 200
CaptureChannels 2
CapturePCM "hw:${CardId},8"
}
}
SectionDevice."Line2" {
Comment "PCM output"
Value {
PlaybackPriority 200
PlaybackChannels 2
PlaybackPCM "hw:${CardId},2"
}
}
SectionDevice."Line3" {
Comment "I2S input"
Value {
CapturePriority 100
CaptureChannels 2
CapturePCM "hw:${CardId},11"
}
}
SectionDevice."Line4" {
Comment "I2S output"
Value {
PlaybackPriority 100
PlaybackChannels 8
PlaybackPCM "hw:${CardId},6"
}
}

View file

@ -0,0 +1,45 @@
Syntax 4
SectionUseCase."HiFi" {
File "/MediaTek/mt8390-evk/HiFi.conf"
Comment "Play high quality music"
}
BootSequence [
cset "name='HP Mux' Audio Playback"
cset "name='LOL Mux' Open"
cset "name='MISO0_MUX' UL1_CH1"
cset "name='MISO1_MUX' UL1_CH1"
cset "name='ADC_L_Mux' Left Preamplifier"
cset "name='PGA_L_Mux' AIN1"
cset "name='HDMI_OUT_MUX' Connect"
cset "name='DPTX_OUT_MUX' Disconnect"
cset "name='ETDM_OUT1_Clock_Source' a1sys_a2sys"
cset "name='ETDM_OUT2_Clock_Source' a1sys_a2sys"
cset "name='ETDM_OUT3_Clock_Source' a1sys_a2sys"
cset "name='ETDM_IN1_Clock_Source' a1sys_a2sys"
cset "name='ETDM_IN2_Clock_Source' a1sys_a2sys"
cset "name='Lineout Volume' 10"
cset "name='Headset Volume' 2"
cset "name='PGA1 Volume' 4"
cset "name='O000 I000 Switch' on"
cset "name='O001 I001 Switch' on"
cset "name='O002 I004 Switch' on"
cset "name='O003 I006 Switch' on"
cset "name='O034 I168 Switch' on"
cset "name='O035 I169 Switch' on"
cset "name='O036 I012 Switch' on"
cset "name='O037 I013 Switch' on"
cset "name='O040 I002 Switch' on"
cset "name='O041 I003 Switch' on"
cset "name='O048 I022 Switch' on"
cset "name='O049 I023 Switch' on"
cset "name='O050 I024 Switch' on"
cset "name='O051 I025 Switch' on"
cset "name='O052 I026 Switch' on"
cset "name='O053 I027 Switch' on"
cset "name='O054 I028 Switch' on"
cset "name='O055 I029 Switch' on"
cset "name='O176 I070 Switch' on"
cset "name='O177 I071 Switch' on"
]

View file

@ -0,0 +1 @@
../../MediaTek/mt8390-evk/mt8390-evk.conf