DSPRelated.com
Forums

Problem with DMA

Started by Vijay B G January 31, 2007
I am working on custom 64x davanci borad and i am using CCS 3.3.
In my code, i am calling DMAN3 and ACPY3 functions to do the DMA .
My DMA works fine, if i use the following cmd file.

Note: I am not using DSP/BIOS

linker command file(DMA works fine):

MEMORY {
CACHE_L1P : origin = 0x11e08000, len = 0x8000
CACHE_L1D : origin = 0x11f10000, len = 0x8000
EXTMEM : origin = 0x80000000, len = 0x400000
L1DSRAM : origin = 0x11f04000, len = 0xc000
}
_DMAN3_EDMA3BASE = 0x01C00000;

SECTIONS
{
.image > EXTMEM
.sysmem > L1DSRAM
.far: {} > EXTMEM
.text: {} > EXTMEM
.const: {} > EXTMEM
.cinit: {} > EXTMEM
.stack: {} > EXTMEM
.switch: {} > EXTMEM
.cio: {} > EXTMEM
}
Note: In this cmd, sysmem is allocated as the internal memory.
As i am dynamically allocating huge(60k) memory, i cant keep the
".sysmem " inthe internal memory.
Now if i change the sysmem (.sysmem > L1DSRAM ) to external memory
(.sysmem > EXTMEM ) , My working DMA fails. It never comes out from
ACPY3_wait.
here is the new cmd (DMA fails)
MEMORY {
CACHE_L1P : origin = 0x11e08000, len = 0x8000
CACHE_L1D : origin = 0x11f10000, len = 0x8000
EXTMEM : origin = 0x80000000, len = 0x400000
L1DSRAM : origin = 0x11f04000, len = 0xc000
}
_DMAN3_EDMA3BASE = 0x01C00000;

SECTIONS
{
.image > EXTMEM
.sysmem > EXTMEM /* ========== this is the only change
=========*/
.far: {} > EXTMEM
.text: {} > EXTMEM
.const: {} > EXTMEM
.cinit: {} > EXTMEM
.stack: {} > EXTMEM
.switch: {} > EXTMEM
.cio: {} > EXTMEM
}

My question is how
1. How DMA is related to .sysmem or heap
2. Why DMA dont work when .sysmem is made as external.
Please some one give me the solution

thanks
vijay