[alsa-devel] [PATCH 6/8] ASoC: tegra: set i2s_offset to 0 for tdm
Ben Dooks
ben.dooks at codethink.co.uk
Tue Sep 17 20:12:31 CEST 2019
Set the offset to 0 for TDM mode, as per the current setup.
Signed-off-by: Ben Dooks <ben.dooks at codethink.co.uk>
---
sound/soc/tegra/tegra30_i2s.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/sound/soc/tegra/tegra30_i2s.c b/sound/soc/tegra/tegra30_i2s.c
index d75ce12fe177..3efef87ed8d8 100644
--- a/sound/soc/tegra/tegra30_i2s.c
+++ b/sound/soc/tegra/tegra30_i2s.c
@@ -206,8 +206,11 @@ static int tegra30_i2s_hw_params(struct snd_pcm_substream *substream,
i2s->soc_data->set_audio_cif(i2s->regmap, reg, &cif_conf);
- val = (1 << TEGRA30_I2S_OFFSET_RX_DATA_OFFSET_SHIFT) |
- (1 << TEGRA30_I2S_OFFSET_TX_DATA_OFFSET_SHIFT);
+ if (i2s->is_tdm)
+ val = 0;
+ else
+ val = (1 << TEGRA30_I2S_OFFSET_RX_DATA_OFFSET_SHIFT) |
+ (1 << TEGRA30_I2S_OFFSET_TX_DATA_OFFSET_SHIFT);
regmap_write(i2s->regmap, TEGRA30_I2S_OFFSET, val);
return 0;
--
2.23.0
More information about the Alsa-devel
mailing list