]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: kirkwood-i2s: fix DMA underruns
authorRussell King <rmk+kernel@arm.linux.org.uk>
Tue, 20 Nov 2012 12:18:52 +0000 (12:18 +0000)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Wed, 21 Nov 2012 01:38:39 +0000 (10:38 +0900)
commit53a61ad4440935c746859a0d4c8dbaa69e911ea2
tree4ca2ef9766708a6c5ae58d24f14d14a2b50c0737
parent19883170bdd227249043bc9fbb7641cfb7d6d3a7
ASoC: kirkwood-i2s: fix DMA underruns

Stress testing the driver with multiple start/stop events causes
kirkwood-dma to report underrun errors (which used to cause the kernel
to lock up solidly).  This is because kirkwood-i2s is not respecting
the restrictions imposed on clearing the 'pause' bit.  Follow what the
spec says; the busy bit must be read as being clear twice before the
pause bit can be released.  This solves the underruns.

However, it has been noticed that the busy bit occasionally does not
clear itself, hence the waiting is bounded to 5ms maximum to avoid a
new reason for the kernel to lockup.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
sound/soc/kirkwood/kirkwood-i2s.c