Using DMA

Bill Gatliff bgat at billgatliff.com
Sun Nov 9 14:25:59 EST 2008


Bruce_Leonard at selinc.com wrote:
> timur.tabi at gmail.com wrote on 11/07/2008 01:46:42 PM:
> 
>> Whether or not using async dma is worth the effort can only be
>> determined by profiling the code.  Either it's better, or it's not.
>> There's no real way to tell in advance.
>>
> 
> Pretty much the answer I expected :), I was just hoping that "wiser and 
> more experienced" minds would say "oh, well to do what you want you should 
> go in this direction".  Ah well, such is the life of a kernel hacker.
> 
> So it sounds like the async dma is the way to go, since I want to off load 
> as much as possible from the core.

One thing to watch out for is an increase in interrupt latency.  If
the DMA grabs the bus and won't turn loose until the whole transfer is
finished, your interrupts will wait along with everything else.

Many DMA controllers support a "cycle steal" mode, which lets them get
interrupted by more important things.  It slows the DMA transfer down,
but does less damage to the rest of the system.


b.g.
-- 
Bill Gatliff
bgat at billgatliff.com


More information about the Linuxppc-embedded mailing list