Skip to content

Audio: Fix the init() in modules to not initialize bytes control with invalid data#10646

Draft
singalsu wants to merge 8 commits intothesofproject:mainfrom
singalsu:fix_modules_no_blob_in_init
Draft

Audio: Fix the init() in modules to not initialize bytes control with invalid data#10646
singalsu wants to merge 8 commits intothesofproject:mainfrom
singalsu:fix_modules_no_blob_in_init

Conversation

@singalsu
Copy link
Collaborator

No description provided.

The pass of bytes control in init() was used in some very early
IPC3 kernels. With IPC4 the module configuration data is not for
control. If a topology does not contain a blob to initialize the
control, the comp_init_data_blob() call initializes to blob
handler an invalid blob that is attempted to be used in prepare().
The prepare() then fails with invalid blob detected while it
should result to pass-through mode.

A check is also added to prepare() for the data_size
from comp_get_data_blob().

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
The pass of bytes control in init() was used in some very early
IPC3 kernels. With IPC4 the module configuration data is not for
control. If a topology does not contain a blob to initialize the
control, the comp_init_data_blob() call initializes to blob
handler an invalid blob that is attempted to be used in prepare().
The prepare() then fails with invalid blob detected while it
should result to pass-through mode. A check is also added to
prepare() for the data_size from comp_get_data_blob().

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
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.

1 participant