Subject: Re: Problems with dma_alloc_coherent()

From: Dan Malek <[email-masked]>
Date: Thu, 01 Apr 2004 11:51:22 -0500

John Whitney wrote:

> To that end, I am submitting the attached patch which modifies
> dma_alloc_coherent() and dma_free_coherent() to do just this for
> cache-coherent platforms.

I think you should change/implement consistent_alloc()/free() to do
the right thing rather that use the #ifdef here.  Also, ensure the
ancillary function (like the dma sync/sg functions) work properly as
well.  They are probably no-ops (well, not the sg functions) but
look for those anyway.

There are also reasons to allocate un-cached DMA regions on
cache coherent platforms (but I will not debate the value in doing so),
so keep that under consideration.

Thanks.

	-- Dan

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/