Commit Graph

442 Commits

Author SHA1 Message Date
Janusz Jankowski 644a1b4746 license: use spdx identifier in python files
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-06-02 16:38:17 +01:00
Janusz Jankowski c6064624f6 cmake: add spdx license identifier
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-06-02 16:38:17 +01:00
Janusz Jankowski ecd506e16d license: use spdx in .c, .h and .S files with BSD3
Use SPDX License identifier in files that already
contain BSD-3-Clause license.

Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-06-02 16:38:17 +01:00
ArturX Kloniecki 3e3f1d0cae Logger: Update license info in sof-looger files.
Signed-off-by: ArturX Kloniecki <arturx.kloniecki@linux.intel.com>
2019-05-31 22:26:31 +02:00
Janusz Jankowski e39ed5ebf4 include: split uapi headers into more directories
Some of interface headers are not needed by kernel,
but are needed by user-space applications, so we can split them
into multiple directories that indicate their purpose.

Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-05-31 20:10:45 +01:00
Marcin Maka 1f4cc9524d ipc: move ipc host ptable ops to dedicated unit
Ipc private data needed by ptable processing removed from
platforms that do not use it.

Less ifdef-s in the main common ipc code, another new unit
compiled for platforms that require ptables.

Dependency on the private data removed from the main ipc code
and moved to the platform specific code. A dependency between
ipc-host-ptable and platform's ipc private data is easier to
maintain then duplicated code in the main ipc units.

Signed-off-by: Marcin Maka <marcin.maka@linux.intel.com>
2019-05-31 18:14:45 +02:00
Marcin Maka ff2bdc8630 ipc: move pm_prepare_D3 flag to common public ipc data
This flag is not private since used by the common IPC handler layer.
This move enables also the next step to make the ipc private data really
private (hidden in the platform ipc code) and make platform specific.

Signed-off-by: Marcin Maka <marcin.maka@linux.intel.com>
2019-05-31 18:14:45 +02:00
Ranjani Sridharan c0434e27ce topology: apl-nocodec: change pipeline format to s32le
Pipeline format determines the buffer size calculation. With the
pipeline format set to S16_LE, hw_params fails for S24_LE and S32_LE
formats. So, change the pipeline format to s32le to support all
three formats.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-05-31 18:13:10 +02:00
Pierre-Louis Bossart 119b326d73 kmod_scripts: fix hdaudio support
Missing modules obviously.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2019-05-31 16:13:31 +01:00
Seppo Ingalsuo d58e733c7b Topology: Change 16kHz DMIC DAI into 32bit mode and make scheduling 1ms
This patch changes the secondary DMIC FIFO configuration into 32 bits
mode for better quality. Since there is volume component in DMIC
capture pipelines the conversion to other PCM formats can happen
there. Using volume controller with 32 bit input gives a lot better
audio quality when the microphone signal needs amplification.

The scheduling of 16 kHz DAI is changed to 1000us. The comment
of 1000 us is correct but the parameter 48 is not. With 16 frames
the scheduling becomes the desired. This change should also save
some RAM due to smaller buffers.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-05-29 12:06:05 +01:00
Seppo Ingalsuo 5afafa880c Topology: Add support for 4ch 32bit 48kHz DMIC DAI
This patch restores the missing configuration into macro
intel-generic-dmic.m4. Without this patch the 48 kHz DMIC DAI
is not created. Both DMIC FIFOs are available at any channels
number and PCM format so there is no need to delete a DAI when
4ch configuration is used.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-05-29 12:06:05 +01:00
Jaska Uimonen a8ca07f6e7 topology: add more buffering to media pipe after src
Currently we have 1.5 times buffering after SRC in media pipeline. This
will not work for S24 or S32 playback as SRC will use the bigger buffers
with non-integer sample rate conversions as 44.1kHz to 48kHz. So add as
big buffer after SRC as before it.

Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
2019-05-29 12:01:18 +01:00
Jaska Uimonen a26c51a43e topology: add volume component to demux topology
Demux topology doesn't have format conversions so playback files need to
be converted to S24 or S32 format. As this is a bit cumbersome add
volume component to demux topology to enable standard 16 bit playback
from alsa. Also change the demux capture pipe PCM format range.

Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
2019-05-24 10:18:18 +02:00
Pierre-Louis Bossart ca84a89b40 kmod_scripts: first support for SoundWire
remove additional modules in the right order to stress test SoundWire
support

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2019-05-22 19:36:35 +01:00
Jaska Uimonen 3e423f418e topology: fix pipeline indexes in cml demux topology
Dmic and hdmi1 have wrong pipeline id's in demux topology
so fix them.

Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
2019-05-21 11:48:32 +02:00
Keyon Jie 8ca92a4b3f topology: sof-glk-da7219-kwd: add virtual widgets for driver
Add virtual widgets to remove error warnings in kernel dmesg logs, this
is also aligned to sof-glk-da7219 topology file.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-05-20 11:09:47 +02:00
Janusz Jankowski 0c30369f98 uapi: xtensa: remove stack field
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-05-17 16:34:26 +02:00
Seppo Ingalsuo 846e693f1f Tools: sof-eqctl: Print return code for fails.
This patch adds printing of return code in decimal for failed
user control attempt. It helps the user to understand why a fail
happened.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-05-17 10:11:13 +02:00
Tomasz Lauda 346a522cbf topology: fix sof-glk-da7219-kwd topology
This patch fixes two things:
- Configures HDA pipelines to be timer driven.
- Moves definition of pipe-kfbm-capture to avoid overwrite
of deadline and frames for other pipelines.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-05-16 19:37:27 -07:00
Seppo Ingalsuo 6951af2a6d DMIC: Add topologies for DMIC configuration variants testing
The example and test topologies demonstrate new non-symmetrical
microphones/channels setup for capture via FIFOs A and B.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-05-17 00:00:46 +02:00
Keyon Jie caa4808186 topology: kwd: update detector configure blob to align with default
settings

We should load_mips to be 0, align values with default settings, that
is:

load_mips = 0, load_memory_size = 0, keyphrase_length = 0x780,
activation_shift = 0x3, activation_threshold = 0x3fff.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-05-16 10:59:22 +02:00
Jaska Uimonen 73cefecd15 topology: add platform define for demux topology
Add whl define to cmakefile to compile the cml demux topology
correctly with SSP names and indexes defined.

Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
2019-05-15 22:35:24 +02:00
Jaska Uimonen 1d3b0ccfc3 topology: add demux topology for apl and cml
This topology will add a capture branch back from playback pipeline's
mux component. It can be used for example as a echo cancellation
reference signal.

Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
2019-05-14 10:58:52 -07:00
Pierre-Louis Bossart 4c060fd89f tools/kmod_scripts: fix module lists
I just wonder how many people run these module/remove tests? Clearly
they have been broken for a while with modules missing from the lists,
so we must have a parallel universe where CI operates.

