android_kernel_xiaomi_sm8450/sound/soc/meson
Jerome Brunet 24d71c7e46 ASoC: meson: axg-tdm-interface: add frame rate constraint
[ Upstream commit 59c6a3a43b221cc2a211181b1298e43b2c2df782 ]

According to Amlogic datasheets for the SoCs supported by this driver, the
maximum bit clock rate is 100MHz.

The tdm interface allows the rates listed by the DAI driver, regardless of
the number slots or their width. However, these will impact the bit clock
rate.

Hitting the 100MHz limit is very unlikely for most use cases but it is
possible.

For example with 32 slots / 32 bits wide, the maximum rate is no longer
384kHz but ~96kHz.

Add the constraint accordingly if the component is not already active.
If it is active, the rate is already constrained by the first stream rate.

Fixes: d60e4f1e4b ("ASoC: meson: add tdm interface driver")
Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
Link: https://msgid.link/r/20240223175116.2005407-3-jbrunet@baylibre.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-03-26 18:21:59 -04:00
..
aiu-acodec-ctrl.c ASoC: meson: Fix event generation for AUI ACODEC mux 2022-05-12 12:25:33 +02:00
aiu-codec-ctrl.c ASoC: meson: Fix event generation for AUI CODEC mux 2022-05-12 12:25:33 +02:00
aiu-encoder-i2s.c ASoC: meson: aiu: Move AIU_I2S_MISC hold setting to aiu-fifo-i2s 2021-12-29 12:26:01 +01:00
aiu-encoder-spdif.c ASoC: meson: aiu: add i2s and spdif support 2020-02-13 20:57:22 +00:00
aiu-fifo-i2s.c ASoC: meson: aiu: Move AIU_I2S_MISC hold setting to aiu-fifo-i2s 2021-12-29 12:26:01 +01:00
aiu-fifo-spdif.c ASoC: meson: aiu: add i2s and spdif support 2020-02-13 20:57:22 +00:00
aiu-fifo.c ASoC: meson: aiu: fifo: Add missing dma_coerce_mask_and_coherent() 2021-12-29 12:25:55 +01:00
aiu-fifo.h ASoC: meson: aiu: add i2s and spdif support 2020-02-13 20:57:22 +00:00
aiu.c ASoC: meson: aiu: fix function pointer type mismatch 2024-03-26 18:21:57 -04:00
aiu.h ASoC: meson: aiu: fix function pointer type mismatch 2024-03-26 18:21:57 -04:00
axg-card.c Merge remote-tracking branch 'asoc/for-5.9' into asoc-next 2020-07-31 19:54:03 +01:00
axg-fifo.c ASoC: meson: Use dev_err_probe() helper 2024-03-26 18:21:57 -04:00
axg-fifo.h ASoC: meson: axg-fifo: relax period size constraints 2019-12-18 20:01:34 +00:00
axg-frddr.c ASoC: meson: axg-fifo: improve depth handling 2019-12-18 20:01:15 +00:00
axg-pdm.c ASoC: meson: Use dev_err_probe() helper 2024-03-26 18:21:57 -04:00
axg-spdifin.c ASoC: meson: Use dev_err_probe() helper 2024-03-26 18:21:57 -04:00
axg-spdifout.c ASoC: meson: Use dev_err_probe() helper 2024-03-26 18:21:57 -04:00
axg-tdm-formatter.c ASoC: meson: Use dev_err_probe() helper 2024-03-26 18:21:57 -04:00
axg-tdm-formatter.h ASoC: meson: axg-tdm-formatters: fix sclk inversion 2020-07-30 19:45:01 +01:00
axg-tdm-interface.c ASoC: meson: axg-tdm-interface: add frame rate constraint 2024-03-26 18:21:59 -04:00
axg-tdm.h ASoC: meson: axg-tdm: fix sample clock inversion 2019-06-13 19:44:02 +01:00
axg-tdmin.c ASoC: meson: axg-tdmin: fix axg skew offset 2021-01-19 18:27:29 +01:00
axg-tdmout.c ASoC: meson: axg-tdm-formatters: fix sclk inversion 2020-07-30 19:45:01 +01:00
axg-toddr.c ASoC: meson: axg-toddr: fix channel order on g12 platforms 2020-08-28 19:02:54 +01:00
g12a-toacodec.c ASoC: meson: g12a-toacodec: Fix event generation 2024-01-15 18:48:05 +01:00
g12a-tohdmitx.c ASoC: meson: g12a-tohdmitx: Fix event generation for S/PDIF mux 2024-01-15 18:48:05 +01:00
gx-card.c Merge remote-tracking branch 'asoc/for-5.9' into asoc-next 2020-07-31 19:54:03 +01:00
Kconfig ASoC: meson: fix COMPILE_TEST error 2020-12-30 11:53:12 +01:00
Makefile ASoC: meson: g12a: add internal DAC glue driver 2020-02-21 16:39:04 +00:00
meson-card-utils.c ASoC: meson: Use dev_err_probe() helper 2024-03-26 18:21:57 -04:00
meson-card.h ASoC: meson: axg: extract sound card utils 2020-02-13 20:57:25 +00:00
meson-codec-glue.c ASoC: meson: use asoc_substream_to_rtd() 2020-07-23 19:07:35 +01:00
meson-codec-glue.h ASoC: meson: g12a: extract codec-to-codec utils 2020-02-13 20:57:20 +00:00
t9015.c ASoC: meson: t9015: fix function pointer type mismatch 2024-03-26 18:21:57 -04:00