linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm/amdgpu: add missing header dependencies
@ 2016-09-18 13:12 Baoyou Xie
  2016-09-19  9:59 ` Christian König
  0 siblings, 1 reply; 2+ messages in thread
From: Baoyou Xie @ 2016-09-18 13:12 UTC (permalink / raw)
  To: alexander.deucher, christian.koenig, airlied, nicolai.haehnle,
	michel.daenzer, daniel.vetter, tom.stdenis, gustavo.padovan,
	eric.engestrom, Emily.Deng, Flora.Cui, vitaly.prosyak,
	alexandre.f.demers, Jerry.Zhang
  Cc: dri-devel, linux-kernel, arnd, baoyou.xie, xie.baoyou

We get 6 warnings when building kernel with W=1:
drivers/gpu/drm/amd/amdgpu/dce_v8_0.c:629:6: warning: no previous prototype for 'dce_v8_0_disable_dce' [-Wmissing-prototypes]
drivers/gpu/drm/amd/amdgpu/dce_v10_0.c:730:6: warning: no previous prototype for 'dce_v10_0_disable_dce' [-Wmissing-prototypes]
drivers/gpu/drm/amd/amdgpu/dce_v11_0.c:699:6: warning: no previous prototype for 'dce_v11_0_disable_dce' [-Wmissing-prototypes]
drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c:40:5: warning: no previous prototype for 'amdgpu_gfx_scratch_get' [-Wmissing-prototypes]
drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c:62:6: warning: no previous prototype for 'amdgpu_gfx_scratch_free' [-Wmissing-prototypes]
drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c:84:6: warning: no previous prototype for 'amdgpu_gfx_parse_disable_cu' [-Wmissing-prototypes]

In fact, these functions are declared in
drivers/gpu/drm/amd/amdgpu/dce_v8_0.h
drivers/gpu/drm/amd/amdgpu/dce_v10_0.h
drivers/gpu/drm/amd/amdgpu/dce_v11_0.h
drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h,
so this patch adds missing header dependencies.

Signed-off-by: Baoyou Xie <baoyou.xie@linaro.org>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 1 +
 drivers/gpu/drm/amd/amdgpu/dce_v10_0.c  | 1 +
 drivers/gpu/drm/amd/amdgpu/dce_v11_0.c  | 1 +
 drivers/gpu/drm/amd/amdgpu/dce_v8_0.c   | 1 +
 4 files changed, 4 insertions(+)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
index a074edd..01a42b6 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
@@ -24,6 +24,7 @@
  */
 #include <drm/drmP.h>
 #include "amdgpu.h"
+#include "amdgpu_gfx.h"
 
 /*
  * GPU scratch registers helpers function.
diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
index bc5bb4e..fb943ee 100644
--- a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
@@ -35,6 +35,7 @@
 #include "dce/dce_10_0_d.h"
 #include "dce/dce_10_0_sh_mask.h"
 #include "dce/dce_10_0_enum.h"
+#include "dce_v10_0.h"
 #include "oss/oss_3_0_d.h"
 #include "oss/oss_3_0_sh_mask.h"
 #include "gmc/gmc_8_1_d.h"
diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
index b93eba0..1555d6d 100644
--- a/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
@@ -35,6 +35,7 @@
 #include "dce/dce_11_0_d.h"
 #include "dce/dce_11_0_sh_mask.h"
 #include "dce/dce_11_0_enum.h"
+#include "dce_v11_0.h"
 #include "oss/oss_3_0_d.h"
 #include "oss/oss_3_0_sh_mask.h"
 #include "gmc/gmc_8_1_d.h"
diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
index abd5213..ef7add9 100644
--- a/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
@@ -34,6 +34,7 @@
 
 #include "dce/dce_8_0_d.h"
 #include "dce/dce_8_0_sh_mask.h"
+#include "dce_v8_0.h"
 
 #include "gca/gfx_7_2_enum.h"
 
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] drm/amdgpu: add missing header dependencies
  2016-09-18 13:12 [PATCH] drm/amdgpu: add missing header dependencies Baoyou Xie
@ 2016-09-19  9:59 ` Christian König
  0 siblings, 0 replies; 2+ messages in thread
