This will significantly speed up CI in some cases.
Fixes commit ffdf001eee ("xtensa-build-zephyr.py: clone zephyr with
--depth 5")
When I added --depth 5 to git clone in that commit I naively assumed git
fetch would "inherit" that. I think it does but only when fetching an
_existing_ (and shallow) branch, not when fetching something new.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Remove the assumption that the AEC reference was coming from a DEMUX.
It now uses the fact that the AEC reference comes from another pipeline
in order to detect it is the reference signal.
Signed-off-by: Lionel Koenig <lionelk@google.com>
To track the docker images, need to keep all the hashes of the projects
builts in the image. Log git tree information to
/home/sof/work/sof_git_hash.txt in the docker image.
Signed-off-by: Fred Oh <fred.oh@linux.intel.com>
This fixes the sof-docs build and stops producing a dai-drivers-api.html
garbage that randomly mixed the two .h files.
```
Warning: Duplicate target detected:
group__sof__dai__drivers_1ga8c720c310f408b2f97ce014562d6a910
sof-docs/api/dai-drivers-api.rst:4: WARNING: Duplicate ID:
"group__sof__dai__drivers_1ga8c720c310f408b2f97ce014562d6a910".
sof-docs/api/dai-drivers-api.rst:4: WARNING: Duplicate explicit target name:
"group__sof__dai__drivers_1ga8c720c310f408b2f97ce014562d6a910".
sof/sof-docs/api/dai-drivers-api.rst:6: WARNING:
Duplicate declaration, const struct device* dai::drv
```
(Temporarily?) fixes commit 015ec63c4d ("zephyr: add glue code to
use zephyr dai drivers") that introduced a lot of duplication with
dai-zephyr.h. See more details at
https://github.com/thesofproject/sof/pull/5731#issuecomment-1175630147
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Fixes doxygen warning:
warning: Included by graph for 'src.h' not generated, too many
nodes (111), threshold is 50. Consider increasing DOT_GRAPH_MAX_NODES.
This code is generated and pollutes doxygen output anyway.
Temporary, manual solution until the `\cond` directive is also generated
by the sof/tools/tune/src/*export*.m script(s)
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Fixes doxygen warning:
warning: Include graph for 'src_ipc4_int32_table.h' not generated, too
many nodes (89), threshold is 50. Consider increasing
DOT_GRAPH_MAX_NODES.
This code is generated and pollutes doxygen output anyway.
Temporary, manual solution until the `\cond` directive is also generated
by the sof/tools/tune/src/*export*.m script(s)
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
This should upgrade doxygen from version 1.8.17 to 1.9.1
This will hopefully provide FAIL_ON_WARNINGS and fix issues like
https://github.com/doxygen/doxygen/issues/7970
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
There are some restrictions when --fw-naming is set to 'AVS' for the
sake of providing reasonable FW outputs that make sense.
Restriction 1: When argument fw_naming is set as AVS, IPC4 ipc version
will be automatically chosen.
This is because --fw-naming 'AVS' is added for supporting IPC4 SOF build by
nature.
Restriction 2: When argument fw_naming is set as AVS, using platform
subdirectories will be automatically chosen.
The reason is that the platform subdirectories actually belong to the
"AVS" naming scheme, we must enable using platform subdirectories when
building FW in AVS naming convention.
This also ensure that we can tell firmwares of different platforms apart
by organizing them in different subdirectories.
Signed-off-by: Xiaoyun Wu(Iris) <xiaoyun.wu@intel.com>
Add argument option --fw-naming for specifying FW output with its
filename set with AVS style(filename as dsp_basefw.bin specifically)
OR SOF style(filename as sof-{platform}.ri). SOF style is by default.
This will be useful when building SOF+Zephyr IPC4 FW, because
dsp_basefw.bin will be loaded by default when snd_sof_pci parameter
ipc_type is set to 1 (which indicates running IPC4 mode).
Signed-off-by: Iris Wu <xiaoyun.wu@intel.com>
From time to time sof-docs regressions are introduced in sof.git. This
introduces a random and sometimes long delay between when the regression
is introduced and when it is found. A recent example is
https://github.com/thesofproject/sof/pull/5731#issuecomment-1175630147
where the doxygen comments were duplicated. Doxygen alone did not mind,
then the sof-docs build failed much later which took multiple people a
lot of time to understand and bisect.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Optimize the read frags of copier module in function
apply_attenuation. By using the optimized function
audio_stream_samples_without_wrap_s32, we can reduce
the address judgment and save about 60% MCPS.
Signed-off-by: Andrula Song <xiaoyuan.song@intel.com>
Quoting https://github.com/zephyrproject-rtos/zephyr/pull/46880#pullrequestreview-1020096140
> No complaints about the code here. Just a general comment:
> I do worry that as cavstool grows features (first to add the test
> integration support, now the new client/server architecture) that
> we're obscuring the core code that does the loading behind a big
> facade of other stuff that also has to be run In Just The Right Way to
> make things work. That impedes development flow. It might be time to
> split the code up so that a minimal "just run this file please" tool
> can continue to be maintained.`
Long story short: `cavstool.py` is likely to be split in the future.
To be readi-er, copy the entire `zephyr/soc/xtensa/intel_adsp/tools/`
directory.
Copying the entire directory also copies scripts that will never be used
on a test device like `cavstool_client.py`. They're small Python script
sso we don't care: keep it simple.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
When the host pipeline and DAI pipelines have the same scheduling
period, the host pipeline will be prioritized over the DAI pipeline when
the scheduler picks a task to execute after receiving a pipeline trigger
IPC.
But in the case that the host pipeline's scheduling period is larger
than that of DAI pipeline, the DAI pipeline task will likely get
executed before the host pipeline gets the chance to execute the trigger
command. And when this happens, the state of the aborted flag is
insufficient to determine if the pipeline task should be kept running or
completed. For example, consider the mixer based pipelines in the
nocodec topology:
PCM0 (pipeline 11, 1ms period) ---> Volume -----|
V
Mixer (Pipeline 1, 1ms)----> SSP0
^
PCM3 (pipeline 7, 10ms period ) ---> Volume -----|
When PCM 3 is started and the START trigger completes, the aborted flag
for pipelines 7 iand pipeline 1 will be reset. And when PCM 3 is paused,
the PAUSE trigger is scheduled for both the pipelines 7 and 1. But since
pipeline 1 has a lower latency requirement than pipeline 7, it gets
scheduled first and because it is not the host pipeline, the trigger is
not executed and the aborted flag is not set, the task gets completed and
a subsequent release for PCM 3 ends up in an IPC timeout.
To fix this, add a new flag called pending to the pipeline trigger that
can be set when a pipeline trigger is scheduled for a pipeline. This flag
must be cleared when the first component in the pipeline executes it's
trigger op. This flag combined with the aborted flag are sufficient to
prevent the IPC timeouts for the cases where the DAI pipeline task executes
ahead of the host pipeline when the trigger has not been executed yet.
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Consider the mixer-based pipeline in the nocodec topologies:
PCM0 (pipeline 11) ---> Volume -----|
V
Mixer (Pipeline 1)----> SSP0
^
PCM3 (pipeline 7) ---> Volume -----|
When PCM0 is started it triggers pipelines 7 and 1. When PCM3 is
started followed by PCM0, it will trigger pipelines 11 and 1. But since
pipeline 1 is already is started, it's aborted flag will be set.
But the aborted flag is never cleared for pipeline 1 because it is
not the host pipeline.
Fix this, by clearing the aborted flag for non-host pipelines in
pipeline_task_cmd()
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
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>
Instead of acquiring and releasing buffers locally multiple times,
do that once for .copy() and .prepare() methods.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Instead of acquiring and releasing buffers locally multiple times,
do that once for .copy() and .prepare() methods.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Instead of acquiring and releasing buffers locally multiple times,
do that once for .copy() and .prepare() methods.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Instead of acquiring and releasing buffers locally multiple times,
do that once for the .copy() method.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Instead of acquiring and releasing buffers locally multiple times,
do that once for .copy(), .params() and .prepare() methods.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Instead of acquiring and releasing buffers locally multiple times,
do that once for .copy(), .trigger() and .prepare() methods.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Add multiple third-party and optional audio processing components to
the Zephyr cmake and initialisation lists.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Changed names of peak_meter_, current_volume_ and target_volume_
fields in the ipc4_peak_volume_regs structure to comply with the
convention used in the project - deleted postfix _.
Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
In the dai_free function, dma channel device data was cleared after calling
to dma_channel_put. This patch changes the order of the instructions so,
we don't reference a released channel.
Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
The gateway configuration structure in ipc4 can specify the size of a dma
buffer, what a interface should use. This patch adds support for it in dai
and host interfaces.
Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
This makes code easier to read and fixes checkpatch.pl warning:
WARNING: Possible repeated word: 'on'
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
when call pause and then call stop, it will cause next triger start failed
The reason:
for PAUSE, the state machine:SOF_TASK_STATE_CANCEL—>SOF_TASK_STATE_FREE
call STOP, the state machine:SOF_TASK_STATE_FREE—>SOF_TASK_STATE_CANCEL
Signed-off-by: honglin leng <a909204013@gmail.com>
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>
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>
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>