diff options
| author | Mark Brown <broonie@kernel.org> | 2026-09-14 00:37:42 +0100 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2026-09-14 00:37:42 +0100 |
| commit | 0cde044bc4768203ae70840eafe9df1290d8cb22 (patch) | |
| tree | f880e72c75475630068a9aa88ee6c11e028b7273 /include | |
| parent | d56fe35c1bce1f547eb600695f60c139a508ff6e (diff) | |
| parent | b5b00a57868b1eabdf90a29a51f0eb732c609f3a (diff) | |
| download | linux-0cde044bc4768203ae70840eafe9df1290d8cb22.tar.gz linux-0cde044bc4768203ae70840eafe9df1290d8cb22.zip | |
ASoC: Fix missing channel fixup for codec end of ch_map
Richard Fitzgerald <rf@opensource.cirrus.com> says:
Struct snd_soc_dai_link_ch_map had a single mask member to set the
CPU channel masks. But no fixup was done to the codec end of the link.
For example if a 4-channel CPU capture DAI was made from two codecs both
supplying 2 channels, the hw_params() of the codec would be passed a
channel count of 4.
On SoundWire this could cause multiple codecs to send data in the same
bits of a frame because the unused channels were not disabled.
The changes in this series are:
- Separate channel masks for CPU and codec in struct
snd_soc_dai_link_ch_map .
- Apply the codec channel mask as a channel count fixup if the machine
drive has not set a TDM mask.
- Set the codec channel mask in the SoundWire machine driver.
- Remove the workaround from the cs_amp machine driver.
Link: https://patch.msgid.link/20260910114500.1586637-1-rf@opensource.cirrus.com
Diffstat (limited to 'include')
| -rw-r--r-- | include/sound/soc.h | 3 | ||||
| -rw-r--r-- | include/sound/soc_sdw_utils.h | 2 |
2 files changed, 2 insertions, 3 deletions
diff --git a/include/sound/soc.h b/include/sound/soc.h index f46b2bc2a022..5afc34b147b5 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -699,7 +699,8 @@ struct snd_soc_dai_link_component { struct snd_soc_dai_link_ch_map { unsigned int cpu; unsigned int codec; - unsigned int ch_mask; + unsigned int cpu_ch_mask; + unsigned int codec_ch_mask; }; struct snd_soc_dai_link { diff --git a/include/sound/soc_sdw_utils.h b/include/sound/soc_sdw_utils.h index 9b28e9aef4f1..9fbb69b9052d 100644 --- a/include/sound/soc_sdw_utils.h +++ b/include/sound/soc_sdw_utils.h @@ -250,8 +250,6 @@ int asoc_sdw_cs_amp_init(struct snd_soc_card *card, struct snd_soc_dai_link *dai_links, struct asoc_sdw_codec_info *info, bool playback); -int asoc_sdw_cs_spk_feedback_rtd_init(struct snd_soc_pcm_runtime *rtd, - struct snd_soc_dai *dai); int asoc_sdw_cs35l56_volume_limit(struct snd_soc_card *card, const char *name_prefix); /* MAXIM codec support */ |
