diff options
author | Alex Deucher <[email protected]> | 2022-06-15 17:00:19 -0400 |
---|---|---|
committer | Alex Deucher <[email protected]> | 2022-06-15 22:31:25 -0400 |
commit | c0c87382c1a6985cd12a49a62a893361e5fd1b8f (patch) | |
tree | edb4f5a4628db53e9f264982dc68b2efa8269cf3 | |
parent | abf0ba5a34eae0d7359228f4319a6659676fbd0a (diff) |
drm/amdgpu/display: fix build when CONFIG_DEBUG_FS is not set
amdgpu_dm_crtc_late_register() is only used when CONFIG_DEBUG_FS
is enabled so make it dependent on that.
Fixes: 4cd79f614b50 ("drm/amd/display: Move connector debugfs to drm")
Cc: Bhanuprakash Modem <[email protected]>
Cc: Harry Wentland <[email protected]>
Cc: Arun R Murthy <[email protected]>
Cc: Jani Nikula <[email protected]>
Reported-by: Randy Dunlap <[email protected]>
Reported-by: Nathan Chancellor <[email protected]>
Reviewed-by: Harry Wentland <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
Tested-by: Nathan Chancellor <[email protected]> # build
Link: https://lists.freedesktop.org/archives/dri-devel/2022-June/359496.html
Signed-off-by: Alex Deucher <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
-rw-r--r-- | drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c index dae0b772865c..4515630fb9d2 100644 --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c @@ -6617,12 +6617,14 @@ dm_crtc_duplicate_state(struct drm_crtc *crtc) return &state->base; } +#ifdef CONFIG_DEBUG_FS static int amdgpu_dm_crtc_late_register(struct drm_crtc *crtc) { crtc_debugfs_init(crtc); return 0; } +#endif static inline int dm_set_vupdate_irq(struct drm_crtc *crtc, bool enable) { @@ -6720,7 +6722,9 @@ static const struct drm_crtc_funcs amdgpu_dm_crtc_funcs = { .enable_vblank = dm_enable_vblank, .disable_vblank = dm_disable_vblank, .get_vblank_timestamp = drm_crtc_vblank_helper_get_vblank_timestamp, +#if defined(CONFIG_DEBUG_FS) .late_register = amdgpu_dm_crtc_late_register, +#endif }; static enum drm_connector_status |