Skip to content

Conversation

@ujfalusi
Copy link
Collaborator

Hi,

inital (draft) support for compress offload with IPC4 on Intel platforms (MTL+).

There are still missing features, and few areas to improve, tune, but it works reasonably well and the hope is that the IPC3 compr is still functional.

@dbaluta, if you could be able to test that, we would really appreciate it.

ujfalusi and others added 9 commits January 14, 2026 13:52
With DPCM when compr is used on FE side, the BE is still running as
'normal' PCM.
It is expected that the be_substream->runtime on the BE is not NULL, for
example some codec drivers expect to have the substream->runtime valid, to
store configuration for example.

Signed-off-by: Peter Ujfalusi <[email protected]>
In preparation for adding support for compressed offload support for
IPC4, rename the current compress implementation with the IPC3 prefix.
Introduce a new field in struct sof_ipc_pcm_ops to save the
IPC-specific compressed ops pointer. This should be set when the
component driver ops are assigned during SOF device probe. Expose a couple
of common functions that will be used by both IPC-specific implementations
and rename the compress.c file to ipc3-compress.c

Signed-off-by: Ranjani Sridharan <[email protected]>
Signed-off-by: Peter Ujfalusi <[email protected]>
These are common functions that will also be needed for the IPC4
compressed support.

Signed-off-by: Ranjani Sridharan <[email protected]>
Signed-off-by: Peter Ujfalusi <[email protected]>
In order to reuse the pipeline triggering logic for compressed support
with IPC4, modify the signature of the trigger and hw_free PCM IPC ops
so that they can be reused.

Signed-off-by: Ranjani Sridharan <[email protected]>
Signed-off-by: Peter Ujfalusi <[email protected]>
…ng stream

After the host DMA IID is released, reset the curr_pos to 0 for a clean
start for subsequent stream starts. This is not needed for PCM streams
but for compressed streams.

Signed-off-by: Ranjani Sridharan <[email protected]>
Signed-off-by: Peter Ujfalusi <[email protected]>
Add new ops in the struct snd_sof_ops for platform-specific ops for
compresssed streams. Also, define and set them for the HDA platforms.

Signed-off-by: Ranjani Sridharan <[email protected]>
Co-developed-by: Peter Ujfalusi <[email protected]>
Signed-off-by: Peter Ujfalusi <[email protected]>
The SOF_IPC4_MOD_INIT_DATA_ID_MODULE_DATA type within the module_init_ext
area is module specific init data.

Signed-off-by: Peter Ujfalusi <[email protected]>
…dules

Add support for handling init_ext_module_data for process modules, which is
going to be used by decoder and encoder type of process mdoules.
The support is generic and it can be extended to other type of process
modules or other module types than process with a small update of
sof_ipc4_add_init_ext_module_data() function.

Signed-off-by: Peter Ujfalusi <[email protected]>
…cm.c

The support for compressed stream will also need to have access to the
same information which is used for delay reporting for DAI data
progression tracking.

Make the necessary struct and functions to be available and premare them to
be called without a valid substream.

Signed-off-by: Peter Ujfalusi <[email protected]>
@ujfalusi
Copy link
Collaborator Author

I don't see these errors with gcc (GCC) 15.2.1 20251112 locally, hrm.

@ujfalusi ujfalusi force-pushed the peter/topic/ipc4_compr branch from cea54e7 to c3f4c47 Compare January 14, 2026 14:08
ranj063 and others added 7 commits January 14, 2026 16:09
Set and define the compressed ops for IPC4.

Signed-off-by: Ranjani Sridharan <[email protected]>
Co-developed-by: Peter Ujfalusi <[email protected]>
Signed-off-by: Peter Ujfalusi <[email protected]>
There is no need to select IPC3 and IPC4 along with INTEL_CNL as INTEL_CNL
selects both.

Similarly, INTEL_MTL selects IPC4, so there is no need to do that for LNL,
PTL and NVL.

Signed-off-by: Peter Ujfalusi <[email protected]>
Select SOF_COMPRESS for TGL and newer platforms, on Intel devices the
compressed support is available with IPC4 only.

Signed-off-by: Peter Ujfalusi <[email protected]>
Decoder and encoder modules fall under process modules in SOF.

Signed-off-by: Ranjani Sridharan <[email protected]>
Co-developed-by: Peter Ujfalusi <[email protected]>
Signed-off-by: Peter Ujfalusi <[email protected]>
…g_params

SOF_CODEC_INFO tuple holds information about the supported codecs for
decode/encode.

If present in the fw_config payload, make a copy of it and store it
sof_ipc4_fw_data->codec_info to be used by the compressed code.

Signed-off-by: Peter Ujfalusi <[email protected]>
Parse the codec_info from fw_config message if present and return the
supported codecs by the booted firmware.
If the codec_info is missing then only set the information regarding to
fragment sizes, numbers.

Signed-off-by: Peter Ujfalusi <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants