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


Groups > linux.kernel > #1703015 > unrolled thread

[PATCH 05/29] drm/atmel-hlcdc: switch to drm_*{get,put} helpers

Started byCihangir Akturk <cakturk@gmail.com>
First post2017-08-03 14:10 +0200
Last post2017-08-03 17:00 +0200
Articles 3 — 2 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 05/29] drm/atmel-hlcdc: switch to drm_*{get,put} helpers Cihangir Akturk <cakturk@gmail.com> - 2017-08-03 14:10 +0200
    Re: [PATCH 05/29] drm/atmel-hlcdc: switch to drm_*{get,put} helpers Boris Brezillon <boris.brezillon@free-electrons.com> - 2017-08-03 14:20 +0200
      Re: [PATCH 05/29] drm/atmel-hlcdc: switch to drm_*{get,put} helpers Boris Brezillon <boris.brezillon@free-electrons.com> - 2017-08-03 17:00 +0200

#1703015 — [PATCH 05/29] drm/atmel-hlcdc: switch to drm_*{get,put} helpers

FromCihangir Akturk <cakturk@gmail.com>
Date2017-08-03 14:10 +0200
Subject[PATCH 05/29] drm/atmel-hlcdc: switch to drm_*{get,put} helpers
Message-ID<uan6Y-8co-49@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/atmel-hlcdc/atmel_hlcdc_plane.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c
index 1124200..fc3f910 100644
--- a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c
+++ b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c
@@ -809,7 +809,7 @@ static void atmel_hlcdc_plane_destroy(struct drm_plane *p)
 	struct atmel_hlcdc_plane *plane = drm_plane_to_atmel_hlcdc_plane(p);
 
 	if (plane->base.fb)
-		drm_framebuffer_unreference(plane->base.fb);
+		drm_framebuffer_put(plane->base.fb);
 
 	drm_plane_cleanup(p);
 }
@@ -958,7 +958,7 @@ static void atmel_hlcdc_plane_reset(struct drm_plane *p)
 		state = drm_plane_state_to_atmel_hlcdc_plane_state(p->state);
 
 		if (state->base.fb)
-			drm_framebuffer_unreference(state->base.fb);
+			drm_framebuffer_put(state->base.fb);
 
 		kfree(state);
 		p->state = NULL;
@@ -996,7 +996,7 @@ atmel_hlcdc_plane_atomic_duplicate_state(struct drm_plane *p)
 	}
 
 	if (copy->base.fb)
-		drm_framebuffer_reference(copy->base.fb);
+		drm_framebuffer_get(copy->base.fb);
 
 	return &copy->base;
 }
@@ -1015,7 +1015,7 @@ static void atmel_hlcdc_plane_atomic_destroy_state(struct drm_plane *p,
 	}
 
 	if (s->fb)
-		drm_framebuffer_unreference(s->fb);
+		drm_framebuffer_put(s->fb);
 
 	kfree(state);
 }
-- 
2.7.4

[toc] | [next] | [standalone]


#1703031

FromBoris Brezillon <boris.brezillon@free-electrons.com>
Date2017-08-03 14:20 +0200
Message-ID<uangC-8g7-3@gated-at.bofh.it>
In reply to#1703015
On Thu,  3 Aug 2017 14:58:20 +0300
Cihangir Akturk <cakturk@gmail.com> wrote:

> drm_*_reference() and drm_*_unreference() functions are just
> compatibility alias for drm_*_get() and drm_*_put() adn should not be

s/adn/and/

> 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: Boris Brezillon <boris.brezillon@free-electrons.com>

> ---
>  drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c
> index 1124200..fc3f910 100644
> --- a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c
> +++ b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c
> @@ -809,7 +809,7 @@ static void atmel_hlcdc_plane_destroy(struct drm_plane *p)
>  	struct atmel_hlcdc_plane *plane = drm_plane_to_atmel_hlcdc_plane(p);
>  
>  	if (plane->base.fb)
> -		drm_framebuffer_unreference(plane->base.fb);
> +		drm_framebuffer_put(plane->base.fb);
>  
>  	drm_plane_cleanup(p);
>  }
> @@ -958,7 +958,7 @@ static void atmel_hlcdc_plane_reset(struct drm_plane *p)
>  		state = drm_plane_state_to_atmel_hlcdc_plane_state(p->state);
>  
>  		if (state->base.fb)
> -			drm_framebuffer_unreference(state->base.fb);
> +			drm_framebuffer_put(state->base.fb);
>  
>  		kfree(state);
>  		p->state = NULL;
> @@ -996,7 +996,7 @@ atmel_hlcdc_plane_atomic_duplicate_state(struct drm_plane *p)
>  	}
>  
>  	if (copy->base.fb)
> -		drm_framebuffer_reference(copy->base.fb);
> +		drm_framebuffer_get(copy->base.fb);
>  
>  	return &copy->base;
>  }
> @@ -1015,7 +1015,7 @@ static void atmel_hlcdc_plane_atomic_destroy_state(struct drm_plane *p,
>  	}
>  
>  	if (s->fb)
> -		drm_framebuffer_unreference(s->fb);
> +		drm_framebuffer_put(s->fb);
>  
>  	kfree(state);
>  }

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


#1703181

FromBoris Brezillon <boris.brezillon@free-electrons.com>
Date2017-08-03 17:00 +0200
Message-ID<uapLr-1ol-15@gated-at.bofh.it>
In reply to#1703031
On Thu, 3 Aug 2017 14:10:50 +0200
Boris Brezillon <boris.brezillon@free-electrons.com> wrote:

> On Thu,  3 Aug 2017 14:58:20 +0300
> Cihangir Akturk <cakturk@gmail.com> wrote:
> 
> > drm_*_reference() and drm_*_unreference() functions are just
> > compatibility alias for drm_*_get() and drm_*_put() adn should not be  
> 
> s/adn/and/
> 
> > 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: Boris Brezillon <boris.brezillon@free-electrons.com>

Applied to drm-misc-next (as suggested by Daniel) after fixing the
typo.

Thanks,

Boris

> 
> > ---
> >  drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c | 8 ++++----
> >  1 file changed, 4 insertions(+), 4 deletions(-)
> > 
> > diff --git a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c
> > index 1124200..fc3f910 100644
> > --- a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c
> > +++ b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c
> > @@ -809,7 +809,7 @@ static void atmel_hlcdc_plane_destroy(struct drm_plane *p)
> >  	struct atmel_hlcdc_plane *plane = drm_plane_to_atmel_hlcdc_plane(p);
> >  
> >  	if (plane->base.fb)
> > -		drm_framebuffer_unreference(plane->base.fb);
> > +		drm_framebuffer_put(plane->base.fb);
> >  
> >  	drm_plane_cleanup(p);
> >  }
> > @@ -958,7 +958,7 @@ static void atmel_hlcdc_plane_reset(struct drm_plane *p)
> >  		state = drm_plane_state_to_atmel_hlcdc_plane_state(p->state);
> >  
> >  		if (state->base.fb)
> > -			drm_framebuffer_unreference(state->base.fb);
> > +			drm_framebuffer_put(state->base.fb);
> >  
> >  		kfree(state);
> >  		p->state = NULL;
> > @@ -996,7 +996,7 @@ atmel_hlcdc_plane_atomic_duplicate_state(struct drm_plane *p)
> >  	}
> >  
> >  	if (copy->base.fb)
> > -		drm_framebuffer_reference(copy->base.fb);
> > +		drm_framebuffer_get(copy->base.fb);
> >  
> >  	return &copy->base;
> >  }
> > @@ -1015,7 +1015,7 @@ static void atmel_hlcdc_plane_atomic_destroy_state(struct drm_plane *p,
> >  	}
> >  
> >  	if (s->fb)
> > -		drm_framebuffer_unreference(s->fb);
> > +		drm_framebuffer_put(s->fb);
> >  
> >  	kfree(state);
> >  }  
> 

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web