summaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorVaibhav Bedia <vaibhav.bedia@ti.com>2012-08-08 20:40:31 +0530
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-08-09 14:05:47 +0100
commit0d624275720a4b01217693eb80d967a0d5f1f3a3 (patch)
tree1e3233645b1cb23bfca4e5b4c81359535679c3a3 /sound
parent0865a75d4166bddc533fd50831829ceefb94f9b0 (diff)
downloadop-kernel-dev-0d624275720a4b01217693eb80d967a0d5f1f3a3.zip
op-kernel-dev-0d624275720a4b01217693eb80d967a0d5f1f3a3.tar.gz
ASoC: Davinci: McASP: Flush the FIFO before enabling
FIFO should be flushed before it is enabled for the first time. This fixes the I/O errors reported by the ASoC core on a fresh boot Signed-off-by: Vaibhav Bedia <vaibhav.bedia@ti.com> Signed-off-by: Hebbar, Gururaja <gururaja.hebbar@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/davinci/davinci-mcasp.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/sound/soc/davinci/davinci-mcasp.c b/sound/soc/davinci/davinci-mcasp.c
index 95441bf..ce5e5cd 100644
--- a/sound/soc/davinci/davinci-mcasp.c
+++ b/sound/soc/davinci/davinci-mcasp.c
@@ -380,14 +380,20 @@ static void mcasp_start_tx(struct davinci_audio_dev *dev)
static void davinci_mcasp_start(struct davinci_audio_dev *dev, int stream)
{
if (stream == SNDRV_PCM_STREAM_PLAYBACK) {
- if (dev->txnumevt) /* enable FIFO */
+ if (dev->txnumevt) { /* enable FIFO */
+ mcasp_clr_bits(dev->base + DAVINCI_MCASP_WFIFOCTL,
+ FIFO_ENABLE);
mcasp_set_bits(dev->base + DAVINCI_MCASP_WFIFOCTL,
FIFO_ENABLE);
+ }
mcasp_start_tx(dev);
} else {
- if (dev->rxnumevt) /* enable FIFO */
+ if (dev->rxnumevt) { /* enable FIFO */
+ mcasp_clr_bits(dev->base + DAVINCI_MCASP_RFIFOCTL,
+ FIFO_ENABLE);
mcasp_set_bits(dev->base + DAVINCI_MCASP_RFIFOCTL,
FIFO_ENABLE);
+ }
mcasp_start_rx(dev);
}
}
OpenPOWER on IntegriCloud