diff --git a/app/boards/intel_adsp/Kconfig.defconfig b/app/boards/intel_adsp/Kconfig.defconfig index 4edb5b81e22b..0fd7126d58d1 100644 --- a/app/boards/intel_adsp/Kconfig.defconfig +++ b/app/boards/intel_adsp/Kconfig.defconfig @@ -121,7 +121,7 @@ config MM_DRV default y config UAOL - default n + default y if ACE # # Zephyr / power settings diff --git a/app/wov-d0i3-fake-wake.conf b/app/wov-d0i3-fake-wake.conf index 8c506e9706a3..1f247d88f6a9 100644 --- a/app/wov-d0i3-fake-wake.conf +++ b/app/wov-d0i3-fake-wake.conf @@ -7,7 +7,3 @@ CONFIG_COMP_MWW_FAKE_WAKE_MS=5000 # LLEXT relocatable ELF format for loadable modules on Intel ADSP ACE 3.0 CONFIG_LLEXT_TYPE_ELF_RELOCATABLE=y -# Disable USB Audio Offload (UAOL) -CONFIG_UAOL=n -CONFIG_DAI_INTEL_UAOL=n - diff --git a/src/audio/intel_uaol.c b/src/audio/intel_uaol.c index b6b50981c2c3..155787a33f9c 100644 --- a/src/audio/intel_uaol.c +++ b/src/audio/intel_uaol.c @@ -4,9 +4,9 @@ */ #include +#include #include #include -#include #include LOG_MODULE_REGISTER(uaol, CONFIG_SOF_LOG_LEVEL); diff --git a/tools/topology/topology2/README.md b/tools/topology/topology2/README.md index 0d62fd859a08..10d587d8e35d 100644 --- a/tools/topology/topology2/README.md +++ b/tools/topology/topology2/README.md @@ -243,8 +243,10 @@ default ID ranges for the same endpoint types. | Jack Echo Ref | 11 | `SDW_JACK_ECHO_REF_PCM_ID` | | Speaker Echo Ref | 12 | `SDW_SPK_ECHO_REF_PCM_ID` | | Bluetooth | 2 or 20 | `BT_PCM_ID` | -| USB Audio Offload (UAOL) | 21 | `UAOL_PCM_ID` | -| Deepbuffer UAOL | 22 | `DEEP_BUFFER_PCM_ID` | +| USB Audio Offload (UAOL0) | 21 | `UAOL_PCM_ID` | +| USB Audio Offload (UAOL1) | 22 | `UAOL_PCM1_ID` | +| Deepbuffer UAOL0 | 23 | `UAOL_DB_PCM_ID` | +| Deepbuffer UAOL1 | 24 | `UAOL_DB1_PCM_ID` | | Deep Buffer (Jack) | 31 | `DEEP_BUFFER_PCM_ID` | | Deep Buffer (Speaker) | 35 | `DEEP_BUFFER_PCM_ID_2` | | DMIC Deep Buffer | 46 | `DMIC0_DEEP_BUFFER_PCM_ID` | @@ -304,9 +306,12 @@ is at N1 (50/51, 60/61, 70/71, 80/81). | HDMI 4 Host / DAI | 80 / 81 | `HDMI4_HOST_PIPELINE_ID` / `HDMI4_DAI_PIPELINE_ID` | | Compress Jack / Speaker | 90 / 92 | `COMPR_PIPELINE_ID` / `COMPR_2_PIPELINE_ID` | | PCH DMIC0 Host / DAI | 100 / 101 | `DMIC0_HOST_PIPELINE_ID` / `DMIC0_DAI_PIPELINE_ID` | -| UAOL Playback Host / DAI | 210 / 211 | `UAOL_PB_HOST_PIPELINE_ID` / `UAOL_PB_DAI_PIPELINE_ID` | -| UAOL Capture Host / DAI | 212 / 213 | `UAOL_CP_HOST_PIPELINE_ID` / `UAOL_CP_DAI_PIPELINE_ID` | -| UAOL Deepbuffer | 214 | `DEEP_BUFFER_PIPELINE_ID` | +| UAOL0 Playback Host / DAI | 210 / 211 | `UAOL_PB_HOST_PIPELINE_ID` / `UAOL_PB_DAI_PIPELINE_ID` | +| UAOL0 Capture Host / DAI | 212 / 213 | `UAOL_CP_HOST_PIPELINE_ID` / `UAOL_CP_DAI_PIPELINE_ID` | +| UAOL0 Deepbuffer | 214 | `UAOL_DB_PIPELINE_ID` | +| UAOL1 Playback Host / DAI | 215 / 216 | `UAOL_PB1_HOST_PIPELINE_ID` / `UAOL_PB1_DAI_PIPELINE_ID` | +| UAOL1 Capture Host / DAI | 217 / 218 | `UAOL_CP1_HOST_PIPELINE_ID` / `UAOL_CP1_DAI_PIPELINE_ID` | +| UAOL1 Deepbuffer | 219 | `UAOL_DB1_PIPELINE_ID` | **Intel HDA Pipeline IDs:** diff --git a/tools/topology/topology2/cavs-uaol.conf b/tools/topology/topology2/cavs-uaol.conf index 0baa4cb28f74..85ee38b5401e 100644 --- a/tools/topology/topology2/cavs-uaol.conf +++ b/tools/topology/topology2/cavs-uaol.conf @@ -42,45 +42,64 @@ Define { - UAOL_PLAYBACK_PCM 'UAOL Playback' - UAOL_CAPTURE_PCM 'UAOL Capture' + UAOL_PLAYBACK_PCM 'USB Offload 0 Playback' + UAOL_CAPTURE_PCM 'USB Offload 0 Capture' # The two directions are separate DAI links so that the format fixup of - # a link is decided by the DAI copier of that direction alone. The names - # are abbreviated because alsatplg drops widget tuples above 36 characters - # and the dai-copier name is 'dai-copier.UAOL..' - UAOL_PB_DAI_NAME 'UAOL0-Play' - UAOL_CP_DAI_NAME 'UAOL0-Cap' + # a link is decided by the DAI copier of that direction alone, and the + # link carries two streams per direction, each with a backend of its + # own: UAOL-Play and UAOL-Cap. The names are abbreviated + # because alsa-lib drops widget tuples once the dai-copier name, + # 'dai-copier.UAOL..', exceeds 37 characters + UAOL_PB_DAI_NAME 'UAOL0-Play0' + UAOL_CP_DAI_NAME 'UAOL0-Cap0' # The BE IDs are the dai link IDs that are matched with the machine - # driver, which creates the playback link first + # driver, which creates the backends in the order Play0, Cap0, Play1, + # Cap1 UAOL_PB_BE_ID 9 UAOL_CP_BE_ID 10 # UAOL_DAI_INDEX is the UAOL link the DSP uses, only link 0 is addressable UAOL_DAI_INDEX 0 - UAOL_PCM_NAME 'UAOL' + UAOL_PCM_NAME 'USB Offload 0' UAOL_PCM_ID 21 UAOL_PB_HOST_PIPELINE_ID 210 UAOL_PB_DAI_PIPELINE_ID 211 UAOL_CP_HOST_PIPELINE_ID 212 UAOL_CP_DAI_PIPELINE_ID 213 + + # Second stream pair of the link, on its own PCM + UAOL_NUM_STREAMS 2 + UAOL_PLAYBACK1_PCM 'USB Offload 1 Playback' + UAOL_CAPTURE1_PCM 'USB Offload 1 Capture' + UAOL_PB1_DAI_NAME 'UAOL0-Play1' + UAOL_CP1_DAI_NAME 'UAOL0-Cap1' + UAOL_PB1_BE_ID 11 + UAOL_CP1_BE_ID 12 + UAOL_PCM1_NAME 'USB Offload 1' + UAOL_PCM1_ID 22 + UAOL_PB1_HOST_PIPELINE_ID 215 + UAOL_PB1_DAI_PIPELINE_ID 216 + UAOL_CP1_HOST_PIPELINE_ID 217 + UAOL_CP1_DAI_PIPELINE_ID 218 # Both paths pass through whatever the offloaded USB device asks for, so # the PCM advertises everything a USB device may support. 7 channels is # left out of the widget formats, it has no channel config and no channel # map, so it is the one count in the range which cannot be run. UAOL_CHANNELS_MIN 1 UAOL_CHANNELS_MAX 8 - # UAOL supports up to 192 kHz + # UAOL supports up to 384 kHz UAOL_RATE_MIN 8000 - UAOL_RATE_MAX 192000 - UAOL_RATES '8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000,128000,176400,192000' + UAOL_RATE_MAX 384000 + UAOL_RATES '8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000,128000,176400,192000,384000' - # The deep buffer PCM feeds the same mixer as the normal playback PCM. It - # takes the source and the sink as plain widget names, so it repeats the - # pipeline IDs defined above. - DEEP_BUFFER_PCM_NAME 'Deepbuffer UAOL' - DEEP_BUFFER_PCM_ID 22 - DEEP_BUFFER_PIPELINE_ID 214 - DEEP_BUFFER_PIPELINE_SRC 'mixin.214.1' - DEEP_BUFFER_PIPELINE_SINK 'mixout.211.1' + # The deep buffer PCMs feed the same mixer as the normal playback PCM of + # their stream + UAOL_DEEP_BUFFER 'true' + UAOL_DB_PCM_NAME 'Deepbuffer USB Offload 0' + UAOL_DB_PCM_ID 23 + UAOL_DB_PIPELINE_ID 214 + UAOL_DB1_PCM_NAME 'Deepbuffer USB Offload 1' + UAOL_DB1_PCM_ID 24 + UAOL_DB1_PIPELINE_ID 219 } diff --git a/tools/topology/topology2/development/sof-hda-generic-uaol.conf b/tools/topology/topology2/development/sof-hda-generic-uaol.conf new file mode 100644 index 000000000000..d997a90210a9 --- /dev/null +++ b/tools/topology/topology2/development/sof-hda-generic-uaol.conf @@ -0,0 +1,101 @@ +# HDA generic topology extended with the USB Audio Offload Link (UAOL). +# +# Development topology. The UAOL is not part of sof-hda-generic itself: the +# backend of a function which is not present on the machine makes the whole +# topology fail to load, and the UAOL DAIs only exist on ACE2 and newer +# platforms, with a kernel built for USB audio offload. Keeping it separate +# leaves sof-hda-generic loadable everywhere. +# +# Select it with: +# options snd_sof tplg_filename=sof-hda-generic-uaol.tplg +# +# The module parameter also stops the machine driver from appending the -idisp +# suffix, so this topology carries the iDisp backends unconditionally, as +# sof-hda-generic does. For a machine without an HDA codec, where the driver +# would have picked sof-hda-generic-idisp, use the sof-hda-generic-idisp-uaol variant +# instead, which is built from this file without the HDA codec paths. +# +# The UAOL function itself lives in platform/intel/uaol-generic.conf, and is +# shared with the cavs-uaol function topology of the sof_sdw card. + + + + + + + + + + + + + + + + +Define { + UAOL_PLAYBACK_PCM 'USB Offload 0 Playback' + UAOL_CAPTURE_PCM 'USB Offload 0 Capture' + # The two directions are separate DAI links so that the format fixup of + # a link is decided by the DAI copier of that direction alone, and the + # link carries two streams per direction, each with a backend of its + # own: UAOL-Play and UAOL-Cap. The names are abbreviated + # because alsa-lib drops widget tuples once the dai-copier name, + # 'dai-copier.UAOL..', exceeds 37 characters + UAOL_PB_DAI_NAME 'UAOL0-Play0' + UAOL_CP_DAI_NAME 'UAOL0-Cap0' + # The BE IDs are the dai link IDs that are matched with the machine + # driver. skl_hda_dsp_generic assigns fixed IDs, so these are the same + # whichever other functions the board has. The backends come in the + # order Play0, Cap0, Play1, Cap1 + UAOL_PB_BE_ID 9 + UAOL_CP_BE_ID 10 + # UAOL_DAI_INDEX is the UAOL link the DSP uses, only link 0 is addressable + UAOL_DAI_INDEX 0 + UAOL_PCM_NAME 'USB Offload 0' + UAOL_PCM_ID 21 + UAOL_PB_HOST_PIPELINE_ID 210 + UAOL_PB_DAI_PIPELINE_ID 211 + UAOL_CP_HOST_PIPELINE_ID 212 + UAOL_CP_DAI_PIPELINE_ID 213 + + # Second stream pair of the link, on its own PCM. Each backend offloads + # the USB PCM its route kcontrol points at; with a single USB device both + # routes point at it and the second PCM fails with EBUSY while the first + # one runs, a second device or a second PCM of the first lets both run + UAOL_NUM_STREAMS 2 + UAOL_PLAYBACK1_PCM 'USB Offload 1 Playback' + UAOL_CAPTURE1_PCM 'USB Offload 1 Capture' + UAOL_PB1_DAI_NAME 'UAOL0-Play1' + UAOL_CP1_DAI_NAME 'UAOL0-Cap1' + UAOL_PB1_BE_ID 11 + UAOL_CP1_BE_ID 12 + UAOL_PCM1_NAME 'USB Offload 1' + UAOL_PCM1_ID 22 + UAOL_PB1_HOST_PIPELINE_ID 215 + UAOL_PB1_DAI_PIPELINE_ID 216 + UAOL_CP1_HOST_PIPELINE_ID 217 + UAOL_CP1_DAI_PIPELINE_ID 218 + # Both paths pass through whatever the offloaded USB device asks for, so + # the PCM advertises everything a USB device may support. 7 channels is + # left out of the widget formats, it has no channel config and no channel + # map, so it is the one count in the range which cannot be run. + UAOL_CHANNELS_MIN 1 + UAOL_CHANNELS_MAX 8 + # UAOL supports up to 384 kHz + UAOL_RATE_MIN 8000 + UAOL_RATE_MAX 384000 + UAOL_RATES '8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000,128000,176400,192000,384000' + + # The deep buffer PCMs feed the same mixer as the normal playback PCM of + # their stream, next to the one the HDA playback has + UAOL_DEEP_BUFFER 'true' + UAOL_DB_PCM_NAME 'Deepbuffer USB Offload 0' + UAOL_DB_PCM_ID 23 + UAOL_DB_PIPELINE_ID 214 + UAOL_DB1_PCM_NAME 'Deepbuffer USB Offload 1' + UAOL_DB1_PCM_ID 24 + UAOL_DB1_PIPELINE_ID 219 +} + + diff --git a/tools/topology/topology2/development/tplg-targets.cmake b/tools/topology/topology2/development/tplg-targets.cmake index a2f4f9eda740..be12c019fb9a 100644 --- a/tools/topology/topology2/development/tplg-targets.cmake +++ b/tools/topology/topology2/development/tplg-targets.cmake @@ -316,6 +316,14 @@ PREPROCESS_PLUGINS=nhlt,NHLT_BIN=nhlt-sof-tgl-nocodec-crossover.bin,EFX_CROSSOVE "development/cavs-nocodec-rtcaec\;sof-tgl-nocodec-rtcaec\;PLATFORM=tgl,\ PREPROCESS_PLUGINS=nhlt,NHLT_BIN=nhlt-sof-tgl-nocodec-rtcaec.bin" +# Topology to test the USB audio offload on an HDA machine, load it with +# snd_sof.tplg_filename=sof-hda-generic-uaol.tplg +"development/sof-hda-generic-uaol\;sof-hda-generic-uaol\;HDA_CONFIG=mix,HDA_MIC_ENHANCED_CAPTURE=true,\ +EFX_HDA_MIC_TDFB_PARAMS=line2_pass,EFX_HDA_MIC_DRC_PARAMS=passthrough" +# The same for a machine without an HDA codec, HDMI only, load it with +# snd_sof.tplg_filename=sof-hda-generic-idisp-uaol.tplg +"development/sof-hda-generic-uaol\;sof-hda-generic-idisp-uaol\;" + # SSP test topology for Data Processing SRC on MTL "cavs-nocodec\;sof-mtl-nocodec-dp-test\;PLATFORM=mtl,NUM_DMICS=4,PDM1_MIC_A_ENABLE=1,PDM1_MIC_B_ENABLE=1,\ PREPROCESS_PLUGINS=nhlt,NHLT_BIN=nhlt-sof-mtl-nocodec.bin,SRC_DOMAIN=DP" diff --git a/tools/topology/topology2/include/formats/uaol_input_audio_formats.conf b/tools/topology/topology2/include/formats/uaol_input_audio_formats.conf index 4a8ca0c0c9f0..9312e9257845 100644 --- a/tools/topology/topology2/include/formats/uaol_input_audio_formats.conf +++ b/tools/topology/topology2/include/formats/uaol_input_audio_formats.conf @@ -1,9 +1,9 @@ # Every format the offloaded USB endpoint can carry: S16_LE, S24_LE and - # S32_LE, 1 to 8 channels and every standard rate from 8 to 192 kHz. + # S32_LE, 1 to 8 channels and every standard rate from 8 to 384 kHz. # # 7 channels is left out, it has no channel config and no channel map in # common_definitions.conf. - num_input_audio_formats 315 + num_input_audio_formats 336 CombineArrays.Object.Base.input_audio_format [ { in_rate [ @@ -22,6 +22,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -46,6 +47,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 32 ] @@ -70,6 +72,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -94,6 +97,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 32 ] @@ -118,6 +122,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -142,6 +147,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 32 ] @@ -166,6 +172,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -190,6 +197,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 32 ] @@ -214,6 +222,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -238,6 +247,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 32 ] @@ -262,6 +272,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -286,6 +297,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 32 ] @@ -310,6 +322,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -334,6 +347,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 32 ] diff --git a/tools/topology/topology2/include/formats/uaol_input_audio_formats_msb.conf b/tools/topology/topology2/include/formats/uaol_input_audio_formats_msb.conf index 2fc36190e00f..6e920a657d7e 100644 --- a/tools/topology/topology2/include/formats/uaol_input_audio_formats_msb.conf +++ b/tools/topology/topology2/include/formats/uaol_input_audio_formats_msb.conf @@ -1,5 +1,5 @@ # Every format the offloaded USB endpoint can carry: S16_LE, S24_LE and - # S32_LE, 1 to 8 channels and every standard rate from 8 to 192 kHz. + # S32_LE, 1 to 8 channels and every standard rate from 8 to 384 kHz. # # 7 channels is left out, it has no channel config and no channel map in # common_definitions.conf. @@ -13,7 +13,7 @@ # 32 valid bits stay LSB: the alignment is a no-op when every bit # is valid, and the driver only honours the tag at 8 and 32 bits, # so an MSB tag there would never match an S32_LE PCM. - num_input_audio_formats 315 + num_input_audio_formats 336 CombineArrays.Object.Base.input_audio_format [ { in_rate [ @@ -32,6 +32,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -57,6 +58,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 ] @@ -82,6 +84,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -107,6 +110,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -132,6 +136,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 ] @@ -157,6 +162,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -182,6 +188,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -207,6 +214,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 ] @@ -232,6 +240,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -257,6 +266,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -282,6 +292,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 ] @@ -307,6 +318,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -332,6 +344,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -357,6 +370,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 ] @@ -382,6 +396,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -407,6 +422,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -432,6 +448,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 ] @@ -457,6 +474,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -482,6 +500,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 16 ] in_valid_bit_depth [ 16 ] @@ -507,6 +526,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 24 ] @@ -532,6 +552,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] diff --git a/tools/topology/topology2/include/formats/uaol_input_audio_formats_s32.conf b/tools/topology/topology2/include/formats/uaol_input_audio_formats_s32.conf index a98428ba1533..f5110ca2e957 100644 --- a/tools/topology/topology2/include/formats/uaol_input_audio_formats_s32.conf +++ b/tools/topology/topology2/include/formats/uaol_input_audio_formats_s32.conf @@ -3,7 +3,7 @@ # # 7 channels is left out, it has no channel config and no channel map in # common_definitions.conf. - num_input_audio_formats 105 + num_input_audio_formats 112 CombineArrays.Object.Base.input_audio_format [ { in_rate [ @@ -22,6 +22,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -46,6 +47,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -70,6 +72,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -94,6 +97,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -118,6 +122,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -142,6 +147,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] @@ -166,6 +172,7 @@ 128000 176400 192000 + 384000 ] in_bit_depth [ 32 ] in_valid_bit_depth [ 32 ] diff --git a/tools/topology/topology2/include/formats/uaol_output_audio_formats.conf b/tools/topology/topology2/include/formats/uaol_output_audio_formats.conf index 0ff39effcd62..6567ea3a15db 100644 --- a/tools/topology/topology2/include/formats/uaol_output_audio_formats.conf +++ b/tools/topology/topology2/include/formats/uaol_output_audio_formats.conf @@ -1,9 +1,9 @@ # Every format the offloaded USB endpoint can carry: S16_LE, S24_LE and - # S32_LE, 1 to 8 channels and every standard rate from 8 to 192 kHz. + # S32_LE, 1 to 8 channels and every standard rate from 8 to 384 kHz. # # 7 channels is left out, it has no channel config and no channel map in # common_definitions.conf. - num_output_audio_formats 315 + num_output_audio_formats 336 CombineArrays.Object.Base.output_audio_format [ { out_rate [ @@ -22,6 +22,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -46,6 +47,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 32 ] @@ -70,6 +72,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -94,6 +97,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 32 ] @@ -118,6 +122,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -142,6 +147,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 32 ] @@ -166,6 +172,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -190,6 +197,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 32 ] @@ -214,6 +222,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -238,6 +247,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 32 ] @@ -262,6 +272,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -286,6 +297,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 32 ] @@ -310,6 +322,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -334,6 +347,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 32 ] diff --git a/tools/topology/topology2/include/formats/uaol_output_audio_formats_msb.conf b/tools/topology/topology2/include/formats/uaol_output_audio_formats_msb.conf index 3f783df3270f..080cbc93a973 100644 --- a/tools/topology/topology2/include/formats/uaol_output_audio_formats_msb.conf +++ b/tools/topology/topology2/include/formats/uaol_output_audio_formats_msb.conf @@ -1,5 +1,5 @@ # Every format the offloaded USB endpoint can carry: S16_LE, S24_LE and - # S32_LE, 1 to 8 channels and every standard rate from 8 to 192 kHz. + # S32_LE, 1 to 8 channels and every standard rate from 8 to 384 kHz. # # 7 channels is left out, it has no channel config and no channel map in # common_definitions.conf. @@ -9,7 +9,7 @@ # matching the convention every other link type (HDA, SoundWire, # SSP, DMIC) uses so the copier left-justifies 24-bit samples # before handing them to the link. - num_output_audio_formats 315 + num_output_audio_formats 336 CombineArrays.Object.Base.output_audio_format [ { out_rate [ @@ -28,6 +28,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -53,6 +54,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 ] @@ -78,6 +80,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -103,6 +106,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -128,6 +132,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 ] @@ -153,6 +158,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -178,6 +184,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -203,6 +210,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 ] @@ -228,6 +236,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -253,6 +262,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -278,6 +288,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 ] @@ -303,6 +314,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -328,6 +340,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -353,6 +366,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 ] @@ -378,6 +392,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -403,6 +418,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -428,6 +444,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 ] @@ -453,6 +470,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -478,6 +496,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 16 ] out_valid_bit_depth [ 16 ] @@ -503,6 +522,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 24 ] @@ -528,6 +548,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] diff --git a/tools/topology/topology2/include/formats/uaol_output_audio_formats_s32.conf b/tools/topology/topology2/include/formats/uaol_output_audio_formats_s32.conf index 8dea01de8020..1a6871ece1e2 100644 --- a/tools/topology/topology2/include/formats/uaol_output_audio_formats_s32.conf +++ b/tools/topology/topology2/include/formats/uaol_output_audio_formats_s32.conf @@ -3,7 +3,7 @@ # # 7 channels is left out, it has no channel config and no channel map in # common_definitions.conf. - num_output_audio_formats 105 + num_output_audio_formats 112 CombineArrays.Object.Base.output_audio_format [ { out_rate [ @@ -22,6 +22,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -46,6 +47,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -70,6 +72,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -94,6 +97,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -118,6 +122,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -142,6 +147,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] @@ -166,6 +172,7 @@ 128000 176400 192000 + 384000 ] out_bit_depth [ 32 ] out_valid_bit_depth [ 32 ] diff --git a/tools/topology/topology2/platform/intel/uaol-deep-buffer.conf b/tools/topology/topology2/platform/intel/uaol-deep-buffer.conf new file mode 100644 index 000000000000..572c9fc57a78 --- /dev/null +++ b/tools/topology/topology2/platform/intel/uaol-deep-buffer.conf @@ -0,0 +1,61 @@ +# Deep buffer playback of the first UAOL stream pair. +# +# Included by platform/intel/uaol-generic.conf when UAOL_DEEP_BUFFER is true +# and the deep buffer DMA size is in range. An instance of the deepbuffer-playback +# pipeline on the UAOL_DB_* variables, routed into the mixer of the first +# playback stream, the way platform/intel/deep-buffer-spk.conf is for the +# speaker. platform/intel/deep-buffer.conf cannot be used, it works on the +# global DEEP_BUFFER_* variables, which the deep buffer of a jack or speaker the +# topology also has takes. + +Object.Pipeline.deepbuffer-playback [ + { + index $UAOL_DB_PIPELINE_ID + + Object.Widget.host-copier.1 { + stream_name $UAOL_DB_PCM_NAME + pcm_id $UAOL_DB_PCM_ID + } + Object.Widget.gain.1 { + Object.Control.mixer.1 { + name 'Pre Mixer $UAOL_DB_PCM_NAME Volume' + } + } + } +] + +Object.PCM.pcm [ + { + name $UAOL_DB_PCM_NAME + id $UAOL_DB_PCM_ID + direction playback + playback_compatible_d0i3 $DEEPBUFFER_D0I3_COMPATIBLE + + Object.Base.fe_dai.1 { + name "$UAOL_DB_PCM_NAME" + } + Object.PCM.pcm_caps.1 { + name $UAOL_DB_PCM_NAME + formats 'S16_LE,S24_LE,S32_LE' + # To avoid DMA spinning on a buffer we need bigger + # buffer than the host buffer size, let's say twice as + # big + # (S16_LE, Stereo, 48KHz, DEEPBUFFER_FW_DMA_MS) * 2 + # + # Note: The lower limit for the buffer size is rate + # dependent + buffer_size_min "$[(((2 * $channels_min) * 48) * $DEEPBUFFER_FW_DMA_MS) * 2]" + } + } +] + +Object.Base.route [ + { + source mixin.$UAOL_DB_PIPELINE_ID.1 + sink mixout.$UAOL_PB_DAI_PIPELINE_ID.1 + } + { + source host-copier.$UAOL_DB_PCM_ID.playback + sink gain.$UAOL_DB_PIPELINE_ID.1 + } +] diff --git a/tools/topology/topology2/platform/intel/uaol-deep-buffer1.conf b/tools/topology/topology2/platform/intel/uaol-deep-buffer1.conf new file mode 100644 index 000000000000..242912325a5f --- /dev/null +++ b/tools/topology/topology2/platform/intel/uaol-deep-buffer1.conf @@ -0,0 +1,57 @@ +# Deep buffer playback of the second UAOL stream pair. +# +# Included by platform/intel/uaol-stream1.conf under the same conditions as the +# first pair's deep buffer, platform/intel/uaol-deep-buffer.conf, which this +# repeats on the UAOL_DB1_* variables. + +Object.Pipeline.deepbuffer-playback [ + { + index $UAOL_DB1_PIPELINE_ID + + Object.Widget.host-copier.1 { + stream_name $UAOL_DB1_PCM_NAME + pcm_id $UAOL_DB1_PCM_ID + } + Object.Widget.gain.1 { + Object.Control.mixer.1 { + name 'Pre Mixer $UAOL_DB1_PCM_NAME Volume' + } + } + } +] + +Object.PCM.pcm [ + { + name $UAOL_DB1_PCM_NAME + id $UAOL_DB1_PCM_ID + direction playback + playback_compatible_d0i3 $DEEPBUFFER_D0I3_COMPATIBLE + + Object.Base.fe_dai.1 { + name "$UAOL_DB1_PCM_NAME" + } + Object.PCM.pcm_caps.1 { + name $UAOL_DB1_PCM_NAME + formats 'S16_LE,S24_LE,S32_LE' + # To avoid DMA spinning on a buffer we need bigger + # buffer than the host buffer size, let's say twice as + # big + # (S16_LE, Stereo, 48KHz, DEEPBUFFER_FW_DMA_MS) * 2 + # + # Note: The lower limit for the buffer size is rate + # dependent + buffer_size_min "$[(((2 * $channels_min) * 48) * $DEEPBUFFER_FW_DMA_MS) * 2]" + } + } +] + +Object.Base.route [ + { + source mixin.$UAOL_DB1_PIPELINE_ID.1 + sink mixout.$UAOL_PB1_DAI_PIPELINE_ID.1 + } + { + source host-copier.$UAOL_DB1_PCM_ID.playback + sink gain.$UAOL_DB1_PIPELINE_ID.1 + } +] diff --git a/tools/topology/topology2/platform/intel/uaol-generic.conf b/tools/topology/topology2/platform/intel/uaol-generic.conf index 6735827e52da..41816ca3e369 100644 --- a/tools/topology/topology2/platform/intel/uaol-generic.conf +++ b/tools/topology/topology2/platform/intel/uaol-generic.conf @@ -4,27 +4,45 @@ # # PCM ---------------> gain ---> mixin ---+ # | -# Deepbuffer PCM ----> gain ---> mixin ---+--> mixout --> gain --> UAOL0-Play +# Deepbuffer PCM ----> gain ---> mixin ---+--> mixout --> gain --> UAOL0-Play0 # -# PCM <------------ module-copier <--- eqiir <---------------- UAOL0-Cap +# PCM <------------ module-copier <--- eqiir <---------------- UAOL0-Cap0 # # The capture path carries no mixer, as the number of channels follows the USB # device and a mixer only handles a fixed channel count. # +# A UAOL link runs several streams at a time, and the kernel creates a backend +# for each of them: UAOL-Play and UAOL-Cap, n counting the +# streams of a direction. This file describes the paths of the first stream +# pair, with the PCM, pipeline and backend IDs taken from the UAOL_* variables. +# The second pair, platform/intel/uaol-stream1.conf, is pulled in when +# UAOL_NUM_STREAMS is 2; it is the same paths on the UAOL_*1_* variables, with +# a deep buffer of its own on UAOL_DB1_*. A topology only has to describe the +# streams it wants to expose, a backend the topology leaves out simply stays +# unused. +# # What the endpoint can be run at is decided by the USB device, which is only # known once one is plugged in, so every widget of both paths carries the whole # set of formats a USB device may ask for: S16_LE, S24_LE and S32_LE, 1 to 8 -# channels and the standard rates from 8 to 192 kHz, which is as far as UAOL +# channels and the standard rates from 8 to 384 kHz, which is as far as UAOL # goes. The kernel narrows the PCM down to what the connected device actually # supports. # -# The deep buffer PCM is left at 48 kHz stereo, as it comes from the shared -# platform/intel/deep-buffer.conf. It can only join the mixer while the normal +# The deep buffer PCM is left at 48 kHz stereo, the default of the +# deepbuffer-playback pipeline. It can only join the mixer while the normal # playback PCM runs at that format, or is not running at all. -# Deep buffer playback, included when the DMA buffer is 1 - 1000 ms -IncludeByKey.DEEPBUFFER_FW_DMA_MS { - "([1-9]|[1-9][0-9]|[1-9][0-9][0-9]|1000)" "platform/intel/deep-buffer.conf" +# Deep buffer playback, included when UAOL_DEEP_BUFFER is true and the DMA +# buffer is 1 - 1000 ms. The deep buffers of the UAOL streams are instances of +# their own, platform/intel/uaol-deep-buffer.conf and uaol-deep-buffer1.conf on +# the UAOL_DB_* and UAOL_DB1_* variables, so they sit next to the deep buffer a +# jack or speaker of the topology has on the global DEEP_BUFFER_* ones. +IncludeByKey.UAOL_DEEP_BUFFER { + "true" { + IncludeByKey.DEEPBUFFER_FW_DMA_MS { + "([1-9]|[1-9][0-9]|[1-9][0-9][0-9]|1000)" "platform/intel/uaol-deep-buffer.conf" + } + } } Object.Dai.UAOL [ @@ -34,7 +52,7 @@ Object.Dai.UAOL [ id $UAOL_PB_BE_ID default_hw_conf_id 0 Object.Base.hw_config.1 { - name "UAOL0-Play" + name $UAOL_PB_DAI_NAME } direction playback } @@ -44,7 +62,7 @@ Object.Dai.UAOL [ id $UAOL_CP_BE_ID default_hw_conf_id 0 Object.Base.hw_config.1 { - name "UAOL0-Cap" + name $UAOL_CP_DAI_NAME } direction capture } @@ -202,3 +220,8 @@ Object.Base.route [ sink "host-copier.$UAOL_PCM_ID.capture" } ] + +# The second stream pair of the link +IncludeByKey.UAOL_NUM_STREAMS { + "2" "platform/intel/uaol-stream1.conf" +} diff --git a/tools/topology/topology2/platform/intel/uaol-stream1.conf b/tools/topology/topology2/platform/intel/uaol-stream1.conf new file mode 100644 index 000000000000..71475300b58a --- /dev/null +++ b/tools/topology/topology2/platform/intel/uaol-stream1.conf @@ -0,0 +1,195 @@ +# Second stream pair of a USB Audio Offload Link (UAOL). +# +# Included by platform/intel/uaol-generic.conf when UAOL_NUM_STREAMS is 2. The +# same paths as the first pair, on the UAOL_*1_* variables, the deep buffer +# from platform/intel/uaol-deep-buffer1.conf on UAOL_DB1_*. +# +# PCM ---------------> gain ---> mixin ---+ +# | +# Deepbuffer PCM ----> gain ---> mixin ---+--> mixout --> gain --> UAOL0-Play1 +# +# PCM <------------ module-copier <--- eqiir <---------------- UAOL0-Cap1 + +IncludeByKey.UAOL_DEEP_BUFFER { + "true" { + IncludeByKey.DEEPBUFFER_FW_DMA_MS { + "([1-9]|[1-9][0-9]|[1-9][0-9][0-9]|1000)" "platform/intel/uaol-deep-buffer1.conf" + } + } +} + +Object.Dai.UAOL [ + { + name $UAOL_PB1_DAI_NAME + dai_index $UAOL_DAI_INDEX + id $UAOL_PB1_BE_ID + default_hw_conf_id 0 + Object.Base.hw_config.1 { + name $UAOL_PB1_DAI_NAME + } + direction playback + } + { + name $UAOL_CP1_DAI_NAME + dai_index $UAOL_DAI_INDEX + id $UAOL_CP1_BE_ID + default_hw_conf_id 0 + Object.Base.hw_config.1 { + name $UAOL_CP1_DAI_NAME + } + direction capture + } +] + +Object.Pipeline { + host-copier-gain-mixin-playback [ + { + index $UAOL_PB1_HOST_PIPELINE_ID + + Object.Widget.host-copier.1 { + stream_name $UAOL_PLAYBACK1_PCM + pcm_id $UAOL_PCM1_ID + + + } + Object.Widget.gain.1 { + Object.Control.mixer.1 { + name 'Pre Mixer $UAOL_PCM1_NAME Playback Volume' + } + + + } + Object.Widget.mixin.1 { + + + } + } + ] + + mixout-gain-dai-copier-playback [ + { + index $UAOL_PB1_DAI_PIPELINE_ID + + Object.Widget.mixout.1 { + + + } + Object.Widget.dai-copier.1 { + node_type $ALH_UAOL_STREAM_LINK_OUTPUT_CLASS + stream_name $UAOL_PB1_DAI_NAME + dai_type "UAOL" + copier_type "UAOL" + + + } + Object.Widget.gain.1 { + Object.Control.mixer.1 { + name 'Post Mixer $UAOL_PCM1_NAME Playback Volume' + } + + + } + } + ] + + host-gateway-capture [ + { + index $UAOL_CP1_HOST_PIPELINE_ID + + Object.Widget.host-copier.1 { + stream_name $UAOL_CAPTURE1_PCM + pcm_id $UAOL_PCM1_ID + + + } + } + ] + + dai-copier-eqiir-module-copier-capture [ + { + index $UAOL_CP1_DAI_PIPELINE_ID + + Object.Widget.dai-copier.1 { + node_type $ALH_UAOL_STREAM_LINK_INPUT_CLASS + stream_name $UAOL_CP1_DAI_NAME + dai_type "UAOL" + type dai_out + copier_type "UAOL" + num_output_pins 1 + + + } + + # The coefficients are designed for 48 kHz, so the corner + # frequency scales with the rate the device is run at + Object.Widget.eqiir.1 { + Object.Control.bytes.1 { + name '$UAOL_PCM1_NAME Capture IIR Eq' + + } + + + } + + Object.Widget.module-copier.2 { + + + } + } + ] +} + +Object.PCM.pcm [ + { + name $UAOL_PCM1_NAME + id $UAOL_PCM1_ID + direction "duplex" + Object.Base.fe_dai.1 { + name $UAOL_PCM1_NAME + } + Object.PCM.pcm_caps.1 { + direction "playback" + name $UAOL_PLAYBACK1_PCM + formats 'S16_LE,S24_LE,S32_LE' + channels_min $UAOL_CHANNELS_MIN + channels_max $UAOL_CHANNELS_MAX + rates $UAOL_RATES + rate_min $UAOL_RATE_MIN + rate_max $UAOL_RATE_MAX + } + Object.PCM.pcm_caps.2 { + direction "capture" + name $UAOL_CAPTURE1_PCM + formats 'S16_LE,S24_LE,S32_LE' + channels_min $UAOL_CHANNELS_MIN + channels_max $UAOL_CHANNELS_MAX + rates $UAOL_RATES + rate_min $UAOL_RATE_MIN + rate_max $UAOL_RATE_MAX + } + } +] + +# top-level pipeline connections +Object.Base.route [ + { + source "host-copier.$UAOL_PCM1_ID.playback" + sink "gain.$UAOL_PB1_HOST_PIPELINE_ID.1" + } + { + source "mixin.$UAOL_PB1_HOST_PIPELINE_ID.1" + sink "mixout.$UAOL_PB1_DAI_PIPELINE_ID.1" + } + { + source "gain.$UAOL_PB1_DAI_PIPELINE_ID.1" + sink "dai-copier.UAOL.$UAOL_PB1_DAI_NAME.playback" + } + { + source "dai-copier.UAOL.$UAOL_CP1_DAI_NAME.capture" + sink "eqiir.$UAOL_CP1_DAI_PIPELINE_ID.1" + } + { + source "module-copier.$UAOL_CP1_DAI_PIPELINE_ID.2" + sink "host-copier.$UAOL_PCM1_ID.capture" + } +] diff --git a/tools/topology/topology2/production/tplg-targets-sdca-generic.cmake b/tools/topology/topology2/production/tplg-targets-sdca-generic.cmake index 8bb6d700e1e3..ce63b75b002e 100644 --- a/tools/topology/topology2/production/tplg-targets-sdca-generic.cmake +++ b/tools/topology/topology2/production/tplg-targets-sdca-generic.cmake @@ -42,18 +42,20 @@ EFX_MIC_TDFB_PARAMS=line4_pass" "cavs-sdw\;sof-hdmi-pcm5-id6\;SDW_JACK=false,HDMI1_ID=6,HDMI2_ID=7,HDMI3_ID=8" "cavs-sdw\;sof-hdmi-pcm5-id7\;SDW_JACK=false,HDMI1_ID=7,HDMI2_ID=8,HDMI3_ID=9" -# USB Audio Offload Link function topology. The UAOL backend is the last one -# sof_sdw creates, so its dai link ID depends on the composition of the board: -# it follows the SoundWire links, the PCH DMIC pair, the three HDMI links and -# the BT link. Each direction is a separate link, so two consecutive IDs are -# taken. The range below covers a jack and amplifier board without DMIC and BT -# (6) up to a jack, amplifier with feedback, PCH DMIC and BT board (10). -# Add a variant here for every further ID that is needed. -"cavs-uaol\;sof-uaol-id6\;UAOL_PB_BE_ID=6,UAOL_CP_BE_ID=7" -"cavs-uaol\;sof-uaol-id7\;UAOL_PB_BE_ID=7,UAOL_CP_BE_ID=8" -"cavs-uaol\;sof-uaol-id8\;UAOL_PB_BE_ID=8,UAOL_CP_BE_ID=9" -"cavs-uaol\;sof-uaol-id9\;UAOL_PB_BE_ID=9,UAOL_CP_BE_ID=10" -"cavs-uaol\;sof-uaol-id10\;UAOL_PB_BE_ID=10,UAOL_CP_BE_ID=11" +# USB Audio Offload Link function topology. The UAOL backends are the last ones +# sof_sdw creates, so their dai link IDs depend on the composition of the board: +# they follow the SoundWire links, the PCH DMIC pair, the three HDMI links and +# the BT link. The link has two streams per direction and each gets a backend, +# in the order Play0, Cap0, Play1, Cap1, so four consecutive IDs are taken and +# the topology exposes a PCM per pair. The range below covers a jack and +# amplifier board without DMIC and BT (6) up to a jack, amplifier with feedback, +# PCH DMIC and BT board (10). Add a variant here for every further ID that is +# needed. +"cavs-uaol\;sof-uaol-id6\;UAOL_PB_BE_ID=6,UAOL_CP_BE_ID=7,UAOL_PB1_BE_ID=8,UAOL_CP1_BE_ID=9" +"cavs-uaol\;sof-uaol-id7\;UAOL_PB_BE_ID=7,UAOL_CP_BE_ID=8,UAOL_PB1_BE_ID=9,UAOL_CP1_BE_ID=10" +"cavs-uaol\;sof-uaol-id8\;UAOL_PB_BE_ID=8,UAOL_CP_BE_ID=9,UAOL_PB1_BE_ID=10,UAOL_CP1_BE_ID=11" +"cavs-uaol\;sof-uaol-id9\;UAOL_PB_BE_ID=9,UAOL_CP_BE_ID=10,UAOL_PB1_BE_ID=11,UAOL_CP1_BE_ID=12" +"cavs-uaol\;sof-uaol-id10\;UAOL_PB_BE_ID=10,UAOL_CP_BE_ID=11,UAOL_PB1_BE_ID=12,UAOL_CP1_BE_ID=13" # Feature topologies which should work with the function topologies above "cavs-sdw\;sof-sdca-amp-ref\;SDW_JACK=false,NUM_HDMIS=0,JACK_RATE=48000,\