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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>