History log of /linux-master/sound/soc/intel/avs/messages.c
Revision Date Author Comments
# 275b583d 19-Feb-2024 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: ICL-based platforms support

Define handlers specific to cAVS 2.0 platforms, that is ICL, JSL and all
other variants based on this very version of AudioDSP architecture. Most
operations are inherited from their predecessors with the major
difference being firmware-logging functionality - IPC request as well as
debug memory windows layout have changed.

Reviewed-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://msgid.link/r/20240220115035.770402-8-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 26033ae6 29-Sep-2023 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Move IPC error messages one level down

Code size can be reduced if avs_dsp_send_xxx_msg()s take responsibility
for dumping logs in case of an IPC message failure. In consequence,
avs_ipc_err() helper is removed.

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Link: https://lore.kernel.org/r/20230929112436.787058-2-amadeuszx.slawinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 905ea24f 14-Dec-2022 Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>

ASoC: Intel: avs: Add peakvol runtime-parameter requests

Peakvol module allows for setting and obtaining DSP volume as well as
modifying shape and duration at which volume actually changes. Add IPC
messages to expose those capabilities.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Link: https://lore.kernel.org/r/20221214185500.3896902-2-amadeuszx.slawinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# dab8d000 02-Dec-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Add data probing requests

Data probing is a cAVS firmware functionality that allows for data
extraction and injection directly from or to DMA stream. To support it,
new functions and types are added. These facilitate communication
with the firmware.

Total of eight IPCs:
- probe module initialization and cleanup
- addition and removal of probe points
- addition and removal of injection DMAs
- dumping list of currently connected probe points or enlisted DMAs

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20221202152841.672536-10-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# b3eefa5d 02-Dec-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Make enable_logs() dependent on DEBUG_FS

Without debug filesystem present, this code is redundant.
Operations: log_buffer_status and log_buffer_offset are left as is as
EXCEPTION_CAUGHT and even unexpected LOG_BUFFER_STATUS notifications may
occur without user ever touching debugfs.

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20221202152841.672536-8-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 65edda60 10-Oct-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Do not print IPC error message twice

ENABLE_LOGS and SYSTEM_TIME IPCs call LARGE_CONFIG_SET internally which
dumps an error message in case of an error. There is no need to repeat
the process in the top level handler.

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20221010121955.718168-13-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 8758ae88 07-Jul-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Lower UNLOAD_MULTIPLE_MODULES IPC timeout

Module unloading operation performs memory unmapping and the weight of
the opration does not different from any other standard IPC. There is no
dependency on secondary task like in module loading scenario where
larger message timeout is recommended.

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220707124153.1858249-12-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 79c351fb 07-Jul-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Recognize FW_CFG_RESERVED

If exposed by firmware, count RESERVED parameter as known one to avoid
dumping noise in kernel logs.

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220707124153.1858249-10-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 00566ad4 07-Jul-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Shield LARGE_CONFIG_GETs against zero payload_size

Some LARGE_CONFIG_GETs are never expected to return payload of size 0.
Check for such situation and collapse if met.

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220707124153.1858249-6-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 3c1923a1 07-Jul-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Copy only as many RX bytes as necessary

There is no need to copy number of bytes specified by IPC message caller
if DSP firmware returned lower number. In consequence, LARGE_CONFIG_GET
handler is simplified.

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220707124153.1858249-5-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 335c4cbd 15-May-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: D0ix power state support

Audio DSP device supports D0 substates in form of D0ix, allowing for
preserving more power even when device is still considered active (D0).
When entered, certain domains which are not being currently used become
power gated. Entering and leaving D0ix is a complex process and differs
between firmware generations.

Conditions that disallow D0i3 and require immediate D0i0 transition
include but may not be limited to: IPC traffic, firmware tracing and
SRAM I/O. To make D0ix toggling sane, delay D0i3 transition and refresh
the timer each time an IPC is requested.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220516101116.190192-9-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 4b86115c 15-May-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Prepare for firmware tracing

Firmware provides its own debug functionality. While coredump is one of
these, traces are the main area of interest. kfifo is enlisted to cache
log data that is being pumped to driver through SRAM. Separate DSP
operations are declared as actual feature implementation differs between
firmware generations.

As log gathering involves usage of IPCs, add all necessary: ENABLE_LOGS
and SYSTEM_TIME.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220516101116.190192-8-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 580a5912 11-Mar-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Declare module configuration types

Declare structures and constants for all modules being part of basefw
binary. These are used in streaming operations to communicate the needs
of software to firmware side.

While adding module types, append handler for SET_SINK_FORMAT runtime
for COPIER module which allows for configuration of output pin other
than the default one (0).

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220311153544.136854-13-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 3322e168 11-Mar-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Add basefw runtime-parameter requests

Each module may expose a range of runtime parameters. For basefw,
implement handlers for: FIRMWARE_CONFIG, HARDWARE_CONFIG and
MODULES_INFO. These are used by driver to dynamically allocate resources
in respect to platform details, reducing number of hardcodes and code
duplications that would otherwise be needed to be defined within the
driver code.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220311153544.136854-11-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 25f414fc 11-Mar-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Add ROM requests

ROM requests are messages initiated by Host to alter firmware early boot
process. They specify whether the next boot should be a fresh start or if
IMR can be used to speed things up.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220311153544.136854-10-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# 469e87ca 11-Mar-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Add power management requests

Audio DSP supports low power states i.e.: transitions between D0 and D3
and D0-substates in form of D0i0 and D0i3. That process is a combination
of core and IPC operations. Here, Dx and D0ix IPC handlers are added.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220311153544.136854-9-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# f14a1c5a 11-Mar-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Add module management requests

Firmware modules implement processing algorithms. Their lifecycle,
similarly to pipelines is being controlled by IPCs: initialization,
deletion and (un)binding.

Modules can be configured at runtime - runtime parameters. This is done
with help of LARGE_CONFIG IPCs: getter and setter.

Due to firmware limitations, LARGE_CONFIG_GET handler implementation
does not support retrieving payload with size larger than IPC inbox
window size.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220311153544.136854-8-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# b956b27b 11-Mar-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Add pipeline management requests

Pipeline represents a scheduling entity. Their existence as well as
their state machine is controlled through CREATE_PIPELINE,
DELETE_PIPELINE and SET_PIPELINE_STATE IPCs.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220311153544.136854-7-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>


# cb1eb6b5 11-Mar-2022 Cezary Rojewski <cezary.rojewski@intel.com>

ASoC: Intel: avs: Add code loading requests

Before firmware and its modules can be used, they have to be loaded.
Code loading process is complex and is a combination of DMA and IPC
operations. Here, IPC part is being added and accounts for CLDMA and HDA
mechanisms both.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220311153544.136854-6-cezary.rojewski@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>