This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/LINUXEZSDK-SITARA: Audio breaksdown on USB/NAND access

Part Number: LINUXEZSDK-SITARA
Other Parts Discussed in Thread: AM3352

Tool/software: Linux

Hi,

I have reproduced this issue on Linux Kernel 4.9, 4.14 and 4.19 (even tried on older kernels).

I am using both McASPs of Sitara with 16 input and 8 audio output channels (32-Bit, 48kHz) using the provided davinci-mcasp audio driver inside the kernel.

Everything works well so far (incl. simultaneous record and playback) - except that I get audio interruptions and even sometimes a permanent buffer loss on EDMA level when e.g. accessing NAND memory or USB (E.g. debug application across emulated Ethernet over MicroUSB).

I have checked already interrupt priority, the DMA channel (and EDMA queue priority) (as well as my process priority on application level) but somehow it looks like the DMA can not access the DDR memory at the requested time so, it loses audio and also sometime even loses it's buffers.

I have already tried with different ALSA period sizes and buffer counts but it looks like the issues is on lower level (in the mcasp or even the DMA driver).

I do not have any other load on the system (no graphics output, no real ethernet, no other interfaces) and processor load is also pretty relaxed but nevertheless I get the audio interruptions and sometimes entire buffer audio loss (system then plays audio witha artefacts, sometimes no audio at all).

Can I somewhere set the priority for CPU/DMA/other interfaces on the access of the internal bus matrix or external memory interface ?

Regards,

Sebastian