Fix by adding all the currently supported modules in the SOF kconfig.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2019-05-12 09:55:15 +01:00
Seppo Ingalsuo 992aa661ab Topology: Rename pipe-src-playback.m4 macro
This patch renames the macro to pipe-src-volume-playback.m4 for
consistency with other audio processing plus volume
pipelines. The topologies those use it are modified for the new
file name.

A new macro for testbench usage called pipe-src-playback.m4 is
added. It is plain SRC component pipeline without volume. The
volume component in the pipeline caused difficulties with test.
The script tools/test/topology/tplg-build.sh will use the
pipeline to create test topology for SRC component.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-05-11 09:28:44 +02:00
Seppo Ingalsuo 31e67a227c Testbench: Update SRC tests criteria for lower 16 bit quality data
The tests created lot of unnecessary fails when testing with S16_LE
format. The test pass criteria for THD+N, DR is relaxed for tests
with 16 bit data.

Since the gain of SRC conversions was lowered to -1 dB the test
case for gain need to be updated. The gain is retrieved from
src_param() function. An exception is added for FS1 == FS2 case
when data is passed through. In that case expected gain is 0 dB.

The frequency response measurement grid does not necessarily cover
the exact upper frequency of pass-band. Therefore the min. upper
passband frequency is scaled by 0.99. This avoids measurement
technique related fails in test.

The chirp spectra test case was updated to use for RMS level criteria
for testing the level of signal. The peak level was less robust and
caused unnecessary test fails.

The option to not open plot windows during test is set. It improves
speed of test and avoids display clutter.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-05-11 09:28:44 +02:00
Seppo Ingalsuo dea1f82b2a Testbench: Update SRC run script
This patch updates the testbench binary path into current default
install location when built with scripts/host-build-all.sh.

The path to test topologies is updated also.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-05-11 09:28:44 +02:00
Seppo Ingalsuo 796b99cf0b Testbench: Fix file read/write component to work with pipelines
This patch fixes the freeze problem when running pipeline in
testbench. The file read/write component needs to use similar
logic to determine number of frames to process as the the
components under test those have been updated to work with timer
based scheduling.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-05-11 09:28:44 +02:00
Jakub Dabek 3020d4aba4 memory: changed memcpy_s error handling
Failing to copy will result in FW panic

Signed-off-by: Jakub Dabek <jakub.dabek@intel.com>
2019-05-11 09:08:31 +02:00
Keyon Jie 030c81c75b topology: keyword-detect: add bytes control for detector
Add bytes control and initial value for detector component.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-05-09 22:25:53 +01:00
Keyon Jie 4a34ab058a topology: keyword-detect: get kpb configure data from ipc
We design to use bytes kcontrol to send kpb configuration data via IPC
from topology, here implement it.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-05-09 22:25:53 +01:00
Seppo Ingalsuo 7dd76db0a8 Topology: Add volume ramp tokens into topologies
This patch adds volume configuration tokens as fifth parameter
for pga.m. All the topologies those use W_PGA() are updated to
use a linear (type=0) ramp with length of 250 ms.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-05-09 22:13:48 +01:00
Keyon Jie e4cb046a2c Topology: kwd: change to use correct buffer caps
We don't need to use host/dai caps for detector buffer and selector
buffer, here correct it.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-05-09 14:57:19 +02:00
Rander Wang 39a373500d topology: add virtual widgets for hda_idisp
Add some more virtual widgets to suppress the machine driver errors.

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2019-05-08 20:24:38 +02:00
Rander Wang d50fa6f920 topology: correct widget type for HDA
It should be type of input for capture widgets

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2019-05-08 20:24:38 +02:00
Janusz Jankowski 2693daf503 cmake: rename BUILD_HOST to BUILD_LIBRARY
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-05-07 08:49:48 +02:00
Janusz Jankowski 62e894eb9d testbench: rename include folder
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-05-07 08:49:48 +02:00
Janusz Jankowski 91578f1a22 host: move testbench to tools
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-05-07 08:49:48 +02:00
Fred Oh 35e438501f topology: hda: fix virtual widget warnings
Add some more virtual widgets to suppress the machine driver errors.

Signed-off-by: Fred Oh <fred.oh@linux.intel.com>
2019-05-07 08:05:04 +02:00
Keyon Jie 47fcac2d47 topology: add topology file for glk kwd.
Add topology file sof-glk-da7219-kwd.m4 which is used for Keyword
Detection feature integrated on GLK platform.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-05-06 18:16:23 +01:00
Keyon Jie b424c98cd8 topology: pipe-kfbm-capture: use DMIC16k for Keyword Detect PCM
Use DMIC16k for Keyword Detect PCM to align with driver.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-05-06 18:16:23 +01:00
Xun Zhang 6dfddfc550 topology: add rt5682 m4 topology file for icl and byt platforms
Add topology support for rt5682 codec in both Bay Trail and Icelake
platforms.

Signed-off-by: Xun Zhang <xun2.zhang@intel.com>
2019-05-06 14:57:17 +01:00
Keyon Jie 6e4faef8e7 topology: keyword-detect: change to use DMIC FIFO B
We need use FIFO B for keyword detect DMIC, here change it.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-04-30 15:12:53 +01:00
Libin Yang 68a237c963 topology: DMIC: DMIC16k use pipe-volume-capture-16khz.m4
DMIC16k only supports 16KHz sample rate. It should use
pipe-volume-capture-16khz.m4 to create the pipe which supports
the 16KHz recording.

Signed-off-by: Libin Yang <libin.yang@intel.com>
2019-04-26 09:41:24 -07:00
Libin Yang 55d1f5ac81 topology: sof: add pipe-volume-capture-16khz.m4
DMIC16k only supports 16000Hz sample rate. pipe-volume-capture.m4
only supports 48000Hz. Add pipe-volume-capture-16khz.m4 to support 16KHz
record.

Signed-off-by: Libin Yang <libin.yang@intel.com>
2019-04-26 09:41:24 -07:00
Yong Zhi 092eb61781 topology: glk-rt5682: add more virtual widgets
Add some more virtual widgets to suppress the machine
driver errors.

