Commit Graph

3682 Commits

Author SHA1 Message Date
Curtis Malainey 1571af188b topology: cht-max98090 add missing virtual widgets
Topology will fail to probe without these widgets

Signed-off-by: Curtis Malainey <cujomalainey@google.com>
2019-09-20 11:44:19 +02:00
Liam Girdwood 25c8990d39 fuzzer: add BSW platform and fix fw_ready for CHT.
CHT was missing fw_ready callback. Add BSW platform.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-20 10:09:17 +01:00
Liam Girdwood 689ce5ac99 fuzzer: byt: align macros to line length limit.
Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-20 10:09:17 +01:00
Liam Girdwood 224f177020 fuzzer: add support for HSW and BDW platforms.
Can now send fuzzing IPCs and topologies to HSW/BDW VMs.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-20 10:09:17 +01:00
Liam Girdwood bf72bf7a7b fuzzer: cleanup mailbox platform abstraction
Pass mailbox as parameter and add convenience helper for platform ops.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-20 10:09:17 +01:00
Liam Girdwood 29a9b9d529 fuzzer: add more logging and cleanup printf
provide more detail to the user and print to stdout.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-20 10:09:17 +01:00
Liam Girdwood c33e1a3677 fuzzer: no need for extra new line.
message already contains the newline.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-20 10:09:17 +01:00
Liam Girdwood 5dce3fb8fb fuzzer: fix return value of topology loader.
Return the real error code.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-20 10:09:17 +01:00
Liam Girdwood 8cd194e624 fuzzer: fix fuzzer hardcoding of topology.
Command line option was ignored. Fix it.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-20 10:09:17 +01:00
Pan Xiuli b0bb5a33c8 scripts: qemu: fix qemu check for BDW and HSW
The qemu for BDW and HSW removed shm mbox and moved it into dram.
Change the scripts to the new version.

Signed-off-by: Pan Xiuli <xiuli.pan@linux.intel.com>
2019-09-19 15:36:59 +01:00
Tomasz Lauda 0bed38788e timer: remove unused core field
Removes unused core field from timer structure.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Tomasz Lauda 7325dda291 timer: remove unused timesource_data structure
Removes structure timesource_data, which is no longer used.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Tomasz Lauda 0e6f3a9fe4 platform: rename PLATFORM_WORKQ_DEFAULT_TIMEOUT define
Renames define PLATFORM_WORKQ_DEFAULT_TIMEOUT to
PLATFORM_LL_DEFAULT_TIMEOUT.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Tomasz Lauda ec0570483d platform: remove unused PLATFORM_WORKQ_CLOCK define
Removes unused define PLATFORM_WORKQ_CLOCK.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Tomasz Lauda 93ecfe671a agent: use PLATFORM_DEFAULT_CLOCK
Changes clock used by agent to PLATFORM_DEFAULT_CLOCK.
Previously used PLATFORM_WORKQ_CLOCK also has value of
PLATFORM_DEFAULT_CLOCK.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Tomasz Lauda e95edfe48d platform: remove unused PLATFORM_WORKQ_WINDOW define
Removes unused define PLATFORM_WORKQ_WINDOW.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Tomasz Lauda 0f1f3d1222 platform: remove unused PLATFORM_LINK_DMA_TIMEOUT define
Removes unused define PLATFORM_LINK_DMA_TIMEOUT.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Tomasz Lauda 7d5842f300 ll_schedule: use ll_schedule_domain in ll_schedule
Refactors ll scheduler in order to incorporate the usage
of ll scheduling domain. Functionally it stays the same.
Now we use data shared in ll_schedule_domain instead
of allocating shared ll context.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Tomasz Lauda a4b4d5ff2b notifier: add macro for getting clk notification id
Adds macro to simplify getting clock change notification id
based on the selected clock id.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Tomasz Lauda 8fa4c0013c schedule: add timer_domain
Adds first ll scheduler domain, which is timer.
Timer domain implementation is functionally the same,
as the implementation already used in ll_schedule.
It will replace the original ll_schedule one.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Tomasz Lauda 869b0c11e3 timer: save handler irq argument in scheduler
Changes timer API to save interrupt handler argument
in ll scheduler shared context instead of timer struct.
This way we will be able to share the same timer structure
between all the cores.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Tomasz Lauda 4ee233990e schedule: introduce ll_schedule_domain
This patch introduces new structure called ll_schedule_domain.
It will be used to initialize ll scheduler with different
types of scheduling time domains. Right now it's only working
based on timer interrupts, but will be extended.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-19 15:32:23 +01:00
Liam Girdwood 460c41aa66 tgl: platform: removed unused scheduling macros.
No longer used so remove.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-18 21:01:16 +02:00
Liam Girdwood 39874c5f6c mailbox: remove duplicated mailbox macro
Duplicates MAILBOX_SIZE

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-18 21:01:16 +02:00
Liam Girdwood 049411519e linker: Make sure config.h is used by all linker scripts and memory.h.
This was partially used in some scripts. Fix it so all scripts can use
config.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-18 21:01:16 +02:00
Liam Girdwood 9d560bba9e tools: build: use standard naming convention for build dirs.
Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-09-18 21:01:16 +02:00
Seppo Ingalsuo 81f8de93c5 Tools: Test: Updates for testbench to match other changes in SOF
This patch updates the locations of "make install" libraries default
install locations into shell script to run SRC test cases. The script
also now prints the used LD_LIBRARY path to ease setting up code
debugging.

