Commit Graph

1606 Commits

Author SHA1 Message Date
Jyri Sarha a940766d27 tools/probe: Fix realloc() usage
Realloc may change the location of memory and the code should
anticipate it.

Signed-off-by: Jyri Sarha <jyri.sarha@intel.com>
2022-09-28 14:04:39 +01:00
Jyri Sarha 50caa7dc1a tools/probe: Several fixes and restructuring for demuxcode
Several fixes and restructuring for demuxcode to make it work with sub
32-bit word granularity.

Signed-off-by: Jyri Sarha <jyri.sarha@intel.com>
2022-09-28 14:04:39 +01:00
Jyri Sarha 34d750d40b probe: Drop old IPC3 style probe DMA framing
Drop IPC3 probe DMA framing and use IPC4 framing for IPC3 mode
too. This change simplifies the code quite a bit. After this change
both the SOF firmware and sof-probe demux tool should be updated at
the same time.

Signed-off-by: Jyri Sarha <jyri.sarha@intel.com>
2022-09-28 14:04:39 +01:00
Muralidhar Reddy 586716e1b9 topology1: CMakeLists: add ADL support for ES83x6 & HDMI_In Capture
Add ADL support for ES83x6 on SSP1, LT_HDMI_In capture on SSP0 & SSP2.
Signed-off-by: Muralidhar Reddy <muralidhar.reddy@intel.com>
2022-09-26 11:24:23 +01:00
Muralidhar Reddy 187c845ddc topology1: CMakeLists: add ADL support for ES83x6
Added ADL support for ES83x6 on SSP1.
Signed-off-by: Muralidhar Reddy <muralidhar.reddy@intel.com>
2022-09-26 11:24:23 +01:00
Joe.Cheng a78fdcebc1 topology1:enable SOF EQ + DTS on AMD renoir
Period has to be 1ms to avoid playback noise issue on Renoir
when SOF EQ + DTS are both enabled.

Signed-off-by: Joe.Cheng <joe.cheng@xperi.com>
2022-09-26 11:03:29 +01:00
Peter Ujfalusi 2474fb48c6 topology2: Revert the conditional topology2 building for CAVS/ACE
The MTL support added conditional build for topology2 based on CONFIG_CAVS
or CONFIG_ACE.
This is wrong for several reasons:
There is not ace directory present
The Kconfig system is not used when building topologies, so we are ending
up not building topology2 files at all.

There is no reason why CAVS and ACE topologies should be exclusive.

Fixes: 784bce763c ("mtl: Added meteorlake platform to the build system")
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
2022-09-23 15:50:56 +01:00
Adrian Warecki 784bce763c mtl: Added meteorlake platform to the build system
Added new mtl platform to xtensa-build-zephyr.py.
Added ace directories to cmake files.
Added ACE to kconfig.
Add Meteorlake platform to be built with Zephyr under
CONFIG_ACE_VERSION_1_5 flag.

Signed-off-by: Andrey Borisovich <andrey.borisovich@intel.com>
Signed-off-by: Marcin Szkudlinski <marcin.szkudlinski@intel.com>
Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
Signed-off-by: Konrad Leszczynski <konrad.leszczynski@intel.com>
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Signed-off-by: Tomasz Leman <tomasz.m.leman@intel.com>
Signed-off-by: Rafal Redzimski <rafal.f.redzimski@intel.com>
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@intel.com>
2022-09-21 15:15:26 +02:00
Rander Wang 93d159d7fb topology2: add lp_mode as a attribute in pipeline
Currently lp_mode setting is not included by topology binary
since lp_mode is not defined as a attribute. This patch adds
it in pipeline.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-09-15 14:15:08 +01:00
Joe.Cheng 87de994f49 topology1:remove runtime config from DTS topologies
Follow PR#5190, remove runtime config from DTS topologies

