diff options
author | Nicolin Chen <b42378@freescale.com> | 2013-11-11 16:31:22 +0800 |
---|---|---|
committer | Nitin Garg <nitin.garg@freescale.com> | 2014-04-16 08:47:11 -0500 |
commit | 7e64647281d80ebe3e2e37622a34793adc846eb3 (patch) | |
tree | 5224b3f13df91e1c96cc243062420c0f0d145617 /sound/soc | |
parent | a566e6bcb46b34a34dd390f3a2f596c9e8270319 (diff) |
ENGR00286961-5 ASoC: fsl: set tdm slot number for imx-si476x
When using SSI I2S master mode, we need to decide the time slot number.
Because we use SSI normal mode to trick I2S signal, we here need to set
time slot number to two (left/right).
Acked-by: Wang Shengjiu <b02247@freescale.com>
Signed-off-by: Nicolin Chen <b42378@freescale.com>
Diffstat (limited to 'sound/soc')
-rw-r--r-- | sound/soc/fsl/imx-si476x.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/sound/soc/fsl/imx-si476x.c b/sound/soc/fsl/imx-si476x.c index 3d56912ed5f4..621fd1823a55 100644 --- a/sound/soc/fsl/imx-si476x.c +++ b/sound/soc/fsl/imx-si476x.c @@ -56,6 +56,15 @@ static int imx_si476x_hw_params(struct snd_pcm_substream *substream, return ret; } + ret = snd_soc_dai_set_tdm_slot(cpu_dai, + channels == 1 ? 0xfffffffe : 0xfffffffc, + channels == 1 ? 0xfffffffe : 0xfffffffc, + 2, 32); + if (ret) { + dev_err(cpu_dai->dev, "failed to set dai tdm slot\n"); + return ret; + } + ret = snd_soc_dai_set_sysclk(cpu_dai, 0, bclk, SND_SOC_CLOCK_OUT); if (ret) dev_err(cpu_dai->dev, "failed to set sysclk\n"); |