Re: [PATCH 1/1] dma: imx-sdma: buf_tail should be initialize inprepare function

From: Richard Zhao
Date: Wed May 23 2012 - 23:27:45 EST


On Thu, May 24, 2012 at 11:20:29AM +0800, Shawn Guo wrote:
> On Mon, May 21, 2012 at 08:31:34PM +0800, Richard Zhao wrote:
> > This fix audio underrun issue. When SNDRV_PCM_TRIGGER_STOP
> > and SNDRV_PCM_TRIGGER_START, it calls prepare again. buf_tail
> > should be reset to zero.
> > So move buf_tail initialization into prepare function.
> >
> I tried the patch on imx51, and it does not fix the issue for me.
>
> Regards,
> Shawn
>
> root@linaro-developer:~# aplay audio8k16S.wav
> Playing WAVE 'audio8k16S.wav' : Signed 16 bit Little Endian, Rate 8000 Hz, Stere
> o
> ^Z
> [1]+ Stopped aplay audio8k16S.wav
> root@linaro-developer:~# fg
> aplay audio8k16S.wav
> underrun!!! (at least 2034.382 ms long)
Does the audio playback recover? Without the patch, sometimes the
playback will have distortion and play too fast.

Thanks
Richard

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/