Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
audio: dai-zephyr: reset DMA buffer cursors on TRIGGER_RELEASE
On NXP platforms, stopping the DMAC and then re-configuring it leads to the internal DMA buffer cursors being reset. Leaving the SOF DMA buffer cursors in the same state means the DMA driver and SOF may potentially end up with two different views of the same buffer (from the cursors' point of view). This in, turn, may lead to the DAI consuming stale data because of the values of "free" and "pending" queried from dma_reload() stopping dai_common_copy() from copying new data. To fix this, reset the read and write cursors of the DMA buffer from SOF side. This way, both SOF and the DMA driver will have the same initial view of the DMA buffer cursors. Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
- Loading branch information