Skip to contentSkip to conversation

drm/amdgpu/discovery: make amdgpu_discovery_get_mall_info static

PATCH In review Jiapeng Chong 2 participants 2 messages May 24, 2022

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/amdgpu/discovery: make amdgpu_discovery_get_mall_info static

This symbol is not used outside of amdgpu_discovery.c, so marks it static.

Fixes the following w1 warning:

drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c:1364:5: warning: no previous prototype for ‘amdgpu_discovery_get_mall_info’ [-Wmissing-prototypes].

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +1 -1
index 881570dced41..16cdfb30b013 100644
@@ -1361,7 +1361,7 @@ union mall_info {
 	struct mall_info_v1_0 v1;
 };
 
-int amdgpu_discovery_get_mall_info(struct amdgpu_device *adev)
+static int amdgpu_discovery_get_mall_info(struct amdgpu_device *adev)
 {
 	struct binary_header *bhdr;
 	union mall_info *mall_info;
Signature · 1 line
2.20.1.7.g153144c
Reviewed-by Alex Deucher on v1 1/1
#1 lore raw

This is already static, in our local branch, from this commit:

commit 6852e61a0917a2

Author: Evan Quan <[email protected]>
Date:   Thu May 19 17:28:12 2022 +0800

drm/amdgpu: suppress some compile warnings

Suppress two compile warnings about "no previous prototype".

Regards,
Luben

Quoted 19 lines · Jiapeng Chong

This symbol is not used outside of amdgpu_discovery.c, so marks it static.

Fixes the following w1 warning:

drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c:1364:5: warning: no previous prototype for ‘amdgpu_discovery_get_mall_info’ [-Wmissing-prototypes].

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +0 -0
index 881570dced41..16cdfb30b013 100644

drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c union mall_info { · line 1367

Quoted 8 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +1 -1
@@ -1361,7 +1361,7 @@ union mall_info {
 	struct mall_info_v1_0 v1;
 };
 
-int amdgpu_discovery_get_mall_info(struct amdgpu_device *adev)
+static int amdgpu_discovery_get_mall_info(struct amdgpu_device *adev)
 {
 	struct binary_header *bhdr;
 	union mall_info *mall_info;

Regards,

Signature · 1 line
Luben