Re: [RFC/PARTIAL PATCH 0/3] dma: passing "attributes" to dma_map_* routines

From: akepner
Date: Wed Jan 09 2008 - 16:07:27 EST


On Wed, Jan 09, 2008 at 01:00:38PM -0800, Roland Dreier wrote:
> .....
> The reason this hasn't been an issue until now is that almost all
> drivers work correctly if the Altix code just sets the "flush" bit for
> memory allocated via the consistent/coherent allocators. However, if
> we want the device to write to userspace memory, this doesn't work
> (and mapping coherent memory allocated in the kernel into userspace is
> a mess on other platforms, because it unnecessarily consumes lowmem
> and/or kernel address space).
>

And the only way that user level CQs work on Altix now is
that we apply our own patches to allocate them in the
kernel (with dma_alloc_coherent()) them mmap() them back
to user space. A bug in one of these patches recently led
to considerable drama with several customers - I'd love
to get a fix in mainline so we can drop our patches and
avoid the possibility such theatrics in the future ;-)

--
Arthur

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/