The segfault of testbench executable is fixed by returning a valid
pointer reference instead of a NULL from test dummy function
arch_schedulers_get().  The rest of testbench version of schedule.c
was also updated to be like the current real version module.

Finally in the testbench.c main the file names string pointers are
initilizated to null as well as the word length parameter to avoid
a segfault if executable is started without command line arguments
to see the usage help text.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-09-18 20:50:50 +02:00
Seppo Ingalsuo 573e0b17b3 Tools: Audio quality test for ssh accessible device
This patch adds a shell script sof_test_perf.sh that measures
gain, frequency response, and total harmonic distortion plus
noise for a remote device.

Matlab or Octave is needed. The shell script launches by default
Octave to process the signal generation and test results analysis
scripts.

The remote device must be set to be accessible by ssh without
passwords. An external high quality USB sound card is recommended
as analog interface to connect to test device's analog interface.

The configuration file sof_test_perf_config.m must be edited for
the remote device's user account, audio device, audio format, and
capture sound card audio device, and audio format.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-09-17 15:40:29 +01:00
Bartosz Kokoszko 03d68261cf alloc: fix first free update in alloc_cont_blocks()
In alloc_cont_blocks() function after allocation we should
check whether new first_free block has been already used.
If it was used, we should find first not used block.

fixes #1714

Signed-off-by: Bartosz Kokoszko <bartoszx.kokoszko@linux.intel.com>
2019-09-17 09:22:42 +02:00
Jaska Uimonen 0d74d3a563 src: do not treat 0 size input data as error
Currently SRC returns error when 0 size input or output data is detected
and pipeline interpretes this as fatal xrun error. This could happen
for example when host dma has no time to fill in first iteration of
samples. So instead of error, return PPL_STATUS_PATH_STOP as SRC in the
middle of the pipeline should handle also occasional 0 size data.

Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
2019-09-17 09:22:19 +02:00
Tomasz Lauda 0ba3fec518 topology: byt: fix media pipeline period for nocodec
Fixes media pipeline period for nocodec byt and cht topologies.
Now codec and nocodec topologies are aligned in regards to pipe
configurations.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-16 16:14:59 +02:00
Tomasz Lauda 5bb4ce172c topology: remove accidentally added topologies
Removes topologies, which have been removed and accidentally
added again to the repository.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-16 16:14:59 +02:00
Marcin Maka 2339a62762 arch: xtensa: remove include constraint from wait.h
This header may be included by a platform specific, intermediate
wait() layer inserted between the lib and the architecture code.
Therefore the including unit should not be limited to lib only.

Signed-off-by: Marcin Maka <marcin.maka@linux.intel.com>
2019-09-16 12:59:34 +02:00
Marcin Maka ced0ea054c arch: xtensa: remove dependency on platform headers
Integration specific tweaks for xtensa architecture should
use Kconfig options selected for required platforms, not the
platform headers.

Signed-off-by: Marcin Maka <marcin.maka@linux.intel.com>
2019-09-16 12:59:34 +02:00
Marcin Maka 0f00c11531 cavs: pm: fix include of version header
Should include cavs/version to compile on < 1.8, not
the global version.h one.

Signed-off-by: Marcin Maka <marcin.maka@linux.intel.com>
2019-09-16 12:59:34 +02:00
Tomasz Lauda 2bd725df02 trace: move platform_trace_point to dedicated headers
Moves platform_trace_point macro from platform/platform.h
to platform/trace/trace.h. This way we don't need to
include platform header from generic sof/trace/trace.h.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-14 23:53:02 +02:00
Marcin Maka 94733aa588 task: remove edf specific elements from context switching layer
The context switching layer is a common mechanism for all
pre-emptive schedulers and should not depend on data types
defined for any specific one.

