diff mbox series

[43/43] drm/radeon/radeon_drv: Move 'radeon_gem_prime_import_sg_table()'s prototype to shared header

Message ID 20201116173700.1830487-44-lee.jones@linaro.org
State Accepted
Commit 4138b62b8a799cc3d1cb0ec2b443a1c42369f4dd
Headers show
Series Rid W=1 warnings from GPU | expand

Commit Message

Lee Jones Nov. 16, 2020, 5:37 p.m. UTC
Fixes the following W=1 kernel build warning(s):

 drivers/gpu/drm/radeon/radeon_prime.c:43:24: warning: no previous prototype for ‘radeon_gem_prime_import_sg_table’ [-Wmissing-prototypes]
 43 | struct drm_gem_object *radeon_gem_prime_import_sg_table(struct drm_device *dev,
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Gareth Hughes <gareth@valinux.com>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/radeon/radeon_drv.c   | 4 +---
 drivers/gpu/drm/radeon/radeon_prime.h | 3 +++
 2 files changed, 4 insertions(+), 3 deletions(-)

Comments

Alex Deucher Nov. 16, 2020, 8:50 p.m. UTC | #1
On Mon, Nov 16, 2020 at 12:38 PM Lee Jones <lee.jones@linaro.org> wrote:
>
> Fixes the following W=1 kernel build warning(s):
>
>  drivers/gpu/drm/radeon/radeon_prime.c:43:24: warning: no previous prototype for ‘radeon_gem_prime_import_sg_table’ [-Wmissing-prototypes]
>  43 | struct drm_gem_object *radeon_gem_prime_import_sg_table(struct drm_device *dev,
>  | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: Gareth Hughes <gareth@valinux.com>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Applied.  Thanks!

Alex

> ---
>  drivers/gpu/drm/radeon/radeon_drv.c   | 4 +---
>  drivers/gpu/drm/radeon/radeon_prime.h | 3 +++
>  2 files changed, 4 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/radeon/radeon_drv.c b/drivers/gpu/drm/radeon/radeon_drv.c
> index 211932d73b191..7a0989b397da1 100644
> --- a/drivers/gpu/drm/radeon/radeon_drv.c
> +++ b/drivers/gpu/drm/radeon/radeon_drv.c
> @@ -55,6 +55,7 @@
>  #include "radeon_ttm.h"
>  #include "radeon.h"
>  #include "radeon_device.h"
> +#include "radeon_prime.h"
>
>  /*
>   * KMS wrapper.
> @@ -129,9 +130,6 @@ int radeon_mode_dumb_mmap(struct drm_file *filp,
>  int radeon_mode_dumb_create(struct drm_file *file_priv,
>                             struct drm_device *dev,
>                             struct drm_mode_create_dumb *args);
> -struct drm_gem_object *radeon_gem_prime_import_sg_table(struct drm_device *dev,
> -                                                       struct dma_buf_attachment *,
> -                                                       struct sg_table *sg);
>
>  /* atpx handler */
>  #if defined(CONFIG_VGA_SWITCHEROO)
> diff --git a/drivers/gpu/drm/radeon/radeon_prime.h b/drivers/gpu/drm/radeon/radeon_prime.h
> index 11b7f80987834..24ddfd4b48a6d 100644
> --- a/drivers/gpu/drm/radeon/radeon_prime.h
> +++ b/drivers/gpu/drm/radeon/radeon_prime.h
> @@ -35,5 +35,8 @@ int radeon_gem_prime_pin(struct drm_gem_object *obj);
>  void radeon_gem_prime_unpin(struct drm_gem_object *obj);
>  void *radeon_gem_prime_vmap(struct drm_gem_object *obj);
>  void radeon_gem_prime_vunmap(struct drm_gem_object *obj, void *vaddr);
> +struct drm_gem_object *radeon_gem_prime_import_sg_table(struct drm_device *dev,
> +                                                       struct dma_buf_attachment *,
> +                                                       struct sg_table *sg);
>
>  #endif                         /* __RADEON_PRIME_H__ */
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
diff mbox series

Patch

diff --git a/drivers/gpu/drm/radeon/radeon_drv.c b/drivers/gpu/drm/radeon/radeon_drv.c
index 211932d73b191..7a0989b397da1 100644
--- a/drivers/gpu/drm/radeon/radeon_drv.c
+++ b/drivers/gpu/drm/radeon/radeon_drv.c
@@ -55,6 +55,7 @@ 
 #include "radeon_ttm.h"
 #include "radeon.h"
 #include "radeon_device.h"
+#include "radeon_prime.h"
 
 /*
  * KMS wrapper.
@@ -129,9 +130,6 @@  int radeon_mode_dumb_mmap(struct drm_file *filp,
 int radeon_mode_dumb_create(struct drm_file *file_priv,
 			    struct drm_device *dev,
 			    struct drm_mode_create_dumb *args);
-struct drm_gem_object *radeon_gem_prime_import_sg_table(struct drm_device *dev,
-							struct dma_buf_attachment *,
-							struct sg_table *sg);
 
 /* atpx handler */
 #if defined(CONFIG_VGA_SWITCHEROO)
diff --git a/drivers/gpu/drm/radeon/radeon_prime.h b/drivers/gpu/drm/radeon/radeon_prime.h
index 11b7f80987834..24ddfd4b48a6d 100644
--- a/drivers/gpu/drm/radeon/radeon_prime.h
+++ b/drivers/gpu/drm/radeon/radeon_prime.h
@@ -35,5 +35,8 @@  int radeon_gem_prime_pin(struct drm_gem_object *obj);
 void radeon_gem_prime_unpin(struct drm_gem_object *obj);
 void *radeon_gem_prime_vmap(struct drm_gem_object *obj);
 void radeon_gem_prime_vunmap(struct drm_gem_object *obj, void *vaddr);
+struct drm_gem_object *radeon_gem_prime_import_sg_table(struct drm_device *dev,
+							struct dma_buf_attachment *,
+							struct sg_table *sg);
 
 #endif				/* __RADEON_PRIME_H__ */