* Use %z specifier for size types to avoid format
specifier warnings on arm32
* in ctl_dump(), size_t n may be used uninitialized
if ctl_data->out_fd > 0 and !ctl_data->binary.
Signed-off-by: Li-Yu Yu <aaronyu@google.com>
This patch adds the Kconfig option COMP_SRC_IPC4_FULL_MATRIX and
adds handling to src.c. Testbench build was changed to use this
largest matrix.
The coefficients were generated with script src_ipc4_int32.m. The
new sample rates were added to test script src_test.m.
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
There's need to have a 0 dB gain SRC conversion matrix while
earlier all defaulted to -1 dB. With this change the parameter
cfg.gain can be used with src_generate() function.
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
This patch helps to pass the code style check in generated header
file src_<profile>_<data type>_table.h. The error was:
CHECK: Please use a blank line after function/struct/union/enum
declarations
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
This patch forces open of every plot to the same picture window.
Earlier version could open hundreds of windows and freeze the
computer.
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
Test pipelines with SRC due internal block processing constraints need
this to avoid fail due to insufficient buffer. Other pipelines continue
to use 2 buffer periods.
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
The file component buffer resize was incorrect. It caused some
SRC testbench tests to fail due to insufficient sink buffer
size. The resize of file component source/sink was in prepare().
This patch moves it to one step earlier to params(). Then the
components' check for buffers in prepare() will see the impact
and let them error if the size is not sufficient.
After this change the number of periods in the buffer (from topology)
is preserved in resize. If a test does not run, need to fix the
test topology.
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
The order of BE DAI Link in topology must match the order in machine
driver. Create this include file to organize the definition of BE DAI
Link ID.
Signed-off-by: Brent Lu <brent.lu@intel.com>
Add a topology sof-adl-cs35l41 which supports four Cirrus Logic
CS35L41/CS35L53 speaker amplifiers running in TDM mode without
headphone codec on ADL platform.
Two compile options are added to support the board configuration:
'NO_HEADPHONE' removes headphone pipelines from the topology while
'SSP_AMP_LINK_ORDER' uses the DAI Link order in sof_ssp_amp.c machine
driver instead of sof_rt5682.c.
Signed-off-by: Brent Lu <brent.lu@intel.com>
This patch adds load possibility of mux, demux, and
google-rtc-audio-processing to testbench.
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
This patch changes testbench to retrieve pipeline direction
from pipeline host direction. Earlier all pipelines were forced
to playback.
The topology parsing filters the parsed pipelines to command line
specified pipeline IDs. All the pipeline operations are done
looped to these pipelines to be able to simulate multiple simultaneous
pipelines.
The pipeline context struct remains single. So the simulation works
only for pipelines with identical PCM format and rate.
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
This patch duplicates the configuration at the higher level and adds
the "HEADSET_DEEP_BUFFER" definition.
This is not very elegant and will require changes in two places, but I
don't see a better solution with M4.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
We don't want to release these topologies to world+dog due to
dependencies on kernel version, so let's make the deep-buffer
optional. The next patch will enable these topologies in the
development/ directory.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Before we enable the headset deep-buffer solution, we want to extract
the NOJACK topologies where the headset deep-buffer would be an
oxymoron.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
For some reason the topologies are in separate blocks, regroup them.
No functionality change.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
This patch duplicates the configuration at the higher level and adds
the "DEEP_BUFFER" definition. The topologies are generated in the
kernel_dependent/v5.19 directory and shall only be used by
distro/users when their kernel is based on 5.19-rc1 or later. If these
topologies are used with an older kernel, the ASoC DPCM state machine
issues will result in broken audio. We have no ability to detect a
dependency on kernel to load a topology.
This is not very elegant and will require changes in two places, but I
don't see a better solution with M4.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
We don't want to release these topologies to world+dog due to
dependencies on kernel version, so let's make the deep-buffer
optional. The next patch will enable these topologies in the
development/ directory.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
We don't support this topology in production and it's not clear if
it's even maintained, move to development.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
This patch enables testing of DRC in HDA generic devices by adding
it to headset/speaker pipeline after mixer.
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
STOP copying all files
from dir: sof/tools/build_tools/topology/topology2/cavs/
to dir: sof/tools/build_tools/topology/
The original plan discussed in the reviews of commit c0bee428ae
("topology: prepare for Topology2.0") and commit 308a24a92b
("topology2: Add build support") and more recently
mentioned in #4611 was to overwrite in place some v1 topologies with
newer v2 topologies in order to "force" users to upgrade without them
realizing it. This original plan is now being abandoned. v2 topologies
will never overwrite v1 topologies and if ever then certainly not "en
masse". Moreover, v2 topologies will be placed in a new /lib/firmware/
subdirectory. So, partial revert the aforementioned commits. More
specifically. stop installing v2 topologies into the same directory as
v1 topologies.
Note there had never been any actual overwrite of any v1 topology yet
because there had never been any v2 topology of the same name.
At this point in time this gets rid of the following copies:
tools/build_tools/topology: abi.conf
tools/build_tools/topology: cavs-mixin-mixout-hda-2ch-cnl.conf
tools/build_tools/topology: cavs-mixin-mixout-hda-2ch-cnl.tplg
tools/build_tools/topology: cavs-mixin-mixout-hda-2ch-tgl.conf
tools/build_tools/topology: cavs-mixin-mixout-hda-2ch-tgl.tplg
tools/build_tools/topology: cavs-mixin-mixout-hda-4ch-cnl.conf
tools/build_tools/topology: cavs-mixin-mixout-hda-4ch-cnl.tplg
tools/build_tools/topology: cavs-mixin-mixout-hda-4ch-tgl.conf
tools/build_tools/topology: cavs-mixin-mixout-hda-4ch-tgl.tplg
tools/build_tools/topology: cavs-mixin-mixout-hda.conf
tools/build_tools/topology: cavs-mixin-mixout-hda.tplg
tools/build_tools/topology: cavs-passthrough-hdmi.conf
tools/build_tools/topology: cavs-passthrough-hdmi.tplg
tools/build_tools/topology: cavs-sdw.conf
tools/build_tools/topology: cavs-sdw.tplg
tools/build_tools/topology: cavs-tgl-nocodec.conf
tools/build_tools/topology: cavs-tgl-nocodec.tplg
tools/build_tools/topology: nhlt-ace-mtl-nocodec.bin
tools/build_tools/topology: nhlt.bin
tools/build_tools/topology: nhlt-cavs-tgl-nocodec.bin
tools/build_tools/topology: sof-mtl-nocodec.conf
tools/build_tools/topology: sof-mtl-nocodec.tplg
From an "installer/" and sof-bin release perspective, this removes the
following topology that was just added by commit
ba26eeff9d ("topology2: cavs-nocodec: Add support for MTL nocodec
topology"). Installing v2 topologies into a new /lib/firmware/
subdirectory has not been implemented yet.
No other change besides dropping these copies, everything else is the
same.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
These paths are not well supported on all devices and lead to errors such as
17:06:06 kernel: HDA Digital: ASoC: dpcm_be_dai_startup() failed at Digital Playback and Capture (-22)
17:06:06 kernel: Digital Playback and Capture: __soc_pcm_open() failed (-22)
17:06:06 kernel: snd_hda_codec_conexant ehdaudio0D0: ASoC: error at snd_soc_dai_startup on Digital Codec DAI: -22
17:06:06 kernel: snd_hda_codec_conexant ehdaudio0D0: ASoC: error at snd_soc_dai_startup on Digital Codec DAI: -22
17:06:06 kernel: snd_hda_codec_conexant ehdaudio0D0: didn't find PCM for DAI Digital Codec DAI
We've already removed this digital path for IPC4/topology2, let's also remove this for topology1.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Add the audio formats for 4ch in passthrough-be and passthrough-capture
pipelines.
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Sometimes we want to load a binary block of data without letting
userspace interact with the underlying control. An RO control will do
this exactly by loading the data and providing no write access.
Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Building in parallel is much faster but it makes logs unreadable and
build failures impossible to understand. This is especially true when
building with recent ALSA that produces of deprecation warnings, see
examples below. For test topologies the problem is even worse: its
XARGS parallel build provides no log at all.
To find what actually fails, it is required to fall back on a single
threaded and verbose build and this is achieved with the variables
USE_XARGS, NO_PROCESSORS and VERBOSE. Pass these through docker-run.sh
and CMake.
Examples from #5608https://github.com/thesofproject/sof/runs/5717553555?check_suite_focus=truehttps://sof-ci.01.org/sofpr/PR5608/build12556/build/tools.txt
ALSA pcm.c:1523:(parse_hw_config) deprecated fsync value 'codec_slave',...
ALSA pcm.c:1471:(parse_hw_config) deprecated bclk value 'codec_slave',...
ALSA pcm.c:1523:(parse_hw_config) deprecated fsync value 'codec_slave',...
ALSA pcm.c:1471:(parse_hw_config) deprecated bclk value 'codec_slave',...
ALSA pcm.c:1523:(parse_hw_config) deprecated fsync value 'codec_slave',...
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
The major/minor/patch values are represented with u16 in the FW. So,
change the numbers of bytes to match that of the FW when adding the
ABI to the topology manifest for IPC4. For IPC3, we still only use 3
bytes as there's no clean way to increase the number of bytes without
breaking backwards compatibility with the older kernel. There are no
topologies using topology2 for IPC3 today but it is possible in the
future.
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
This removes two layers of indirection when trying to find what fails.
The lack of this proved especially painful when working on #5632 and
similar backports.
Also move outputs to a subdirectory by default. No change when invoked
from CMake which does not use the default output directory.
Also show the exact m4 and alsatplg commands run when not using XARGS
parallelization. Again this is critical when something fails.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
The correct frame length should be calculated by
FRAME_LEN = SAMPLING_RATE * PERIODS / 1000000
The macro COMP_PERIOD_FRAMES does the thing.
Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Signed-off-by: Ming Jen Tai <mingjen_tai@realtek.com>
The DTS Codec can be conditionally added to the sof-adl-nau8825 topology
on those pipelines intended for headphone and speaker output.
Signed-off-by: Joe.Cheng <joe.cheng@xperi.com>
For builds with no Hotword on DSP, generic dmic m4 is used.
RTNR is running on DMIC CORE ID 1. Hence adding the flag.
Signed-off-by: Jairaj Arava <jairaj.arava@intel.com>
No functional change.
Move some common testbench code into the topology parser and group
feature parsing by file name.
Add a tplg_ prefix to external APIs without a prefix, others with an
existing prefix to follow this change.
Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
sof-ctl assumed the binary control were of size of a
multiple of unsigned integer.
This caused the control byte array to be truncated when the
size of the control was 6 bytes.
This change allow setting any size of control in binary form.
Using CSV will always end up with a number of unsigned integer size.
I tested this change using the Google RTC Audio processing with control
of size:
- 6 bytes,
- 2 bytes
- and 4 bytes.
Signed-off-by: Lionel Koenig <lionelk@google.com>
NO_AGGREGATION is never used now. Let's remove it.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Libin Yang <libin.yang@intel.com>
This patch adds build of topologies sof-hda-generic-multiband-drc.tplg
and sof-hda-generic-2ch-multiband-drc.tplg. The processing happens in
pipeline part after mixer. Volume is controlled in PGA before mixer.
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>