Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/amdgpu: Fix build warnings

Fix header guard and make internal functions static. Fixes the below warnings:

drivers/gpu/drm/amd/amdgpu/../amdgpu/amdgpu_reset.h:24:9: warning: '__AMDUGPU_RESET_H__' is used as a header guard here, followed by #define of a different macro [-Wheader-guard]
drivers/gpu/drm/amd/amdgpu/aldebaran.c:110:6: warning: no previous prototype for function 'aldebaran_async_reset' [-Wmissing-prototypes]
drivers/gpu/drm/amd/amdgpu/../pm/swsmu/smu13/aldebaran_ppt.c:1435:5: warning: no previous prototype for function 'aldebaran_mode2_reset' [-Wmissing-prototypes]

Signed-off-by: Lijo Lazar <lijo.lazar@amd.com>
Reported-by: kernel test robot <lkp@intel.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

authored by

Lijo Lazar and committed by
Alex Deucher
928a0fe6 ea4e96a7

+3 -3
+1 -1
drivers/gpu/drm/amd/amdgpu/aldebaran.c
··· 107 107 return r; 108 108 } 109 109 110 - void aldebaran_async_reset(struct work_struct *work) 110 + static void aldebaran_async_reset(struct work_struct *work) 111 111 { 112 112 struct amdgpu_reset_handler *handler; 113 113 struct amdgpu_reset_control *reset_ctl =
+1 -1
drivers/gpu/drm/amd/amdgpu/amdgpu_reset.h
··· 21 21 * 22 22 */ 23 23 24 - #ifndef __AMDUGPU_RESET_H__ 24 + #ifndef __AMDGPU_RESET_H__ 25 25 #define __AMDGPU_RESET_H__ 26 26 27 27 #include "amdgpu.h"
+1 -1
drivers/gpu/drm/amd/pm/swsmu/smu13/aldebaran_ppt.c
··· 1433 1433 return sizeof(struct gpu_metrics_v1_1); 1434 1434 } 1435 1435 1436 - int aldebaran_mode2_reset(struct smu_context *smu) 1436 + static int aldebaran_mode2_reset(struct smu_context *smu) 1437 1437 { 1438 1438 u32 smu_version; 1439 1439 int ret = 0, index;