ppc405 dma - vm - cache question
Feng, Shuchen
feng at bnl.gov
Wed Oct 27 14:25:38 UTC 2004
Gene Smith wrote :
>I have a question for ppc experts in rtems land. I am trying to port the
>emac ethernet driver from netbsd to rtems. In the driver code I see all
>kinds of calls to things like this:
>bus_dmamap_create();
>bus_dmamem_alloc();
>bus_dmamap_load();
>bus_dmamap_sync(); <-- called a lot in tx/rx ISRs.
>I think that these are used to reconcile virtual memory in unix to
>physical memory addressed by devices (emac or mal device on ppc405).
My understanding is that they do software snoop to ensure cache
coherency.
> My assumption is that in rtems I can pretty much ignore these or make my
> own versions since rtems always uses real mode; anywhere memory is
> needed for dma purposes by the ethernet device and/or driver I can just
> malloc it and use the returned address for dma verbatim.
Either hardware snoop or software snoop is required if the ethernet
controller
accesses SDRAM space that is also cacheable by the CPU.
Cheers,
Kate
More information about the users
mailing list