Signed-off-by: Yong Zhi <yong.zhi@intel.com>
2019-04-26 10:43:49 +01:00
Kai Vehmanen 6a84b4e945 sof: logger: reopen trace file upon EOF
If logger reads an end-of-file from trace node, reopen the file
to ensure trace read position is in sync between host and DSP.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2019-04-25 20:12:17 +02:00
Ranjani Sridharan e4c1651b36 topology: glk: add more virtual widgets
Add some more virtual widgets to suppress the machine
driver errors.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-04-23 13:40:52 +01:00
Ranjani Sridharan 332e2735c9 topology: apl/byt: add low-latency and media pipelines
This patch does the following:
1. Modify pipe-pcm-media to use the SCHED_COMP macro to set the
scheduling comp for the media pipeline.
2. Add low-latency and media pipelines to the apl nocodec
and apl pcm512x.
3. For the byt codec and nocodec topologies, modify the
PIPELINE_PCM_ADD macro to pass the scheduling comp name

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-04-23 10:47:05 +01:00
Ranjani Sridharan fc5dedd57f topology: pipe-dai: save the scheduling comp name
This will be used by pipelines like the media pipeline, which will
need the information to set up their scheduling comps.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-04-23 10:47:05 +01:00
Ranjani Sridharan ae2b0a4603 topology: pipeline: add scheduling comp argument to PIPELINE_PCM_ADD
Add the scheduling comp argument to PIPELINE_PCM_ADD that
will be used to pass the name of the scheduling comp
when the pipeline is created.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-04-23 10:47:05 +01:00
Rander Wang 896f73d36a topology: dmic: add dmic support in generic hda topology
Now sof kernel driver supports two dmic dai links: DMIC01 PIN,
which supports rate of 48k, and DMIC16k Pin, which supports rate
of 16k. And if four channels dmic is used, we only support one dmic
dai link. CHANNELS would check in intel-generic-dmic to generate
the correct topology file.

Tested on whiskylake & icelake & apollolake up2

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2019-04-19 10:19:04 +01:00
Seppo Ingalsuo 5ef0713b7b TPLG: Rename a volume scale macro to avoid confusion
The macro in tlv.m4 defines a volume scale from -64 dB with 2 dB
steps for playback pipelines. Hence the name m90s3 is incorrect.
The new name m64s2 is a correct description of the defined volume
scale. It's useful since there's another volume scale defined for
capture pipelines.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-04-18 22:06:13 +02:00
Seppo Ingalsuo 90a6efd154 TPLG: Change volume capture pipeline gain range to -50 .. +30 dB
This patch replaces the -64 to 0 dB volume scale for capture with
more practical -50 to +30 dB gain. The step is 1 dB. It allows to
compensate for different microphone model sensitivities when constant
acoustical decibels to digital decibels level is needed in a
microphone capture application.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-04-18 22:06:13 +02:00
Adrian Bonislawski 9d3471d851 coredump-reader: print exception cause and location
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-16 10:14:37 +01:00
Tomasz Lauda 68f27263c8 topology: increase number of periods for low latency pipeline
Increases number of periods for low latency playback pipeline
from 1 to 2 for volume and mixer components. 1 period
is not good enough to have continuous DMA transfer across
the whole pipeline, especially with the new copy flow,
which requires playback pipeline preload.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-04-16 10:13:20 +01:00
Seppo Ingalsuo 1b15fad849 TPLG: Fix mistake in 2ch configuration related DMIC macro
This patch fixes 2ch dmic capture topology. It appeared as topology
completion fail in SOF boot. The missing quote characters in m4
caused the STEREO_PDM0 macro triggered lines to no not be included
into conf file.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-04-15 23:08:08 +02:00
Kai Vehmanen e14ab7088b tools: logger: fix parsing of -s argument
Fix logic for saving the snapshot file argument. getopt()
is called at least once after snapshot option is parsed and
getopt() will erase the optarg value when exiting the while
loop. Without this patch, argument is always NULL and snapshot
cannot be taken.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2019-04-15 16:25:39 +01:00
Adrian Bonislawski db1e17d880 coredump-reader: grep gdb output to print only interesting parts
this will hide default starting gdb prints

Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-15 15:41:49 +02:00
Kai Vehmanen 9fa0aef635 tools: logger: ignore end-of-file in trace mode
Change logger behaviour such that in trace (-t) mode logger
only stops if an error is detected. If no error, logger
continues to try and read data from debugfs node.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2019-04-11 10:29:54 +02:00
Adrian Bonislawski ed6ac05f6b coredump-reader: proper structs alignment with fw data
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-09 12:46:48 +02:00
Adrian Bonislawski faf6696ea3 coredump-reader: fix windowbase and windowstart calculations
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-09 12:46:48 +02:00
Adrian Bonislawski b5ea5da52b coredump: add stack ptr + rewind_frames offset to plat header
+ coredump-reader changes to use new variable
+ moved dump_stack before arch_dump_regs in panic

Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-09 12:46:48 +02:00
Janusz Jankowski 3caeefd824 tools: scripts: update host installation path
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-04-05 15:01:44 +01:00
Adrian Bonislawski 1071076be1 coredump: enhancement of example file
To make it more user-friendly by getting rid of empty prompts in output

Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-05 11:25:16 +02:00
Adrian Bonislawski 5949148b94 coredump-reader: add info to notice user about non-critical warning
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-04 15:10:42 +01:00
Adrian Bonislawski fc13cff773 coredump-reader: unnecessary comments removed
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-04 15:10:42 +01:00
Adrian Bonislawski db7a3cfe1b coredump-reader: core header and registers printing separately
To separate them visually for better reading

Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-04 15:10:42 +01:00
Adrian Bonislawski 56682f4d79 coredump-reader: remove isatty() and fixed print when used with piped more
Now it is possible to pipe output with 'more'

Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-04 15:10:42 +01:00
Adrian Bonislawski 2e63ee2144 coredump-reader: make columncount dependent on verbose option in help
This is to notice user that columncount option will work only with verbose

Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-04 15:10:42 +01:00
Adrian Bonislawski 75466d8b2d coredump-reader: remove unnecessary separator + proper permissions
Two separators didnt work correctly

Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-04 15:10:42 +01:00
Xun Zhang cbbc6afd35 tools: test: topology: add argument to fix build error in test tplg
Add one argument in test-tone-playback.m4 to fix the building error
of insufficient PIPELINE_ADD arguments.

Signed-off-by: Xun Zhang <xun2.zhang@intel.com>
2019-04-03 21:39:42 +01:00
Marcin Maka cbd3e07031 tools: doc: README converted to README.md
MD content is rendered by GH automatically when listing
tools folder.

Signed-off-by: Marcin Maka <marcin.maka@linux.intel.com>
2019-04-02 12:23:13 +01:00
Bard liao ed97bb9418 topology: update HDA index
The index should be 0,1,2 instead of all 0.

