drm/amd/display: Add a new DC debug mask for PSR-SU
authorMario Limonciello <mario.limonciello@amd.com>
Thu, 14 Dec 2023 21:07:32 +0000 (15:07 -0600)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 19 Dec 2023 19:47:15 +0000 (14:47 -0500)
Some issues have been raised that appear to be tied to PSR-SU.
To allow users to confirm they're tied to PSR-SU without turning off
PSR entirely introduce a new debug mask:

amdgpu.dcdebugmask=0x200

Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_psr.c
drivers/gpu/drm/amd/include/amd_shared.h

index 08ce3bb8f640d9dc24de199526383b18b1cb4469..1f08c6564c3bfea6dbc047b04eb1ee7603df0ead 100644 (file)
@@ -51,6 +51,9 @@ static bool link_supports_psrsu(struct dc_link *link)
            !link->dpcd_caps.psr_info.psr2_su_y_granularity_cap)
                return false;
 
+       if (amdgpu_dc_debug_mask & DC_DISABLE_PSR_SU)
+               return false;
+
        return dc_dmub_check_min_version(dc->ctx->dmub_srv->dmub);
 }
 
index bf7f258c324a1c52047f490bf3de8b42e8b87ec4..c739f12fb937d4e73d7e7538c224f1a6cc1b3be8 100644 (file)
@@ -258,6 +258,7 @@ enum DC_DEBUG_MASK {
        DC_DISABLE_REPLAY = 0x50,
        DC_ENABLE_DPIA_TRACE = 0x80,
        DC_ENABLE_DML2 = 0x100,
+       DC_DISABLE_PSR_SU = 0x200,
 };
 
 enum amd_dpm_forced_level;