Skip to content

Commit

Permalink
ipc3: override type field once comp_driver found
Browse files Browse the repository at this point in the history
A bad IPC can mismatch UUID and type, causing downstream processes to
operate differently than the final component target. This is because
get_drv will not reject the mismatch and given we don't know the
state of topology we can't start now. Instead we can override the ipc
with the proper type.

Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
  • Loading branch information
cujomalainey authored and lgirdwood committed Sep 26, 2024
1 parent 4bec102 commit b53573a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ipc/ipc3/helper.c
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ static const struct comp_driver *get_drv(struct sof_ipc_comp *comp)
info = container_of(clist, struct comp_driver_info,
list);
if (!memcmp(info->drv->uid, comp_ext->uuid,
UUID_SIZE)) {
UUID_SIZE) && comp->type == info->drv->type) {
drv = info->drv;
break;
}
Expand Down

0 comments on commit b53573a

Please sign in to comment.