OSDN Git Service

ASoC: tegra: Add audio graph based card driver
authorSameer Pujar <spujar@nvidia.com>
Tue, 19 Jan 2021 09:28:13 +0000 (14:58 +0530)
committerMark Brown <broonie@kernel.org>
Tue, 19 Jan 2021 14:09:21 +0000 (14:09 +0000)
commit202e2f7745437aa5b694de92cbd30bb43b23fbed
treecbf299a22af80faca5e807e37b3a880cb3074e3c
parenta9f22c03a8ac5d21ce7a9b9307d9654c963a1f9c
ASoC: tegra: Add audio graph based card driver

Add Tegra audio machine driver which is based on generic audio graph card
driver. It re-uses most of the common stuff from audio graph driver and
uses the same DT binding. Required Tegra specific customizations are done
in the driver and additional DT bindings are required for clock handling.

Details on the customizations done:

 - Update PLL rates at runtime: Tegra HW supports multiple sample rates
   (multiples of 8x and 11.025x) and both of these groups require different
   PLL rates. Hence there is a requirement to update this at runtime.
   This is achieved by providing a custom 'snd_soc_ops' and in hw_param()
   callback PLL rate is updated as per the sample rate.

 - Internal structure 'tegra_audio_graph_data' is used to maintain clock
   handles of PLL.

 - The 'force_dpcm' flag is set to use DPCM for all DAI links.

 - The 'component_chaining' flag is set to use DPCM with component model.

Signed-off-by: Sameer Pujar <spujar@nvidia.com>
Reviewed-by: Jon Hunter <jonathanh@nvidia.com>
Link: https://lore.kernel.org/r/1611048496-24650-4-git-send-email-spujar@nvidia.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/tegra/Kconfig
sound/soc/tegra/Makefile
sound/soc/tegra/tegra_audio_graph_card.c [new file with mode: 0644]