]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: soc-pcm: Don't zero TDM masks in __soc_pcm_open()
authorRichard Fitzgerald <rf@opensource.cirrus.com>
Fri, 4 Nov 2022 13:22:13 +0000 (13:22 +0000)
committerMark Brown <broonie@kernel.org>
Thu, 10 Nov 2022 21:01:48 +0000 (21:01 +0000)
commit7950205d10759b7ab57b30d0c38fa101c0b78005
tree9ebd3800fb3bea9815a306fc715c9af9f69658ac
parented211ee25ed27d16e6098af8e39dae7246292d17
ASoC: soc-pcm: Don't zero TDM masks in __soc_pcm_open()

The DAI tx_mask and rx_mask are set by snd_soc_dai_set_tdm_slot()
and used by later code that depends on the TDM settings. So
__soc_pcm_open() should not be obliterating those mask values.

The code in __soc_pcm_hw_params() uses these masks to calculate the
active channels so that only the AIF_IN/AIF_OUT widgets for the
active TDM slots are enabled. The zeroing of the masks in
__soc_pcm_open() disables this functionality so all AIF widgets
were enabled even for channels that are not assigned to a TDM slot.

Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com>
Fixes: 510a8bf0e95d ("ASoC: pcm: Add support for DAI multicodec")
Link: https://lore.kernel.org/r/20221104132213.121847-1-rf@opensource.cirrus.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/soc-pcm.c