[PATCH v2 12/17] ASoC: sun8i-codec: Protect the clock rate while streams are open
Maxime Ripard
maxime at cerno.tech
Mon Oct 19 10:28:08 CEST 2020
On Wed, Oct 14, 2020 at 01:19:36AM -0500, Samuel Holland wrote:
> The codec's clock input is shared among all AIFs, and shared with other
> audio-related hardware in the SoC, including I2S and SPDIF controllers.
> To ensure sample rates selected by userspace or by codec2codec DAI links
> are maintained, the clock rate must be protected while it is in use.
>
> Signed-off-by: Samuel Holland <samuel at sholland.org>
> ---
> sound/soc/sunxi/Kconfig | 1 +
> sound/soc/sunxi/sun8i-codec.c | 29 +++++++++++++++++++++++++++--
> 2 files changed, 28 insertions(+), 2 deletions(-)
>
> diff --git a/sound/soc/sunxi/Kconfig b/sound/soc/sunxi/Kconfig
> index 9cd7009cb570..69b9d8515335 100644
> --- a/sound/soc/sunxi/Kconfig
> +++ b/sound/soc/sunxi/Kconfig
> @@ -9,16 +9,17 @@ config SND_SUN4I_CODEC
> help
> Select Y or M to add support for the Codec embedded in the Allwinner
> A10 and affiliated SoCs.
>
> config SND_SUN8I_CODEC
> tristate "Allwinner SUN8I audio codec"
> depends on OF
> depends on MACH_SUN8I || (ARM64 && ARCH_SUNXI) || COMPILE_TEST
> + select COMMON_CLK
Wouldn't a depends on make more sense here? It's kind of weird to pull
it from a driver when the platform that would run it has no CCF support.
With this changed,
Acked-by: Maxime Ripard <mripard at kernel.org>
Maxime
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20201019/675e5f6c/attachment-0001.sig>
More information about the Alsa-devel
mailing list