Commit Graph

1640 Commits

Author SHA1 Message Date
Seppo Ingalsuo 155137b878 Tools: Test: Timeout src_test.m after 300k copy() iterations
This prevents testbench run freeze from src_test.m. Function
test_run_src() passes to testbench option -C that limits the number
iterations to 300k that corresponds to 5 min of audio.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-12-02 15:30:14 +00:00
Yong Zhi a4e5fea520 topology2: Add rt5682+max98357a support
Add sof-mtl-max98357a-rt5682 topology which supports
RT5682 headset and MAX98357A speaker amplifiers.

Signed-off-by: Yong Zhi <yong.zhi@intel.com>
2022-12-02 15:09:56 +00:00
Ranjani Sridharan b0c5b08d63 topology2: sof-ace-tplg: Rename sof-mtl-sdw
To it's actual name sof-mtl-rt711-4ch.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-12-02 13:13:25 +00:00
Ranjani Sridharan 3a98634714 topology2: avs-tplg: Build ADL nocodec tplg
This will avoid having to rename the TGL tplg on ADL devices.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-12-02 13:13:25 +00:00
Seppo Ingalsuo 689b91e6f2 Tools: Topology1: Add sof-hda-generic topology with SRC
This patch adds to sof-hda-generic.m4 macros HSSFX, HSSFX_FILTER1,
and HSSFX_FILTER2 those can be used to customize stream effect
for PCM 30. The macro defaults to volume so the default topology
build is not impacted.

The CMakeLists.txt in development is updated to build topologies
sof-hda-generic-src.tplg, sof-hda-generic-2ch-src.tplg, and
sof-hda-generic-4ch-src.tplg. The stream effect is set with HSSFX
to src-volume.

The pipeline pipe-host-src-volume-playback.m4 is added. It is similar
as pipe-host-volume-playback.m4 but a sample rate converter (SRC)
is added after PCM, before volume. The PCM capability is changed to
min 8000, max 192000 Hz.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-12-02 12:33:56 +00:00
Ranjani Sridharan 0bdf8e3d31 topology2: rename cavs-passthrough-hdmi.conf
Rename it to sof-hda-generic.conf.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-11-30 16:55:18 -08:00
Ranjani Sridharan d25f775108 topology2: sof-ace-tplg: Build sof-hda-generic-2ch topology
This will be needed for MTL.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-11-30 16:55:18 -08:00
Ranjani Sridharan e303098d2a topology2: Remove the cavs folder
This folder contains definitions for both CAVS and ACE. So remove the
incorrect folder naming and move everything one level up.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-11-30 16:55:18 -08:00
Ranjani Sridharan 5444cd2097 topology2: build the topologies in the right folder
The CAVS topologies need to be in the avs-tplg folder and the MTL
topologies need to be in sof-ace-tplg folder. Also, change the output
file names to the names expected by the kernel and the NHLT binary files
to match the topology file names.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-11-30 16:55:18 -08:00
Pin-chih Lin ff7861f222 topology: fix DMICPROC undefined issue for intel-generic-dmic
Adds fatal assertion in intel-generic-dmic.m4 for DMICPROC is not
defined in upper m4, and fixes a potential risk of assertion by
sof-tgl-max98357a-rt5682.m4.

Signed-off-by: Pin-chih Lin <johnylin@google.com>
2022-11-28 17:05:25 +00:00
MARUTHI MACHANI 017892ec48 topology1: topology support for tdm configuration
Topology support for tdm configuration for amd platform

Signed-off-by: MARUTHI MACHANI <maruthi.machani@amd.com>
2022-11-23 20:28:09 +00:00
Vamshi Krishna Gopal a036799103 topology: Change Speaker period size to 10 ms for RPL and ADL-N Chrome designs
with 10ms period size we have seen power improvements.
We are working to move all topologies of Chrome to 10 ms.
Starting with current RPL and ADL-N topologies.

With many topologies already using GOOGLE_RTC_PROCESSING
flag to set 10ms, making a simpler flag to be used across
to set required SPEAKER PERIOD. This helps to scale later
to all designs.

Signed-off-by: Sathya Prakash M R <sathya.prakash.m.r@intel.com>
Signed-off-by: Vamshi Krishna Gopal <vamshi.krishna.gopal@intel.com>
2022-11-22 12:59:18 +00:00
Joe.Cheng 1013277791 topology1:enable DTS on MT8186
Enable SOF EQ + DTS

Signed-off-by: Joe.Cheng <joe.cheng@xperi.com>
2022-11-21 12:39:25 +00:00
Seppo Ingalsuo f5dd529190 Tools: Test: Remove unused variable from src_test.m
The variable tn is not used, it is safe to delete it.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-11-18 10:10:16 +00:00
Seppo Ingalsuo 1d81cb6a62 Tools: Test: Audio: Fix typo in THD+N help text
There's incorrect dynamic range test function usage in help.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-11-18 10:10:16 +00:00
Seppo Ingalsuo c11d99241d Tools: Tune: Fix erroneous fprintf() in src_get.m
This fprintf() with missing %d causes in Matlab and octave
messed up console output. This fix prints filter order
if this issue happens. This could be caused by too high
filter specification request that was not possible to reach.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-11-18 10:10:16 +00:00
Seppo Ingalsuo 00c51bde78 Tools: Test: Audio: In markers find fail show the captured waveform
This patch adds to chirp test (executed first usually) plot of
audio waveform to help understand why the audio markers were not
found. The reasons like very low level or corruption or large
time shift can be seen from the plot easily.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-11-18 10:10:16 +00:00
Seppo Ingalsuo db66ae457b Tools: Test: Add to SRC test control for quick test and make plots
This patch helps to avoid editing the script to change the test
behavior. The full_test set to 0 performs a quick test with chirp
(default 1).  The option show_plots set to 1 (default 0) shows
the plot graps from each test step those help to understand the
test verdict.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-11-18 10:10:16 +00:00
Seppo Ingalsuo 5471357792 Tools: Test: Audio: Replace the gaussian dither with triangular
The gaussian (or other normal distribution shape) dither impacts
too much 16 bit signals. The triangular probability density
function (TDPF) is a sufficient compromise between added noise energy
and de-correlation of PCM samples.

This change improves for 48 kHz 16 bit audio measurement the THD+N
from -62.6 dB to -73.6 dB.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-11-18 10:10:16 +00:00
Seppo Ingalsuo 044d0b208d Tools: Test: Audio: In SRC THD+N test apply standard low pass
This patch applies for conversions where Nyquist rate allows
a 20 kHz low-pass filter as specified in AES17 standard (test.fu).
The sweep test is set no higher than 20 kHz (test.f_end).

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-11-18 10:10:16 +00:00
Seppo Ingalsuo 4d35480c64 Tools: Tune: SRC: Change the SRC gain to 0 dB
This change aligns the gains in all other conversions sets
with IPC4 that already has the same setting. The max gain of a
converter is 0 dB. It also avoids the issue of 1 dB lower gain
in 2-stage vs. 1-stage conversions.

This changes only the generate scripts. The coefficients need a
separate patch.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-11-18 10:10:16 +00:00
Seppo Ingalsuo 40f78a9325 Tools: Tune: Add minimum THD+N performance check to snr_generate.m
This patch updates the SRC coefficients generator scripts with
add of parameter cfg.thdn that is the min. THD+N performance. The
target gain is set to 0 dB for all conversions to be generated.

in src_param.m the default stop-band is relaxed from 70 dB to 63 dB.
It can be done because the THD+N performance check will step up the
attenuation. The default lower attenuation saves RAM in easy
simple fractions conversions.

The main change is in src_generate.m. The conversions matrix is
two pass. In the first pass the converters are designed and the
converter for same fraction and other bandwidth parameters with
highest performance is preserved. In the second pass the table
of converters is constructed and the size of filters and buffers
and other information like MCPS estimate are collected.

Other changes include reduction of plots made during batch design
and remove of some commented out code.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-11-18 10:10:16 +00:00
Pin-chih Lin 466a0508a1 topology: unify RTNR+AEC topology file
pipe-rtnr-google-rtc-audio-processing-capture.m4 and
pipe-google-rtc-audio-processing-rtnr-capture.m4 are actually the same
graph. The filename differs because they are originated from different
branch.

This commit unifies them to avoid confusion.

Signed-off-by: Pin-chih Lin <johnylin@google.com>
2022-11-18 10:06:42 +00:00
Pin-chih Lin 058dc69b1f topology: enable GOOGLE_AEC and WAVES on CS35L41 amp
Add WAVES+AEC topology

Signed-off-by: Pin-chih Lin <johnylin@google.com>
2022-11-18 10:06:42 +00:00
Pin-chih Lin 864064d4a9 sof-nau8825: add DSM lib and remove hotword/dmic16k
For nau8825 codec devices e.g. Kano/Volmar/Zavala, it had been observed
that when Hotword module is enabled, noticeable pop noises appear in the
playback audio. While disabled, the playback audio becomes clear.

Because Hotword module is optional, remove it for now as WA fix for noise
issue.

Signed-off-by: Pin-chih Lin <johnylin@google.com>
2022-11-18 10:06:42 +00:00
Curtis Malainey efd3742cab topology: add rtnr + google_aec topology files
Add topologies for RTNR and GOOGLE AEC integration

Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Signed-off-by: Pin-chih <johnylin@google.com>
2022-11-18 10:06:42 +00:00
Curtis Malainey 048ffd8003 topology: add new aec topology
New target device, also move the path over to core 1 when running in
no_hotword mode

Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Signed-off-by: Pin-chih Lin <johnylin@google.com>
2022-11-18 10:06:42 +00:00
Balakishorepati 343bd7d4a1 topology1: CMakeLists: fix topology typo name
Add proper topology name for rembrandt platform.

Signed-off-by: Balakishorepati <balaKishore.pati@amd.com>
2022-11-16 13:18:56 +00:00
Joe.Cheng 192c1a24d4 topology1:renoir: add DTS + EQ topology
Add a new m4 to support DTS SDK -> EQ processing

Signed-off-by: Joe.Cheng <joe.cheng@xperi.com>
2022-11-15 18:15:32 +00:00
Brent Lu 1e3a4cfe9b topology: sof-adl-nau8825: support RT1015P amplifier
Add new topology sof-adl-rt1015-nau8825 which implements Realtek
ALC1015 on SSP1.

Signed-off-by: Brent Lu <brent.lu@intel.com>
2022-11-14 16:40:08 +00:00
Ranjani Sridharan 70c7a02c66 gain-capture: Add copier module
Gain module cannot be bound to a module from another pipeline. So,
add a module copier in the gain-capture pipeline.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-11-14 15:11:51 +00:00
Gongjun Song b91af845b7 topology1: Add sof-rpl-rt711-l0-rt1318-l12-rt714-l3
Audio hardware configuration of SKU 0C11 product is rt711 on link0,
two rt1318s on link1 and link2, rt714 on link3

Signed-off-by: Gongjun Song <gongjun.song@intel.com>
2022-11-11 13:25:07 +00:00
Bard Liao 92ad7bd974 Revert "topology2: add ssp multi stream capture"
This reverts commit 0857ed68b9.
The "topology2: add ssp multi stream capture" impacted PR test.
Will resubmit once we fixed the issue.

Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
2022-11-11 12:54:41 +00:00
Bard Liao 0857ed68b9 topology2: add ssp multi stream capture
Add ssp multi stream capture support.

Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
2022-11-09 14:40:04 +00:00
Libin Yang 691b80261a topology2: add payload_with_output_fmt token
payload_with_output_fmt token is used to tell sof driver whether
there is output audio format in the init instance ipc4 message
payload. payload_with_output_fmt = 1 mean there is audio output
format in the ipc4 message payload.

Signed-off-by: Libin Yang <libin.yang@intel.com>
2022-11-08 13:34:08 +00:00
Pierre-Louis Bossart a5635e0011 topology1: add missing ES8336 topologies for ICL
This needs to be added in sof-bin.

Link: https://github.com/thesofproject/linux/issues/3873
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-11-08 13:31:26 +00:00
Ranjani Sridharan dd58f5ba1d topology2: cavs-passthrough-hdmi: Add support for chained DMA
Add support for chained DMA pipelines in the HDMI passthrough topology.
Since the HDA hardware does not support S24_LE, remove the format from
the PCM capabilities for all the HDMI PCM's as well.

