aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/omap
diff options
context:
space:
mode:
authorAxel Castaneda Gonzalez <x0055901@ti.com>2012-04-22 23:05:36 -0500
committerDmytro Kedrovskyi <x0169235@ti.com>2012-05-11 17:06:55 +0300
commit976a2e2b2c73aa656955c8b4dba3d0ab8f064b31 (patch)
treecb94848bd95213e90c9c80f45d43a30924d2b41f /sound/soc/omap
parent8b73bbf6ea6fc837b18c0926303dc531813bda25 (diff)
downloadkernel_samsung_espresso10-976a2e2b2c73aa656955c8b4dba3d0ab8f064b31.zip
kernel_samsung_espresso10-976a2e2b2c73aa656955c8b4dba3d0ab8f064b31.tar.gz
kernel_samsung_espresso10-976a2e2b2c73aa656955c8b4dba3d0ab8f064b31.tar.bz2
ASoC: sdp4430: Use internal clock for DMic legacy
Configure DMic Legacy DAI to use OMAP_DMIC_SYSCLK_MUX_CLKS as FCLK. When using OMAP_DMIC_SYSCLK_PAD_CLKS (provided by TWL6040) as an external FCLK, ABE_ICLK2 gets gated just before the start of the information exchange between DMic and the host, which causes the DMic FIFO to get full before data gets consumed. Using OMAP_DMIC_SYSCLK_MUX_CLKS prevents this behavior. Change-Id: Iccda2327a5379e200f877b46c9497060c10668a8 Signed-off-by: Axel Castaneda Gonzalez <x0055901@ti.com>
Diffstat (limited to 'sound/soc/omap')
-rwxr-xr-xsound/soc/omap/sdp4430.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/sound/soc/omap/sdp4430.c b/sound/soc/omap/sdp4430.c
index 02fe2db..de4ac69 100755
--- a/sound/soc/omap/sdp4430.c
+++ b/sound/soc/omap/sdp4430.c
@@ -285,13 +285,25 @@ static int sdp4430_dmic_hw_params(struct snd_pcm_substream *substream,
struct snd_soc_dai *cpu_dai = rtd->cpu_dai;
int ret = 0;
- ret = snd_soc_dai_set_sysclk(cpu_dai, OMAP_DMIC_SYSCLK_PAD_CLKS,
- 19200000, SND_SOC_CLOCK_IN);
+ if (!rtd->dai_link->no_pcm)
+ ret = snd_soc_dai_set_sysclk(cpu_dai,
+ OMAP_DMIC_SYSCLK_SYNC_MUX_CLKS, 24000000,
+ SND_SOC_CLOCK_IN);
+ else
+ ret = snd_soc_dai_set_sysclk(cpu_dai,
+ OMAP_DMIC_SYSCLK_PAD_CLKS, 19200000,
+ SND_SOC_CLOCK_IN);
+
if (ret < 0) {
printk(KERN_ERR "can't set DMIC cpu system clock\n");
return ret;
}
- ret = snd_soc_dai_set_clkdiv(cpu_dai, OMAP_DMIC_CLKDIV, 8);
+
+ if (!rtd->dai_link->no_pcm)
+ ret = snd_soc_dai_set_clkdiv(cpu_dai, OMAP_DMIC_CLKDIV, 10);
+ else
+ ret = snd_soc_dai_set_clkdiv(cpu_dai, OMAP_DMIC_CLKDIV, 8);
+
if (ret < 0) {
printk(KERN_ERR "can't set DMIC cpu clock divider\n");
return ret;