[PATCH] Sam440ep support

Benjamin Herrenschmidt benh at kernel.crashing.org
Tue May 6 21:34:43 EST 2008


On Tue, 2008-05-06 at 13:31 +0200, Takashi Iwai wrote:
> > I don't think we can easily update the DMA API at this stage. What
> we
> > could do is provide a way to retrieve the struct page array from the
> > result of dma_alloc_coherent...
> 
> In most cases, it can be obtained via pfn_to_page(), I suppose.  But,
> it's definitely arch-specific thingy, and a generic solution would be
> really appreciated.

You can't get a pfn out of the result of dma_alloc_coherent on
non-coherent powerpc at least. It's a virtual mapping created from the
underlying pages set to be non-cacheable. virt_to_* will do no good.

> Alternatively, we can change the ALSA PCM core code that accesses the
> virtual linear buffer and handles SG-buffers as they are.  Maybe it'll
> give a bit more useful clean-up in the whole memory-management codes
> in ALSA in the end.

I need to get my head around what the exact usage in Alsa is, and it's a
bit too late for me to thing right now :-)

Ben.





More information about the Linuxppc-dev mailing list