Signed-off-by: Joe.Cheng <joe.cheng@xperi.com>
2022-09-14 12:08:36 +01:00
Liam Girdwood e8733b4f4c header: rtos: use rtos specific version of clk.h
Code can now include <rtos/clk.h>. API is not yet wrapped to Zephyr.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2022-09-12 11:44:27 +01:00
Liam Girdwood 4843516ab8 header: rtos: use rtos specific version of alloc.h
Code can now include <rtos/alloc.h> and uses thinly wrapped Zephyr
native for most uses. Wrapping can be removed over time.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2022-09-12 11:44:27 +01:00
Fred Oh 51abaff072 Tools: Testbench: add suffix to keep all the logs
When series of tests are run, only last result with same component is
saved. Make unique output filename. For now adding bits per sample
at the end of file, all the logs can be saved.

Ideally datetime string would be good. I keep it as FIXME.

Signed-off-by: Fred Oh <fred.oh@linux.intel.com>
2022-09-07 22:09:33 +01:00
Fred Oh d9d5842654 Tools: Testbench: add fulltest parameter in process_test
fulltest param to control quick chirp test only or full test
including all quality tests.

As minor clean up, unused parameter in thdnf_mask() and test_run_process()
is removed.

Signed-off-by: Fred Oh <fred.oh@linux.intel.com>
2022-09-07 22:09:33 +01:00
Fred Oh 7eb9863cdc Tools: Testbench: apply common indentation for functions
No functional change. Set common function indentation and add comment
sections for better readability.

Signed-off-by: Fred Oh <fred.oh@linux.intel.com>
2022-09-07 22:09:33 +01:00
Fred Oh 86e6e4e5b0 Tools: Testbench: fix typo in copyright year
Obvious typo in copyright year, it is 2022.

Signed-off-by: Fred Oh <fred.oh@linux.intel.com>
2022-09-07 22:09:33 +01:00
Rander Wang 1394832fd7 topology2: add more audio formats support for deep buffer pipeline
Add 32bits/32bits support for deep buffer.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-09-07 13:33:51 +01:00
Rander Wang 26b8406c28 topology2: add more audio formats support for host-mixin pipeline
Add 24bits/32bits support for gain

Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-09-07 13:33:51 +01:00
Rander Wang 2ad89eb0d3 topology2: add deep buffer support on sdw platforms
Sdw platforms will support deep buffer

Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-09-06 22:06:23 +01:00
Rander Wang ba03937264 topolog2: add deep buffer support on HDA platforms
Deep buffer uses large 100ms dma buffer size and
it also enables lp mode.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-09-06 22:06:23 +01:00
Liam Girdwood c3c94fc515 header: rtos: use rtos specific version of wait.h
Code can now include <rtos/wait.h> and uses native Zephyr 64
cycle API instead of SOF version.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2022-09-06 15:37:21 +01:00
Marc Herbert d0bc72290a test/tplg-build.sh: remove spurious xargs -n1 option
The xargs option `-I/--replace` hardcodes max lines `-L 1`. In other
words, it always splits the input line by line and ignores whitespace
delimiters inside each line. Initial xargs commit
d0f4aba934 ("topology: speed up topology build") used `--replace`
after `-n/--max-args=1` which was silently ignored by xargs version
4.7.0. Now xargs 4.8.0 prints the following warning:

  xargs: warning: options --max-args and --replace/-I/-i are mutually
        exclusive, ignoring previous --max-args value

Remove the ignored `-n 1` to remove the warning.

I compared the outputs before and after this commit and they're exactly
the same.

There's an extra twist. The same xargs command also uses the
`-d/--delimiter=,` option which makes xargs ignore newlines and
"translates" any max-line `-L` option to `--max-args`; including the `-L
1` max implied by `--replace`. This twist does not make a difference:
any max-line or max-args is always overridden by `--replace` whether
`--delimiter` is used or not.

Of course this entire xargs script is re-inventing (C)Make/ninja that
provide build parallelism for free and much more... I digress.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-09-02 11:25:19 +01:00
Liam Girdwood c90055f2f5 header: rtos: use rtos specific version of string.h
No runtime semantic change. Use C library when RTOS uses
C library otherwise use own C library calls.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2022-08-31 12:01:07 +01:00
Liam Girdwood 09c52810a7 header: rtos: use rtos specific version of bit.h
No runtime functional change. Code can now include <rtos/bit.h>

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2022-08-31 12:01:07 +01:00
Liam Girdwood 1629a1f72c header: rtos: decouple headers into rtos specific directories.
No functional runtime change, but changes to rtos partitioning and the
layout of headers .