Signed-off-by: Marcin Maka <marcin.maka@linux.intel.com>
2019-09-13 14:35:18 +03:00
Tomasz Lauda e01c696337 common: add missing include
Adds missing include of stddef.h, which defines offsetof
macro.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-13 11:57:37 +02:00
Seppo Ingalsuo 92ec08dad5 Tools: Tune: Fix file paths for example FIR script
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-09-13 10:25:58 +01:00
Seppo Ingalsuo fa2f3a51ad Tools: Tune: Get SOF ABI header for EQs with sof-ctl
This patch avoids the need to main SOF ABI version information in
Matlab/Octave file eq_get_abi.m for equalizer tools. The ABI
header is fetched via new "-p" command line option for sof-ctl.

The BSD 3 clause copyright text is also updated to new short style.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-09-13 10:25:58 +01:00
Seppo Ingalsuo d013fbc6d7 Tools: Add current sof_abi_hdr struct print capability to sof-ctl
This patch adds command line option "-g" to generate and with help
of options "-o <file>" to store the current ABI version header data
into file. Use "-b" to change the default CSV format to binary.

It is used by external tools to create configuration data blobs for
SOF audio processing components.

The parameter for size is the configuration data payload size with
the size of sof_abi_hdr struct excluded. It does not impact the
the length of printed header. It just places the length into the
correct location in the header.

This patch also fixes the permissions of file output. The mode
need to be provided for open() to avoid having no access to
created file and allow overwrite of existing file.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-09-13 10:25:58 +01:00
Curtis Malainey 23d9c78a5c scripts: allocate tty on docker
Bash and menuconfig cannot run without this flag. Docker-run just hangs
without it

Signed-off-by: Curtis Malainey <cujomalainey@google.com>
2019-09-12 19:52:34 +01:00
Tomasz Lauda 8c61213c37 schedule: support dynamic scheduler creation
Refactors schedule code in order to allow dynamic scheduler
creation. We don't want to add every new scheduler to the static
array of scheduler_ops and also we don't want to have every
scheduler created on every platform. Maybe some of the platforms
won't need some of the future scheduler types.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-11 16:24:00 +02:00
Pan Xiuli b899489e49 topology: fix wrongly used SCHEDULE_DEADLINE
SCHEDULE_DEADLINE is replaced with SCHEDULE_PERIOD, but there is one
missed in DAI_ADD for W_PIPELINE.

Signed-off-by: Pan Xiuli <xiuli.pan@linux.intel.com>
2019-09-11 14:48:46 +02:00
Tomasz Lauda 09a44ab7c9 kpb: add missing flag to task init
Adds missing flag during draining task initialization.
It's needed at the moment, so the EDF scheduler can ignore
deadline for this task. Scheduling flags will be soon
refactored.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-09-10 23:08:12 +02:00
Marcin Rajwa 0242a5c0f8 pipeline: don't disable IRQs on prepare()
This patch removes the IRQ disable during
pipeline_prepare() as there is no potential
race condition. Also, the disable of IRQs
result in long delays in queued interrupts.

Signed-off-by: Marcin Rajwa <marcin.rajwa@linux.intel.com>
2019-09-10 16:24:42 +02:00
Marcin Rajwa 43b1cc428b pipeline: don't disable IRQs on params()
This patch removes the IRQ disable during
pipeline_params() as there is no potential
race condition. Also, The disable of IRQs
result in long delays in queued interrupts.

Signed-off-by: Marcin Rajwa <marcin.rajwa@linux.intel.com>
2019-09-10 16:24:42 +02:00
Jerome Laclavere 114692728a host: remove empty new line
Make code easier to read. Found using checkpatch.

Signed-off-by: Jerome Laclavere <jerome.laclavere@nxp.com>
2019-09-10 13:00:31 +03:00
Guennadi Liakhovetski 596f761bf0 ipc: propagate an error from ipc_stream_pcm_params()
Instead of always returning -EINVAL propagate the error code from
ipc_stream_pcm_params() that actually caused the failure.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2019-09-09 12:52:03 +02:00
Guennadi Liakhovetski bd9bd37f3f pipeline: remove redundant variable initialisations
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2019-09-09 12:52:03 +02:00