LKML Archive on
help / color / mirror / Atom feed
From: Robin Murphy <>
To: "Christoph Hellwig" <>, "Horia Geantă" <>
Cc: Konrad Rzeszutek Wilk <>,
	Marek Szyprowski <>,,,
Subject: Re: [PATCH] swiotlb: sync buffer when mapping FROM_DEVICE
Date: Wed, 22 May 2019 13:50:47 +0100	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

On 22/05/2019 13:32, Christoph Hellwig wrote:
> I'm a little worried about this.  While it looks functionally correct
> we have surived without it, and doing another copy for every swiotlb
> dma mapping from the device looks extremely painful for the typical use
> cases where we expect the device to transfer the whole mapping.
> I'd be tempted to instead properl document the current behavior and
> introduce a new DMA_ATTR_PARTIAL flag to allow for partial mappings.

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.


  reply	other threads:[~2019-05-22 12:50 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-22  7:20 Horia Geantă
2019-05-22 12:32 ` Christoph Hellwig
2019-05-22 12:50   ` Robin Murphy [this message]
2019-05-22 13:09     ` Christoph Hellwig
2019-05-22 13:25       ` Robin Murphy
2019-05-22 13:34         ` Christoph Hellwig
2019-05-22 13:55           ` Robin Murphy
2019-05-23  5:35             ` Marek Szyprowski
2019-05-23 16:25               ` Horia Geanta
2019-05-23 16:43               ` Christoph Hellwig
2019-05-23 17:53                 ` Horia Geanta
2019-05-23 18:05                 ` Robin Murphy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \ \ \ \
    --subject='Re: [PATCH] swiotlb: sync buffer when mapping FROM_DEVICE' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).