Commit Graph

10737 Commits

Author SHA1 Message Date
Adrian Warecki e5f337ba70 smex: elf: Fixed an error code returned when a file operation fails
If fseek reports an error, the error code set in errno is returned.
Improved handling an error during reading from a file. Now it distinguishes
between an error reported by the fread and insufficient data in a file.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-09-26 09:20:03 +01:00
Adrian Warecki 71418367e7 smex: elf: Added checking of value returned by file operation function
Added checking of the value returned by fseek function and added memory
release when an error is detected.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-09-26 09:20:03 +01:00
Adrian Warecki 877079af47 smex: elf: Removed unnecessary initialization of local variables
The values assigned when declaring variables were overwritten in the code.
Redundant initialization was removed.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
2023-09-26 09:20:03 +01:00
Tobiasz Dryjanski a63f6b61eb dcblock: remove buffer_acquire from dcblock
remove buffer ops from dcblock module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-25 20:52:51 +03:00
Tobiasz Dryjanski dc3169aa5a rtnr: remove buffer_acquire from rtnr.c
remove buffer ops from rtnr.c

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-25 20:52:51 +03:00
Tobiasz Dryjanski 1d4cca5610 mux: remove buffer_acquire from mux
remove buffer ops from mux module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-25 20:52:51 +03:00
Tobiasz Dryjanski b0f4605d97 multiband_drc: remove buffer_acquire from multiband_drc
remove buffer ops from multiband_drc module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-25 20:52:51 +03:00
Tobiasz Dryjanski 989a13c94c mfcc: remove buffer_acquire from mfcc
remove buffer ops from mfcc modules

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-25 20:52:51 +03:00
Tobiasz Dryjanski 352a465759 igo_nr: remove buffer_acquire from igo_nr
remove buffer ops from igo_nr module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-25 20:52:51 +03:00
Tobiasz Dryjanski fe91b3c97f eq: remove buffer_acquire from eq_fir and eq_iir
remove buffer ops from eq_fir and eq_iir modules

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-25 20:52:51 +03:00
Seppo Ingalsuo f57e478f4c Zephyr: Fix path to google_hotword_detect.c
The file is found from subdirectory src/audio/google. Without
fix if CONFIG_COMP_GOOGLE_HOTWORD_DETECT is enabled build fails:

CMake Error at sof/zephyr/cmake/modules/extensions.cmake:424
(add_library):
Cannot find source file:
/src/audio/google_hotword_detect.c

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-09-25 10:35:27 -07:00
Jaroslaw Stelter e4136a4e0e lnl: memory: expand HEAPMEM_SIZE
FW infrastructure shall support buffering of historic data
from 1ch up to 6 channels 24bit samples in 24bit container.
For this reason, the heap should be extended.Increase HEAPMEM_SIZE
by 0x90000 because for audio format 16000Hz/6ch/24bit
history_buffer_size = 16 * 6 * 3 * 2100s = 604800 bytes (0x93A80)

Signed-off-by: Jaroslaw Stelter <Jaroslaw.Stelter@intel.com>
2023-09-25 16:23:27 +01:00
Marc Herbert 2a9473a17b app/prj.conf: disable PICOLIBC with CONFIG_MINIMAL_LIBC=y
Starting from Zephyr commit f0daf904bb02, CONFIG_PICOLIBC is on by
default.

PICOLIBC does not seem compatible with sparse yet:
https://github.com/zephyrproject-rtos/zephyr/issues/63003

Even if it were compatible with sparse, it seems like a pretty big
change that we should not immediately and blindly accept.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2023-09-25 15:04:17 +03:00
Seppo Ingalsuo 2cdd11a95d Tools: Topology2: Remove 50 ms curve duration set from nocodec
We need to care about audio user experience and peak MCPS
usage in production topologies.

The alsabat test is disturbed by the longer ramp so the
change can be reverted from nocodec topologies. Those
topologies are never used by end users. Also the peak MCPS
mitigation is not relevant for test topologies, as long as
higher MCPS is not triggering error reports. The curve
duration is restored without explicit set to the default 20 ms.

