topology2: add be pipeline for sdw

Use two separated pipelines for BE and FE.

Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
This commit is contained in:
Bard Liao 2022-03-02 15:24:55 +08:00 committed by Liam Girdwood
parent 0ee59c317e
commit ccde447b05
1 changed files with 43 additions and 74 deletions

View File

@ -10,6 +10,7 @@
<virtual.conf>
<passthrough-playback.conf>
<passthrough-capture.conf>
<passthrough-be.conf>
<data.conf>
<pcm.conf>
<pcm_caps.conf>
@ -41,38 +42,6 @@ Object.Dai {
Object.Base.hw_config."ALH2" {
id 0
}
# include DAI copier components
Object.Widget.copier."0" {
index 2
dai_index 2
type "dai_in"
dai_type "ALH"
copier_type "ALH"
direction "playback"
stream_name "SDW0-Playback"
period_sink_count 0
period_source_count 2
format s16le
node_type $ALH_LINK_OUTPUT_CLASS
num_audio_formats 2
# 16-bit 48KHz 2ch
Object.Base.audio_format.1 {
# 16 -> 32 bits conversion will be done in the copier,
# therefore the out_bit_depth is 32
out_bit_depth 32
# dma_buffer_size should be 2 * obs for playback
dma_buffer_size "$[$obs * 2]"
}
# 32-bit 48KHz 2ch
Object.Base.audio_format.2 {
in_bit_depth 32
in_valid_bit_depth 32
out_bit_depth 32
out_valid_bit_depth 32
dma_buffer_size "$[$obs * 2]"
}
}
}
ALH."3" {
id 1
@ -85,38 +54,6 @@ Object.Dai {
Object.Base.hw_config."ALH3" {
id 1
}
Object.Widget.copier."0" {
index 3
dai_index 3
type "dai_out"
dai_type "ALH"
copier_type "ALH"
direction "capture"
stream_name "SDW0-Capture"
period_sink_count 2
period_source_count 0
format s16le
node_type $ALH_LINK_INPUT_CLASS
num_audio_formats 2
# 16-bit 48KHz 2ch
Object.Base.audio_format.1 {
# 32 -> 16 bits conversion will be done in pipeline,
# so both in_bit_depth and out_bit_depth are still 32 here.
in_bit_depth 32
out_bit_depth 32
# dma_buffer_size should be 2 * ibs for capture
dma_buffer_size "$[$ibs * 2]"
}
# 32-bit 48KHz 2ch
Object.Base.audio_format.2 {
in_bit_depth 32
in_valid_bit_depth 32
out_bit_depth 32
out_valid_bit_depth 32
dma_buffer_size "$[$ibs * 2]"
}
}
}
}
@ -126,19 +63,35 @@ Object.Dai {
# Pipeline ID:1 PCM ID: 0
Object.Pipeline {
passthrough-playback."2" {
passthrough-playback."1" {
format "s16le"
index 2
index 1
Object.Widget.pipeline.1.stream_name "copier.ALH.2.0"
Object.Widget.pipeline.1.stream_name "copier.ALH.2.1"
Object.Widget.copier.1.stream_name "Passthrough Playback 0"
}
passthrough-be.1 {
direction "playback"
index 2
passthrough-capture."3" {
Object.Widget.pipeline.1 {
stream_name 'copier.ALH.2.1'
}
Object.Widget.copier.1 {
stream_name 'SDW0-Playback'
dai_type "ALH"
copier_type "ALH"
type "dai_in"
node_type $ALH_LINK_OUTPUT_CLASS
}
format s16le
}
passthrough-capture."4" {
format "s16le"
index 3
Object.Widget.pipeline.1.stream_name "copier.ALH.3.0"
index 4
Object.Widget.pipeline.1.stream_name "copier.ALH.3.1"
Object.Widget.copier.1.stream_name "Passthrough Capture 0"
Object.Widget.copier.1.Object.Base.audio_format.1 {
@ -147,6 +100,22 @@ Object.Pipeline {
in_bit_depth 32
}
}
passthrough-be.2 {
direction "capture"
index 3
copier_type "ALH"
Object.Widget.pipeline.1 {
stream_name 'copier.ALH.3.1'
}
Object.Widget.copier.1 {
stream_name 'SDW0-Capture'
dai_type "ALH"
copier_type "ALH"
type "dai_out"
node_type $ALH_LINK_INPUT_CLASS
}
format s16le
}
}
Object.PCM {
@ -176,12 +145,12 @@ Object.PCM {
Object.Base {
route."0" {
source "copier.host.2.1"
sink "copier.ALH.2.0"
source "copier.host.1.1"
sink "copier.ALH.2.1"
}
route."1" {
source "copier.ALH.3.0"
sink "copier.host.3.1"
source "copier.ALH.3.1"
sink "copier.host.4.1"
}
}