]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: omap-mcbsp: Add PM QoS support for McBSP to prevent glitches
authorMatt Ranostay <matt@ranostay.consulting>
Tue, 31 Jan 2017 21:21:43 +0000 (13:21 -0800)
committerMark Brown <broonie@kernel.org>
Wed, 1 Feb 2017 17:19:53 +0000 (17:19 +0000)
commit276580210a7b7cf665e6ecc24c621c2913218ed5
treeb9241a9299e5e8f4d26072d0eb72e540f895e272
parent88fa2f7f38b4d2643a48b85595412833244accde
ASoC: omap-mcbsp: Add PM QoS support for McBSP to prevent glitches

We can get audio errors if hitting deeper idle states on omaps:

[alsa.c:230] error: Fatal problem with alsa output, error -5.
[audio.c:614] error: Error in writing audio (Input/output error?)!

This seems to happen with off mode idle enabled as power for the
whole SoC may get cut off between filling the McBSP fifo using DMA.
While active DMA blocks deeper idle states in hardware, McBSP
activity does not seem to do so.

Basing the QoS latency calculation on the FIFO size, threshold,
sample rate, and channels.

Based on the original patch by Tony Lindgren
Link: https://patchwork.kernel.org/patch/9305867/
Signed-off-by: Matt Ranostay <matt@ranostay.consulting>
Signed-off-by: Liam Breck <kernel@networkimprov.net>
Tested-by: Tony Lindgren <tony@atomide.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/omap/mcbsp.h
sound/soc/omap/omap-mcbsp.c