Signed-off-by: Bard liao <yung-chuan.liao@linux.intel.com>
2019-04-02 09:52:25 +01:00
Adrian Bonislawski 592ffdd567 coredump-reader: add README
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-04-01 12:39:46 +01:00
Ranjani Sridharan eac4a73232 scripts: use project root directory instead of relative path
Use the SOF project root directory in get_abi.sh to read the
ABI macros instead of using the relative path.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-04-01 10:39:26 +01:00
Marcin Maka ad0ff1f2e5 tools: logger: added less formatted output mode
Activated by '-r' option. Useful for intermediate log
processing when the output is used as an input for another
tool. No headers, tokens separated by single spaces,
component ids concatenated with component name to
still produce a single token if present.

Signed-off-by: Marcin Maka <marcin.maka@linux.intel.com>
2019-04-01 11:37:57 +02:00
Bard liao 052942c863 topology: add ABI information
We can add ABI information to the Manifest section. So kernel can
check if the topology is compatible with the kernel.

Signed-off-by: Bard liao <yung-chuan.liao@linux.intel.com>
2019-03-29 16:55:04 +00:00
Adrian Bonislawski 2302012fe9 coredump-reader: fix fg error when running without colours
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-03-29 13:27:53 +01:00
Kai Vehmanen a9cb19ada3 topology: add param check to PIPELINE_*() macros
Abort build if not all mandatory arguments are passed to
the top-level pipeline macros.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2019-03-29 12:14:05 +00:00
Kai Vehmanen 10c641d307 topology: add param check to VIRTUAL_WIDGET()
Abort build if not all mandatory arguments are passed to the
macro.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2019-03-29 12:14:05 +00:00
Kai Vehmanen 90fbcd54f3 topology: add param check to DAI_CONFIG()
Abort build if not all mandatory arguments are passed to the
macro.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2019-03-29 12:14:05 +00:00
Kai Vehmanen 322fe24e95 topology: add param checks to PCM macros
Abort build if not all mandatory arguments are passed to
the macros. This should help to catch invalid usage.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2019-03-29 12:14:05 +00:00
Tomasz Lauda 6a0dcb3a10 topology: update all HDA pipelines to use timer
Updates all HDA pipelines in topologies to use
timer as a scheduling source.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-03-27 21:44:02 +00:00
Keyon Jie 0da78d7236 topology: refine scheduling period and add time domain for pipelines
Rename 'deadline' to 'period' to indicate pipeline scheduling period,
and add time domain to indicate the pipeline scheduling domain (e.g. DMA
interrupt, timer interrupt).

Please be noticed that this might introduce an abi change so consequent
abi changes in both FW and driver side are needed.

Haven't set the flag in topology/sof/sof-xxx.m4 yet, that means it will
use io/interrupt scheduling for those topologies/pipelines at the
moment, if wanna to change them, please change them specific there.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-03-27 21:44:02 +00:00
Adrian Bonislawski 44705dfc09 debugability: update coredump reader
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
2019-03-27 21:10:48 +00:00
Fred Oh 498a5f571d topology: enable LBM for nocodec topology
Add quirks parameter in SSP_CONFIG_DATA(). Enable LBM in dupulex pipelines
by setting quirks as SOF_DAI_INTEL_SSP_QUIRK_LBM 64(1<<6). SSPx.IN port get
PCM data from SSPx.OUT. Note both mclk and quirks are optional parameter.
When quirks set, mclk should have value or initialize to default value
which is 0.

Signed-off-by: Fred Oh <fred.oh@linux.intel.com>
2019-03-27 11:39:58 +00:00
Fred Oh 5194eabf4f topology: ssp: add quirks parameter in SSP_CONFIG_DATA
Support quirks setting from topology. quirk are used to set
ssc1/ssc2 registers according to its bit value.

Signed-off-by: Fred Oh <fred.oh@linux.intel.com>
2019-03-27 11:39:58 +00:00
Tomasz Lauda 9890d2b782 topology: add missing param to hda-generic-idisp topology
Adds missing param to sof-hda-generic-idisp.m4.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
2019-03-26 17:18:22 +00:00
Bartosz Kokoszko e5cf39ff9c schedule: ll: add ll specific traces
Signed-off-by: Bartosz Kokoszko <bartoszx.kokoszko@linux.intel.com>
2019-03-26 16:20:34 +00:00
Pierre-Louis Bossart e54087caa4 topology: add support for HDMI only w/ 3 iDISP streams
This is useful for headless devices such as Up2 with no external
HDAudio codec but an HDMI/DP output.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2019-03-21 15:39:00 +00:00
Pierre-Louis Bossart 65fb817100 topology: rename HDA topology to name used by kernel
s/sof-hda-intel-common/sof-hda-generic

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2019-03-21 15:39:00 +00:00
Sathya Prakash M R b70e9151cb topology: Add CML topology support for rt5682+max98357a variant
Add max98357a speaker on top of sof-rt5682 CML Audio topology

Signed-off-by: Sathya Prakash M R <sathya.prakash.m.r@intel.com>
2019-03-20 11:19:31 +00:00
Bartosz Kokoszko 648345065a scheduler: add new generic scheduler api
This commit:
1. Renames specific schedulers:
	- schedule (.c/.h) -> edf_schedule (.c/.h)
	- work (.c/.h) -> ll_schedule (.c/.h)
2. Implements new generic scheduler api based on generic
   struct with scheduler ops. Every specific
   scheduler exports struct with pointers to its
   specific functions.
3. Makes edf and ll using generic api (exports structure
   with pointers to its own specific functions)
4. Updates host and pipeline tests due to scheduler
   changes.

Signed-off-by: Bartosz Kokoszko <bartoszx.kokoszko@linux.intel.com>
2019-03-19 14:37:15 +00:00
Ranjani Sridharan 0ead3bda19 topology: merge bdw codec topologies into single m4
Use the same m4 file to generate the topology for all bdw
boards based on the CODEC name defined during compilation.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-03-15 11:51:18 +00:00
Ranjani Sridharan 08c0db49f1 topology: merge all byt codec topologies into one m4 file
BYT with RT5645, RT5640, RT5651 and DA7213 all have similar
topologies with the only difference in codec name. Merge
them all into a single m4 file and set the codec name
using the macro defined during compilation.

