Commit 356aee30 authored by Baoyou Xie's avatar Baoyou Xie Committed by Alex Deucher

drm/amdgpu: change function declarations and add missing header dependencies

We get a few warnings when building kernel with W=1:
drivers/gpu/drm/amd/amdgpu/atombios_crtc.c:38:6: warning: no previous prototype for 'amdgpu_atombios_crtc_overscan_setup' [-Wmissing-prototypes]
drivers/gpu/drm/amd/amdgpu/dce_v8_0.c:661:6: warning: no previous prototype for 'dce_v8_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]
....

In fact, these functions are declared in
drivers/gpu/drm/amd/amdgpu/atombios_crtc.h
drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
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/powerplay/inc/pp_acpi.h.
So this patch adds missing header dependencies.

By the way, this patch changes declaration of amdgpu_gfx_parse_disable_cu()
to subject to its implement, and clean three function declarations
in pp_acpi.h up.
Acked-by: default avatarEdward O'Callaghan <funfunctor@folklore1984.net>
Acked-by: default avatarChristian König <christian.koenig@amd.com>
Signed-off-by: default avatarBaoyou Xie <baoyou.xie@linaro.org>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent f93932bc
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
*/ */
#include <drm/drmP.h> #include <drm/drmP.h>
#include "amdgpu.h" #include "amdgpu.h"
#include "amdgpu_gfx.h"
/* /*
* GPU scratch registers helpers function. * GPU scratch registers helpers function.
......
...@@ -27,6 +27,7 @@ ...@@ -27,6 +27,7 @@
int amdgpu_gfx_scratch_get(struct amdgpu_device *adev, uint32_t *reg); int amdgpu_gfx_scratch_get(struct amdgpu_device *adev, uint32_t *reg);
void amdgpu_gfx_scratch_free(struct amdgpu_device *adev, uint32_t reg); void amdgpu_gfx_scratch_free(struct amdgpu_device *adev, uint32_t reg);
unsigned amdgpu_gfx_parse_disable_cu(unsigned *mask, unsigned max_se, unsigned max_sh); void amdgpu_gfx_parse_disable_cu(unsigned *mask, unsigned max_se,
unsigned max_sh);
#endif #endif
...@@ -31,6 +31,7 @@ ...@@ -31,6 +31,7 @@
#include "atom.h" #include "atom.h"
#include "atom-bits.h" #include "atom-bits.h"
#include "atombios_encoders.h" #include "atombios_encoders.h"
#include "atombios_crtc.h"
#include "amdgpu_atombios.h" #include "amdgpu_atombios.h"
#include "amdgpu_pll.h" #include "amdgpu_pll.h"
#include "amdgpu_connectors.h" #include "amdgpu_connectors.h"
......
...@@ -31,6 +31,7 @@ ...@@ -31,6 +31,7 @@
#include "atombios_encoders.h" #include "atombios_encoders.h"
#include "amdgpu_pll.h" #include "amdgpu_pll.h"
#include "amdgpu_connectors.h" #include "amdgpu_connectors.h"
#include "dce_v10_0.h"
#include "dce/dce_10_0_d.h" #include "dce/dce_10_0_d.h"
#include "dce/dce_10_0_sh_mask.h" #include "dce/dce_10_0_sh_mask.h"
......
...@@ -31,6 +31,7 @@ ...@@ -31,6 +31,7 @@
#include "atombios_encoders.h" #include "atombios_encoders.h"
#include "amdgpu_pll.h" #include "amdgpu_pll.h"
#include "amdgpu_connectors.h" #include "amdgpu_connectors.h"
#include "dce_v11_0.h"
#include "dce/dce_11_0_d.h" #include "dce/dce_11_0_d.h"
#include "dce/dce_11_0_sh_mask.h" #include "dce/dce_11_0_sh_mask.h"
......
...@@ -31,6 +31,7 @@ ...@@ -31,6 +31,7 @@
#include "atombios_encoders.h" #include "atombios_encoders.h"
#include "amdgpu_pll.h" #include "amdgpu_pll.h"
#include "amdgpu_connectors.h" #include "amdgpu_connectors.h"
#include "dce_v8_0.h"
#include "dce/dce_8_0_d.h" #include "dce/dce_8_0_d.h"
#include "dce/dce_8_0_sh_mask.h" #include "dce/dce_8_0_sh_mask.h"
......
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
#include "linux/delay.h" #include "linux/delay.h"
#include "hwmgr.h" #include "hwmgr.h"
#include "amd_acpi.h" #include "amd_acpi.h"
#include "pp_acpi.h"
bool acpi_atcs_functions_supported(void *device, uint32_t index) bool acpi_atcs_functions_supported(void *device, uint32_t index)
{ {
......
...@@ -21,9 +21,6 @@ ...@@ -21,9 +21,6 @@
* *
*/ */
extern bool acpi_atcs_functions_supported(void *device, bool acpi_atcs_functions_supported(void *device, uint32_t index);
uint32_t index); int acpi_pcie_perf_request(void *device, uint8_t perf_req, bool advertise);
extern int acpi_pcie_perf_request(void *device, bool acpi_atcs_notify_pcie_device_ready(void *device);
uint8_t perf_req,
bool advertise);
extern bool acpi_atcs_notify_pcie_device_ready(void *device);
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment