Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1703006 > unrolled thread

[PATCH 23/29] drm/tilcdc: switch to drm_*{get,put} helpers

Started byCihangir Akturk <cakturk@gmail.com>
First post2017-08-03 14:10 +0200
Last post2017-08-03 19:40 +0200
Articles 4 — 3 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH 23/29] drm/tilcdc: switch to drm_*{get,put} helpers Cihangir Akturk <cakturk@gmail.com> - 2017-08-03 14:10 +0200
    Re: [PATCH 23/29] drm/tilcdc: switch to drm_*{get,put} helpers Jyri Sarha <jsarha@ti.com> - 2017-08-03 16:00 +0200
      Re: [PATCH 23/29] drm/tilcdc: switch to drm_*{get,put} helpers Daniel Vetter <daniel@ffwll.ch> - 2017-08-03 17:50 +0200
        Re: [PATCH 23/29] drm/tilcdc: switch to drm_*{get,put} helpers Jyri Sarha <jsarha@ti.com> - 2017-08-03 19:40 +0200

#1703006 — [PATCH 23/29] drm/tilcdc: switch to drm_*{get,put} helpers

FromCihangir Akturk <cakturk@gmail.com>
Date2017-08-03 14:10 +0200
Subject[PATCH 23/29] drm/tilcdc: switch to drm_*{get,put} helpers
Message-ID<uan6W-8co-27@gated-at.bofh.it>
drm_*_reference() and drm_*_unreference() functions are just
compatibility alias for drm_*_get() and drm_*_put() adn should not be
used by new code. So convert all users of compatibility functions to use
the new APIs.

Signed-off-by: Cihangir Akturk <cakturk@gmail.com>
---
 drivers/gpu/drm/tilcdc/tilcdc_crtc.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
index d524ed0..6e936dd 100644
--- a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
+++ b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
@@ -75,7 +75,7 @@ static void unref_worker(struct drm_flip_work *work, void *val)
 	struct drm_device *dev = tilcdc_crtc->base.dev;
 
 	mutex_lock(&dev->mode_config.mutex);
-	drm_framebuffer_unreference(val);
+	drm_framebuffer_put(val);
 	mutex_unlock(&dev->mode_config.mutex);
 }
 
@@ -456,7 +456,7 @@ static void tilcdc_crtc_set_mode(struct drm_crtc *crtc)
 
 	set_scanout(crtc, fb);
 
-	drm_framebuffer_reference(fb);
+	drm_framebuffer_get(fb);
 
 	crtc->hwmode = crtc->state->adjusted_mode;
 }
@@ -621,7 +621,7 @@ int tilcdc_crtc_update_fb(struct drm_crtc *crtc,
 		return -EBUSY;
 	}
 
-	drm_framebuffer_reference(fb);
+	drm_framebuffer_get(fb);
 
 	crtc->primary->fb = fb;
 	tilcdc_crtc->event = event;
-- 
2.7.4

[toc] | [next] | [standalone]


#1703141

FromJyri Sarha <jsarha@ti.com>
Date2017-08-03 16:00 +0200
Message-ID<uaoPn-Jx-5@gated-at.bofh.it>
In reply to#1703006

Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki

On 08/03/17 14:58, Cihangir Akturk wrote:
> drm_*_reference() and drm_*_unreference() functions are just
> compatibility alias for drm_*_get() and drm_*_put() adn should not be
> used by new code. So convert all users of compatibility functions to use
> the new APIs.
> 
> Signed-off-by: Cihangir Akturk <cakturk@gmail.com>

Acked-by: Jyri Sarha <jsarha@ti.com>

This appears to be a part of a larger series. So I guess it will go in
via drm-misc. But if this is not the case just let me know and I'll add
this to my next pull request.

Best Regards,
Jyri

> ---
>  drivers/gpu/drm/tilcdc/tilcdc_crtc.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
> index d524ed0..6e936dd 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
> @@ -75,7 +75,7 @@ static void unref_worker(struct drm_flip_work *work, void *val)
>  	struct drm_device *dev = tilcdc_crtc->base.dev;
>  
>  	mutex_lock(&dev->mode_config.mutex);
> -	drm_framebuffer_unreference(val);
> +	drm_framebuffer_put(val);
>  	mutex_unlock(&dev->mode_config.mutex);
>  }
>  
> @@ -456,7 +456,7 @@ static void tilcdc_crtc_set_mode(struct drm_crtc *crtc)
>  
>  	set_scanout(crtc, fb);
>  
> -	drm_framebuffer_reference(fb);
> +	drm_framebuffer_get(fb);
>  
>  	crtc->hwmode = crtc->state->adjusted_mode;
>  }
> @@ -621,7 +621,7 @@ int tilcdc_crtc_update_fb(struct drm_crtc *crtc,
>  		return -EBUSY;
>  	}
>  
> -	drm_framebuffer_reference(fb);
> +	drm_framebuffer_get(fb);
>  
>  	crtc->primary->fb = fb;
>  	tilcdc_crtc->event = event;
> 

