diff options
author | madmonkey <madfkingmonkey@gmail.com> | 2018-07-26 02:07:39 +0300 |
---|---|---|
committer | madmonkey <madfkingmonkey@gmail.com> | 2018-07-26 02:08:32 +0300 |
commit | 8a2777b41a5af447d35f43b36df0c2910b7136c9 (patch) | |
tree | 75d05a74cd9ea0cc9c6f3feb324627fff67948cc /sound | |
parent | 9f53fdde860f03c64b78091dea3b1055652965a0 (diff) |
sound fix
Diffstat (limited to 'sound')
-rw-r--r-- | sound/soc/sunxi/i2s0/sunxi-i2s0.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sound/soc/sunxi/i2s0/sunxi-i2s0.c b/sound/soc/sunxi/i2s0/sunxi-i2s0.c index b9f028e7..d94b8b29 100644 --- a/sound/soc/sunxi/i2s0/sunxi-i2s0.c +++ b/sound/soc/sunxi/i2s0/sunxi-i2s0.c @@ -90,10 +90,6 @@ static struct sunxi_dma_params sunxi_i2s0_pcm_stereo_in = { static void sunxi_snd_txctrl_i2s0(struct snd_pcm_substream *substream, int on) { u32 reg_val; - /*for test*/ -// reg_val = readl(sunxi_i2s0.regs + SUNXI_I2S0CTL); -// reg_val |= SUNXI_I2S0CTL_LOOP; -// writel(reg_val, sunxi_i2s0.regs + SUNXI_I2S0CTL); reg_val = readl(sunxi_i2s0.regs + SUNXI_TXCHSEL); reg_val &= ~0x7; @@ -167,6 +163,11 @@ static void sunxi_snd_txctrl_i2s0(struct snd_pcm_substream *substream, int on) reg_val = readl(sunxi_i2s0.regs + SUNXI_I2S0INT); reg_val &= ~SUNXI_I2S0INT_TXDRQEN; writel(reg_val, sunxi_i2s0.regs + SUNXI_I2S0INT); + + /* Give the DMA engine some time to complete any pending + * DRQ. This ensures that the following start trigger will + * be the only code changing the FIFO state. */ + udelay(10); } } |