Re: Non-coherent (streaming) contig-dma?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Apr 04, 2016 at 02:53:29PM +0200, Krzysztof Hałasa wrote:
> Hi,
> 
> I know certain approaches had been tried to allow use of streaming DMA
> (dma_map_single() etc. - i.e., not coherent) in the media drivers, is
> there something which can be used at this point (for MMAP method)?
> 
> Coherent buffers on many systems are very slow (uncacheable), should
> i simply add/replace the necessary calls in dma-contig?
> 
> Any other options?
> 
> Is there any potential problem there?

I don't think there's a really good solution to the problem in upstream.

For what it's worth, the USERPTR buffers are allocated non-coherent, and the
cache is flushed when that's needed.

I have a patchset that makes it driver-selectable whether to request
coherent or non-coherent memory. I haven't had time to work on that for a
while, unfortunately, that work stalled in fixing a few drivers that access
the buffers using the CPU as well when they really should not do that.

I sent the set here under the subject "[RFC RESEND 00/11] vb2: Handle user
cache hints, allow drivers to choose cache coherency" last September.

If you don't need to access the buffers using the CPU, you could avoid
flushing the cache as well, but it requires patches from that set as well.

-- 
Kind regards,

Sakari Ailus
e-mail: sakari.ailus@xxxxxx	XMPP: sailus@xxxxxxxxxxxxxx
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux