[PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-12-20 Thread Dave Airlie
> In drm_prime_handle_to_fd_ioctl(), flags is cleared to only support > DRM_CLOEXEC but in gem_prime_export() callbacks of each driver, it uses > 0600 as flags for dma_buf_export() like following. > > return dma_buf_export(obj, &i915_dmabuf_ops, obj->base.size, 0600); Oops, nice catch, radeon and

Re: [PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-12-19 Thread Dave Airlie
> In drm_prime_handle_to_fd_ioctl(), flags is cleared to only support > DRM_CLOEXEC but in gem_prime_export() callbacks of each driver, it uses > 0600 as flags for dma_buf_export() like following. > > return dma_buf_export(obj, &i915_dmabuf_ops, obj->base.size, 0600); Oops, nice catch, radeon and

[PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-12-18 Thread Dave Airlie
On Thu, Sep 27, 2012 at 4:30 PM, Seung-Woo Kim wrote: > Increasing ref counts of both dma-buf and gem for imported dma-buf come from > gem > makes memory leak. release function of dma-buf cannot be called because > f_count > of dma-buf increased by importing gem and gem ref count cannot be decr

[PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-12-18 Thread 김승우
Hi Dave, On 2012? 12? 18? 15:30, Dave Airlie wrote: > On Thu, Sep 27, 2012 at 4:30 PM, Seung-Woo Kim > wrote: >> Increasing ref counts of both dma-buf and gem for imported dma-buf come from >> gem >> makes memory leak. release function of dma-buf cannot be called because >> f_count >> of dma-b

Re: [PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-12-17 Thread 김승우
Hi Dave, On 2012년 12월 18일 15:30, Dave Airlie wrote: > On Thu, Sep 27, 2012 at 4:30 PM, Seung-Woo Kim wrote: >> Increasing ref counts of both dma-buf and gem for imported dma-buf come from >> gem >> makes memory leak. release function of dma-buf cannot be called because >> f_count >> of dma-buf

Re: [PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-12-17 Thread Dave Airlie
On Thu, Sep 27, 2012 at 4:30 PM, Seung-Woo Kim wrote: > Increasing ref counts of both dma-buf and gem for imported dma-buf come from > gem > makes memory leak. release function of dma-buf cannot be called because > f_count > of dma-buf increased by importing gem and gem ref count cannot be decre

[RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-21 Thread 김승우
On 2012? 11? 20? 19:26, Maarten Lankhorst wrote: > Op 20-11-12 02:03, ??? schreef: >> Hi Maarten, >> >> On 2012? 11? 19? 19:27, Maarten Lankhorst wrote: >>> Op 15-11-12 04:52, Seung-Woo Kim schreef: Increasing ref counts of both dma-buf and gem for imported dma-buf come from gem makes mem

Re: [RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-20 Thread 김승우
On 2012년 11월 20일 19:26, Maarten Lankhorst wrote: > Op 20-11-12 02:03, 김승우 schreef: >> Hi Maarten, >> >> On 2012년 11월 19일 19:27, Maarten Lankhorst wrote: >>> Op 15-11-12 04:52, Seung-Woo Kim schreef: Increasing ref counts of both dma-buf and gem for imported dma-buf come from gem makes mem

[RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-20 Thread Maarten Lankhorst
Op 20-11-12 02:03, ??? schreef: > Hi Maarten, > > On 2012? 11? 19? 19:27, Maarten Lankhorst wrote: >> Op 15-11-12 04:52, Seung-Woo Kim schreef: >>> Increasing ref counts of both dma-buf and gem for imported dma-buf >>> come from gem makes memory leak. release function of dma-buf cannot >>> be calle

[RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-20 Thread 김승우
Hi Maarten, On 2012? 11? 19? 19:27, Maarten Lankhorst wrote: > Op 15-11-12 04:52, Seung-Woo Kim schreef: >> Increasing ref counts of both dma-buf and gem for imported dma-buf >> come from gem makes memory leak. release function of dma-buf cannot >> be called because f_count of dma-buf increased by

Re: [RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-20 Thread Maarten Lankhorst
Op 20-11-12 02:03, 김승우 schreef: > Hi Maarten, > > On 2012년 11월 19일 19:27, Maarten Lankhorst wrote: >> Op 15-11-12 04:52, Seung-Woo Kim schreef: >>> Increasing ref counts of both dma-buf and gem for imported dma-buf >>> come from gem makes memory leak. release function of dma-buf cannot >>> be calle

[RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-19 Thread Inki Dae
Hi All, This patch has been tested with only Exynos driver so other maintainers may need to test this. Acked-by: Inki Dae 2012/11/15 Seung-Woo Kim > Increasing ref counts of both dma-buf and gem for imported dma-buf > come from gem makes memory leak. release function of dma-buf cannot > be c

Re: [RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-19 Thread 김승우
Hi Maarten, On 2012년 11월 19일 19:27, Maarten Lankhorst wrote: > Op 15-11-12 04:52, Seung-Woo Kim schreef: >> Increasing ref counts of both dma-buf and gem for imported dma-buf >> come from gem makes memory leak. release function of dma-buf cannot >> be called because f_count of dma-buf increased by

[RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-19 Thread Maarten Lankhorst
Op 15-11-12 04:52, Seung-Woo Kim schreef: > Increasing ref counts of both dma-buf and gem for imported dma-buf > come from gem makes memory leak. release function of dma-buf cannot > be called because f_count of dma-buf increased by importing gem and > gem ref count cannot be decrease because of ex

Re: [RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-19 Thread Maarten Lankhorst
Op 15-11-12 04:52, Seung-Woo Kim schreef: > Increasing ref counts of both dma-buf and gem for imported dma-buf > come from gem makes memory leak. release function of dma-buf cannot > be called because f_count of dma-buf increased by importing gem and > gem ref count cannot be decrease because of ex

Re: [RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-19 Thread Inki Dae
Hi All, This patch has been tested with only Exynos driver so other maintainers may need to test this. Acked-by: Inki Dae 2012/11/15 Seung-Woo Kim > Increasing ref counts of both dma-buf and gem for imported dma-buf > come from gem makes memory leak. release function of dma-buf cannot > be c

[RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-15 Thread Seung-Woo Kim
Increasing ref counts of both dma-buf and gem for imported dma-buf come from gem makes memory leak. release function of dma-buf cannot be called because f_count of dma-buf increased by importing gem and gem ref count cannot be decrease because of exported dma-buf. So I add dma_buf_put() for import

[RESEND][PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-14 Thread Seung-Woo Kim
Increasing ref counts of both dma-buf and gem for imported dma-buf come from gem makes memory leak. release function of dma-buf cannot be called because f_count of dma-buf increased by importing gem and gem ref count cannot be decrease because of exported dma-buf. So I add dma_buf_put() for import

[PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-03 Thread 김승우
Hi Jani, Sorry for late reply. On 2012? 09? 27? 22:43, Jani Nikula wrote: > On Thu, 27 Sep 2012, Seung-Woo Kim wrote: >> Increasing ref counts of both dma-buf and gem for imported dma-buf come from >> gem >> makes memory leak. release function of dma-buf cannot be called because >> f_count >>

Re: [PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-11-03 Thread 김승우
Hi Jani, Sorry for late reply. On 2012년 09월 27일 22:43, Jani Nikula wrote: > On Thu, 27 Sep 2012, Seung-Woo Kim wrote: >> Increasing ref counts of both dma-buf and gem for imported dma-buf come from >> gem >> makes memory leak. release function of dma-buf cannot be called because >> f_count >>

[PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-09-27 Thread Jani Nikula
On Thu, 27 Sep 2012, Seung-Woo Kim wrote: > Increasing ref counts of both dma-buf and gem for imported dma-buf come from > gem > makes memory leak. release function of dma-buf cannot be called because > f_count > of dma-buf increased by importing gem and gem ref count cannot be decrease > becaus

[PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-09-27 Thread 김승우
Hi Rob, On 2012? 09? 27? 15:52, Rob Clark wrote: > fwiw, I had a similar patch: > > https://patchwork.kernel.org/patch/1229161/ Yes, I already check your patch and even my patch's title is a bit from your patch. I thought locking issue blocks your patch, so I sent simple fixes on current state.

[PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-09-27 Thread Seung-Woo Kim
Increasing ref counts of both dma-buf and gem for imported dma-buf come from gem makes memory leak. release function of dma-buf cannot be called because f_count of dma-buf increased by importing gem and gem ref count cannot be decrease because of exported dma-buf. So I add dma_buf_put() for import

[PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-09-27 Thread Rob Clark
On Thu, Sep 27, 2012 at 9:14 AM, ??? wrote: > Hi Rob, > > On 2012? 09? 27? 15:52, Rob Clark wrote: >> fwiw, I had a similar patch: >> >> https://patchwork.kernel.org/patch/1229161/ > > Yes, I already check your patch and even my patch's title is a bit from > your patch. > > I thought locking issue

[PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-09-27 Thread Rob Clark
fwiw, I had a similar patch: https://patchwork.kernel.org/patch/1229161/ although it was on top of some locking fixes from Daniel (which I think are also needed): https://patchwork.kernel.org/patch/1227251/ although that seemed to cause/trigger some explosions which I think still need to be deb

Re: [PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-09-27 Thread Jani Nikula
On Thu, 27 Sep 2012, Seung-Woo Kim wrote: > Increasing ref counts of both dma-buf and gem for imported dma-buf come from > gem > makes memory leak. release function of dma-buf cannot be called because > f_count > of dma-buf increased by importing gem and gem ref count cannot be decrease > becaus

Re: [PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-09-27 Thread Rob Clark
On Thu, Sep 27, 2012 at 9:14 AM, 김승우 wrote: > Hi Rob, > > On 2012년 09월 27일 15:52, Rob Clark wrote: >> fwiw, I had a similar patch: >> >> https://patchwork.kernel.org/patch/1229161/ > > Yes, I already check your patch and even my patch's title is a bit from > your patch. > > I thought locking issue

Re: [PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-09-27 Thread 김승우
Hi Rob, On 2012년 09월 27일 15:52, Rob Clark wrote: > fwiw, I had a similar patch: > > https://patchwork.kernel.org/patch/1229161/ Yes, I already check your patch and even my patch's title is a bit from your patch. I thought locking issue blocks your patch, so I sent simple fixes on current state.

Re: [PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-09-26 Thread Rob Clark
fwiw, I had a similar patch: https://patchwork.kernel.org/patch/1229161/ although it was on top of some locking fixes from Daniel (which I think are also needed): https://patchwork.kernel.org/patch/1227251/ although that seemed to cause/trigger some explosions which I think still need to be deb

[PATCH] drm/prime: drop reference on imported dma-buf come from gem

2012-09-26 Thread Seung-Woo Kim
Increasing ref counts of both dma-buf and gem for imported dma-buf come from gem makes memory leak. release function of dma-buf cannot be called because f_count of dma-buf increased by importing gem and gem ref count cannot be decrease because of exported dma-buf. So I add dma_buf_put() for import