diff mbox

drm/radeon/radeon_fb: Remove unused function

Message ID 1421175723-6893-1-git-send-email-rickard_strandqvist@spectrumdigital.se (mailing list archive)
State New, archived
Headers show

Commit Message

Rickard Strandqvist Jan. 13, 2015, 7:02 p.m. UTC
Remove the function radeon_fbdev_total_size() that is not used anywhere.

This was partially found by using a static code analysis program called cppcheck.

Signed-off-by: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se>
---
 drivers/gpu/drm/radeon/radeon_fb.c   |   10 ----------
 drivers/gpu/drm/radeon/radeon_mode.h |    1 -
 2 files changed, 11 deletions(-)

Comments

Alex Deucher Jan. 14, 2015, 9:44 p.m. UTC | #1
On Tue, Jan 13, 2015 at 2:02 PM, Rickard Strandqvist
<rickard_strandqvist@spectrumdigital.se> wrote:
> Remove the function radeon_fbdev_total_size() that is not used anywhere.
>
> This was partially found by using a static code analysis program called cppcheck.
>
> Signed-off-by: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se>

Applied.  thanks!

Alex

> ---
>  drivers/gpu/drm/radeon/radeon_fb.c   |   10 ----------
>  drivers/gpu/drm/radeon/radeon_mode.h |    1 -
>  2 files changed, 11 deletions(-)
>
> diff --git a/drivers/gpu/drm/radeon/radeon_fb.c b/drivers/gpu/drm/radeon/radeon_fb.c
> index 0ea1db8..76adbdb 100644
> --- a/drivers/gpu/drm/radeon/radeon_fb.c
> +++ b/drivers/gpu/drm/radeon/radeon_fb.c
> @@ -389,16 +389,6 @@ void radeon_fbdev_set_suspend(struct radeon_device *rdev, int state)
>         fb_set_suspend(rdev->mode_info.rfbdev->helper.fbdev, state);
>  }
>
> -int radeon_fbdev_total_size(struct radeon_device *rdev)
> -{
> -       struct radeon_bo *robj;
> -       int size = 0;
> -
> -       robj = gem_to_radeon_bo(rdev->mode_info.rfbdev->rfb.obj);
> -       size += radeon_bo_size(robj);
> -       return size;
> -}
> -
>  bool radeon_fbdev_robj_is_fb(struct radeon_device *rdev, struct radeon_bo *robj)
>  {
>         if (robj == gem_to_radeon_bo(rdev->mode_info.rfbdev->rfb.obj))
> diff --git a/drivers/gpu/drm/radeon/radeon_mode.h b/drivers/gpu/drm/radeon/radeon_mode.h
> index 04db2fd..ec2014a 100644
> --- a/drivers/gpu/drm/radeon/radeon_mode.h
> +++ b/drivers/gpu/drm/radeon/radeon_mode.h
> @@ -915,7 +915,6 @@ void dce8_program_fmt(struct drm_encoder *encoder);
>  int radeon_fbdev_init(struct radeon_device *rdev);
>  void radeon_fbdev_fini(struct radeon_device *rdev);
>  void radeon_fbdev_set_suspend(struct radeon_device *rdev, int state);
> -int radeon_fbdev_total_size(struct radeon_device *rdev);
>  bool radeon_fbdev_robj_is_fb(struct radeon_device *rdev, struct radeon_bo *robj);
>
>  void radeon_fb_output_poll_changed(struct radeon_device *rdev);
> --
> 1.7.10.4
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel
diff mbox

Patch

diff --git a/drivers/gpu/drm/radeon/radeon_fb.c b/drivers/gpu/drm/radeon/radeon_fb.c
index 0ea1db8..76adbdb 100644
--- a/drivers/gpu/drm/radeon/radeon_fb.c
+++ b/drivers/gpu/drm/radeon/radeon_fb.c
@@ -389,16 +389,6 @@  void radeon_fbdev_set_suspend(struct radeon_device *rdev, int state)
 	fb_set_suspend(rdev->mode_info.rfbdev->helper.fbdev, state);
 }
 
-int radeon_fbdev_total_size(struct radeon_device *rdev)
-{
-	struct radeon_bo *robj;
-	int size = 0;
-
-	robj = gem_to_radeon_bo(rdev->mode_info.rfbdev->rfb.obj);
-	size += radeon_bo_size(robj);
-	return size;
-}
-
 bool radeon_fbdev_robj_is_fb(struct radeon_device *rdev, struct radeon_bo *robj)
 {
 	if (robj == gem_to_radeon_bo(rdev->mode_info.rfbdev->rfb.obj))
diff --git a/drivers/gpu/drm/radeon/radeon_mode.h b/drivers/gpu/drm/radeon/radeon_mode.h
index 04db2fd..ec2014a 100644
--- a/drivers/gpu/drm/radeon/radeon_mode.h
+++ b/drivers/gpu/drm/radeon/radeon_mode.h
@@ -915,7 +915,6 @@  void dce8_program_fmt(struct drm_encoder *encoder);
 int radeon_fbdev_init(struct radeon_device *rdev);
 void radeon_fbdev_fini(struct radeon_device *rdev);
 void radeon_fbdev_set_suspend(struct radeon_device *rdev, int state);
-int radeon_fbdev_total_size(struct radeon_device *rdev);
 bool radeon_fbdev_robj_is_fb(struct radeon_device *rdev, struct radeon_bo *robj);
 
 void radeon_fb_output_poll_changed(struct radeon_device *rdev);