On Tue, Nov 8, 2011 at 1:40 AM, Daniel Mack zonque@gmail.com wrote:
Hi,
we're hunting a weird bug on PXA3xx/ssp based audio devices which causes the playback channels to be swapped when the capture stream is started at the same time. Content for the left channel appears on the right and vice versa, in approximately 50% of all test runs of the following command:
$ arecord -f cd - -D hw:0,0 | aplay -D hw:0,0 -f cd -
When just aplay is used, everything's fine.
It's unrelated to the codec part, as we see this with machines that feature different models. I guess this is some sort of a race condition in the stream startup, and suspected sound/soc/pxa/pxa-ssp.c to lack some locking, so I added a spinlock around all register read-modify-write cycles. But that doesn't seem to be the reason.
It could also be the DMA engine that writes to the wrong position, but I fail to see it right now.
Does anyone have an idea where to look for the culprit? Have there been similar effects in other SoC platforms?
Thanks for sharing your thoughts :)
Daniel _______________________________________________ Alsa-devel mailing list Alsa-devel@alsa-project.org http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
Hi Daniel,
I assumed that you're using pxa3xx or pxa93x silicons. Do you also enable D0CS operating point? If you disable this operating point, does this issue exist?
If the codec is configured as master mode, does this issue exist?
Thanks Haojian