| 8a99ccb0 | 09-Mar-2026 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Migrate to the new control operations
Switch to the new implementation and remove all unused code. The change effectively causes the control put() operations to return '1' if a c
ASoC: Intel: catpt: Migrate to the new control operations
Switch to the new implementation and remove all unused code. The change effectively causes the control put() operations to return '1' if a change occurred, '0' if no change was made or error otherwise.
The second effect of the update is reducing the power consumption. With the new control-operations in place, the controls no longer wake the DSP just for the sake of updating volume (or mute) settings on the firmware side. The values are cached and actual update occurs only when streams are being opened for streaming or are already running.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20260309091605.896307-6-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| 150badf7 | 09-Mar-2026 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Do not wake DSP just for volume setup
With the new control-operations in place, the controls no longer wake the DSP just for the sake of updating volume (or mute) settings on the
ASoC: Intel: catpt: Do not wake DSP just for volume setup
With the new control-operations in place, the controls no longer wake the DSP just for the sake of updating volume (or mute) settings on the firmware side. The values are cached and actual update occurs only when streams are being opened for streaming or are already running. In those cases the DSP must already be woken up and we avoid unnecessary power consumption.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20260309091605.896307-5-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| 2464febd | 09-Mar-2026 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Simplify procedure of applying user settings
Existing catpt_dai_apply_usettings() applies all the individual control settings but why-what is covered behind if-statements. Refact
ASoC: Intel: catpt: Simplify procedure of applying user settings
Existing catpt_dai_apply_usettings() applies all the individual control settings but why-what is covered behind if-statements. Refactor the operation into:
catpt_apply_controls() |__ catpt_apply_volume() |__ catpt_apply_mute()
to make it easy to understand why and what is going on. The update also enlists snd_ctl_find_id_mixer() for the query purpose, removing code duplication.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20260309091605.896307-4-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| d16b942a | 09-Mar-2026 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: New volume and mute control operations
The catpt-driver's volume and mute control operations always return '0' regardless if a change occurred or not. To conform to ALSA's interf
ASoC: Intel: catpt: New volume and mute control operations
The catpt-driver's volume and mute control operations always return '0' regardless if a change occurred or not. To conform to ALSA's interface, value '1' shall be returned when a change occurred.
The second major point is power consumption. Existing control operations always wake the DSP even if no streams are running. In such case waking the DSP just for the sake of updating the volume (or mute) settings on the firmware side is a waste of power. The provided implementation caches the values and updates the settings only when streams are being opened for streaming or are already running.
As changing existing code is non-trivial, provide new operations instead. The put() operation, which interests us the most, takes the following shape:
// two values provided to put(): // pin_id - which stream given control relates to // value_to_apply - the value from user
if (control->existing_val == value_to_apply) return 0;
runtime_stream = get_running_stream(pin_id); if (runtime_stream != NULL) { ret = send_ipc(); if (ret) return ret; }
control->existing_val = value_to_apply; return 1;
Adheres to ALSA's expectation and avoids sending IPCs if there is no change to be made.
Two helpers which are part of the patch, catpt_stream_hw_id() and catpt_stream_volume_regs(), help differentiate between individual streams and the general MIXER stream. Translates to one pair of get()/put() instead of two pairs as done currently.
PIN_ID_INVALID is returned if given stream is not currently running - the constant is part of the firmware's API but remained unused by the driver.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20260309091605.896307-3-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| aa30193a | 12-Dec-2025 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Drop superfluous space in PCM code
Those spaces are redundant.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20251212103858.110701-6-
ASoC: Intel: catpt: Drop superfluous space in PCM code
Those spaces are redundant.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20251212103858.110701-6-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| e97e0713 | 12-Dec-2025 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Specify image names in the device descriptor
State files to load explicitly in the device descriptor instead of hiding the details within a loading function. Apart from readabili
ASoC: Intel: catpt: Specify image names in the device descriptor
State files to load explicitly in the device descriptor instead of hiding the details within a loading function. Apart from readability, this also reduces the catpt module size slightly.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20251212103858.110701-5-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| d44f62b0 | 12-Dec-2025 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Simplify catpt_stream_read_position()
Add position to the argument list to simplify the wrapper.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.m
ASoC: Intel: catpt: Simplify catpt_stream_read_position()
Add position to the argument list to simplify the wrapper.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20251212103858.110701-4-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| eded4483 | 12-Dec-2025 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Update CATPT_IPC_ERROR macro
Make it easier for functions that call IPC handlers to deal with their results by accounting for '0' (success) code. Rename the macro to reflect this
ASoC: Intel: catpt: Update CATPT_IPC_ERROR macro
Make it easier for functions that call IPC handlers to deal with their results by accounting for '0' (success) code. Rename the macro to reflect this behaviour change.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20251212103858.110701-3-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| 56736543 | 26-Nov-2025 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Do not block the system from suspending
Even if something goes wrong when performing suspend on DSP, from the system perspective the component is not critical enough to block the
ASoC: Intel: catpt: Do not block the system from suspending
Even if something goes wrong when performing suspend on DSP, from the system perspective the component is not critical enough to block the suspend operation entirely. Leaving recovery to next resume() suffices.
Suggested-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20251126095523.3925364-7-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| 8a342b2b | 26-Nov-2025 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Do not ignore errors on runtime resume
If pm_runtime_resume_and_get() fails, follow up pm_runtime_xxx() operate on device in erroneous state.
Signed-off-by: Cezary Rojewski <cez
ASoC: Intel: catpt: Do not ignore errors on runtime resume
If pm_runtime_resume_and_get() fails, follow up pm_runtime_xxx() operate on device in erroneous state.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20251126095523.3925364-6-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| 16e17736 | 26-Nov-2025 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Fix probing order of driver components
catpt_dai_pcm_new() is called during the bring up sequence of the machine board device which is a different device to the parent (DSP) devi
ASoC: Intel: catpt: Fix probing order of driver components
catpt_dai_pcm_new() is called during the bring up sequence of the machine board device which is a different device to the parent (DSP) device yet utilizes pm_runtime_xxx() against it in order to send IPCs. If the parent's pm_runtime is not configured before that happens, errors will occur.
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://patch.msgid.link/20251126095523.3925364-5-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| 86a5b621 | 26-Nov-2025 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Fix error path in hw_params()
Do not leave any resources hanging on the DSP side if applying user settings fails.
Fixes: 768a3a3b327d ("ASoC: Intel: catpt: Optimize applying use
ASoC: Intel: catpt: Fix error path in hw_params()
Do not leave any resources hanging on the DSP side if applying user settings fails.
Fixes: 768a3a3b327d ("ASoC: Intel: catpt: Optimize applying user settings") Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://patch.msgid.link/20251126095523.3925364-4-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| ea38b262 | 26-Nov-2025 |
Cezary Rojewski <cezary.rojewski@intel.com> |
ASoC: Intel: catpt: Switch to resource_xxx() API
There is a number of interfaces available for manipulating instances of struct resource. To improve readability, move away from manual editing in fav
ASoC: Intel: catpt: Switch to resource_xxx() API
There is a number of interfaces available for manipulating instances of struct resource. To improve readability, move away from manual editing in favor of the common interface.
While at it, adjust spacing so that both code blocks, while found in separate functions, looks cohesive.
Suggested-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://patch.msgid.link/20251126095523.3925364-3-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|