lkml.org 
[lkml]   [2019]   [May]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] swiotlb: sync buffer when mapping FROM_DEVICE
On Wed, May 22, 2019 at 01:50:47PM +0100, Robin Murphy wrote:
> Would that work out any different from the existing DMA_ATTR_SKIP_CPU_SYNC?
>
> If drivers are prepared to handle this issue from their end, they can
> already do so for single mappings by using that attr along with explicit
> partial syncs via dma_sync_single(). For page/sg mappings we'd still have
> the problem of identifying what part of "partial" actually matters, and
> probably having to add some additional new sync operations to cope.

Except that the same optimization we are tripping over here is also
present in dma_sync_* - dma_sync_*_to_device with DMA_FROM_DEVICE is a
no-op in swiotlb.

\
 
 \ /
  Last update: 2019-05-22 15:10    [W:0.156 / U:0.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site