Commit Graph

500 Commits

Author SHA1 Message Date
Seppo Ingalsuo 16975a591b Tools: Topology2: Add sof-hda-benchmark-aria32-tgl build
This patch adds the aria test topologies build. Aria supports
only s32 format so the s16 and s24 versions build is left
out.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-11-01 21:08:59 +02:00
Seppo Ingalsuo 6d6637d608 Tools: Topology2: Add sof-hda-benchmark-gain16/24/32-tgl build
This patch adds test topologies build for gain component. Testing
of gain can be done with all supported s16/s24/s32 source and sink
formats. The topologies normally use only the s32 format
internally.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-11-01 21:08:59 +02:00
Seppo Ingalsuo 98e687edb4 Tools: Topology2: Add sof-hda-benchmark-multiband_drc16/24/32-tgl build
This patch adds the multiband-DRC test topologies build.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-11-01 21:08:59 +02:00
Seppo Ingalsuo 1e5e7edb26 Tools: Topology2: Add sof-hda-benchmark topologies for MTL
The create of component benchmark topologies is moved to
other included file from CMakeLists.txt.

The adding of new components with custom parameters for
multiple formats and platforms is simplified with nested
foreach loops. The previous topologies for TGL are now
built also for MTL.

Due to use of "IN ZIP_LISTS" with foreach, cmake requirement
is bumped to 3.17 for topology2.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-11-01 21:08:59 +02:00
Seppo Ingalsuo 2d27374086 Tools: Topology2: Include controls to multiband_drc class
The includes to define bytes and mixer controls classes are
needed in case no other class definition has included these.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-11-01 21:08:59 +02:00
Seppo Ingalsuo 2831afe345 Tools: Topology2: Easier controls create with bench_comp_generate.sh
This patch adds to benchmark topologies template .conf files
generator commented out control examples types for easier
ALSA controls create.

The controls include files are renamed since they may
contain all controls types and not just bytes.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-11-01 21:08:59 +02:00
Ranjani Sridharan d294036fd5 topology2: google-rtc-aec: adjust the IBS/OBS size based on process needs
Example: if a module has 2 input pins, one 16000/16/2, second 48000/16/2 and
one output pin 48000/32/4 and is designed to process 10ms data chunks:

in pin1 IBS should be 16(samples/1ms) * 2 bytes * 2 * 10(ms) = 640
in pin2 IBS should be 48(samples/1ms) * 2 bytes * 2 * 10(ms) = 1920
out pin1 OBS should be 48(samples/1ms) * 4 bytes * 4 * 10(ms) = 7680

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Yong Zhi <yong.zhi@intel.com>
2023-11-01 20:38:52 +02:00
Chao Song e73cdf6805 topology2: Add sof-mtl-rt722-l0 support
This patch adds sof-mtl-rt722-l0.tplg, which is used
to support MTL RVP + RT722 EVB combination.

Headphone, speaker and DMIC functions are verified
with this topology.

Signed-off-by: Chao Song <chao.song@linux.intel.com>
2023-10-31 20:30:41 +02:00
Chao Song 165e68fdaf topology2: Add sof-lnl-rt711-l0-rt1316-l23-rt714-l1 support
This patch adds sof-lnl-rt711-l0-rt1316-l23-rt714-l1.tplg,
which is used to support LNL RVP + AIOC4.1 codec board
combination.

Signed-off-by: Chao Song <chao.song@linux.intel.com>
2023-10-30 20:35:56 +02:00
Yong Zhi 31140b132c topology2: cavs-rt5682 enable google rtc aec support
Enable Google ACE for for all sof-mtl-max98357a-rt5682 variants.

Signed-off-by: Yong Zhi <yong.zhi@intel.com>
2023-10-27 15:26:27 +03:00
Baofeng Tian e20009bc41 Topology2: condense passthrough tplg file audio format
Condense passthrough audio format with combined arrays.

Signed-off-by: Baofeng Tian <baofeng.tian@intel.com>
2023-10-27 14:33:31 +03:00
Baofeng Tian ae653d06a4 Topology2: condense src input format with combined array
Condense input format to combined array for src.

Signed-off-by: Baofeng Tian <baofeng.tian@intel.com>
2023-10-27 14:33:31 +03:00
Baofeng Tian b0abfe5e20 Topology2: condense tplg audio format for s32 format
Condense src format from s32 to multiple audio format.

Signed-off-by: Baofeng Tian <baofeng.tian@intel.com>
2023-10-27 14:33:31 +03:00
Baofeng Tian b814f307fb Topology2: condense src input format in tplg file
Condense src input audio format convert to 48k in tplg file.

Signed-off-by: Baofeng Tian <baofeng.tian@intel.com>
2023-10-27 14:33:31 +03:00
Baofeng Tian b8c52ecaf7 Topology2: condense output format in tplg file
Condense src 48k to other audio format with combined array format.

Signed-off-by: Baofeng Tian <baofeng.tian@intel.com>
2023-10-27 14:33:31 +03:00
Seppo Ingalsuo 613021b37f Tools: Topology2: Add widget class TDFB
This patch adds the class for the Time domain fixed beamformer
(TDFB) and example blobs for line arrays.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-10-26 17:08:45 +03:00
Seppo Ingalsuo d27d068245 Tools: Topology2: Add support for ALSA enum control
This patch adds to definitions in common.conf a new class "text"
to support the enum control values.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-10-26 17:08:45 +03:00
Marc Herbert d9fb722b64 topology/cmake: move alsatplg_version() one level up
We want to use it in topology1 too.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2023-10-24 20:32:28 +03:00
Marc Herbert 4495357f1e topology2/cmake: extract new function "alsatplg_version()" for re-use
We'll use this new function to require ALSA 1.2.5 and finally rename to
"codec_consumer" (see revert discussion #5192)

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2023-10-23 11:26:07 +01:00
Marc Herbert ec1cfd8f95 topology2/cmake: stricter if execute_process(alsatplg --version ...)
We want to fail if STATUS is not defined, the empty string, the FALSE
string or anything unexpected that it is not strictly equal to success
code "0".

Fixes commit 308a24a92b ("topology2: Add build support")

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2023-10-23 11:26:07 +01:00
Jyri Sarha 2eeae16d24 topology2: doc: Fix main page
The main page sources were dropped out from the document sources in the
last review rounds of the original PR. Add *.doxy to FILE_PATTERNS to
add it back.

Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
2023-10-20 11:42:22 +03:00
Ranjani Sridharan b6d34fb4a8 topology2: Replace audio_format objects
Replace audio_format objects with input_audio_format/output_audio_format
objects in preparation for deprecating the audio_format class.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2023-10-19 20:57:23 +03:00
Ranjani Sridharan 7c735fe7a7 topology2: deepbuffer-playback: Remove stale comments
These were left over when the audio formats were cleaned up.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2023-10-19 20:57:23 +03:00
Ranjani Sridharan 054003f292 topology2: host-gateway-playback: Replace audio_format objects
Use input_audio_format/output_audio_format explicitly in preparation for
deprecating the audio_format class.

Fixes: 7a11e27bf2 ('topology2: host-gateway-capture: Replace audio_format objects')
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2023-10-18 16:56:59 +01:00
Ranjani Sridharan 5945235b42 topology2: mixout-gain-dai-copier-playback: Replace audio_format objects
Use input_audio_format/output_audio_format explicitly in preparation for
deprecating the audio_format class.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2023-10-18 16:56:59 +01:00
Ranjani Sridharan 1125fe06bc topology2: gain-copier-capture: Replace use of audio_format objects
Use input_audio_format/output_audio_format explicitly in preparation for
deprecating the audio_format class.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2023-10-18 16:56:59 +01:00
Ranjani Sridharan f64cc8f528 topology2: dmic-generic: Replace use of audio_format objects
Use input_audio_format/output_audio_format explicitly in preparation for
deprecating the audio_format class.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2023-10-18 16:56:59 +01:00
Keqiao Zhang 02a7c98534 topology: add test TPLGs for LNL-RVP
There're no differences for SSP and SoundWire TPLGs between
MTL and LNL, we can reuse MTL TPLGs for LNL.

Signed-off-by: Keqiao Zhang <keqiao.zhang@intel.com>
2023-10-18 17:41:22 +03:00
Mac Chiang e3fc9c1c8e topology2: add rt713_rt1316, no sdw_dmic config
This is additional HW board: No SDW_DMIC connection

SDW0: rt713 Jack codec
SDW1: rt1316 smart amp l
SDW2: rt1316 smart amp r

Signed-off-by: Mac Chiang <mac.chiang@intel.com>
2023-10-18 16:32:15 +03:00
Rander Wang 1fc1d28584 topology2: clean up audio format
Separate the input & output audio format.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2023-10-17 15:55:07 -07:00
Rander Wang 4dad5c2d5c topolog2: nocodec: set output_pin number
The num_output_pins was set for pass-through path but missed in normal
path. Without it Linux kernel driver wouldn't set second output pin
format for dai copier which connects smart amp and gain module.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2023-10-17 15:55:07 -07:00
Seppo Ingalsuo c22e3f438d Tools: Topology2: Use windows_fade in nocodec topologies
This patch changes all cavs-nocodec.conf based topologies to
use exponential Windows fade curve_type in gain components. It
is done to ensure the ramp gets tested after change of gain
curve_type default to linear.

The gain in included deep buffer playback pipeline (hw:0,31) and
in mixer pipeline (hw:0,41) are not changed because they are used
also in normal topologies. Also in capture direction DMIC raw
(hw:0,10) remains curve_type 2. Other gains are curve_type 1
Windows fade.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-10-17 17:33:50 +01:00
Seppo Ingalsuo 9aadd197ab Tools: Topology2: Change gain default curve type to linear
This change can drop in TGL platform 2ch 48 kHz gain component
peak load e.g. from 16.7 to 7.09 MCPS CPU_PEAK(MAX) reported by
sof_perf_analyzer.py. The peak varies a bit time. If several
gain instances ramp simulatenously in stream start, the peak
MCPS consumption could be source for xruns and glitches if overall
load is high.

The change with linear curve is barely audible. The
computationally heavier Windows fade exponential curve is required
only with Windows OS. Since Windows is not using ALSA topologies
this change does not impact it.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-10-17 17:33:50 +01:00
Ranjani Sridharan aeb83eccc4 topology2: sdw-jack-generic: Replace audio_format objects
Use input_output_format/output_audio_format explicitly. Additionally,
this patch introduces the used of the CombineArrays feature in the
topology2 compiler to generate multiple audio format objects from the
attribute array combinations.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2023-10-17 16:45:29 +01:00
Ranjani Sridharan 6850be91ba topology2: deepbuffer-playback: Replace audio_format objects
Use the input_audio_format/output_audio_format objects explicitly.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2023-10-17 16:45:29 +01:00
Ranjani Sridharan b0b5958875 topology2: sdw-amp/dmic-generic: Remove incorrect audio format
Setting the in bit depth for the second audio format in the
host-gateway-capture object results in resetting the channel count to 2.
The in_bit_depth is set to 32-bit by default for all audio formats in
host-gateway-capture class already.

Fixes: 7a11e27bf2 ('topology2: host-gateway-capture: Replace audio_format objects')
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2023-10-17 15:44:54 +01:00
Seppo Ingalsuo 64fcebbd64 Tools: Topology2: Add nocodec topology to test google-rtc-aec
The first playback PCM is for AEC mic input via SSP0 LBM. The second
playback PCM is for AEC reference via SSP2 LBM. The first capture
PCM is the AEC output.

The AEC (mockup) can be run and tested with the topology like
this:

$ aplay -Dhw:0,0 mic_clip.wav &
$ aplay -Dhw:0,2 ref_clip.wav &
$ arecord -Dhw:0,0 -f dat -d 10 output.wav

With AEC mockup version output.wav is mix of microphone
and reference.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-10-16 16:08:24 +01:00
Bard Liao c1b74bac9b topology2: sof-mtl-rt713-l0-rt1316-l12-rt1713-l3: use default stream
name

rt713 and rt1713 are in different SoundWire links. So, no DAI type will
be appended to DAI link name. We should use default stream name in
the topology.

Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
2023-10-13 12:39:38 +03:00
Seppo Ingalsuo df8f9dfc09 Tools: Topology2: Add sof-hda-benchmark-eqfir16/24/32-tgl build
This patch adds FIR EQ topologies build.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-10-13 12:34:56 +03:00
Seppo Ingalsuo 311c03026f Tools: Topology2: Add sof-hda-benchmark-eqiir16/24/32-tgl generate
This patch adds IIR EQ topologies build.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-10-13 12:34:56 +03:00
Seppo Ingalsuo 501816a90a Tools: Topology2: Add sof-hda-benchmark-drc16/24/32-tgl build
This patch adds DRC test topologies build.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-10-13 12:34:56 +03:00
Seppo Ingalsuo a292c9cf25 Tools: Topology2: Build topologies to test processing components
This patch uses cavs-benchmark-hda.conf to build topologies to
test components in a simple playback and capture configuration.

host copier --> component --> DAI copier
host copier <-- component <-- DAI copier

The built topologies are
sof-hda-benchmark-dcblock16/24/32-tgl.tplg

The shell script bench_comp_generate.sh is added to conveniently
generate include files needed to build new test topologies for
component with s16/s24/s32 format.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-10-13 12:34:56 +03:00
Seppo Ingalsuo 269d8d5924 Tools: Topology2: Add DC block component
This patch adds the widget class dcblock and a sample
bytes configuration blobs.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-10-13 12:34:56 +03:00
Ranjani Sridharan 7a11e27bf2 topology2: host-gateway-capture: Replace audio_format objects
With input_audio_format/output_audio_format objects in preparation to
deprecate the audio_format class.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2023-10-12 15:55:30 +03:00
Jyri Sarha c1996e01e1 topology2: doc: Little fixes to make all classes show correctly
There were couple of classes that did not have their topology2 snippets
showing. Probably the essential problem was just the class definition
starting from the first line of the file. There was nothing obviously
wrong in the output of the filter, but the way the doxygen works is
sometimes hard to anticipate. Adding \struct before the definition
fixed the problem.

Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
2023-10-06 15:34:14 +01:00
Jyri Sarha 649ac7d2d2 topology2: doc: input_audio_format.conf: Translate comments to Doxygen
Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
2023-10-06 15:34:14 +01:00
Jyri Sarha 215d7b3a07 topology2: doc: fe_dai.conf: Change comments to Doxygen
Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
2023-10-06 15:34:14 +01:00
Jyri Sarha a3e6cf7aac topology2: doc: data.conf: Change comments to Doxygen
Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
2023-10-06 15:34:14 +01:00
Jyri Sarha 22ec5b3811 topology2: doc: audio_format.conf: Translate comments to Doxygen
Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
2023-10-06 15:34:14 +01:00
Jyri Sarha c7f0e930f2 topology2: doc: widget-common.conf: Attribute comments to Doxygen
Change attribute comments to Doxygen comments.

Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
2023-10-06 15:34:14 +01:00