ASoC: fsl_asrc_dma: Fix data copying speed issue with EDMA
authorShengjiu Wang <shengjiu.wang@nxp.com>
Fri, 12 Jun 2020 07:37:51 +0000 (15:37 +0800)
committerMark Brown <broonie@kernel.org>
Fri, 12 Jun 2020 13:18:04 +0000 (14:18 +0100)
commitb287a6d9723c601dd947f1c27d4cc0192e384a5a
treeeda9dcf3904cf052a079c37f6502232d98471020
parent706e2c8811585f42612b6cff218ab3adbe63a4ee
ASoC: fsl_asrc_dma: Fix data copying speed issue with EDMA

With EDMA, there is two dma channels can be used for dev_to_dev,
one is from ASRC, one is from another peripheral (ESAI or SAI).

If we select the dma channel of ASRC, there is an issue for ideal
ratio case, the speed of copy data is faster than sample
frequency, because ASRC output data is very fast in ideal ratio
mode.

So it is reasonable to use the dma channel of Back-End peripheral.
then copying speed of DMA is controlled by data consumption
speed in the peripheral FIFO,

Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Reviewed-by: Nicolin Chen <nicoleotsuka@gmail.com>
Link: https://lore.kernel.org/r/424ed6c249bafcbe30791c9de0352821c5ea67e2.1591947428.git.shengjiu.wang@nxp.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/fsl/fsl_asrc_common.h
sound/soc/fsl/fsl_asrc_dma.c