DMA take 3

Swarthout Edward L-SWARTHOU ed.swarthout at freescale.com
Sat Mar 3 18:44:45 EST 2007


From: Charles Krinke:
> Your uboot script works fine with the DMA engine. I can 
> transfer a few bytes from 0xfff8_0000 to 0x1_0000 with no 
> difficulty. However, I have not yet gotten to an 
> understanding when DMA'ing through an address translation 
> window, but at least I know how to make it work in local 
> memory (LM) space.

>From the dma viewpoint there is no difference.

...
> we can write & read 
> single memory locations in both RM & SM space from LM space 
> using these settings.

So from uboot, you can do a "md" or "cp" to/from these areas?

> Next is the burst mode of the PCI for which, I believe, the 
> only recourse is to use the DMA engine. Here things get a bit 
> trickier.
>  
> I am DMA'ing to the window at 0x8800_0000 plus the 
> destination offset within that window and the issue is that 
> although LM->LM DMA is now working, LM->SM is not working.
>  
> So, her are the questions:
>  
> Is there any special consideration in trying to DMA from a 
> 32bit PCI to a 64bit address using DAC (Dual Address Cycles) 
> in the 8541?

No.

> Are there any special considerations relating to using an 
> outbound address translation window to do this?

No.

> Where else might things be going awry?

Based on your descriptions, I don't see anything.

Send me (off list) your uboot console showing md/cp working and the dma
failing.
You can use the following commands to dump the pertinent register data.

I'd say this discussion has strayed from linuxppc-embedded.
Where is embedded-ppc-hwdebug when you need it?

-Ed

setenv lawregs 'echo law;md ${c}00c08 3b'
setenv dmaregs 'echo dma;md ${c}21100 81'
setenv pciregs 'echo pcio;md ${c}08c00 25; echo pcii; md ${c}08da0 15;
echo pcierr;md ${c}08e00 9'
setenv c e00 # or your ccsr bar prefix

savenv # optional!

run lawregs; run dmaregs; run pciregs



More information about the Linuxppc-embedded mailing list