This version should work even if the kernel does not support chained DMA
as yet.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-11-08 13:30:43 +00:00
Gongjun Song fc825a9ecb topology1: Add sof-rpl-rt711-l2-rt1316-l01-rt714-l3
Audio hardware configuration of SKU 0C40 product is rt711 on link2,
two rt1316s on link0 and link1 and rt714 on link3

Signed-off-by: Gongjun Song <gongjun.song@intel.com>
2022-11-04 20:57:15 +02:00
Gongjun Song 11baeefd94 topology1: Add sof-rpl-rt1316-l12-rt714-l0
Audio hardware configuration of SKU 0C10 product is rt714 on link0,
two rt1316s on link1 and link2

Signed-off-by: Gongjun Song <gongjun.song@intel.com>
2022-11-04 20:57:15 +02:00
Gongjun Song 7c47f6aa55 add some missing topologies in v5.19/CMakeLists.txt
Add missing adl SoundWire NOJACK topologies in
v5.19/CMakeLists.txt

Signed-off-by: Gongjun Song <gongjun.song@intel.com>
2022-11-04 20:57:15 +02:00
Liam Girdwood 367580f335 Revert "topology2: cavs: Add chained DMA support for HDMI pipelines"
This reverts commit aed76b5a60.
2022-11-02 19:08:26 +02:00
Ranjani Sridharan aed76b5a60 topology2: cavs: Add chained DMA support for HDMI pipelines
Add a new pipeline chain-dma-playback.conf for chained DMA playback
and use it for HDMI depending on the HDMI_CONFIG.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-11-01 14:20:11 +00:00
Andrula Song ef62a50893 Cmocka: EQ: Fix the errors lead to eq-iir test failure
Fix the mistakes in scripts which would lead to eq-iir
test failure.

Signed-off-by: Andrula Song <xiaoyuan.song@intel.com>
2022-10-31 13:33:40 +00:00
Rander Wang efc71f6c71 topology2: nocodec: add volume and mixer support
Mixer and volume (gain) are used in nocodec topology.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-10-28 12:26:38 +01:00
Pin-chih Lin aa589343fd topology: waves: remove deprecated kcontrol widget and data
Fix aligned to pipe-waves-codec-playback.m4 due to module_adapter
design change.

Signed-off-by: Pin-chih Lin <johnylin@google.com>
2022-10-27 22:05:38 +01:00
Rander Wang b97fd67ef0 cmocka: add eq_fir unit test
This test uses module interface for eq_fir.

The use of decoded 16 bit FIR blob coefficients decreases a lot
the mismatch between float reference FIR vs. SOF fixed point
implementation.

This patch adds the script tools/tune/eq/cmocka_data_eq_fir.m that
generates the files cmocka_fir_coef_2ch.h and cmocka_fir_ref.h.

The script debug_files_plot.m can be used to visualize the unit
test result and error for data that is generated if macro
DEBUG_FILES is defined.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
Signed-off-by: Andrula Song <xiaoyuan.song@intel.com>
Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-10-27 21:12:37 +01:00
Guennadi Liakhovetski 10f6dd0d7b module-adapter: add a constant data pointer
module_config contains a .data pointer that is used both for initial
and run-time configuration. The initial configuration should be
const. We add a new .init_data pointer for it.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2022-10-26 15:56:49 +01:00
Marc Herbert 367df306b6 sof_ri_info: minor BinReader logging fix to support pathlib
Switch to an f-string which automatically converts the argument to a
string.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-10-24 16:15:12 +01:00
MARUTHI MACHANI 252e7e7559 topology1: support for dmic with 4 channels
Topology support to configure dmic with
four channels for amd platforms.

Signed-off-by: MARUTHI MACHANI <maruthi.machani@amd.com>
2022-10-24 12:16:29 +01:00
Ranjani Sridharan 9200231e0e topology2: cavs-passthrough-hdmi: remove the option for HDA passthrough only
cavs-passthrough-hda.conf doesn't exist anymore.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-10-21 15:54:58 +01:00