This will also take care of adding the virtual widgets
for all the BYT topologies for compatibility with the
machine drivers.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-03-15 11:51:18 +00:00
Ranjani Sridharan cd2168cf2b topology: pipe-pcm-media fix various typos/errors in comments
fix some typos and copy errors in pipe-pcm-media m4 file.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-03-15 11:51:18 +00:00
Ranjani Sridharan 958ed657c1 topology: merge sof-byt-nocodec and sof-cht-nocodec m4 files
Merge the 2 m4 files and use the PLATFORM defined during
compilation to generate the appropriate topology.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-03-15 11:51:18 +00:00
Ranjani Sridharan e5e5dcc806 topology: merge sof-apl-dmic-2ch and sof-apl-dmic-4ch m4 files
Use the same m4 files to generate both 2ch and 4ch topologies
by defining channels during compilation.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-03-15 11:51:18 +00:00
Ranjani Sridharan 17f85baa70 topology: merge sof-cml-rt5682 and sof-whl-rt5682 m4 files
The only difference between them is the SSP index and name.
Use a macro during compilation to indicate which platform
we're building for and set these appropriately.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-03-15 11:51:18 +00:00
Guennadi Liakhovetski 01f1a4aeae tools: fix a typo
"Formate" and "format" are two different words, in this case it's
"format" that is meant.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2019-03-14 10:13:22 +00:00
Liam Girdwood e31ef3b96a topology: keyword: Add keyword detection topology for APL
Add initial pipeline for keyword detection on APL platform.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-03-11 15:41:06 +00:00
Jaska Uimonen 500d64fe5d topology: keyword: selector: add bytes control
Add bytes control for selector to send binary
data to it.

Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
2019-03-11 15:41:06 +00:00
Ranjani Sridharan b0c900b9a7 topology: Add keyword detect pipeline
Add pipeline with keyword detect and channel selector comps.
This should be connected to a capture pipeline such as
pipe-kfbm-capture.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-03-11 15:41:06 +00:00
Keyon Jie 5711211e0d topology: add support for channel selector component in topology
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-03-11 15:41:06 +00:00
Ranjani Sridharan 082122556a topology: add support for keyword detect component in topology
Add support for constructing and adding keyword detect
component in topology

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-03-11 15:41:06 +00:00
Ranjani Sridharan 1da08478c0 topology: Add kpbm capture pipeline
Add support for generic capture pipeline with a KPBM between PCM and
other pipelines. This can be used for Keyword detection use case.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-03-11 15:41:06 +00:00
Keyon Jie a22e9fddcc topology: add support for key phrase buffer manager component in topology
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-03-11 15:41:06 +00:00
Keyon Jie 21049e31fb topology: tokens: remove subtype for process token
We can use widget type combined with component type to identify specific
process type, the subtype is no need anymore, here remove it.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-03-11 15:41:06 +00:00
Keyon Jie 1825275784 Topology: define schedule component macro for pipe-dai-capture
This can be used for schedule component sharing between pipelines.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-03-11 15:41:06 +00:00
Ranjani Sridharan 93c130aeec topology:sof-byt-rt5651: add virtual widgets for machine driver compatibitlity
Add virtual widgets for ssp2 RX/TX for compatibility with the
bytcr_rt5651 machine driver. This is needed now because a recent
change in the driver removed these from the dai definitions
which results in card registration failure.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-03-11 15:09:14 +00:00
Fred Oh 5cd7b64100 topology: remove unused properties in tokens
Some properties are not populated from the topologies and not being used
by DSP either. Need to clean up token data structures. These are
identified as unused.

comp_tokens: preload_count
dai_tokens: dmac_config

Signed-off-by: Fred Oh <fred.oh@linux.intel.com>
2019-03-11 14:39:17 +00:00
Lech Betlej 29bdba76d7 logger: add KPB component name
Logger will display a proper component name for traces
from KPB component.

Signed-off-by: Lech Betlej <lech.betlej@linux.intel.com>
2019-03-10 19:07:47 +01:00
Lech Betlej 31d871d5af logger: add channel selector component name
Logger will display a proper component name for traces
from channel selector component.

Signed-off-by: Lech Betlej <lech.betlej@linux.intel.com>
2019-03-10 19:07:47 +01:00
Zhu Yingjiang 8d9438388c topology: fix two comments
fix two comments of SSP number, the da7219 is connected to
SSP2

Signed-off-by: Zhu Yingjiang <yingjiang.zhu@linux.intel.com>
2019-03-07 12:40:10 +00:00
Zhu Yingjiang 05ca4ebd06 topology: fix kcontrol name by topology
the kcontrol item name doesn't follow the SOURCE:DIRECTION:FUNCTION, and
can't separate playback and capture when display in alsamixer.
This fix is to move the pipeline id from the end of the name to the
head, this will make alsamixer to serperate playback and capture when
press F3 F4.

Signed-off-by: Zhu Yingjiang <yingjiang.zhu@linux.intel.com>
2019-03-07 12:35:49 +00:00
Ranjani Sridharan 488cedaf79 topology: pipeline: add sched_comp argument to PIPELINE_ADD
Some pipelines might need to share the scheduling comp
with other pipelines. In this case, the scheduling comp
name should be passed as an argument.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-03-06 17:53:49 +00:00
Keyon Jie cc51ff8f0c topology: change token name from effect to process
The token can be used for more generic processing, not only effect
component, let's rename it.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2019-03-06 17:53:49 +00:00
Bard liao 56eb603c74 topology: add topology for cht with Realtek codecs
This topology is tested on Up board with Realtek rt5682 codec.

Signed-off-by: Bard liao <yung-chuan.liao@linux.intel.com>
2019-03-05 15:00:14 +00:00
Seppo Ingalsuo ee5c247c57 SRC: Add attenuation of -1 dB into processing to avoid saturation
This patch replaces all the filter coefficients to avoid the
unpleasant effect of samples saturation that the previous 0 dB max.
gain scaled coefficients could cause. The saturation of transients
may still happen but it should be more rare.

The filter coefficients scaling is changed from fixed pass band peak
align (to 0 dB) into DC gain controllable via new parameter gain in
src_param.m.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-03-04 15:08:06 +00:00
Zhang Keqiao 95e762f835 test: add a script for pause/release stress test
This script is used to test pause/release audio stream

Signed-off-by: Zhang Keqiao <keqiao.zhang@linux.intel.com>
2019-03-01 18:14:44 +00:00
Zhang Keqiao 0097215afc test: fix a typo, Add a colon to option that have parameter
Signed-off-by: Zhang Keqiao <keqiao.zhang@linux.intel.com>
2019-03-01 18:10:15 +00:00
Zhang Keqiao 7f91296cc1 kmod_scripts: add da7219 codec support for GLK
Signed-off-by: Zhang Keqiao <keqiao.zhang@linux.intel.com>
2019-03-01 17:05:55 +00:00
Ranjani Sridharan e38db1a69d topology: remove dapm route from PCM dev to host comp
This route is automatically created when the host comp is created
during topology loading. So remove it to avoid duplicating
the connection in the dapm graph.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-02-26 13:02:59 +00:00
Dragos Tarcatu e9c81160ee topology: ssp: add polarity inversion option in SSP_CLOCK
alsatplg allows setting inverted bclk and fsync polarities
by setting either bclk_invert or fsync_invert to "true".
This patch adds a default parameter in the SSP_CLOCK m4
macro which allows setting inverted bclk and fsync polarities.