From: Christian König @ 2016-09-19  9:59 UTC (permalink / raw)
  To: Baoyou Xie, Deucher, Alexander, airlied, Haehnle, Nicolai,
	Daenzer, Michel, daniel.vetter, StDenis, Tom, gustavo.padovan,
	eric.engestrom, Deng, Emily, Cui, Flora, Prosyak, Vitaly,
	alexandre.f.demers, Zhang, Jerry
  Cc: dri-devel, linux-kernel, arnd, xie.baoyou

Am 18.09.2016 um 15:12 schrieb Baoyou Xie:
> We get 6 warnings when building kernel with W=1:
> drivers/gpu/drm/amd/amdgpu/dce_v8_0.c:629:6: warning: no previous prototype for 'dce_v8_0_disable_dce' [-Wmissing-prototypes]
> drivers/gpu/drm/amd/amdgpu/dce_v10_0.c:730:6: warning: no previous prototype for 'dce_v10_0_disable_dce' [-Wmissing-prototypes]
> drivers/gpu/drm/amd/amdgpu/dce_v11_0.c:699:6: warning: no previous prototype for 'dce_v11_0_disable_dce' [-Wmissing-prototypes]
> drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c:40:5: warning: no previous prototype for 'amdgpu_gfx_scratch_get' [-Wmissing-prototypes]
> drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c:62:6: warning: no previous prototype for 'amdgpu_gfx_scratch_free' [-Wmissing-prototypes]
> drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c:84:6: warning: no previous prototype for 'amdgpu_gfx_parse_disable_cu' [-Wmissing-prototypes]
>
> In fact, these functions are declared in
> drivers/gpu/drm/amd/amdgpu/dce_v8_0.h
> drivers/gpu/drm/amd/amdgpu/dce_v10_0.h
> drivers/gpu/drm/amd/amdgpu/dce_v11_0.h
> drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h,
> so this patch adds missing header dependencies.
>
> Signed-off-by: Baoyou Xie <baoyou.xie@linaro.org>

Reviewed-by: Christian König <christian.koenig@amd.com>.

> ---
>   drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 1 +
>   drivers/gpu/drm/amd/amdgpu/dce_v10_0.c  | 1 +
>   drivers/gpu/drm/amd/amdgpu/dce_v11_0.c  | 1 +
>   drivers/gpu/drm/amd/amdgpu/dce_v8_0.c   | 1 +
>   4 files changed, 4 insertions(+)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
> index a074edd..01a42b6 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
> @@ -24,6 +24,7 @@
>    */
>   #include <drm/drmP.h>
>   #include "amdgpu.h"
> +#include "amdgpu_gfx.h"
>   
>   /*
>    * GPU scratch registers helpers function.
> diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
> index bc5bb4e..fb943ee 100644
> --- a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
> @@ -35,6 +35,7 @@
>   #include "dce/dce_10_0_d.h"
>   #include "dce/dce_10_0_sh_mask.h"
>   #include "dce/dce_10_0_enum.h"
> +#include "dce_v10_0.h"
>   #include "oss/oss_3_0_d.h"
>   #include "oss/oss_3_0_sh_mask.h"
>   #include "gmc/gmc_8_1_d.h"
> diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
> index b93eba0..1555d6d 100644
> --- a/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
> @@ -35,6 +35,7 @@
>   #include "dce/dce_11_0_d.h"
>   #include "dce/dce_11_0_sh_mask.h"
>   #include "dce/dce_11_0_enum.h"
> +#include "dce_v11_0.h"
>   #include "oss/oss_3_0_d.h"
>   #include "oss/oss_3_0_sh_mask.h"
>   #include "gmc/gmc_8_1_d.h"
> diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
> index abd5213..ef7add9 100644
> --- a/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
> @@ -34,6 +34,7 @@
>   
>   #include "dce/dce_8_0_d.h"
>   #include "dce/dce_8_0_sh_mask.h"
> +#include "dce_v8_0.h"
>   
>   #include "gca/gfx_7_2_enum.h"
>   

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-09-19 10:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-18 13:12 [PATCH] drm/amdgpu: add missing header dependencies Baoyou Xie
2016-09-19  9:59 ` Christian König

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).