src: return number of frames produced in copy

Return the number of frames we produce in the copy() function.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
This commit is contained in:
Liam Girdwood 2017-12-08 20:34:29 +00:00
parent 186806d11e
commit e0f65a2b82
1 changed files with 4 additions and 1 deletions

View File

@ -535,9 +535,12 @@ static int src_copy(struct comp_dev *dev)
if (consumed > 0) if (consumed > 0)
comp_update_buffer_consume(source, consumed); comp_update_buffer_consume(source, consumed);
if (produced > 0) if (produced > 0) {
comp_update_buffer_produce(sink, produced); comp_update_buffer_produce(sink, produced);
return cd->param.blk_out;
}
/* produced no data */
return 0; return 0;
} }