Signed-off-by: Dragos Tarcatu <dragos_tarcatu@mentor.com>
2019-02-26 12:50:29 +00:00
Jiangxinx 82d29e099c Fix issue 1039: Kernel QA scripts are broken.
Signed-off-by: Jiangxinx <xinx.jiang@intel.com>
2019-02-25 16:36:30 +00:00
Janusz Jankowski e502f2286d tools: readme fix for cmake 3.10
Argument -B<builddir> is not supported in minimum version of CMake
required by our project (3.10).

Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-02-22 17:29:53 +01:00
Ranjani Sridharan 2b4467c007 topology: whl: add topology for whl with rt5682
Add topology for WHL with RT5682. This will be merged with
sof-cml-rt5682 in the future to avoid maintaining 2 files
with just the difference in SSP port numbers.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-02-18 16:29:47 +00:00
Ranjani Sridharan abc0d2fc6a topology: cml: change SSP port num for rt5682
The CML board has the rt5682 connected to SSP0 and the
machine driver defines the dai link for the headset
with the name "SSP0-codec" too. So change the topology
file accordingly.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-02-18 16:29:47 +00:00
Janusz Jankowski e57b1346db cmake: tools: README
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-02-14 18:00:26 +00:00
Janusz Jankowski 9fb2097e52 cmake: tools: install targets
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-02-14 18:00:26 +00:00
Janusz Jankowski dff70c4490 cmake: tools: remove autotools
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-02-14 18:00:26 +00:00
Janusz Jankowski 1704bfcb95 cmake: tools: test
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-02-14 18:00:26 +00:00
Janusz Jankowski 67597453ec tools: tplg-build custom output dir
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-02-14 18:00:26 +00:00
Janusz Jankowski 44c0ce7388 cmake: tools: topology
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-02-14 18:00:26 +00:00
Janusz Jankowski f8f71f5938 cmake: tools: eqctl
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-02-14 18:00:26 +00:00
Janusz Jankowski 2728dae14c cmake: tools: logger
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-02-14 18:00:26 +00:00
Janusz Jankowski cfa10b808d cmake: CMakeLists for tools
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-02-14 18:00:26 +00:00
Pierre-Louis Bossart cfcdce9550 kmod_scripts: improve list of devices
HDaudio support was missing, along with a slew of codecs
Also add a log on module insertion

Tested on Up2 with HDMI&PCM512x, and CHT w/ rt5645

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2019-02-07 21:13:43 +00:00
Pierre-Louis Bossart fb137dec6b topology: up2 without HDMI
the kernel supports easy removal of HDMI support, let's add the
matching topology.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2019-02-06 10:26:25 +00:00
Pierre-Louis Bossart 6e26683f9f topology: apl-pcm512x: fix HDMI3 support
missing 2 in DAI_ADD() macro. This seems to be the only place where this
typo/mistake happens

we really need a parameter checker or move away from M4...

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2019-02-05 13:08:41 +00:00
Pierre-Louis Bossart 2da1c71b2c tools: kmod_scripts: remove modprobe error log and cleanups
filter out modprobe log if module is not in tree
also add missing codecs (rt5682 and wm8804) and reorder codec list

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2019-02-05 13:07:51 +00:00
Ranjani Sridharan e56326ab48 topology: cht: fix link id for nocodec DAI
Nocodec machine driver adds all the BE dai links with
ID's linearly incrementing from 0. So the link ID
should match with the SSP dai index.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-02-02 16:35:16 +00:00
Liam Girdwood d4ae0cd3d6 logger: format file name to remove leading directories.
No need for full path as this breaks column formatting.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-02-01 16:17:07 +00:00
Liam Girdwood 50685bfb42 logger: improve some error messages.
Make error messages more meaningful

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2019-02-01 16:17:07 +00:00
Seppo Ingalsuo 1c191a20fd DMIC: Enable capture from secondary FIFO
This patch enables the FIFO B in addition to previously supported
FIFO A. It allows in topology to use in pipelines the DMIC DAI
type with indices 0 and 1. The DAI instances can be operated with
different sample rate and different PCM format. The other
topology parameters for microphones need to be the same (number
of channels and enabled microphones). If the request via topology
differs for those parameters the latter request overrides the
first request. Typical usage for this added feature is to provide
compact 16 kHz / 16 bit capture version for speech in addition to
normal 48 kHz / 32 bit media quality audio capture.

The DMIC HW actually provides a bit more freedom for FIR/FIFO A/B
usage difference but all of that is not exposed yet via the
driver due to added complexity.

Some trace prints for DMIC parameters and used configuration are
modified to print shorter lines for easier reading. The print
order is adjusted to be more logical.

The patch modifies two topologies to showcase the feature. The
sof-apl-dmic-2ch/4ch topologies for APL nocodec machine driver
are changed to instantiate in addition PCM7 set for 16 kHz 16 bit
format in addition to earlier PCM6.

Note: The required change to pipe-passthrough-capture.m4 PCM
capability to enable other than 48 kHz rate is not done to not
break important test cases. Another PR addresses the PCM
capabilities and after it is merged allowing 16 kHz PCM for DMIC
capture can be done safely.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-01-31 20:41:24 +00:00
Bard liao f80c828a77 topology: add cml topology with src supported
The topology is based on sof-cml-rt5682.m4 but use src on SSP playback

Signed-off-by: Bard liao <yung-chuan.liao@linux.intel.com>
2019-01-31 20:39:31 +00:00
Pan Xiuli a45f4d1a1c tools: remove unused travis yml
now we have uplever travis.yml to cover the tools test, the tools level
file is not needed.

Signed-off-by: Pan Xiuli <xiuli.pan@linux.intel.com>
2019-01-31 20:35:44 +00:00
Pierre-Louis Bossart 7fa7413527 topology: remove tone support
This was never properly supported and generates errors. Will re-add when it
actually works

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2019-01-31 20:26:44 +00:00
Janusz Jankowski 08257d3168 tools: remove duplicated rimage keys
Signed-off-by: Janusz Jankowski <janusz.jankowski@linux.intel.com>
2019-01-31 20:24:30 +00:00
Bartosz Kokoszko e3cf1f2fed logger: use fopen binary mode
Signed-off-by: Bartosz Kokoszko <bartoszx.kokoszko@linux.intel.com>
2019-01-31 11:11:57 +01:00
Rander Wang a5d32b4c3a topology: hda: fix a hda bug when pipeline is in 24bit
sof audio pipeline with the format of 24bit doesn't
work on HDA platform. It is caused by sample data layout. SOF supports
S24_LE, and each sample format is like pattern of 0ddd, d stands for
data. Samples are padded with 0‟s at the MSB.

