Skip to contentSkip to conversation

drm/amdgpu/display: fix compilation when CONFIG_DRM_AMD_DC_DCN is not set

PATCH In review Alex Deucher 2 participants 2 messages Feb 23, 2021

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

PATCH 1/1 drm/amdgpu/display: fix compilation when CONFIG_DRM_AMD_DC_DCN is not set

Missing some CONFIG_DRM_AMD_DC_DCN ifdefs.

Fixes 9d99a805a9a0 ("drm/amd/display: Fix system hang after multiple hotplugs")
Cc Stephen Rothwell <[email protected]>
Cc Qingqing Zhuo <[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 7a393eeae4b1..22443e696567 100644
@@ -5457,12 +5457,14 @@ static inline int dm_set_vblank(struct drm_crtc *crtc, bool enable)
 	if (amdgpu_in_reset(adev))
 		return 0;
 
+#if defined(CONFIG_DRM_AMD_DC_DCN)
 	spin_lock_irqsave(&dm->vblank_lock, flags);
 	dm->vblank_workqueue->dm = dm;
 	dm->vblank_workqueue->otg_inst = acrtc->otg_inst;
 	dm->vblank_workqueue->enable = enable;
 	spin_unlock_irqrestore(&dm->vblank_lock, flags);
 	schedule_work(&dm->vblank_workqueue->mall_work);
+#endif
 
 	return 0;
 }
Signature · 6 lines
2.29.2

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Reviewed-by on v1 1/1
#1 lore raw
Quoted 6 lines · Alex Deucher

Missing some CONFIG_DRM_AMD_DC_DCN ifdefs.

Fixes 9d99a805a9a0 ("drm/amd/display: Fix system hang after multiple hotplugs")
Cc Stephen Rothwell <[email protected]>
Cc Qingqing Zhuo <[email protected]>

Regards,
Nicholas Kazlauskas

Quoted 14 lines
---
  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 +1 -0
index 7a393eeae4b1..22443e696567 100644
@@ -5457,12 +5457,14 @@ static inline int dm_set_vblank(struct drm_crtc *crtc, bool enable)
  	if (amdgpu_in_reset(adev))
  		return 0;
 
+#if defined(CONFIG_DRM_AMD_DC_DCN)

drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c static inline int dm_set_vblank(struct drm_crtc *crtc, bool enable) · line 5470

Quoted 10 lines
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +1 -0
  	spin_lock_irqsave(&dm->vblank_lock, flags);
  	dm->vblank_workqueue->dm = dm;
  	dm->vblank_workqueue->otg_inst = acrtc->otg_inst;
  	dm->vblank_workqueue->enable = enable;
  	spin_unlock_irqrestore(&dm->vblank_lock, flags);
  	schedule_work(&dm->vblank_workqueue->mall_work);
+#endif
 
  	return 0;
  }

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