[toc] | [prev] | [next] | [standalone]


#1703213

FromDaniel Vetter <daniel@ffwll.ch>
Date2017-08-03 17:50 +0200
Message-ID<uaqxQ-1Y5-29@gated-at.bofh.it>
In reply to#1703141
On Thu, Aug 3, 2017 at 3:56 PM, Jyri Sarha <jsarha@ti.com> wrote:
>
> Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki
>
> On 08/03/17 14:58, Cihangir Akturk wrote:
>> drm_*_reference() and drm_*_unreference() functions are just
>> compatibility alias for drm_*_get() and drm_*_put() adn should not be
>> used by new code. So convert all users of compatibility functions to use
>> the new APIs.
>>
>> Signed-off-by: Cihangir Akturk <cakturk@gmail.com>
>
> Acked-by: Jyri Sarha <jsarha@ti.com>
>
> This appears to be a part of a larger series. So I guess it will go in
> via drm-misc. But if this is not the case just let me know and I'll add
> this to my next pull request.

Only if you join drm-misc and push it there yourself :-)

In general I prefer driver maintainers pick up their stuff for patch
series which don't have depencies like this here, otherwise, why
exactly do we have driver maintainers.

Thanks, Daniel

>
> Best Regards,
> Jyri
>
>> ---
>>  drivers/gpu/drm/tilcdc/tilcdc_crtc.c | 6 +++---
>>  1 file changed, 3 insertions(+), 3 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
>> index d524ed0..6e936dd 100644
>> --- a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
>> +++ b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
>> @@ -75,7 +75,7 @@ static void unref_worker(struct drm_flip_work *work, void *val)
>>       struct drm_device *dev = tilcdc_crtc->base.dev;
>>
>>       mutex_lock(&dev->mode_config.mutex);
>> -     drm_framebuffer_unreference(val);
>> +     drm_framebuffer_put(val);
>>       mutex_unlock(&dev->mode_config.mutex);
>>  }
>>
>> @@ -456,7 +456,7 @@ static void tilcdc_crtc_set_mode(struct drm_crtc *crtc)
>>
>>       set_scanout(crtc, fb);
>>
>> -     drm_framebuffer_reference(fb);
>> +     drm_framebuffer_get(fb);
>>
>>       crtc->hwmode = crtc->state->adjusted_mode;
>>  }
>> @@ -621,7 +621,7 @@ int tilcdc_crtc_update_fb(struct drm_crtc *crtc,
>>               return -EBUSY;
>>       }
>>
>> -     drm_framebuffer_reference(fb);
>> +     drm_framebuffer_get(fb);
>>
>>       crtc->primary->fb = fb;
>>       tilcdc_crtc->event = event;
>>
>
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel



-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch

[toc] | [prev] | [next] | [standalone]


#1703307

FromJyri Sarha <jsarha@ti.com>
Date2017-08-03 19:40 +0200
Message-ID<uasgj-3eZ-29@gated-at.bofh.it>
In reply to#1703213

Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki

On 08/03/17 18:42, Daniel Vetter wrote:
> On Thu, Aug 3, 2017 at 3:56 PM, Jyri Sarha <jsarha@ti.com> wrote:
>>
>> On 08/03/17 14:58, Cihangir Akturk wrote:
>>> drm_*_reference() and drm_*_unreference() functions are just
>>> compatibility alias for drm_*_get() and drm_*_put() adn should not be
>>> used by new code. So convert all users of compatibility functions to use
>>> the new APIs.
>>>
>>> Signed-off-by: Cihangir Akturk <cakturk@gmail.com>
>> Acked-by: Jyri Sarha <jsarha@ti.com>
>>
>> This appears to be a part of a larger series. So I guess it will go in
>> via drm-misc. But if this is not the case just let me know and I'll add
>> this to my next pull request.
> Only if you join drm-misc and push it there yourself :-)
> 
> In general I prefer driver maintainers pick up their stuff for patch
> series which don't have depencies like this here, otherwise, why
> exactly do we have driver maintainers.
> 

I assumed that the series would deprecate drm_framebuffer_unreference()
and -reference() aliases (if we are cleaning things up, why wouldn't we
go all the way?). But if that is not the case, then by all means I'll
pick the patch for a 4.14 tilcdc pull request.

Cheers,
Jyri

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web