This patch creates RTOS specifc header paths and updates spinlock.h
and kernel.h to show the new usage. Other headers will incrementally follow.
It reuses the current zephyr topleve directory and creates a new
toplevel xtos directory for xtos specific files.

Due to the mixing of RTOS, driver and library headers at the top level include
directory it was necessary to create rtos specific header directories i.e.

src/include/rtos-xtos
src/include/rtos-zephyr

These RTOS include directories will eventually contain RTOS specific headers
whilst common logic and structures will be placed in non RTOS directories.

This will also mean

"#include <sof/spinlock.h>"

will become

"#include <rtos/spinlock.h>"

and will allow easier visualisation of where and why RTOS headers are being used.
This will help to eliminate cross usage of headers between RTOSes.

Subsequqnt patches will move more headers and rtos specific wrppaer
source files into rtos specific locations.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2022-08-31 12:01:07 +01:00
Ming Jen Tai 8496d585d1 Modify periods setting for RTNR capturing pipeline
With the  release of RTNR version 20220728, period for capturing pipeline requires at least 5ms.

Periods setting for 16KHz capturing pipeline is also removed since RTNR is currently running in 48KHz capturing pipeline only.

Signed-off-by: Ming Jen Tai <mingjen_tai@realtek.com>
2022-08-31 11:26:18 +01:00
Kai Vehmanen 13ba5fe90c tools: add mtrace-reader.py
Tool to stream data from Linux SOF driver "mtrace" debugfs
interface to standard output. Plain "cat" is not sufficient
as each read() syscall returns log data with a 32bit binary
header, containing the payload length.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2022-08-31 10:33:46 +01:00
Liam Girdwood 7288d52ab6 testbench: cleanup the logging to use printf.
No point in doing a sprintf to a local buffer.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2022-08-29 14:11:29 +01:00
Liam Girdwood 2865cc2bb2 testbench: cmake: parser does not use CONFIG_LIBRARY cmake variable
Not used by parser cmakefile so delete.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2022-08-29 14:11:29 +01:00
Liam Girdwood 67ae353bfb tplg_parser: support building as static or shared library.
Allow the tplg_parser to built as either static or shared library.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2022-08-29 14:11:29 +01:00
Liam Girdwood d9f9340e1a tplg_parser: split out testbench logic and partition features per file.
This is another tplg_parser and testbench update on the road to provide
further flexibility around supporting new modules and IPC versions.
There will more to follow.

Changes are mostly mechanical code movements i.e. moving testbench related code
to the testbench, splitting the files into per module/component files and
making some functions static and public.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2022-08-29 14:11:29 +01:00
Liam Girdwood 03b4f30129 testbench: include stdlib.h
Newer GCC version complain about free() not being defined.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2022-08-29 14:11:29 +01:00
Chao Song 7882b1a93d topology2: add pin binding classes for multiple I/O queue
An IPC4 widget may support multiple I/O queue. Queue ID is
required during widget binding in route setup.

This patch adds sink_pin_binging and src_pin_binding classes
for multiple I/O queue support.

For widget requires special pin(queue) binding, sink_pin_binding
or src_pin_binding should be defined in the widget object. So
that the kernel knows which pin to use during widget binding
by parsing topology.

Note that pin binding should be defined for all sink/source pins
or for none. Even if there is only one sink pin requires special
pin binding, pin binding should be defined for all sink pins, and
for pins that are not used, give the value "NotConnected". This rule
applies to source pins, too.

Example: smart_amp widget has two sink pins and one source pin,
and its feedback sink pin requires special pin binding, so we have to
define sink_pin_binding objects within smart_amp object like this:

