diff --git a/tools/topology/topology2/cavs-nocodec.conf b/tools/topology/topology2/cavs-nocodec.conf index 09a13b4926ad..4270457f1805 100644 --- a/tools/topology/topology2/cavs-nocodec.conf +++ b/tools/topology/topology2/cavs-nocodec.conf @@ -101,6 +101,7 @@ IncludeByKey.PLATFORM { "adl" "platform/intel/tgl.conf" "mtl" "platform/intel/mtl.conf" "lnl" "platform/intel/lnl.conf" + "ptl" "platform/intel/ptl.conf" } # include DMIC config if needed. @@ -328,10 +329,12 @@ IncludeByKey.PASSTHROUGH { num_input_audio_formats 2 Object.Base.input_audio_format [ { + in_rate $DMIC0_RATE in_bit_depth 32 in_valid_bit_depth 32 } { + in_rate $DMIC0_RATE in_channels 4 in_bit_depth 32 in_valid_bit_depth 32 @@ -343,10 +346,12 @@ IncludeByKey.PASSTHROUGH { num_output_audio_formats 2 Object.Base.output_audio_format [ { + out_rate $DMIC0_RATE out_bit_depth 32 out_valid_bit_depth 32 } { + out_rate $DMIC0_RATE out_channels 4 out_bit_depth 32 out_valid_bit_depth 32 @@ -360,10 +365,12 @@ IncludeByKey.PASSTHROUGH { num_input_audio_formats 2 Object.Base.input_audio_format [ { + in_rate $DMIC0_RATE in_bit_depth 32 in_valid_bit_depth 32 } { + in_rate $DMIC0_RATE in_channels 4 in_bit_depth 32 in_valid_bit_depth 32 @@ -375,10 +382,12 @@ IncludeByKey.PASSTHROUGH { num_output_audio_formats 2 Object.Base.output_audio_format [ { + out_rate $DMIC0_RATE out_bit_depth 32 out_valid_bit_depth 32 } { + out_rate $DMIC0_RATE out_channels 4 out_bit_depth 32 out_valid_bit_depth 32 @@ -764,10 +773,12 @@ IncludeByKey.PASSTHROUGH { num_input_audio_formats 2 Object.Base.input_audio_format [ { + in_rate $DMIC0_RATE in_bit_depth 32 in_valid_bit_depth 32 } { + in_rate $DMIC0_RATE in_channels 4 in_bit_depth 32 in_valid_bit_depth 32 @@ -779,10 +790,12 @@ IncludeByKey.PASSTHROUGH { num_output_audio_formats 2 Object.Base.output_audio_format [ { + out_rate $DMIC0_RATE out_bit_depth 32 out_valid_bit_depth 32 } { + out_rate $DMIC0_RATE out_channels 4 out_bit_depth 32 out_valid_bit_depth 32 @@ -796,10 +809,12 @@ IncludeByKey.PASSTHROUGH { num_input_audio_formats 2 Object.Base.input_audio_format [ { + in_rate $DMIC0_RATE in_bit_depth 32 in_valid_bit_depth 32 } { + in_rate $DMIC0_RATE in_channels 4 in_bit_depth 32 in_valid_bit_depth 32 @@ -811,10 +826,12 @@ IncludeByKey.PASSTHROUGH { num_output_audio_formats 2 Object.Base.output_audio_format [ { + out_rate $DMIC0_RATE out_bit_depth 32 out_valid_bit_depth 32 } { + out_rate $DMIC0_RATE out_channels 4 out_bit_depth 32 out_valid_bit_depth 32 @@ -840,10 +857,12 @@ IncludeByKey.PASSTHROUGH { num_input_audio_formats 2 Object.Base.input_audio_format [ { + in_rate $DMIC0_RATE in_bit_depth 32 in_valid_bit_depth 32 } { + in_rate $DMIC0_RATE in_channels 4 in_bit_depth 32 in_valid_bit_depth 32 @@ -855,10 +874,12 @@ IncludeByKey.PASSTHROUGH { num_output_audio_formats 2 Object.Base.output_audio_format [ { + out_rate $DMIC0_RATE out_bit_depth 32 out_valid_bit_depth 32 } { + out_rate $DMIC0_RATE out_channels 4 out_bit_depth 32 out_valid_bit_depth 32 @@ -872,10 +893,12 @@ IncludeByKey.PASSTHROUGH { num_input_audio_formats 2 Object.Base.input_audio_format [ { + in_rate $DMIC0_RATE in_bit_depth 32 in_valid_bit_depth 32 } { + in_rate $DMIC0_RATE in_channels 4 in_bit_depth 32 in_valid_bit_depth 32 @@ -887,10 +910,12 @@ IncludeByKey.PASSTHROUGH { num_output_audio_formats 2 Object.Base.output_audio_format [ { + out_rate $DMIC0_RATE out_bit_depth 32 out_valid_bit_depth 32 } { + out_rate $DMIC0_RATE out_channels 4 out_bit_depth 32 out_valid_bit_depth 32 @@ -960,6 +985,17 @@ IncludeByKey.PASSTHROUGH { formats 'S32_LE' channels_min $NUM_DMICS channels_max $NUM_DMICS + IncludeByKey.DMIC0_RATE { + "16000" { + rates '16000' + } + "48000" { + rates '48000' + } + "96000" { + rates '96000' + } + } } } { @@ -974,6 +1010,17 @@ IncludeByKey.PASSTHROUGH { formats 'S32_LE' channels_min $NUM_DMICS channels_max $NUM_DMICS + IncludeByKey.DMIC0_RATE { + "16000" { + rates '16000' + } + "48000" { + rates '48000' + } + "96000" { + rates '96000' + } + } } } { diff --git a/tools/topology/topology2/cavs-rt5682.conf b/tools/topology/topology2/cavs-rt5682.conf index f601ef878d47..91462a8c762f 100644 --- a/tools/topology/topology2/cavs-rt5682.conf +++ b/tools/topology/topology2/cavs-rt5682.conf @@ -129,6 +129,7 @@ Define { IncludeByKey.PLATFORM { "mtl" "platform/intel/mtl.conf" "lnl" "platform/intel/lnl.conf" + "ptl" "platform/intel/ptl.conf" } # include DMIC config if needed. diff --git a/tools/topology/topology2/development/tplg-targets.cmake b/tools/topology/topology2/development/tplg-targets.cmake index 67567dc78191..2217ae70fa27 100644 --- a/tools/topology/topology2/development/tplg-targets.cmake +++ b/tools/topology/topology2/development/tplg-targets.cmake @@ -60,6 +60,35 @@ NHLT_BIN=nhlt-sof-lnl-nocodec-fpga-4ch.bin,PASSTHROUGH=true,DMIC_IO_CLK=19200000 # HDA topology with passthrough analog codec pipelines using CHAIN_DMA "sof-hda-generic\;sof-hda-passthrough-chain-dma\;HDA_CONFIG=passthrough\;CODEC_HDA_CHAIN_DMA=true" +# SSP topology for PTL +"cavs-nocodec\;sof-ptl-nocodec\;PLATFORM=ptl,NUM_DMICS=4,PDM1_MIC_A_ENABLE=1,PDM1_MIC_B_ENABLE=1,\ +PREPROCESS_PLUGINS=nhlt,NHLT_BIN=nhlt-sof-ptl-nocodec.bin" + +# SSP topology for PTL with 96 kHz DMIC +"cavs-nocodec\;sof-ptl-nocodec-dmic-4ch-96k\;PLATFORM=ptl,NUM_DMICS=4,PDM1_MIC_A_ENABLE=1,PDM1_MIC_B_ENABLE=1,\ +DMIC0_RATE=96000,PREPROCESS_PLUGINS=nhlt,NHLT_BIN=nhlt-sof-ptl-nocodec-dmic-4ch-96k.bin" + +# SSP topology for PTL FPGA with lower DMIC IO clock of 19.2MHz, 2ch PDM0 enabled +"cavs-nocodec\;sof-ptl-nocodec-fpga-2ch-pdm0\;PLATFORM=ptl,NUM_DMICS=2,PREPROCESS_PLUGINS=nhlt,\ +NHLT_BIN=nhlt-sof-ptl-nocodec-fpga-2ch-pdm0.bin,PASSTHROUGH=true,DMIC_IO_CLK=19200000" + +# SSP topology for PTL FPGA with lower DMIC IO clock of 19.2MHz, 4ch both PDM0 and PDM1 enabled +"cavs-nocodec\;sof-ptl-nocodec-fpga-4ch\;PLATFORM=ptl,NUM_DMICS=4,PDM1_MIC_A_ENABLE=1,\ +PDM1_MIC_B_ENABLE=1,PREPROCESS_PLUGINS=nhlt,\ +NHLT_BIN=nhlt-sof-ptl-nocodec-fpga-4ch.bin,PASSTHROUGH=true,DMIC_IO_CLK=19200000" + +# SSP topology for PTL FPGA with lower DMIC IO clock of 19.2MHz, 4ch both PDM0 and PDM1 enabled, with 96 kHz DMIC +"cavs-nocodec\;sof-ptl-nocodec-fpga-dmic-4ch-96k\;PLATFORM=ptl,NUM_DMICS=4,PDM1_MIC_A_ENABLE=1,\ +PDM1_MIC_B_ENABLE=1,DMIC0_RATE=96000,PREPROCESS_PLUGINS=nhlt,\ +NHLT_BIN=nhlt-sof-ptl-nocodec-fpga-dmic-4ch-96k.bin,PASSTHROUGH=true,DMIC_IO_CLK=19200000" + +# Topology for PTL with max98357a and rt5682 +"cavs-rt5682\;sof-ptl-max98357a-rt5682-ssp2-ssp0\;PLATFORM=ptl,NUM_DMICS=4,PDM1_MIC_A_ENABLE=1,\ +PDM1_MIC_B_ENABLE=1,DMIC0_PCM_ID=99,PREPROCESS_PLUGINS=nhlt,\ +NHLT_BIN=nhlt-sof-ptl-max98357a-rt5682-ssp2-ssp0.bin,DEEPBUFFER_FW_DMA_MS=10,HEADSET_SSP_DAI_INDEX=2,\ +SPK_ID=6,SPEAKER_SSP_DAI_INDEX=0,HEADSET_CODEC_NAME=SSP2-Codec,SPEAKER_CODEC_NAME=SSP0-Codec,\ +BT_NAME=SSP1-BT,BT_INDEX=1,BT_ID=7,BT_PCM_NAME=Bluetooth,INCLUDE_ECHO_REF=true,DEEP_BUF_SPK=true" + # CAVS HDA topology with mixer-based efx eq pipelines for HDA and passthrough pipelines for HDMI "sof-hda-generic\;sof-hda-efx-generic\;HDA_CONFIG=efx,HDA_MIC_ENHANCED_CAPTURE=true,\ EFX_FIR_PARAMS=passthrough,EFX_IIR_PARAMS=passthrough,EFX_DRC_PARAMS=passthrough,\ diff --git a/tools/topology/topology2/include/common/common_definitions.conf b/tools/topology/topology2/include/common/common_definitions.conf index fe4a2d6e142e..9da9fcb78f34 100644 --- a/tools/topology/topology2/include/common/common_definitions.conf +++ b/tools/topology/topology2/include/common/common_definitions.conf @@ -64,4 +64,5 @@ Define { SSP_BLOB_VERSION_1_0 0x100 SSP_BLOB_VERSION_1_5 0x105 + SSP_BLOB_VERSION_3_0 0x300 } diff --git a/tools/topology/topology2/include/dais/ssp.conf b/tools/topology/topology2/include/dais/ssp.conf index 6c0d91f2bd69..cccba74dea10 100644 --- a/tools/topology/topology2/include/dais/ssp.conf +++ b/tools/topology/topology2/include/dais/ssp.conf @@ -113,6 +113,7 @@ Class.Dai."SSP" { !valid_values [ $SSP_BLOB_VERSION_1_0 $SSP_BLOB_VERSION_1_5 + $SSP_BLOB_VERSION_3_0 ] } } diff --git a/tools/topology/topology2/platform/intel/dmic-generic.conf b/tools/topology/topology2/platform/intel/dmic-generic.conf index 22b811c18c83..4929fbab0687 100644 --- a/tools/topology/topology2/platform/intel/dmic-generic.conf +++ b/tools/topology/topology2/platform/intel/dmic-generic.conf @@ -721,8 +721,17 @@ Object.PCM.pcm [ formats 'S32_LE' channels_min $DMIC0_PCM_CHANNELS channels_max $DMIC0_PCM_CHANNELS - rate_min $DMIC0_RATE - rate_max $DMIC0_RATE + IncludeByKey.DMIC0_RATE { + "16000" { + rates '16000' + } + "48000" { + rates '48000' + } + "96000" { + rates '96000' + } + } } } ]