Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/audio/copier/copier.c
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,6 @@ static int create_dai(struct comp_dev *parent_dev, struct copier_data *cd,
const struct comp_driver *drv;
struct ipc_config_dai dai;
int dai_count;
int ret;
int i;

drv = ipc4_get_drv((uint8_t *)&id);
Expand Down Expand Up @@ -388,15 +387,17 @@ static int create_dai(struct comp_dev *parent_dev, struct copier_data *cd,
}

for (i = 0; i < dai_count; i++) {
int ret;

dai.dai_index = dai_index[i];
ret = init_dai(parent_dev, drv, config, copier, pipeline, &dai, type, i);
if (ret) {
comp_err(parent_dev, "failed to create dai");
break;
return ret;
}
}

return ret;
return 0;
}

static int init_pipeline_reg(struct comp_dev *dev)
Expand Down
6 changes: 1 addition & 5 deletions src/audio/data_blob.c
Original file line number Diff line number Diff line change
Expand Up @@ -281,11 +281,7 @@ int ipc4_comp_data_blob_set(struct comp_data_blob_handler *blob_handler,
int ret;
int valid_data_size;

if (!blob_handler) {
comp_err(blob_handler->dev,
"ipc4_comp_data_blob_set(): blob_handler is NULL!");
return -EINVAL;
}
assert(blob_handler);

comp_dbg(blob_handler->dev,
"ipc4_comp_data_blob_set(): data_offset = %d",
Expand Down
4 changes: 4 additions & 0 deletions src/ipc/ipc4/handler.c
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,10 @@ static int set_pipeline_state(struct ipc_comp_dev *ppl_icd, uint32_t cmd,
}
if (ret == PPL_STATUS_SCHEDULED)
*delayed = true;
break;
default:
tr_err(&ipc_tr, "ipc: invalid status %d for RESET", status);
return IPC4_INVALID_REQUEST;
}

/*
Expand Down
30 changes: 11 additions & 19 deletions src/probe/probe.c
Original file line number Diff line number Diff line change
Expand Up @@ -979,41 +979,33 @@ static struct comp_buffer *ipc4_get_buffer(struct ipc_comp_dev *dev, probe_point
struct comp_buffer *buf;
struct comp_buffer __sparse_cache *buf_c;
struct list_item *sink_list, *source_list;
unsigned int queue_id;

switch (probe_point.fields.type) {
case PROBE_TYPE_INPUT:
if (list_is_empty(&dev->cd->bsource_list))
return NULL;

list_for_item(source_list, &dev->cd->bsource_list) {
buf = container_of(source_list, struct comp_buffer, sink_list);
buf_c = buffer_acquire(buf);

if (IPC4_SRC_QUEUE_ID(buf_c->id) == probe_point.fields.index)
break;

queue_id = IPC4_SRC_QUEUE_ID(buf_c->id);
buffer_release(buf_c);

if (queue_id == probe_point.fields.index)
return buf;
}
break;
case PROBE_TYPE_OUTPUT:
if (list_is_empty(&dev->cd->bsink_list))
return NULL;

list_for_item(sink_list, &dev->cd->bsink_list) {
buf = container_of(sink_list, struct comp_buffer, source_list);
buf_c = buffer_acquire(buf);

if (IPC4_SINK_QUEUE_ID(buf_c->id) == probe_point.fields.index)
break;

queue_id = IPC4_SINK_QUEUE_ID(buf_c->id);
buffer_release(buf_c);

if (queue_id == probe_point.fields.index)
return buf;
}
break;
default:
return NULL;
}
buffer_release(buf_c);
return buf;

return NULL;
}
#endif

Expand Down