Object.Base.sink_pin_binding.1 {
    # the main sink pin is connected to host for playback data
    sink_pin_binding_wname	"copier.host.1.1"
}
Object.Base.src_pin_binding.2 {
    # the feedback sink pin is connected to capture dai for codec feedback.
    sink_pin_binding_wname	"copier.SSP.2.1"
}

In this example, smart_amp is connected to host and DAI directly,
it is also possible to be connected to host and DAI indirectly (with
gain or other widget in the middle).

Signed-off-by: Chao Song <chao.song@linux.intel.com>
2022-08-29 13:26:49 +01:00
Chao Song 721e58f3d2 topology2: add num_sink/source_pins tokens for widget
These two tokens will be used by the kernel to decide the
supported number of sink/source pins, thus to allocate
correct widget queue id in route setup.

These two tokens are mandatory for IPC4 widgets, because
the default value in Linux kernel is zero, which is invalid
for queue id allocation.

Signed-off-by: Chao Song <chao.song@linux.intel.com>
2022-08-29 13:26:49 +01:00
Marc Herbert 92d828bc37 sof-logger: make inotify optional
Restores ability to compile on Windows with MSYS.

Fixes commit dcf0577a77 ("logger: allow starting before the driver is
loaded")

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-08-29 13:24:40 +01:00
Marc Herbert 277985e687 tools: delete obsolete tools/.gitignore
We moved to CMake and out-of-source builds years ago.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-08-29 13:24:40 +01:00
Seppo Ingalsuo 04aa27103e Math: FFT: Switch to script generated twiddle.h
This patch adds script tools/tune/fft/export_twiddle.m. Since
the data in original twiddle.h differs by one LSB in few
items the file is replaced with one generated with the script.

The identifier 32 is added to header name and variables names
as preparation to add 16 bit FFT version.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-08-26 10:46:50 +01:00
Chunxu Li 8d9c5485c4 topology1: remove mt8186 unused topologies
Remove mt8186 unused topologies.

We use sof-mt8186 on our demo board, sof-mt8186-mt6366-rt1019-rt5682s
and sof-mt8186-mt6366-da7219-max98357 will no be used anymore.

Signed-off-by: Chunxu Li <chunxu.li@mediatek.com>
2022-08-25 16:20:26 +03:00
Rander Wang d40fb8fc99 topology2: add stream token in topology2
Add stream d0i3 token

Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-08-25 13:24:25 +01:00
Marc Herbert e1d6b9a08a topology2: build only when alsatplg is v1.2.7 or greater
Fixes: #5323

The v1.2.6 requirement was a lie the whole time because alsatplg v1.2.6
does not have any `-I` option. The truth was: un-released alsa-utils
from git was required. The check for v1.2.6 was an approximation good
enough for many users but not for everyone, see for instance #5323.

Now that alsa-utils v1.2.7 has been released we can stop lying:
 https://github.com/alsa-project/alsa-utils/commit/7d934f3142549

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-08-18 13:36:49 +01:00
Laurentiu Mihalcea 3590936101 topology1: Add new i.MX topology for PCM capture using compress API
We add a new i.MX8MP topology which will use the compress API for PCM
capture. This topology is mainly used for testing.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2022-08-17 15:01:59 +03:00
Laurentiu Mihalcea b99bf48195 topology1: Add new i.MX topology for PCM playback using compress API
We add a new i.MX8MP topology which will use the compress API for PCM
playback. This topology is mainly used for testing.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2022-08-17 15:01:59 +03:00
Laurentiu Mihalcea cb38eec76e topology1: Add new i.MX topology for PCM capture using compress API
We add a new i.MX8Q(M/XP) topology which will use the compress API for
PCM capture. This topology is mainly used for testing.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2022-08-17 15:01:59 +03:00
Laurentiu Mihalcea 476b31ecdb topology1: Add new i.MX topology for PCM playback using compress API
We add a new i.MX8Q(M/XP) topology which will use the compress API for
PCM playback. This topology is mainly used for testing.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2022-08-17 15:01:59 +03:00
Laurentiu Mihalcea def03928d5 topology1: pcm: Add new macro for compress capture
We want to be able to create topologies for the case of
compress capture. This change will enable us to do so.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2022-08-17 15:01:59 +03:00
Laurentiu Mihalcea 9d54236675 topology1: pcm: Introduce compress parameter for pcm_capture_add_common
This change will allow us to prepare for adding a new macro
for the case of compress capture.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2022-08-17 15:01:59 +03:00
barry.jan 8efd627964 topology: add Waves for sof-mt8186-mt6366-rt1019-rt5682s tplg
Signed-off-by: barry.jan <barry.jan@waves.com>
2022-08-16 21:53:12 +01:00
Kai Vehmanen 87425baf22 probe-app: add support for non-audio probe buffers
Identify non-audio probe streams and write them out with ".bin"
extension and without the RIFF WAVE header.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2022-08-16 15:35:03 +01:00
Kai Vehmanen bd9168f676 probe-app: support non-word aligned probe data streams
Modify code to correctly handle probe streams where sync word
can occur at any byte boundary, and where probe packet size may
not be aligned to 32bit word size.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2022-08-16 15:35:03 +01:00
Kai Vehmanen e2a5d925ba probe-app: bail out if opening file fails
Do not blindly call fwrite without checking whether file open
succeeded or not.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2022-08-16 15:35:03 +01:00
Kai Vehmanen 89039c6bff probe-app: fix handling of buffer-id of zero
Don't assume buffer-id of zero is an invalid value.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2022-08-16 15:35:03 +01:00
Daniel Baluta 8a1b051940 topology1: codec_adapter: Remove ca_config bytes
After commit:
5763c74bf4 ("codec_adapter: Remove setup config from module data")
we no longer setup config bytes in codec adapter control bytes.

So, we need to remove ca_config bytes and fix payload size. This
didn't introduce any bug because this is the default
CA_SETUP_CONTROLBYTES. Each topology uses a custom control bytes
which overrides this default values.

Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
2022-08-15 12:53:29 +01:00
Seppo Ingalsuo a328223ba5 Topology1: Allow S24_4LE and S32_LE playback with PCM4
This patch allows to test SRC with all 16/24/32 bit formats
in UP-squared device. Without this patch only 16 bit is
supported.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-08-10 07:54:39 +01:00
Daniel Baluta 6231528924 topology: Fix setup control bytes comments
setup config data was removed with commit
5763c74bf4 ("codec_adapter: Remove setup config from module data")
update documentation to reflect this.

Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
2022-08-05 19:22:37 +01:00
Pierre-Louis Bossart 190cfd79f7 topology1: add SSP1 for all ES8336, SSP5 for APL/GLK
We apparently missed quite a few platforms with SSP1, and SSP5 is also
needed for APL/GLK.

One day we'll have a better way to add topologies, but so far it's
brute-force combinatorial addition. Oh well.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-08-05 12:28:12 +01:00
Kai Vehmanen 8881a406af topology: add sof-rpl-nocodec.tplg
Add nocodec topology for Intel Raptor Lake.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2022-08-04 16:22:56 +01:00
Kai Vehmanen f2bfa2824e topology: add sof-rpl-rt711 and sof-rpl-rt711-4ch topologies
Add new topologies for Intel Raptor Lake.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2022-08-04 16:22:56 +01:00
Kai Vehmanen 09944bc058 topology: Add platform definition file for Intel Raptor Lake
Start with Alder Lake definitions.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2022-08-04 16:22:56 +01:00
Marc Herbert dcf0577a77 logger: allow starting before the driver is loaded
Don't fail immediately when the driver is not loaded. Use inotify
instead to wait for /sys/kernel/debug/sof/[e]trace to appear.

This makes it possible to start before the driver is loaded which
reduces considerably the chances of missing early logs.

Fixes a small part of https://github.com/thesofproject/linux/issues/3275

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-08-02 16:48:27 +01:00
Marc Herbert af6bd41a99 logger: open /sys/debug/fw_version _after_ /sys/debug/[e]trace
Open /sys/kernel/debug/sof/fw_version _after_
/sys/kernel/debug/sof/[e]trace because reading the former is optional
and the latter is not.

So when the driver is not loaded, we get the same (missing trace) error
trace message whether we use the -n option or not.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-08-02 16:48:27 +01:00
Seppo Ingalsuo b0336346f7 [SKIP CI] Tools: Tune: SRC: Add missing gain to generate scripts
Patch a0ff2bb277 added field .gain to configuration data for
src_generate() but the previous generator scripts were not
updated to set it. This patch fixes in them the error about
undefined gain by setting it to previous -1 dB default.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-08-01 11:11:56 +01:00
Seppo Ingalsuo 978827f7fc [SKIP CI] Tools: Tune: SRC: Add to coefficients data Doxygen cond comments
This patch updates the SRC tool to export same guidance for
Doxygen as added by a previous patch for coefficients
header files. The added comments to begin and end are:

/** \cond GENERATED_BY_TOOLS_TUNE_SRC */
/** \endcond */

The impacted headers remain identical so they don't need update.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2022-08-01 11:11:56 +01:00
Pierre-Louis Bossart d87adcd2dc topology1: CMakeLists: add missing APL/GLK support for ES8336 with DMIC.
For some reason we added DMIC-based topologies for all platforms
except GLK and APL.

This should be back-ported to 2.2 stable.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-07-19 09:40:28 +01:00
Ranjani Sridharan b80fc03c4c tplg_parser: Add support for parsing process components by UUID
Add support for loading the process components by UUID. This needs a
modification in the IPC3 helper to modify the ipc data pointer to
address followed by the UUID in the component extended data.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-07-18 16:56:40 +01:00
Brent Lu 41e56b336d topology: sof-jsl-rt5682: enable mclk always-on feature
Enable the always-on feature for pop.

Signed-off-by: Brent Lu <brent.lu@intel.com>
2022-07-18 14:20:09 +01:00
Brent Lu 8dfc008b8b intel: ssp: implement mclk always-on feature
In the earliest design, mclk is turned on in set_config() and never
turned off. The behavior is modified in this commit:

d5840a9200 ("ssp: move mclk request/release to pre_start and post_stop")

Now the mclk is enabled only during audio streaming so some codec may
pop. This commit adds the always-on behavior back as an new feature.

Signed-off-by: Brent Lu <brent.lu@intel.com>
2022-07-18 14:20:09 +01:00
Fred Oh 23e81f7c20 topology2: cavs: add mixer-based hda pipelines to passthrough hdmi tplg for mtl
First two pipelines are mixer-based HDA playback and capture pipelines.
Tested with ALC256 HDA codec.

Signed-off-by: Fred Oh <fred.oh@linux.intel.com>
2022-07-15 09:08:12 +01:00
Fred Oh fcca1c3b7c topology2: cavs: re-order cavs hda toplogies
Re-ordering CNL TGL to MTL and DMIC 2ch to 4ch.
No functionality change.

Signed-off-by: Fred Oh <fred.oh@linux.intel.com>
2022-07-15 09:08:12 +01:00
Pierre-Louis Bossart 4be016befc topology1: sof-tgl-rt711-rt1308: use EXT_AMP_REF for rt1316
RT1316 is exposed by the machine driver as having an echo reference,
so the indices are different from the regular ones.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-07-12 09:34:39 +01:00
Pierre-Louis Bossart 04df9161cb topology1: sof-tgl-rt711-rt1308: make BT_OFFLOAD a CMakeFiles parameter
Somehow we assumed that all ADL platforms support BT_OFFLOAD. Wrong,
this is only valid for Chromebooks and needs to be set externally in
the CMakeFiles definitions.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-07-12 09:34:39 +01:00
Pierre-Louis Bossart 7666716e12 topology1: CMakeLists: add topology for HP Omen 16
RT711 on link0 and RT1316 on link3.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-07-12 09:34:39 +01:00
Pierre-Louis Bossart e70fd0fbf7 topology1: sof-tgl-rt711-rt1308: make amplifier link configuration
HP Omen 16 devices have an amplifier on link3, add the required
configuration macro.

BugLink: https://github.com/thesofproject/linux/issues/3727
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-07-12 09:34:39 +01:00
Pierre-Louis Bossart 9d9c28848d topology1: generate new sof-hda-generic version for 2ch PDM1
Generate 2 files for 1 and 2ch cases.

These topologies can be used by setting

options snd-sof-pci tplg_filename=<file>

in /etc/modprobe.d/alsa-base.conf

BugLink: https://github.com/thesofproject/sof/issues/5989
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-07-11 15:52:25 +01:00
Pierre-Louis Bossart 73fd9248e0 topology1: intel-generic-dmic: add macro to enable PDM1 for 2ch cases
There are multiple cases where we cannot detect that PDM1 is used
instead of the default PDM0.

BugLink: https://github.com/thesofproject/sof/issues/5989
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-07-11 15:52:25 +01:00
Bard Liao 606857bca5 topology2: cavs-passthrough-hdmi: use hdmi-generic.conf
hdmi-generic.conf can be used for all topologies with HDMI
support.

Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
2022-07-07 11:58:00 +01:00
Bard Liao 96ac486b58 topology2: add HDMI support on SDW
Create a hdmi-generic.conf and use it in cavs-sdw.conf to add
HDMI support

Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
2022-07-07 11:58:00 +01:00
Bard Liao c97fb30f97 topology2: sdw-cavs: add dmic support
Add PCH DMIC support for MTL RVP with dmic01 id = 2 and dmic16k id = 3.

Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
2022-07-07 11:58:00 +01:00
Bard Liao 73f4f86d73 topology2: remove pipeline format parameter
The "format" parameter is never used by IPC4. And it should not be
mandatory.

Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
2022-07-07 11:58:00 +01:00
Marc Herbert 5dfaf0bf80 sof_ri_info: memory layout: find 'tgl' in ___/build_tgl_xcc/sof.ri
Extend the search for the platform code in directory names when there is
no sof-tgl.ri match.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-07-07 11:53:11 +01:00
Marc Herbert 0f365400eb sof_ri_info: explain why memory layout is empty
It was not obvious at all that the expected memory layout is inferred
from the filename.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-07-07 11:53:11 +01:00
Bard Liao 67daf2ecf5 topology2: add num_audio_formats for gain
We should set num_audio_formats in pipelines when we remove the
default value from gain.conf.
Otherwise, we will see below error with cavs-mixin-mixout-hda-2ch-tgl.tplg
tplg: ready widget id 2 pipe 1 type 6 name : gain.1.1 stream none

Fixes: 773a05a3 ('topology2: add S24LE support')
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
2022-07-04 15:53:06 +01:00
Yong Zhi 45f6d6fa59 topology2: cavs: hda: add tplg build for mtl
Add the topology for skl_hda_dsp_generic machine.

Signed-off-by: Yong Zhi <yong.zhi@intel.com>
2022-07-04 15:28:47 +01:00
Joe.Cheng 2cad1764e4 topology1:renoir:add DTS topology
Add topology pipe-dts-codec-playback to support Renoir platform

Signed-off-by: Joe.Cheng <joe.cheng@xperi.com>
2022-06-29 13:10:33 +01:00
balapati 5c4ca781ec tools:topology: Add HS topology
Add HS I2S instance topolgy for Rembrandt target.

Signed-off-by: balapati <balakishore.pati@amd.com>
2022-06-29 13:00:26 +01:00
Pierre-Louis Bossart c8551e3563 topology1: sof-tgl-rt711-rt1308: add missing switch
For some reason we never added the switch in this topology, with leads
to a missing control when parsing UCM files

BugLink: https://github.com/thesofproject/sof/issues/5950
BugLink: https://github.com/alsa-project/alsa-ucm-conf/issues/179
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-06-29 12:29:45 +01:00
Rander Wang 773a05a32e topology2: add S24LE support
S24LE is the major format used by SOF IPC4 FW and windows platform
and has better perfomance than S32.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-06-29 12:27:24 +01:00
Rander Wang bf65c0783d topology2: add src support on sdw platform
Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-06-29 12:27:24 +01:00
Rander Wang 715233aac9 topology2: add pipeline for src
This pipeline supports conversion from 8k ~ 192k to 48k.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-06-29 12:27:24 +01:00
Rander Wang 7b6d395aca topology2: add cavs src support
Cavs src is different with sof src. It has different uuid
and param which are composed of base module definition and
output rate.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-06-29 12:27:24 +01:00
Rander Wang 3f12097f36 topology2: add support for sampling rate
The original calculation will generate 44 sample size for
44.1khz, actually it at least needs 45 sample size.
This patch uses ceil value for such rate, also inlcude
11.025kh, 22.05kh, 88.2khz, 176.4khz.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2022-06-29 12:27:24 +01:00
Kehuang Li 60df52d454 component: add initial post processing component and topology
Introduce a new component to perform configurable audio post processing
on playback path before smart amplifier.

1. Put google_audio_post_processing libs at $SOF_REPO/third_party/lib
   - libgoogle_audio_post_processing.a
   - libc++.a
   - libc++abi.a
2. Enable google_audio_post_processing in config override
   $SOF_REPO/src/arch/xtensa/configs/override
   CONFIG_COMP_GOOGLE_AUDIO_POST_PROCESSING=y
3. Build the firmware and tool with xcc
4. To verify it works:
   - aplay some audio
   - amixer and grep GAPP
   - sof-ctl to get/set control

Signed-off-by: Kehuang Li <kehuangli@google.com>
2022-06-20 16:06:17 +01:00
Ranjani Sridharan c40743ec8d testbench: add support for parsing UUID
In preparation for comverting the volume component to use the module
interface, add support for parsing the UUID from topology when parsing
the PGA widget in testbench.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2022-06-10 09:50:08 +01:00
Pierre-Louis Bossart 51f2b1fe8e topology2: cavs: cavs-mixin-mixout-hda: use macro for DAI name
The copier 'stream_name' and dai 'name' need to match, use macro to
enforce consistency.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-06-09 14:41:40 +01:00
Pierre-Louis Bossart 1ef9979c73 topology2/cavs/cavs-mixin-mixout-hda: remove pipeline object from widget
The pipeline stream_name is not used at all, and as a consequence we
can remove the pipeline from the Widget objects

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-06-09 14:41:40 +01:00
Pierre-Louis Bossart e21649c109 topology2: cavs: use macro for PCM devices
The same 'Analog Playback' string is used for the copier stream_name
and PCM caps name. This is not a coincidence but a requirement to
match PCM and widgets. Same for 'Analog Capture'

Use a macro to make sure this 1:1 mapping is not broken.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-06-09 14:41:40 +01:00
Pierre-Louis Bossart 80c1cb0deb topology2: cavs: rename mixin-capture as dai-copier-gain-mixin-capture
Be exhaustive on pipeline contents.

Also remove Windows references and copy/pasted comments

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-06-09 14:41:40 +01:00
Pierre-Louis Bossart 660c9d2617 topology2: cavs: rename mixout-capture as mixout-gain-host-copier-capture
Be exhaustive on pipeline contents.

Also remove Windows references and copy/pasted comments

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-06-09 14:41:40 +01:00
Pierre-Louis Bossart 6a8eb721f2 topology2: cavs: rename mixin-playback as host-copier-gain-mixin-playback
Be exhaustive on pipeline contents.

Also remove Windows references and copy/pasted comments

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-06-09 14:41:40 +01:00
Pierre-Louis Bossart a5d568edb0 topology2: cavs: rename mixout-playback as mixout-gain-dai-copier-playback
Be exhaustive on pipeline contents.

Also remove Windows references and copy/pasted comments

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-06-09 14:41:40 +01:00
Pierre-Louis Bossart dbd0ab3493 topology2: cavs: remove mixout-gain-playback
there's already a gain in mixout-playback, and mixout-gain-playback is
not used anywhere.

let's reduce the options

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2022-06-09 14:41:40 +01:00