Fixes: #8238
Fixes: d0d74a477f
       ("Tools: Topology2: Change in capture gain
       curve_duration to 50 m")

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-09-25 11:24:01 +01:00
Rander Wang beddfb360a topology2: Add 4ch audio formats for gain-capture pipeline
Add support in gain-capture pipeline to support 4ch DMIC stream.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2023-09-25 11:23:25 +01:00
Rander Wang e7a1592002 topology2: use input|output audio format
The old style is not used now.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2023-09-25 11:23:25 +01:00
Marc Herbert 8eedfe4836 .github: build-windows: choco install ninja
Ninja seems to have just mysteriously disappeared from
https://github.com/actions/runner-images/blob/win22/20230918.1/images/win/Windows2022-Readme.md
See #8250 for more details.

Let's try to install it explicitly.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2023-09-25 10:13:42 +03:00
Chao Song 75337b41eb topology2: remove duplicated pipeline index attribute definition
The pipeline-common.conf helps us to define several
common pipeline attributes include pipeline index,
there is no need to define pipeline index in each
pipeline class definition if pipeline-common.conf
is included.

Signed-off-by: Chao Song <chao.song@linux.intel.com>
2023-09-22 14:21:59 +01:00
Tobiasz Dryjanski d7ebc159d0 crossover: remove buffer_acquire from crossover
remove buffer ops from crossover module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-22 12:28:15 +03:00
Tobiasz Dryjanski 4f74ed7018 volume: remove buffer_acquire from volume
remove buffer ops from volume module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-22 12:28:15 +03:00
Tobiasz Dryjanski cd7e3d3e40 kpb: remove buffer_acquire from kpb
remove buffer ops from kpb module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-22 12:28:15 +03:00
Tobiasz Dryjanski d7957df17e chain_dma: remove buffer_acquire from chain_dma
remove buffer ops from chain_dma module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-22 12:28:15 +03:00
Tobiasz Dryjanski 4f42a65b66 asrc: remove buffer_acquire from asrc
remove buffer ops from asrc module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-22 12:28:15 +03:00
Tobiasz Dryjanski 9d0f0aad14 aria: remove buffer_acquire from aria
remove buffer ops from aria module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-22 12:28:15 +03:00
Tobiasz Dryjanski 08c6b7992e smart_amp: remove buffer_acquire from smart_amp
remove buffer ops from smart_amp module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-21 13:58:50 +03:00
Tobiasz Dryjanski a0256007e6 mixer: remove buffer_acquire from mixer
remove buffer ops from mixer modules

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-21 13:58:50 +03:00
Tobiasz Dryjanski f87fa4d6fa mixin/mixout: remove buffer_acquire from mixin/mixout
remove buffer ops from mixin/mixout module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-21 13:58:50 +03:00
Tobiasz Dryjanski 527e5f7d4b copier: remove buffer_acquire from copier
remove buffer ops from copier module

this is a continuation of changes
from commit 4a03699

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-21 13:58:50 +03:00
Chao Song b0afa39126 app: overlays: remove tgl and tgl-h ipc4 overlays
We build tgl and tgl-h with ipc4 by default, those
ipc4 overlays are empty now, can be removed safely.

Signed-off-by: Chao Song <chao.song@linux.intel.com>
2023-09-21 11:00:12 +03:00
Chao Song a17c2823d3 xtensa-build-zephyr: remove ipc option
For legacy CAVS platforms (TGL/ADL/EHL), the default
build config is IPC4 now, and the overlay file is
already emptied. Remove the option in this build
script.

Signed-off-by: Chao Song <chao.song@linux.intel.com>
2023-09-21 11:00:12 +03:00
Chao Song 5004d0fe1e zephyr.yml: remove ipc option for zephyr build
For TGL and TGL-H, IPC4 is the default build config,
remove the '-i IPC4' option as it is not needed
anymore.

Signed-off-by: Chao Song <chao.song@linux.intel.com>
2023-09-21 11:00:12 +03:00
Pierre-Louis Bossart 0912756595 topology2: intel: bt-ssp-config: use cardinal clock as source
All existing SSP-based topologies use the audio cardinal clock,
*EXCEPT* Bluetooth related ones. This doesn't make much sense, let's
use the same clock source for all SSPs.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2023-09-20 20:45:20 +03:00
Kai Vehmanen 1479462824 topology1: remove Intel CML and EHL topologies
These topologies are no longer supported by mainline firmware
code for these platforms. The stable-v2.2 branch continues to
support these targets.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2023-09-20 15:41:51 +01:00
Seppo Ingalsuo d0d74a477f Tools: Topology2: Change in capture gain curve_duration to 50 ms
This change increases the ramp duration from 20 ms to 50 ms. It
lowers the peak load of peak volume component due to longer same
gain value blocks. The internal update rate for gain becomes 250 us
instead of 125 us. The longer fade-in ramp also conceals better
possible analog capture start transients.

This changes for 4ch capture for gain.11.1 in sof-hda-generic-4ch.tplg
from

CPU_PEAK(MAX) = 21.95
PEAK(MAX)/AVG(AVG) = 7.51

to

CPU_PEAK(MAX) = 9.07
PEAK(MAX)/AVG(AVG) = 3.12

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2023-09-20 15:37:05 +01:00
Tobiasz Dryjanski f070135e04 kpb: Implement configuration part of fast mode task
This patch implements handling of the configuration IPC for FMT in KPB
module. KPB now saves the list of module instances to be processed by
FMT. This is the first step for implementing FMT functionality. In case
of WoV event, FMT is needed for KPB to drain history buffer and send
this data to Host ASAP, as normal tasks are too slow.

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-20 17:02:53 +03:00
Tobiasz Dryjanski fb2727536a ipc4: Add Vendor Config Set
Add Vendor Config Set, a special case of Large Config Set. Large Config Set
handling now checks for this case and extracts extended param_id from ipc
payload as param_id and handles the rest of the payload as usual. KPB now
uses extended param_id. Necessary for fast mode task configuration in KPB.

Signed-off-by: Tobiasz Dryjanski <tobiaszx.dryjanski@intel.com>
2023-09-20 17:02:53 +03:00
Kai Vehmanen f3c290f14b ipc4: logging: fix builds with mtrace and probes both disabled
If both SOF_PROBES and MTRACE logging backends are disabled at build
time, IPC4 build failed due to undefined ipc4_logging_enable_logs().
Fixes a bug in commit 1721f70426 ("logging: add logging through
probes").

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2023-09-20 15:08:29 +03:00
Daniel Baluta 7ca9a2eb8a driver: imx: Add PDM MICFIL driver
The Pulse Density Modulated Microphone Interface (MICFIL) is a popular
way to deliver audio from microphones to the processor in several
applications, such as mobile telephones. However, current digital-audio
systems use multibit audio signal (also known as multibit PCM) to
represent the signal. This block implements the required digital
interface to provide a 24-bits audio signal from a PDM microphone
bitstream in a configurable output sampling rate.

This patch adds initial support for PDM MICFIL IP found on i.MX8MP
board.

Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
2023-09-20 14:43:11 +03:00
Daniel Baluta 1b337ef437 imx: sdma: Fix sdma firmware selection
CONFIG_SDMA_SCRIPT_CODE is always defined (even if not selected
it defaults to empty string) so this is not a good way of including
sdma script code header file.

Make use of HAVE_SDMA_FIRMWARE boolean config in order to select
the sdma script code header.

Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
2023-09-20 14:43:11 +03:00
Marcin Szkudlinski b608ec840c pipeline: remove buffer_acquire from pipeline files
remove buffer ops from pipeline-graph.c and
pipeline-params.c

this is a continuation of changes
from commit 4a03699911

Signed-off-by: Marcin Szkudlinski <marcin.szkudlinski@intel.com>
2023-09-19 11:51:20 +03:00
Marcin Szkudlinski 4c895a56eb mod: remove buffer_acquire from module_adapter
This change removes all buffer_acquire/buffer_release
from module adapter

The change does not contain any optimalizations that now may
be easy to do. They will be introduced in separate PR

this is a continuation of changes
from commit 4a03699911

Signed-off-by: Marcin Szkudlinski <marcin.szkudlinski@intel.com>
2023-09-19 11:51:20 +03:00
Marcin Szkudlinski 7ca691dd24 ipc: remove buffer_acquire from ipc helpers
remove buffer_acquire / release from ipc helpers

this is a continuation of changes
from commit 4a03699911

Signed-off-by: Marcin Szkudlinski <marcin.szkudlinski@intel.com>
2023-09-19 11:51:20 +03:00
Marcin Szkudlinski dcc41ffac6 comp: remove buffer_acquire from component.h
remove 2 inline functions
comp_get_copy_limits_with_lock
comp_get_copy_limits_with_lock_frame_aligned

this is a continuation of changes
from commit 4a03699911

Signed-off-by: Marcin Szkudlinski <marcin.szkudlinski@intel.com>
2023-09-19 11:51:20 +03:00
Marcin Szkudlinski e4447e272a buf: remove buffer_acquire/release from buffer.c
remove unnecessary calls from buffer.c/h

this is a continuation of changes
from commit 4a03699911

Signed-off-by: Marcin Szkudlinski <marcin.szkudlinski@intel.com>
2023-09-19 11:51:20 +03:00
Adrian Warecki c9e0fc8c9a module_adapter: ModuleInitialSettingsConcrete: Fix possible null reference
The dataAs function can return null if the buffer size is smaller than the
size of the target structure. Added handler for this situation.

Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2023-09-19 09:35:32 +03:00
Vamshi Krishna Gopal 6f2475b086 topology1: Use DYNAMIC for ADL and RPL topologies
use dynamic for all the adl and rpl topologies except 3p(waves,DTS),
excluded Dell sdw topologies which are not tested.

Signed-off-by: Vamshi Krishna Gopal <vamshi.krishna.gopal@intel.com>
2023-09-18 19:09:57 +03:00
Guennadi Liakhovetski 0675b2af33 system-agent: remove an unused variable
sys_service_p in
src/audio/module_adapter/library/native_system_agent.c is unused,
remove it.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2023-09-18 18:56:00 +03:00
Kwasowiec, Fabiola 3b31adc259 helper: add a condition before updating the component direction
At the pipeline reset stage, the direction of the components
is not always known, resulting in a call to a field that is null
and consequently a crash/timeout.

Signed-off-by: Kwasowiec, Fabiola <fabiola.kwasowiec@intel.com>
2023-09-18 15:23:16 +03:00
Daniel Baluta 57cb19ecec drivers: imx: sai: Fix frame size computation
When I2S-like interface is enabled we must have
2 words in a frame because this is how I2S works (it has 2 channels)!

So, even if the user plays a mono file we must configure 2 words per
slot and the second slot will be masked so the users will get silence
on the second channel.

Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
2023-09-18 12:01:49 +03:00
Andrula Song 2ede148444 Audio: use struct dai_ts_cfg replace timestamp_cfg
Use struct dai_ts_cfg replace timestamp_cfg of struct
dai_data in dai-zephyr.h

Signed-off-by: Andrula Song <andrula.song@intel.com>
2023-09-18 11:36:13 +03:00