All of lore.kernel.org
 help / color / mirror / Atom feed
* RFC: unpinned DMA-buf exporting v2
@ 2018-03-16 13:20 ` Christian König
  0 siblings, 0 replies; 64+ messages in thread
From: Christian König @ 2018-03-16 13:20 UTC (permalink / raw)
  To: linaro-mm-sig, linux-media, dri-devel, amd-gfx

Hi everybody,

since I've got positive feedback from Daniel I continued working on this approach.

A few issues are still open:
1. Daniel suggested that I make the invalidate_mappings callback a parameter of dma_buf_attach().

This approach unfortunately won't work because when the attachment is created the importer is not necessarily ready to handle invalidation events.

E.g. in the amdgpu example we first need to setup the imported GEM/TMM objects and install that in the attachment.

My solution is to introduce a separate function to grab the locks and set the callback, this function could then be used to pin the buffer later on if that turns out to be necessary after all.

2. With my example setup this currently results in a ping/pong situation because the exporter prefers a VRAM placement while the importer prefers a GTT placement.

This results in quite a performance drop, but can be fixed by a simple mesa patch which allows shred BOs to be placed in both VRAM and GTT.

Question is what should we do in the meantime? Accept the performance drop or only allow unpinned sharing with new Mesa?

Please review and comment,
Christian.

^ permalink raw reply	[flat|nested] 64+ messages in thread

end of thread, other threads:[~2018-03-27  8:27 UTC | newest]

Thread overview: 64+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-16 13:20 RFC: unpinned DMA-buf exporting v2 Christian König
2018-03-16 13:20 ` Christian König
2018-03-16 13:20 ` [PATCH 1/5] dma-buf: add optional invalidate_mappings callback v2 Christian König
2018-03-16 13:20   ` Christian König
2018-03-16 13:51   ` Chris Wilson
2018-03-16 13:51     ` Chris Wilson
2018-03-16 14:22     ` Christian König
2018-03-16 14:22       ` Christian König
2018-03-19 15:53       ` Chris Wilson
2018-03-19 15:53         ` Chris Wilson
2018-03-19 16:23         ` Christian König
2018-03-19 16:23           ` Christian König
2018-03-20  7:44           ` [Linaro-mm-sig] " Daniel Vetter
2018-03-20  7:44             ` Daniel Vetter
2018-03-20 10:54             ` Christian König
2018-03-20 10:54               ` Christian König
2018-03-20 14:08               ` Daniel Vetter
2018-03-20 14:08                 ` Daniel Vetter
2018-03-20 17:47                 ` Christian König
2018-03-20 17:47                   ` Christian König
2018-03-21  8:18                   ` Daniel Vetter
2018-03-21  8:18                     ` Daniel Vetter
2018-03-21  9:34                     ` Christian König
2018-03-21  9:34                       ` Christian König
2018-03-22  7:14                       ` Daniel Vetter
2018-03-22  7:14                         ` Daniel Vetter
2018-03-22  9:37                         ` Christian König
2018-03-22  9:37                           ` Christian König
2018-03-26  7:51                           ` Daniel Vetter
2018-03-26  7:51                             ` Daniel Vetter
2018-03-21  8:28                   ` Daniel Vetter
2018-03-21  8:28                     ` Daniel Vetter
2018-03-21 11:54                     ` Christian König
2018-03-21 11:54                       ` Christian König
2018-03-22  7:18                       ` Daniel Vetter
2018-03-22  7:18                         ` Daniel Vetter
2018-03-22  9:58                         ` Christian König
2018-03-22  9:58                           ` Christian König
2018-03-26  8:01                           ` Daniel Vetter
2018-03-26  8:01                             ` Daniel Vetter
2018-03-26 15:42                             ` Jerome Glisse
2018-03-26 15:42                               ` Jerome Glisse
2018-03-27  7:35                               ` Christian König
2018-03-27  7:35                                 ` Christian König
2018-03-27  7:53                                 ` Daniel Vetter
2018-03-27  7:53                                   ` Daniel Vetter
2018-03-27  8:06                                   ` Christian König
2018-03-27  8:06                                     ` Christian König
2018-03-27  8:27                                     ` Daniel Vetter
2018-03-27  8:27                                       ` Daniel Vetter
2018-03-19 14:04   ` Daniel Vetter
2018-03-19 14:04     ` Daniel Vetter
2018-03-16 13:20 ` [PATCH 2/5] drm/ttm: keep a reference to transfer pipelined BOs Christian König
2018-03-16 13:20   ` Christian König
2018-03-27  3:32   ` He, Roger
2018-03-27  3:32     ` He, Roger
2018-03-16 13:20 ` [PATCH 3/5] drm/ttm: remove the backing store if no placement is given Christian König
2018-03-16 13:20   ` Christian König
2018-03-16 13:20 ` [PATCH 4/5] drm/amdgpu: add independent DMA-buf export v2 Christian König
2018-03-16 13:20   ` Christian König
2018-03-16 13:20 ` [PATCH 5/5] drm/amdgpu: add independent DMA-buf import v2 Christian König
2018-03-16 13:20   ` Christian König
2018-03-19 14:09 ` RFC: unpinned DMA-buf exporting v2 Daniel Vetter
2018-03-19 14:09   ` Daniel Vetter

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.