Subject: DMA buffers
To: None <>
From: Marcus Comstedt <>
List: port-dreamcast
Date: 01/10/2001 01:06:52
For the Maple Bus driver, I need to allocate some contiguous physical
memory for use as DMA buffers.  The code I use currently looks in
principle like this:

 paddr_t dmabuf = SH3_P2SEG_TO_PHYS(vtophys(uvm_km_alloc(phys_map, SIZE)))

Can someone confirm that this is the right way to do it?  I'm a little
confused that the vtophys function returns a P2 address rather than a
physical address...

  // Marcus