pipeline: move check for xrun

Moves xrun check in pipeline_trigger after checking
if this pipeline is running on current core. Only owner
of the pipeline should access its data.

Signed-off-by: Tomasz Lauda <tomasz.lauda@linux.intel.com>
This commit is contained in:
Tomasz Lauda 2019-08-01 12:48:36 +02:00 committed by Liam Girdwood
parent 39b59af35f
commit 397c1a0d94
1 changed files with 4 additions and 4 deletions

View File

@ -607,6 +607,10 @@ int pipeline_trigger(struct pipeline *p, struct comp_dev *host, int cmd)
trace_pipe_with_ids(p, "pipeline_trigger()");
/* if current core is different than requested */
if (p->ipc_pipe.core != cpu_get_id())
return pipeline_trigger_on_core(p, host, cmd);
/* handle pipeline global checks before going into each components */
if (p->xrun_bytes) {
ret = pipeline_xrun_handle_trigger(p, cmd);
@ -619,10 +623,6 @@ int pipeline_trigger(struct pipeline *p, struct comp_dev *host, int cmd)
return 0;
}
/* if current core is different than requested */
if (p->ipc_pipe.core != cpu_get_id())
return pipeline_trigger_on_core(p, host, cmd);
data.start = host;
data.cmd = cmd;