Skip to contentSkip to conversation

drm/amdgpu/display: remove an old DCN3 guard

PATCH In review Alex Deucher 3 participants 6 messages May 7, 2021 – May 10, 2021

Subsystems (3)
lore
Share & tools
lore

Alex Deucher

author maintainer
#0 lore raw

PATCH 1/3 drm/amdgpu/display: remove an old DCN3 guard

The DCN3 guards were dropped a while ago, this one must have snuck in in a merge or something.

---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 --
 1 file changed, 2 deletions(-)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +0 -2
index bdbc577be65c..73d41cdd98ba 100644
@@ -3720,10 +3720,8 @@ static int amdgpu_dm_initialize_drm_device(struct amdgpu_device *adev)
 
 	/* Use Outbox interrupt */
 	switch (adev->asic_type) {
-#if defined(CONFIG_DRM_AMD_DC_DCN3_0)
 	case CHIP_SIENNA_CICHLID:
 	case CHIP_NAVY_FLOUNDER:
-#endif
 	case CHIP_RENOIR:
 		if (register_outbox_irq_handlers(dm->adev)) {
 			DRM_ERROR("DM: Failed to initialize IRQ\n");
Signature · 6 lines
2.30.2

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
author maintainer
#1 lore raw

PATCH 2/3 drm/amdgpu/display: fix warning when CONFIG_DRM_AMD_DC_DCN is not defined

Fixes:
At top level:
drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm.c:633:13: warning: ‘dm_dmub_outbox1_low_irq’ defined but not used [-Wunused-function]
633 | static void dm_dmub_outbox1_low_irq(void *interrupt_params)

      |             ^~~~~~~~~~~~~~~~~~~~~~~
Fixes 77a49c458931 ("drm/amd/display: Support for DMUB AUX")
Cc Jude Shih <[email protected]>
---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +1 -1
index 73d41cdd98ba..77bde54c9515 100644
@@ -620,7 +620,6 @@ static void dm_dcn_vertical_interrupt0_high_irq(void *interrupt_params)
 	amdgpu_dm_crtc_handle_crc_window_irq(&acrtc->base);
 }
 #endif
-#endif
 
 /**
  * dm_dmub_outbox1_low_irq() - Handles Outbox interrupt
@@ -673,6 +672,7 @@ static void dm_dmub_outbox1_low_irq(void *interrupt_params)
 
 	ASSERT(count <= DMUB_TRACE_MAX_READ);
 }
+#endif
 
 static int dm_set_clockgating_state(void *handle,
 		  enum amd_clockgating_state state)
Signature · 6 lines
2.30.2

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Reviewed-by Jude Shih on v1 2/3
#2 lore raw

RE: [PATCH 2/3] drm/amdgpu/display: fix warning when CONFIG_DRM_AMD_DC_DCN is not defined

[AMD Official Use Only - Internal Distribution Only]

-----Original Message-----
From: Deucher, Alexander <[email protected]>
Sent: Saturday, May 8, 2021 4:37 AM
To: [email protected]
Cc: Deucher, Alexander <[email protected]>; Shih, Jude <[email protected]>
Subject: [PATCH 2/3] drm/amdgpu/display: fix warning when CONFIG_DRM_AMD_DC_DCN is not defined

Fixes:
At top level:
drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm.c:633:13: warning: ‘dm_dmub_outbox1_low_irq’ defined but not used [-Wunused-function]
633 | static void dm_dmub_outbox1_low_irq(void *interrupt_params)

      |             ^~~~~~~~~~~~~~~~~~~~~~~
Fixes 77a49c458931 ("drm/amd/display: Support for DMUB AUX")
Cc Jude Shih <[email protected]>
---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +0 -1
index 73d41cdd98ba..77bde54c9515 100644
@@ -620,7 +620,6 @@ static void dm_dcn_vertical_interrupt0_high_irq(void *interrupt_params)
 	amdgpu_dm_crtc_handle_crc_window_irq(&acrtc->base);
 }
 #endif
-#endif
 
 /**
  * dm_dmub_outbox1_low_irq() - Handles Outbox interrupt @@ -673,6 +672,7 @@ static void dm_dmub_outbox1_low_irq(void *interrupt_params)

ASSERT(count <= DMUB_TRACE_MAX_READ);
}
+#endif

static int dm_set_clockgating_state(void *handle,
enum amd_clockgating_state state)
--
2.30.2
_______________________________________________
amd-gfx mailing list [email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

author maintainer
#3 lore raw

PATCH 3/3 drm/amdgpu/display: fix build when CONFIG_DRM_AMD_DC_DCN is not defined

In reply to Alex Deucher

Fixes:
drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm.c: In function ‘amdgpu_dm_initialize_drm_device’:
drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm.c:3726:7: error: implicit declaration of function ‘register_outbox_irq_handlers’; did you mean ‘register_hpd_handlers’? [-Werror=implicit-function-declaration]

 3726 |   if (register_outbox_irq_handlers(dm->adev)) {
      |       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |       register_hpd_handlers
Fixes 77a49c458931 ("drm/amd/display: Support for DMUB AUX")
Cc Jude Shish <[email protected]>
---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +2 -0
index 77bde54c9515..8ee9c03bf26c 100644
@@ -3718,6 +3718,7 @@ static int amdgpu_dm_initialize_drm_device(struct amdgpu_device *adev)
 			goto fail;
 		}
 
+#if defined(CONFIG_DRM_AMD_DC_DCN)
 	/* Use Outbox interrupt */
 	switch (adev->asic_type) {
 	case CHIP_SIENNA_CICHLID:
@@ -3731,6 +3732,7 @@ static int amdgpu_dm_initialize_drm_device(struct amdgpu_device *adev)
 	default:
 		DRM_DEBUG_KMS("Unsupported ASIC type for outbox: 0x%X\n", adev->asic_type);
 	}
+#endif
 
 	/* loops over all connectors on the board */
 	for (i = 0; i < link_cnt; i++) {
Signature · 6 lines
2.30.2

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Reviewed-by Jude Shih on v1 3/3
#4 lore raw

RE: [PATCH 3/3] drm/amdgpu/display: fix build when CONFIG_DRM_AMD_DC_DCN is not defined

[AMD Official Use Only - Internal Distribution Only]

-----Original Message-----
From: Deucher, Alexander <[email protected]>
Sent: Saturday, May 8, 2021 4:37 AM
To: [email protected]
Cc: Deucher, Alexander <[email protected]>; Shih, Jude <[email protected]>
Subject: [PATCH 3/3] drm/amdgpu/display: fix build when CONFIG_DRM_AMD_DC_DCN is not defined

Fixes:
drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm.c: In function ‘amdgpu_dm_initialize_drm_device’:
drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm.c:3726:7: error: implicit declaration of function ‘register_outbox_irq_handlers’; did you mean ‘register_hpd_handlers’? [-Werror=implicit-function-declaration]

 3726 |   if (register_outbox_irq_handlers(dm->adev)) {
      |       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |       register_hpd_handlers
Fixes 77a49c458931 ("drm/amd/display: Support for DMUB AUX")
Cc Jude Shish <[email protected]>
---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +2 -0
index 77bde54c9515..8ee9c03bf26c 100644
@@ -3718,6 +3718,7 @@ static int amdgpu_dm_initialize_drm_device(struct amdgpu_device *adev)
 			goto fail;
 		}
 
+#if defined(CONFIG_DRM_AMD_DC_DCN)
 	/* Use Outbox interrupt */
 	switch (adev->asic_type) {
 	case CHIP_SIENNA_CICHLID:
@@ -3731,6 +3732,7 @@ static int amdgpu_dm_initialize_drm_device(struct amdgpu_device *adev)
 	default:
 		DRM_DEBUG_KMS("Unsupported ASIC type for outbox: 0x%X\n", adev->asic_type);
 	}
+#endif
 
 	/* loops over all connectors on the board */
 	for (i = 0; i < link_cnt; i++) {
Signature · 5 lines
2.30.2
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Reviewed-by on v1 1/3
#5 lore raw
In reply to Alex Deucher

Thanks,

Quoted 30 lines · Alex Deucher

The DCN3 guards were dropped a while ago, this one must have snuck in in a merge or something.

---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 --
 1 file changed, 2 deletions(-)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +0 -2
index bdbc577be65c..73d41cdd98ba 100644
@@ -3720,10 +3720,8 @@ static int amdgpu_dm_initialize_drm_device(struct amdgpu_device *adev)
 
 	/* Use Outbox interrupt */
 	switch (adev->asic_type) {
-#if defined(CONFIG_DRM_AMD_DC_DCN3_0)
 	case CHIP_SIENNA_CICHLID:
 	case CHIP_NAVY_FLOUNDER:
-#endif
 	case CHIP_RENOIR:
 		if (register_outbox_irq_handlers(dm->adev)) {
 			DRM_ERROR("DM: Failed to initialize IRQ\n");
Signature · 6 lines
2.30.2

_______________________________________________
amd-gfx mailing list
[email protected]
https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfx&amp;data=04%7C01%7CRodrigo.Siqueira%40amd.com%7C25680479109e4017707308d91197df29%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637560166252532452%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&amp;sdata=nDdFg7%2FPczkIeaw9vNoD4%2BctBPiyfYNIGsbKKZQCpEs%3D&amp;reserved=0
Signature · 2 lines
Rodrigo Siqueira
https://siqueira.tech

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx