aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/davinci
diff options
context:
space:
mode:
authorRajashekhara, Sudhakar <sudhakar.raj@ti.com>2011-07-20 08:06:04 -0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2011-07-20 15:51:23 -0400
commit3012f43eaf7592d8121426918e43e3b5db013aff (patch)
tree558d96ee81c9d086d0009179903cccb5aa852e8e /sound/soc/davinci
parentc219c80929ca942c38334aad38b7582aed4e038e (diff)
ASoC: davinci: fix codec start and stop functions
According to DM365 voice codec data sheet at [1], before starting recording or playback, ADC/DAC modules should follow a reset and enable cycle. Writing a 1 to the ADC/DAC bit in the register resets the module and clearing the bit to 0 will enable the module. But the driver seems to be doing the reverse of it. [1] http://focus.ti.com/lit/ug/sprufi9b/sprufi9b.pdf Signed-off-by: Rajashekhara, Sudhakar <sudhakar.raj@ti.com> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@kernel.org
Diffstat (limited to 'sound/soc/davinci')
-rw-r--r--sound/soc/davinci/davinci-vcif.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sound/soc/davinci/davinci-vcif.c b/sound/soc/davinci/davinci-vcif.c
index 9259f1f3489..c957e9e4a73 100644
--- a/sound/soc/davinci/davinci-vcif.c
+++ b/sound/soc/davinci/davinci-vcif.c
@@ -62,9 +62,9 @@ static void davinci_vcif_start(struct snd_pcm_substream *substream)
62 w = readl(davinci_vc->base + DAVINCI_VC_CTRL); 62 w = readl(davinci_vc->base + DAVINCI_VC_CTRL);
63 63
64 if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) 64 if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK)
65 MOD_REG_BIT(w, DAVINCI_VC_CTRL_RSTDAC, 1); 65 MOD_REG_BIT(w, DAVINCI_VC_CTRL_RSTDAC, 0);
66 else 66 else
67 MOD_REG_BIT(w, DAVINCI_VC_CTRL_RSTADC, 1); 67 MOD_REG_BIT(w, DAVINCI_VC_CTRL_RSTADC, 0);
68 68
69 writel(w, davinci_vc->base + DAVINCI_VC_CTRL); 69 writel(w, davinci_vc->base + DAVINCI_VC_CTRL);
70} 70}
@@ -80,9 +80,9 @@ static void davinci_vcif_stop(struct snd_pcm_substream *substream)
80 /* Reset transmitter/receiver and sample rate/frame sync generators */ 80 /* Reset transmitter/receiver and sample rate/frame sync generators */
81 w = readl(davinci_vc->base + DAVINCI_VC_CTRL); 81 w = readl(davinci_vc->base + DAVINCI_VC_CTRL);
82 if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) 82 if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK)
83 MOD_REG_BIT(w, DAVINCI_VC_CTRL_RSTDAC, 0); 83 MOD_REG_BIT(w, DAVINCI_VC_CTRL_RSTDAC, 1);
84 else 84 else
85 MOD_REG_BIT(w, DAVINCI_VC_CTRL_RSTADC, 0); 85 MOD_REG_BIT(w, DAVINCI_VC_CTRL_RSTADC, 1);
86 86
87 writel(w, davinci_vc->base + DAVINCI_VC_CTRL); 87 writel(w, davinci_vc->base + DAVINCI_VC_CTRL);
88} 88}