mirror of https://github.com/thesofproject/sof.git
ipc: validate pipeline on stream free IPC.
Make sure we have a valid pipeline for stream free IPC calls. Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
This commit is contained in:
parent
27d354dbde
commit
7d00023689
|
@ -287,6 +287,13 @@ static int ipc_stream_pcm_free(uint32_t header)
|
|||
return -ENODEV;
|
||||
}
|
||||
|
||||
/* sanity check comp */
|
||||
if (pcm_dev->cd->pipeline == NULL) {
|
||||
trace_ipc_error("eF1");
|
||||
trace_value(free_req->comp_id);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
/* reset the pipeline */
|
||||
return pipeline_reset(pcm_dev->cd->pipeline, pcm_dev->cd);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue