drm/amdgpu: report DC not supported if virtual display is enabled (v2)
authorAlex Deucher <alexander.deucher@amd.com>
Tue, 25 Aug 2020 00:17:30 +0000 (20:17 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 26 Aug 2020 20:40:19 +0000 (16:40 -0400)
Virtual display is non-atomic so report false to avoid checking
atomic state and other atomic things at runtime.

v2: squash into the sr-iov check

Acked-by: Nirmoy Das <nirmoy.das@amd.com>
Acked-by: Guchun Chen <guchun.chen@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c

index 5a948ed..8f37f9f 100644 (file)
@@ -2861,7 +2861,7 @@ bool amdgpu_device_asic_has_dc_support(enum amd_asic_type asic_type)
  */
 bool amdgpu_device_has_dc_support(struct amdgpu_device *adev)
 {
-       if (amdgpu_sriov_vf(adev))
+       if (amdgpu_sriov_vf(adev) || adev->enable_virtual_display)
                return false;
 
        return amdgpu_device_asic_has_dc_support(adev->asic_type);