Commit Graph

336 Commits

Author SHA1 Message Date
Adrian Bonislawski fea2a30e56 mtl: fill in cps and cpc data for smart_amp_test module
Fill in measured cps consumption data for SMATEST module

Signed-off-by: Adrian Bonislawski <adrian.bonislawski@intel.com>
2023-08-28 11:51:31 +01:00
Krzysztof Frydryk 476d63608b mtl: fill in cps and cpc data for ASRC module
Fill in measured cps consumption data for ASRC module for various
formats.

Signed-off-by: Krzysztof Frydryk <krzysztofx.frydryk@intel.com>
2023-08-28 11:51:31 +01:00
Krzysztof Frydryk 352f01fee4 mtl: fill in subsequent measured cps and mcps data
Fill in measured cps consumption data for: mixin, mixout, copier,
peakvol, gain, src, updwnmixer for a range of supported formats.

Signed-off-by: Krzysztof Frydryk <krzysztofx.frydryk@intel.com>
2023-08-28 11:51:31 +01:00
Krzysztof Frydryk c183ce2739 mtl: add measured cps and cpc values
Add CPS and CPC consumptions for given modules

Signed-off-by: Krzysztof Frydryk <krzysztofx.frydryk@intel.com>
2023-08-28 11:51:31 +01:00
Seppo Ingalsuo 43eb2a435c Config: Add crossover component for MTL and LNL platforms
This PR adds the crossover component for MTL and LNL. The
parameters are copied from TGL and TGL-H configuration of
crossover.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-08-28 11:51:08 +01:00
Kai Vehmanen 4fb9fe0057 config: lnl+mtl: fix length of ADSP.man CSE manifest
The ADSP.man contents is different for ACE_V1_5 layout
compared to CAVS_V2_5 layout. so the ADSP.man length should
be adjusted accordingly.

With this fix, sof_ri_info.py can be used to analyze
LNL and MTL firmware images created with rimage.

Closes: https://github.com/thesofproject/sof/issues/8073
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2023-08-25 10:56:41 +03:00
Seppo Ingalsuo c809af8168 Config: Add crossover component for TGL and TGL-H cAVS platforms
The configuration is for now copy from IIR, name and UUID are
changed. The init_config is set to 1 to let kernel know that the
base_cfg_ext is passed to firmware.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-08-11 12:17:58 +03:00
Curtis Malainey 8c8440070a style: trailing whitespace is the root of all evil
Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
2023-07-31 11:20:35 +01:00
Curtis Malainey d20f1d8a85 actions: remove travis
We removed them from the main repo, lets remove them here too.

Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
2023-07-31 11:19:52 +01:00
Seppo Ingalsuo af9a2fe58f Config: Fix comment typo for EQ FIR module
The comment for FIR module entry is corrected.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-07-26 16:08:43 +01:00
Seppo Ingalsuo b8ee1aa8f6 Config: Add DRC component to TGL, TGL-H, MTL, LNL
This patch allows to load the DRC component.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-07-26 16:08:43 +01:00
Marc Herbert aa0ac9eae6 rimage.c: fix bug where -p requires a new and ignored parameter
Fixes commit 6e3abe6afe ("rimage: Add suport for loadable modules")

It looks like that commit mistook the `:` sign as a separator. This
accidentally added the requirement to give `-p` a parameter which is
then ignored. Remove the spurious `:`.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2023-07-12 12:48:25 +03:00
SaiSurya, Ch 48777207f5 config: add vangogh toml file to support vangogh build
Add vangogh toml file to support sof-vangogh.ri binary build

Signed-off-by: SaiSurya, Ch <saisurya.chakkaveeravenkatanaga@amd.com>
2023-07-04 10:20:01 +01:00
Seppo Ingalsuo 089157d461 Config: Add Aria module to tgl-cavs.toml and tgl-h-cavs.toml
This patch adds Aria module for TGL and TGL-H platforms. The
used configuration data is copy from mtl.toml. This change
allows to use Aria component in topologies.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-07-04 10:18:31 +01:00
Jaroslaw Stelter 4ce79b152e kpb: update kpb uuid for lnl
Change of uuid
regarding Windows compatibility

Signed-off-by: Jaroslaw Stelter <Jaroslaw.Stelter@intel.com>
2023-06-01 17:57:20 +02:00
Paul Olaru 649b0a6790 file_simple: Allocate correct buffer size for writing sections out
The original size given to the "calloc" call did not account for the
necessity to pad section sizes to a multiple of 4 bytes. As such, every
time we wrote a section that did not have a size multiple of 4 we would
overflow the allocated buffer.

Fix the calloc call to account for that padding requirement.

Signed-off-by: Paul Olaru <paul.olaru@nxp.com>
2023-05-30 22:31:53 +03:00
Marc Herbert 1ea1327b9c README.md: remove "install" target
Fixes commit 77d4a2acd7 ("cmake: remove "install" target")

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2023-05-25 12:34:53 -07:00
Seppo Ingalsuo 8f250a99eb Config: Change indent for SRCINTC
This patch removes one unnecessary tab from section for SRCINTC.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-04-27 21:03:44 +03:00
Seppo Ingalsuo acd8a2bc1b Config: Change SRCINTC for tgl-cavs.toml and tgl-h-cavs.toml to LL
The SRC should be a normal LL component, it can process 1 ms blocks
of audio in real-time. The domain_types = "1" is for DP scheduling
that is not enabled currently in Zephyr configuration. It causes a
pipeline prepare fail when a topology contains SRC.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-04-27 21:03:44 +03:00
Marc Herbert 77d4a2acd7 cmake: remove "install" target
The deleted "install" target copied only the rimage executable and
left the config files behind. This gave the wrong impression that the
executable is useful without config files.

"Installing" also gave the wrong impression that rimage versions are
somewhat stable and relatively independent of SOF versions: they're
not. In fact there is no such thing as an rimage "version": everyone
should always use the exact rimage _git commit_ from the west manifest
or git submodule. There are no rimage "releases" and no semantic
versioning or anything like it, rimage is effectively part of the SOF
source and build and run directly from its build directory by
practically every SOF developer and SOF CI thanks to

  sof/src/arch/xtensa/CMakeLists.txt#ExternalProject_Add(rimage_ep ...
  sof/scripts/xtensa-build-zephyr.py#def build_rimage()
  sof/zephyr/CMakeLists.txt#set(RIMAGE_CONFIG_PATH ...

etc.

Providing an "install" target greatly increases the chances of
different people and CIs using different rimage versions which is the
last thing we want considering the many significant rimage changes
happening right now, examples:

- https://github.com/zephyrproject-rtos/zephyr/pull/56099
- https://github.com/zephyrproject-rtos/zephyr/pull/54700
- https://github.com/thesofproject/sof/issues/7270
- https://github.com/thesofproject/sof/issues/7304
- https://github.com/thesofproject/sof/pull/7320
- https://github.com/thesofproject/rimage/pull/155

While it's useful for multiple files (e.g.: config files), a CMake
target was always overkill to copy a single file. Someone or some
script who really wants to copy the rimage binary to some other place
that the build directory for some (discouraged) reason _can still do
so_ with a much more basic, simpler and more transparent file copy
command.

Finally, the default "bin" DESTINATION required root access which
is otherwise totally unncessary to build SOF.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2023-04-26 18:53:13 +03:00
Adrian Warecki ab0429fdbe Fix: Use module manifest from toml as a template for elf modules
Some platforms (eg. tgl) dont have modules configuration in a toml files.
An attempt to use the configuration template ended with a reference to
a null pointer. This commit fixes this issue.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-06 21:29:56 +01:00
Adrian Warecki 25804e7dc8 manifest: Use module manifest from toml as a template for elf modules
The manifest for elf modules is read from their .module section.
The modules configuration parsed from a toml file was completely ignored.
After this change, the parsed configuration is treated as a template for
the module manifest.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Adrian Warecki debf4cf605 manifest: Move MAN_MAX_SIZE_V1_8 define to the public manifest header
Currently, sof incorrectly includes a private manifest.h header belonging
to the manifest.c module. Moved the MAN_MAX_SIZE_V1_8 definition used by
sof, to the public manifest header to allow sof to switch to using the
correct file.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Adrian Warecki 6e3abe6afe rimage: Add suport for loadable modules
A new -l parameter has been added to the program's command line. It
instructs the program to not treat the first module as a bootloader
and not to skip the bss section for it.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Adrian Warecki 1bda0c5254 manifest_module: Add is_bootloader field
A is_bootloader field has been added to determine whether a module is
a bootloader. This is clearer than checking the module index and the number
of modules in different places in the program.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Adrian Warecki 7367fdf1e6 manifest_module: rename fw_size to output_size
Changed the name of the fw_size variable to a more clear one and added
a description.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Adrian Warecki 99195d2ee6 rimage: manifest: Rename struct module to manifest_module
Changing the name of the structure type is a prelude to separating
information about the elf file from the information used during creation
of a manifest.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Adrian Warecki 9ecae53e28 rimage: Moved memory alias configuration to a new struct
A new memory_alias structure containing memory address alias configurations
has been created. It was placed in the memory_config structure.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Adrian Warecki b9ecb0072d rimage: adsp_config: Create new memory_config structure.
Moved mem_zone field from adsp structure to the new memory_config structure

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Adrian Warecki d20916066e misc_utils: Added functions to print enum and flags value
Added name_val structure representing name/value tuple. Added function
print_enum which displays the name of the enum corresponding to a given
value. Added print_flags function which display names of flags constituting
a given value.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Adrian Warecki c21018335a Remove unused dram_offset field / config option
There was no dram_offset value in any configuration file. It also wasn't
used anywhere in the code. So the code reading it from the tolm file has
been removed.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Adrian Warecki 9633c3b66f manifest: Check return value of man_create_modules
The man_create_modules function may return an error that was ignored. Added
check of a return value.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Adrian Warecki b2177e5585 elf: Add header guard to elf.h
Added header guard in elf.h file to allow safe include this header by
multiple units.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-04-05 14:06:01 +01:00
Kwasowiec, Fabiola 9643a986dd kpb: update UUID
Change of uuid
regarding Windows compatibility

Signed-off-by: Kwasowiec, Fabiola <fabiola.kwasowiec@intel.com>
2023-04-03 14:03:47 +02:00
Jaroslaw Stelter 01fd742605 lnl: Add LNL configuration file
Add base LNL config derived from MTL.

Signed-off-by: Jaroslaw Stelter <Jaroslaw.Stelter@intel.com>
2023-04-03 14:43:07 +03:00
Kai Vehmanen 1bf447c8c2 config: tgl-h-cavs: align modules to tgl-cavs config
Update the list of modules to match that of "tgl-cavs".

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2023-04-03 14:42:37 +03:00
Guennadi Liakhovetski 63eb6ffb0a cAVS: add alias definitions to cAVS 1.5-2.0
cAVS 1.5, 1.8 and 2.0 are supported by Zephyr, their configurations
need alias definitions.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2023-03-21 17:44:57 +02:00
Guennadi Liakhovetski 343b6d863d Revert "config:tgl/tglh: Do not set cached/uncached address aliases"
Now that rimage can distinguish between Zephyr and XTOS builds, we
can use memory alias specifiers with both.

This reverts commit 1e0a85b44a.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2023-03-17 18:33:52 +02:00
Adrian Warecki 125745bcad file_utils: Fix error detection in get_file_size function
The fseek function returns -1 to signal an error. Return value was assigned
to a variable without a sign, so the error could not be detected.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-03-08 14:46:46 +01:00
Adrian Warecki 4aacac3460 Use file_error function to print file related errors
Added error handling where it was missing. According to the documentation,
the fseek function returns a non-zero value on error. The conditions for
checking this value have been corrected.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-03-08 14:46:46 +01:00
Adrian Warecki 32a5388c10 file_utils: Add file_error function
Added a generic function that displays a file operation error message.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-03-08 14:46:46 +01:00
Adrian Warecki dd15443129 file_utils: Removed duplicated function descriptions
Functions are already described in the header file.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-03-08 14:46:46 +01:00
Przemyslaw Blaszkowski d32db50b61 mtl: add Aria module to extended manifest
Add ARIA module to MTL extended manifest.

Signed-off-by: Przemyslaw Blaszkowski <przemyslaw.blaszkowski@intel.com>
2023-03-06 13:20:34 +00:00
Chao Song 5bc201039d rimage: fix build error
Recent changes introduce build error, fix the build
error.

Signed-off-by: Chao Song <chao.song@linux.intel.com>
2023-03-06 13:17:21 +00:00
Rander Wang 35bc64467a mtl: add eq-iir and fir support
Port from tgl-cavs.toml

Signed-off-by: Rander Wang <rander.wang@intel.com>
2023-03-06 12:23:48 +00:00
Adrian Warecki 6fad35625f rimage: Removed hash context from image structure
Fields related to hash computing have been removed from the image
structure. Removed openssl headers from rimage.h, which made it necessary
to add some missing includes in several files.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-03-02 15:55:03 +01:00
Adrian Warecki 6c7a1512c6 hash: Remove old hash functions
Removed currently unused functions.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-03-02 15:55:03 +01:00
Adrian Warecki d258ea23fc manifest: pkcs1_5: Use new hash functions
Switched to use new hash functions. The parameter list for the rimage_sign
and rimage_verify functions has been simplified. The necessary information
is now included in the hash_context structure. In addition, code fragments
that may be common to different versions of the manifest have been
separated.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-03-02 15:55:03 +01:00
Adrian Warecki 2bd8be35d2 hash: New hash functions
Prepared a new set of functions for computing digest with error handling.
The hash context has been placed into a separate structure. This allows
to conveniently pass the calculated digest along with its length and used
algorithm.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-03-02 15:55:03 +01:00
Adrian Warecki 93c5e8b51f misc_utils: Move byte_swap function to new misc_utils.c file
This function will be used in different places in the code, so I moved it
to a separate file.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-03-02 15:55:03 +01:00