]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: fsl_asrc: refine the setting of internal clock divider
authorShengjiu Wang <shengjiu.wang@nxp.com>
Mon, 28 Oct 2019 09:10:29 +0000 (17:10 +0800)
committerMark Brown <broonie@kernel.org>
Mon, 28 Oct 2019 13:13:18 +0000 (13:13 +0000)
commite93a76a0c1b587d8f41794dfd0c0b7c4e8257627
tree335dcb1f2fbea7a9219df81d37e5a3767367fab7
parented500d1a320b49256a80f00c8399b451955ab3d7
ASoC: fsl_asrc: refine the setting of internal clock divider

The output divider should align with the output sample
rate, if use ideal sample rate, there will be a lot of overload,
which would cause underrun.

The maximum divider of asrc clock is 1024, but there is no
judgement for this limitation in driver, which may cause the divider
setting not correct.

For non-ideal ratio mode, the clock rate should divide the sample
rate with no remainder, and the quotient should be less than 1024.

Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Acked-by: Nicolin Chen <nicoleotsuka@gmail.com>
Link: https://lore.kernel.org/r/23c634e4bf58afce5b3ae67f5f42e8d1cae2639a.1572252307.git.shengjiu.wang@nxp.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/fsl/fsl_asrc.c