Re: [RFC] Experimental DMA-BUF Device Heaps

2020-09-16 Thread Daniel Vetter
On Mon, Aug 17, 2020 at 9:09 AM Ezequiel Garcia wrote: > > This heap is basically a wrapper around DMA-API dma_alloc_attrs, > which will allocate memory suitable for the given device. > > The implementation is mostly a port of the Contiguous Videobuf2 > memory allocator (see videobuf2/videobuf2-dm

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-09-08 Thread Daniel Vetter
On Tue, Sep 08, 2020 at 08:43:59AM +0300, Laurent Pinchart wrote: > Hi Daniel, > > On Tue, Sep 01, 2020 at 09:32:22AM +0200, Daniel Vetter wrote: > > On Sun, Aug 16, 2020 at 02:22:46PM -0300, Ezequiel Garcia wrote: > > > This heap is basically a wrapper around DMA-API dma_alloc_attrs, > > > which

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-09-07 Thread Laurent Pinchart
Hi Daniel, On Tue, Sep 01, 2020 at 09:32:22AM +0200, Daniel Vetter wrote: > On Sun, Aug 16, 2020 at 02:22:46PM -0300, Ezequiel Garcia wrote: > > This heap is basically a wrapper around DMA-API dma_alloc_attrs, > > which will allocate memory suitable for the given device. > > > > The implementatio

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-09-01 Thread Daniel Vetter
On Sun, Aug 16, 2020 at 02:22:46PM -0300, Ezequiel Garcia wrote: > This heap is basically a wrapper around DMA-API dma_alloc_attrs, > which will allocate memory suitable for the given device. > > The implementation is mostly a port of the Contiguous Videobuf2 > memory allocator (see videobuf2/vide

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-31 Thread Laurent Pinchart
Hi James, On Sun, Aug 23, 2020 at 03:53:50PM -0700, James Jones wrote: > On 8/23/20 1:46 PM, Laurent Pinchart wrote: > > On Sun, Aug 23, 2020 at 01:04:43PM -0700, James Jones wrote: > >> On 8/20/20 1:15 AM, Ezequiel Garcia wrote: > >>> On Mon, 2020-08-17 at 20:49 -0700, James Jones wrote: > O

DMA-BUF Heaps BoF notes (Re: [RFC] Experimental DMA-BUF Device Heaps)

2020-08-31 Thread Ezequiel Garcia
Dear all, Here are the notes we took during the BoF. I believe the meeting was super interesting. Although it felt a bit short for the topic, we left with a few interesting ideas. Thanks everyone! Ezequiel --- LPC 2020 BoF: Negotiating DMA-BUF Heaps Attendees: * Brian Starkey * Daniel Stone *

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-27 Thread Simon Ser
On Thursday, August 20, 2020 10:15 AM, Ezequiel Garcia wrote: > > I'm rather interested on where this goes, as I was toying with using > > some sort of heap ID as a basis for a "device-local" constraint in the > > memory constraints proposals Simon and I will be discussing at XDC this > > year.

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-27 Thread Simon Ser
On Tuesday, August 25, 2020 10:26 PM, Nicolas Dufresne wrote: > > I don't think we can do this in a system-agnostic way. What I'd like to > > see is an API for the kernel to expose opaque constraints for each > > Please, take into consideration that constraints can also come from > userspace. Th

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-26 Thread Nicolas Dufresne
Le jeudi 20 août 2020 à 18:54 +0300, Laurent Pinchart a écrit : > Hi Ezequiel, > > On Thu, Aug 20, 2020 at 05:36:40AM -0300, Ezequiel Garcia wrote: > > Hi John, > > > > Thanks a ton for taking the time > > to go thru this. > > > > On Mon, 2020-08-17 at 21:13 -0700, John Stultz wrote: > > > On Su

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-23 Thread James Jones
On 8/23/20 1:46 PM, Laurent Pinchart wrote: Hi James, On Sun, Aug 23, 2020 at 01:04:43PM -0700, James Jones wrote: On 8/20/20 1:15 AM, Ezequiel Garcia wrote: On Mon, 2020-08-17 at 20:49 -0700, James Jones wrote: On 8/17/20 8:18 AM, Brian Starkey wrote: On Sun, Aug 16, 2020 at 02:22:46PM -030

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-23 Thread Laurent Pinchart
Hi James, On Sun, Aug 23, 2020 at 01:04:43PM -0700, James Jones wrote: > On 8/20/20 1:15 AM, Ezequiel Garcia wrote: > > On Mon, 2020-08-17 at 20:49 -0700, James Jones wrote: > >> On 8/17/20 8:18 AM, Brian Starkey wrote: > >>> On Sun, Aug 16, 2020 at 02:22:46PM -0300, Ezequiel Garcia wrote: >

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-23 Thread James Jones
On 8/20/20 1:15 AM, Ezequiel Garcia wrote: On Mon, 2020-08-17 at 20:49 -0700, James Jones wrote: On 8/17/20 8:18 AM, Brian Starkey wrote: Hi Ezequiel, On Sun, Aug 16, 2020 at 02:22:46PM -0300, Ezequiel Garcia wrote: This heap is basically a wrapper around DMA-API dma_alloc_attrs, which will a

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-21 Thread Ezequiel Garcia
On Mon, 2020-08-17 at 20:49 -0700, James Jones wrote: > On 8/17/20 8:18 AM, Brian Starkey wrote: > > Hi Ezequiel, > > > > On Sun, Aug 16, 2020 at 02:22:46PM -0300, Ezequiel Garcia wrote: > > > This heap is basically a wrapper around DMA-API dma_alloc_attrs, > > > which will allocate memory suitabl

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-21 Thread Ezequiel Garcia
Hi Brian, Thanks a lot for reviewing this patch. I'm happy my humble proof-of-concept is able to spark some interest and raise some questions. On Mon, 2020-08-17 at 16:18 +0100, Brian Starkey wrote: > Hi Ezequiel, > > On Sun, Aug 16, 2020 at 02:22:46PM -0300, Ezequiel Garcia wrote: > > This hea

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-21 Thread Ezequiel Garcia
Hi John, Thanks a ton for taking the time to go thru this. On Mon, 2020-08-17 at 21:13 -0700, John Stultz wrote: > On Sun, Aug 16, 2020 at 10:23 AM Ezequiel Garcia > wrote: > > This heap is basically a wrapper around DMA-API dma_alloc_attrs, > > which will allocate memory suitable for the given

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-20 Thread Laurent Pinchart
Hi Ezequiel, On Thu, Aug 20, 2020 at 05:36:40AM -0300, Ezequiel Garcia wrote: > Hi John, > > Thanks a ton for taking the time > to go thru this. > > On Mon, 2020-08-17 at 21:13 -0700, John Stultz wrote: > > On Sun, Aug 16, 2020 at 10:23 AM Ezequiel Garcia > > wrote: > > > This heap is basicall

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-20 Thread Brian Starkey
Hi, On Thu, Aug 20, 2020 at 09:07:29AM +0100, Ezequiel Garcia wrote: > > For single-device allocations, would using the buffer allocation > > functionality of that device's native API be better in most > > cases? (Some other possibly relevant discussion at [1]) > > > > That may be true for exist

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-17 Thread John Stultz
On Sun, Aug 16, 2020 at 10:23 AM Ezequiel Garcia wrote: > > This heap is basically a wrapper around DMA-API dma_alloc_attrs, > which will allocate memory suitable for the given device. > > The implementation is mostly a port of the Contiguous Videobuf2 > memory allocator (see videobuf2/videobuf2-d

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-17 Thread James Jones
On 8/17/20 8:18 AM, Brian Starkey wrote: Hi Ezequiel, On Sun, Aug 16, 2020 at 02:22:46PM -0300, Ezequiel Garcia wrote: This heap is basically a wrapper around DMA-API dma_alloc_attrs, which will allocate memory suitable for the given device. The implementation is mostly a port of the Contiguou

Re: [RFC] Experimental DMA-BUF Device Heaps

2020-08-17 Thread Brian Starkey
Hi Ezequiel, On Sun, Aug 16, 2020 at 02:22:46PM -0300, Ezequiel Garcia wrote: > This heap is basically a wrapper around DMA-API dma_alloc_attrs, > which will allocate memory suitable for the given device. > > The implementation is mostly a port of the Contiguous Videobuf2 > memory allocator (see

[RFC] Experimental DMA-BUF Device Heaps

2020-08-17 Thread Ezequiel Garcia
This heap is basically a wrapper around DMA-API dma_alloc_attrs, which will allocate memory suitable for the given device. The implementation is mostly a port of the Contiguous Videobuf2 memory allocator (see videobuf2/videobuf2-dma-contig.c) over to the DMA-BUF Heap interface. The intention of t