We're using DM6467T DVSDK 3.10 GA. It has served us very well.
We have an audio driver that uses DMA from a McASP to read samples from an AIC32. This has appeared to be rock solid for a long time. Now that we have hundreds of units in the field, though, we're getting an occasional ARM hang (as in nothing else happens on any interfaces - UART, PCI network driver, etc.). By digging into the ARM's DDR2 over PCI I can see the final dmesg output by following the crumbs from log_buf in System.map. The hang happens when the audio driver starts the McASP. Meanwhile a user thread is creating the code and that thread dies when the Codec Server reaches out to the DSP (see http://e2e.ti.com/support/embedded/f/354/t/140023.aspx "ARM hangs after Comm_create during instantiation of DSP codec"). As indicated in that posting, this problem is usually is repeatable once it gets in that state. It goes away after a power cycle.
When I saw http://e2e.ti.com/support/embedded/f/354/p/104964/504621.aspx ("DM6467T Linux driver - how to use EDMA") I realized that I may need to reserve more DMA channels for the DSP. It seems like a likely candidate to solve my problem. But not all of the questions were answered there. I believe this happened because it was a "Verified Answer" before all the original poster's questions were answered (and I added a few of my own!).
So I'd just like to know how to determine which DMA channels are in use by the DSP, and how to avoid them (presumably via entries in dm646x_dma_rsv_chans in the ARM Linux kernel source, arch/arm/mach-davinci/dm646x.c).
I've looked at a number of places to try to determine which DMA channels I should reserve in the ARM kernel to make sure that my own driver's use of EDMA does not interfere with the ones used by the Codec Server running in the DSP. I could simply reserve the first 49 and hope that my problem goes away. But I would like the confidence to tell management that the problem was solved; it may appear two weeks later in a customer's unit. Not good.
A quick summary of the places I've looked:
- server.cfg lists the number of channels used (49 EDMA!), not which.
- cs.x64P.DataSheet.html mentions idma3 and qdma, but I''m not sure what the numbers mean (only 8?); there's no range given.
- specific codec User's Manuals
- find/grep for EDMA in various code bases (ARM Linux kernel, linuxutils, cs2dm6467_1_00_00_10, etc.)
- I've monitored the DMA PARAM fields during a successful run and I see channels 20-49 (and a couple more) being used. Presumably this the DSP, though I see what I think are channels being used by DaVinci resizer/chroma-converted.
So my questions are:
- What DMA channels are used by codecs in the Codec Server for my platform?
- If this is something I can change or determine myself from the DVSDK source tree, how and where?
- Could this possibly be related to Advisory 3.0.3 or 3.0.19 in the errata (SPRZ307A.pdf)? Do the codecs or Codec Server behave in a way that would fall under those advisories?
Thanks!
Doug