drm/amd/display: Reuse Subvp debug option for FAMS
authorAurabindo Pillai <aurabindo.pillai@amd.com>
Thu, 22 May 2025 14:34:50 +0000 (10:34 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 29 May 2025 14:54:56 +0000 (10:54 -0400)
FAMS is the successor to SubVP starting with DCN4x. Reuse the same
debug option to disable FAMS for debugging purposes.

Signed-off-by: Aurabindo Pillai <aurabindo.pillai@amd.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
drivers/gpu/drm/amd/include/amd_shared.h

index 9f2e263..1797fa8 100644 (file)
@@ -2000,8 +2000,10 @@ static int amdgpu_dm_init(struct amdgpu_device *adev)
        if (amdgpu_dc_debug_mask & DC_FORCE_SUBVP_MCLK_SWITCH)
                adev->dm.dc->debug.force_subvp_mclk_switch = true;
 
-       if (amdgpu_dc_debug_mask & DC_DISABLE_SUBVP)
+       if (amdgpu_dc_debug_mask & DC_DISABLE_SUBVP_FAMS) {
                adev->dm.dc->debug.force_disable_subvp = true;
+               adev->dm.dc->debug.fams2_config.bits.enable = false;
+       }
 
        if (amdgpu_dc_debug_mask & DC_ENABLE_DML2) {
                adev->dm.dc->debug.using_dml2 = true;
index 31de36c..11374a2 100644 (file)
@@ -351,9 +351,10 @@ enum DC_DEBUG_MASK {
        DC_DISABLE_HDMI_CEC = 0x10000,
 
        /**
-        * @DC_DISABLE_SUBVP: If set, disable DCN Sub-Viewport feature in amdgpu driver.
+        * @DC_DISABLE_SUBVP_FAMS: If set, disable DCN Sub-Viewport & Firmware Assisted
+        * Memory Clock Switching (FAMS) feature in amdgpu driver.
         */
-       DC_DISABLE_SUBVP = 0x20000,
+       DC_DISABLE_SUBVP_FAMS = 0x20000,
        /**
         * @DC_DISABLE_CUSTOM_BRIGHTNESS_CURVE: If set, disable support for custom brightness curves
         */