Re: [Intel-gfx] [PATCH v3 3/3] drm/vgem: Keep a reference to the dmabuf when mmaped

2016-10-05 Thread Daniel Vetter
On Wed, Oct 05, 2016 at 02:40:09PM +0100, Chris Wilson wrote: > On Wed, Oct 05, 2016 at 03:11:00PM +0200, Daniel Vetter wrote: > > On Fri, Sep 30, 2016 at 02:59:59PM +0100, Chris Wilson wrote: > > > In order to keep the dmabuf alive whilst the mmap is, we need to hold a > > > reference to the

Re: [Intel-gfx] [PATCH v3 3/3] drm/vgem: Keep a reference to the dmabuf when mmaped

2016-10-05 Thread Chris Wilson
On Wed, Oct 05, 2016 at 03:11:00PM +0200, Daniel Vetter wrote: > On Fri, Sep 30, 2016 at 02:59:59PM +0100, Chris Wilson wrote: > > In order to keep the dmabuf alive whilst the mmap is, we need to hold a > > reference to the dmabuf and not the backing object. This is important as > > the dmabuf not

Re: [Intel-gfx] [PATCH v3 3/3] drm/vgem: Keep a reference to the dmabuf when mmaped

2016-10-05 Thread Daniel Vetter
On Fri, Sep 30, 2016 at 02:59:59PM +0100, Chris Wilson wrote: > In order to keep the dmabuf alive whilst the mmap is, we need to hold a > reference to the dmabuf and not the backing object. This is important as > the dmabuf not only keeps the object alive, but also the device so that > >

[Intel-gfx] [PATCH v3 3/3] drm/vgem: Keep a reference to the dmabuf when mmaped

2016-09-30 Thread Chris Wilson
In order to keep the dmabuf alive whilst the mmap is, we need to hold a reference to the dmabuf and not the backing object. This is important as the dmabuf not only keeps the object alive, but also the device so that dmabuf = vgem_create_dmabuf(); ptr = mmap(... dmabuf ...);