]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: sun4i-i2s: Use module clock as BCLK parent on newer SoCs
authorMaxime Ripard <maxime.ripard@bootlin.com>
Mon, 19 Aug 2019 19:25:15 +0000 (21:25 +0200)
committerMark Brown <broonie@kernel.org>
Tue, 20 Aug 2019 17:31:24 +0000 (18:31 +0100)
commit4cf4dc9a3644cb2ebc94904a386a75ac219a6ff4
treed7538620d176ff99cf8b2927bf640cea63bf63f8
parentb051ebb0828fe49c6da14438a41a9f796261cdfa
ASoC: sun4i-i2s: Use module clock as BCLK parent on newer SoCs

On the first generation of Allwinner SoCs (A10-A31), the i2s controller was
using the MCLK as BCLK parent. However, this changed since the introduction
of the A83t and BCLK now uses the module clock as its parent.

Let's introduce a hook to get the parent rate and use that in our divider
calculations.

Fixes: 56bb0388a32c ("ASoC: sun4i-i2s: Add support for H3")
Fixes: 409ee34ece8c ("ASoC: sun4i-i2s: Add support for A83T")
Signed-off-by: Maxime Ripard <maxime.ripard@bootlin.com>
Link: https://lore.kernel.org/r/0b6665be216b3bd0e7bc43724818f05f3f8ee881.1566242458.git-series.maxime.ripard@bootlin.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sunxi/sun4i-i2s.c