Link dma copys samples directly to hda bus, but hda bus requires samples
layout like pattern of ddd0. Samples are padded with 0‟s at the LSB to
left justify the sample within the container.

Now there is a volume at the end of hda pipeline. We only need to
convert dai type from S24_LE to S32_LE to make volume convert hda data to
correct format

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2019-01-29 09:53:39 +00:00
Rander Wang b46740523b topology: hda: delete sof-whl-hda.m4
It is useless now and sof-hda-generic.m4 would be used by WHL.

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2019-01-29 09:53:39 +00:00
Pierre-Louis Bossart 7f7e48e27e kmod_scripts: fix dependencies and add delays
dependencies are incorrect due to kernel changes

also add 6s delay after insert to let userspace complete its tasks and
go back to idle

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2019-01-23 12:56:21 -06:00
Zhu Yingjiang a766e471b0 add nocodec topology for CNL
add nocodec topology for CNL, with three SSPs and one DMIC

Signed-off-by: Zhu Yingjiang <yingjiang.zhu@linux.intel.com>
2019-01-23 09:20:41 +00:00
Zhang Keqiao eca416ad79 test: add a script for xrun injection test
This script is used to check the ability of alsa xrun handling

Signed-off-by: Zhang Keqiao <keqiao.zhang@linux.intel.com>
2019-01-21 21:41:22 +00:00
Ranjani Sridharan 03ababfb1c scripts: modify sof_bootone.sh to exit if sof_remove failed
Exit if sof_remove fails. This avoids running into further issues.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-01-18 08:36:03 +00:00
Ranjani Sridharan 364f52b74f topology: cml: update macros for HDA DAI's
HDA_DAI_CONFIG has been replaced to re-use DAI_CONFIG.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-01-17 08:50:06 +00:00
Zhu Yingjiang 2981a6f22c add topology file for Cometlake with rt5682
add the topology file for Cometlake with codec rt5682, a
analog codec with SSP1, and DMIC, HDMIs

Signed-off-by: Zhu Yingjiang <yingjiang.zhu@linux.intel.com>
2019-01-16 13:35:21 +00:00
Ranjani Sridharan a00a38a1ec topology: remove HDA_DAI_CONFIG and re-use DAI_CONFIG
remove the HDA_DAI_CONFIG macro and reuse the DAI_CONFIG
macro with type HDA. This will ensure the hw_config
section gets added for HDA dai's as well.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2019-01-16 09:53:09 +00:00
Marek Lucki db3d730913 trace: schedule trace added
Added schedule trace instead of pipe. Logger updated.

Signed-off-by: Marek Lucki <marekx.lucki@linux.intel.com>
2019-01-14 14:02:49 +00:00
Pan Xiuli a2fe69c020 tools: gitignore: change the test topology path
Test topology changed location, need the gitignore to update.

Signed-off-by: Pan Xiuli <xiuli.pan@linux.intel.com>
2019-01-14 13:31:24 +00:00
Xun Zhang 24422c6373 topology: fix virtual widget warnings
add some widgets to prevent kernel warnings generated by the machine
driver.

Signed-off-by: Xun Zhang <xun2.zhang@intel.com>
2019-01-14 11:50:36 +00:00
Guennadi Liakhovetski 64bbee865b logger: support reading from a serial port
On some systems the DSP has no DMA interface to the host and is
using a serial port for sending its trace. This patch adds a "-u"
argument to specify a baudrate, that should be used with the serial
interface. The implementation takes care of spurious bytes,
sometimes seen in the beginning of the trace, produced by the port
initialisation by the DSP. The format is fixed to 8N1.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2019-01-11 11:44:21 +00:00
Guennadi Liakhovetski 28039d3024 logger: (cosmetic) fix the return value, use pointers
1. Programs shouldn't exit with negative return values, strictly
   speaking only EXIT_SUCCESS and EXIT_FAILURE should be used,
   however it is also valid to return 0 for success and any number
   from 1 to 125 for a failure.
2. Avoid passing complete structs as function parameters where an
   additional copy of one isn't needed, use const pointers instead.
3. Remove a left-over unused argument.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2019-01-11 11:44:21 +00:00
Seppo Ingalsuo 843553646a Topology: Add volume control into SRC playback pipeline
This patch adds a volume component after SRC to be able to convert
the variable pipeline s16/s24/s32 PCM format into PCM format used
by DAI. The PCM capabilities are changed to allow all formats.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-01-09 16:30:58 +00:00
Seppo Ingalsuo 81e0333e19 Testbench: Add S16_LE format test for SRC
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-01-09 16:30:58 +00:00
Zhang Keqiao 0a57440a35 test: add a script for multiplex pipeline stress test
This script is used for simultaneous playback/capture test on
arbitrary multiple pipelines.

Signed-off-by: Zhang Keqiao <keqiao.zhang@linux.intel.com>
2019-01-08 15:32:31 +00:00
Michal Jerzy Wierzbicki dd07c8e3b0 tools/coredumper: added support for sof_ipc_dsp_oops_header; added handling of invalid windowbase; added exceptions for invalid flag usage 2019-01-08 13:25:32 +00:00
Seppo Ingalsuo 676e72a895 Topology: EQ IIR: Allow capture with all formats with pipe-eq-capture
This patch adds to IIR EQ capability to convert from s32 source to
s16/s24/s32 sink formats in normal PCM samples equalization. The
feature is useful in microphone equalization where input dynamic
range is high but where pipeline needs to be lower word length. A
typical IIR high-pass response when combined with gain will reduce
the dynamic range by suppressing lowest frequencies from signal to
better fit the smaller sample word length.

The PCM capability in topology macro pipe-eq-capture.m4 is changed to
allow the s16/s24/s32 formats.

The patch also includes 4096 bytes increase to SOF_TEXT_SIZE for CNL
platform.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2018-12-20 14:08:32 +00:00
Seppo Ingalsuo dd8cfda311 EQ: Update ABI version number in configuration to match current version
This patch updates the provided example responses as data for
sof-eqctl and in the include files for topologies. The updates into
Matlab scripts are included also. The FIR and IIR example script is
updated to contain all examples.

