From: Hamza Mahfooz Date: Thu, 26 Oct 2023 15:50:45 +0000 (-0400) Subject: drm/amd/display: fix S/G display enablement X-Git-Tag: v6.7-rc1~145^2^2~7 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1efdd37cc015ed1cade8c1c12227ad25ebb17c77;p=thirdparty%2Fkernel%2Flinux.git drm/amd/display: fix S/G display enablement An assignment statement was reversed during a refactor which effectively disabled S/G display outright. Since, we use adev->mode_info.gpu_vm_support to indicate to the rest of the driver that S/G display should be enabled and currently it is always set to false. So, to fix this set adev->mode_info.gpu_vm_support's value to that of init_data.flags.gpu_vm_support (and not vice versa). Fixes: 098c13079c6f ("drm/amd/display: enable S/G display for for recent APUs by default") Reported-by: Mark Broadworth Tested-by: Mark Broadworth Acked-by: Alex Deucher Reviewed-by: Harry Wentland Reviewed-by: Yifan Zhang Signed-off-by: Hamza Mahfooz Signed-off-by: Alex Deucher --- 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 f08202abab4e9..6f99f6754c119 100644 --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c @@ -1642,7 +1642,7 @@ static int amdgpu_dm_init(struct amdgpu_device *adev) init_data.flags.gpu_vm_support = (amdgpu_sg_display != 0) && (adev->flags & AMD_IS_APU); } - init_data.flags.gpu_vm_support = adev->mode_info.gpu_vm_support; + adev->mode_info.gpu_vm_support = init_data.flags.gpu_vm_support; if (amdgpu_dc_feature_mask & DC_FBC_MASK) init_data.flags.fbc_support = true;