Re: [PATCH 1/1] Userspace I/O (UIO): Add support for userspace DMA

Edward Estabrook
2008-12-04T02:44:19Z

> You are using a magic value to mmap(), just to keep options open:
>
> Would this in the future allow us to also add support for streaming
> non-coherent DMA directly into user space buffers?

Yes, but additional userspace control is also required.
Specifically:
1) The specification of direction at the time of buffer creation,
unless force DMA_BIDIRECTIONAL is assumed.
2) An API to faciliate userspace control over dma_unmap_page() /
dma_sync_single_for_cpu() calls (perhaps by further overloading
of the write method).

The use of this magic value does not prevent the future addition of
streaming DMA support, but does not provide sufficient controls.