The patch includes also a bug fix into IPC handler where the check
against SOF_IPC_MSG_MAX_SIZE is off by one and caused it to reject
all set data commands (to the EQs).

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2018-12-19 10:28:25 +00:00
Naveen Manohar 8e1249c293 topology: Add GLK topology support for chromebook rt5682+max98357a variant
Add new PCMs and backends for GLK chromebook with codecs rt5682+max98357a.

Signed-off-by: Naveen Manohar <naveen.m@intel.com>
2018-12-18 11:30:08 +00:00
Seppo Ingalsuo 0526077c87 Tools: Update SRC tool for 50 kHz modes, SRC testbench, add topology
This patch adds 50 kHz into SRC generator script for std and tiny
profiles. The src generator script is cleaned up and the default
conversion matrix is moved into caller script for easier maintenance.
The plots appearance is improved and the generated coefficients code
look is improved to pass the git pre- and post-commit script
requirements.

The SRC test bench scripts are updated for changed locations. A SRC
playback topology is used for test bench and real device usage.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2018-12-18 11:29:32 +00:00
Liam Girdwood dd98c4721e topology: apl: nocodec config out of host GW DMAC channels
By default topology is using too many capture and playback PCMs, DAIs and
pipelines for available host GW DMAC channels. Comment out some so that
DMAC channels stay within bounds. This also gives users options to
re-enable for theer given test HW.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-12-13 17:18:16 +00:00
Ranjani Sridharan 30007ca825 topology: glk: change DMIC capture to support 4ch 16-bit format
The requirement for DMIC capture is to support upto 4ch
and 16-bit format. So modify the topology accordingly.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2018-12-11 20:25:33 +00:00
Pierre-Louis Bossart ddebac091f topology: realign sof-apl-da7219 on sof-glk-da7219
Somehow those two files should only differ on SSP connections and MCLK
ID1, so it's pretty obvious no one has tested this since August...

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2018-12-07 15:47:52 +00:00
Ranjani Sridharan 1aa95f8e27 logger: show version numbers with the ABI mismatch error
Show the version numbers along with the ABI mismatch error.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2018-12-05 11:08:20 +00:00
Marcin Maka 95a3d93bbd tools: logger: turn off colors if the output file is not a tty.
Signed-off-by: Marcin Maka <marcin.maka@linux.intel.com>
2018-12-04 13:37:16 +00:00
Rander Wang 5571da6dc1 topology: hda: change stream format from 32bits to 24bits
For most of hda codecs, 32bits is not supported and 24bits
is a suitable one.

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2018-12-04 13:36:57 +00:00
Rander Wang 15e891202f topology: hda: refine dai setting for hda
This refinement follows commit on WHL

topology: whl: refine topology for hda on whl

    Fix the issue that ipc timeout when simutalously playback
    and capture. Now in FW, playback and capture are supported
    by different dai. So dai index should be different for playback
    and capture in the same be dai, or playback would use the same
    dai as capture

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2018-12-04 13:36:57 +00:00
Seppo Ingalsuo cc6c76f1de Tools: Tune: Update EQ tools for new user ABI plus other cleanup
This patch adds into filter tools retrieving of ABI version from a
single function (a quick solution) and updates all configuration
data tools to apply the user ABI header.

The confusing platform_max_channels struct field is renamed to
channels_in_config (the EQ channel map) that creates many updates. The
EQ response plot title is fixed.

Finally new functions to decode IIR and FIR settings blobs is added.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2018-11-30 17:19:59 +02:00
Seppo Ingalsuo d27de3a671 tools: Update eqctl tool and sample configurations for new user ABI
The ext bytes read response parsing needs a fix since it now includes
the ABI header. A warning is printed if max control size is reached.
The example configurations are also updated to contain the header.

The patch also includes new IIR and FIR setup for pass-through
configuration (for testing) that configures the EQ component to totally
pass the filter computation.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2018-11-30 17:19:26 +02:00
Seppo Ingalsuo 2e4b435302 Tools: Topology: Update EQ related topology files for new user ABI
This patch adds the ABI header into topology EQ data files and updates
the pipe-eq-volume-playback.m4 to include the coefficients from m4
directory like other topology files to prevent duplication of
response data.

The CONTROLBYTES_MAX is decreased to 304 due to larger IPC header size.
The update is not critical since the kernel contains other checks to
cover this. However it's done to avoid confusion.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2018-11-30 14:19:37 +02:00
Liam Girdwood 983517e359
Merge pull request #638 from bkokoszx/logger-rimage-headers
logger: include file_format.h directly from rimage
2018-11-27 14:33:57 +00:00
Liam Girdwood bad017ba56
Merge pull request #636 from ranj063/fix/glk-virtual-widget-warnings
Topology: Fix glk virtual widget warnings
2018-11-27 14:30:25 +00:00
Bartosz Kokoszko 93f1a2eaa7 logger: include file_format.h directly from rimage
Signed-off-by: Bartosz Kokoszko <bartoszx.kokoszko@linux.intel.com>
2018-11-27 10:43:06 +01:00
Ranjani Sridharan 6ff198df7c topology: glk: fix virtual widget warnings
Modify hard-coded virtual widgets to prevent kernel
warnings generated by the machine driver. No need to
add virtual_dapm_routes. Just adding the required virtual
widgets suffices to suppress the warnings.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2018-11-27 00:10:01 -08:00
Ranjani Sridharan f9b8e08f75 topology: modify virtual_widget definition
Modify virtual_widget macro definition to take type as
an input so it can used for different types and update
its users.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2018-11-27 00:08:53 -08:00
Rander Wang f9c23243d6 topology: whl: refine topology for hda on whl
Fix the issue that ipc timeout when simutalously playback
and capture. Now in FW, playback and capture are supported
by different dai. So dai index should be different for playback
and capture in the same be dai, or playback would use the same
dai as capture

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2018-11-27 13:59:45 +08:00
Bartosz Kokoszko 221064d463 tools: logger: abi verification addition
I've added abi_version verification. Be default logger verify: abi
in *.ldc file with logger abi version. Additionally, logger can verify
abi in "/sys/kernel/debug/sof/fw_version" (with -e flag) or in
ver_file (with -v ver_file) with logger abi version.

Signed-off-by: Bartosz Kokoszko <bartoszx.kokoszko@linux.intel.com>
2018-11-26 18:06:55 +01:00
Bartosz Kokoszko 159cea157f tools: logger: removed uapi dependency
Logger now includes uapi directly from FW code.

Signed-off-by: Bartosz Kokoszko <bartoszx.kokoszko@linux.intel.com>
2018-11-26 18:06:26 +01:00
Curtis Malainey 5b5888ce07 Move SOFT into sub folder for SOF merge
Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
2018-11-24 23:27:24 -08:00